top | up | prev | next

AliasDeclarationNode Class

Definition at line 31 of Declaration.hpp

Constructors

AliasDeclarationNode()
AliasDeclarationNode(const Span& span_, const std::u32string& id_, Node* typeExpr_)

Member Functions

void Accept(Visitor& visitor) override
const std::u32string& Id() const
void Read(Reader& reader) override
Node* TypeExpr()
void Write(Writer& writer) override

Member Variables

std::u32string id
std::unique_ptr<Node> typeExpr

Constructor Details

AliasDeclarationNode Constructor

sngcpp::ast::AliasDeclarationNode::AliasDeclarationNode()

Definition at line 52 of Declaration.cpp :
 52 : Node(NodeType::aliasDeclarationNode)
 53 {
 54 }


Declaration at line 34 of Declaration.hpp


AliasDeclarationNode Constructor

sngcpp::ast::AliasDeclarationNode::AliasDeclarationNode(const Span& span_, const std::u32string& id_, Node * typeExpr_)

Definition at line 56 of Declaration.cpp :
 56 : Node(NodeType::aliasDeclarationNodespan_)id(id_)typeExpr(typeExpr_)
 57 {
 58 }


Declaration at line 35 of Declaration.hpp


Member Function Details

Accept Member Function

void sngcpp::ast::AliasDeclarationNode::Accept(Visitor & visitor) override

Definition at line 60 of Declaration.cpp :
 61 {
 62     visitor.Visit(*this);
 63 }


Declaration at line 36 of Declaration.hpp

Base class overridden functions: sngcpp::ast::Node::Accept

Calls: sngcpp::ast::Visitor::Visit


Id Member Function

const std::u32string& sngcpp::ast::AliasDeclarationNode::Id() const

Definition at line 39 of Declaration.hpp :
 39 { return id; }


Read Member Function

void sngcpp::ast::AliasDeclarationNode::Read(Reader & reader) override

Definition at line 72 of Declaration.cpp :
 73 {
 74     Node::Read(reader);
 75     id = reader.GetBinaryReader().ReadUtf32String();
 76     typeExpr.reset(reader.ReadNode());
 77 }


Declaration at line 38 of Declaration.hpp

Base class overridden functions: sngcpp::ast::Node::Read

Calls: sngcpp::ast::Node::Read , sngcpp::ast::Reader::GetBinaryReader , sngcpp::ast::Reader::ReadNode


TypeExpr Member Function

Node * sngcpp::ast::AliasDeclarationNode::TypeExpr()

Definition at line 40 of Declaration.hpp :
 40 { return typeExpr.get(); }


Write Member Function

void sngcpp::ast::AliasDeclarationNode::Write(Writer & writer) override

Definition at line 65 of Declaration.cpp :
 66 {
 67     Node::Write(writer);
 68     writer.GetBinaryWriter().Write(id);
 69     typeExpr->Write(writer);
 70 }


Declaration at line 37 of Declaration.hpp

Base class overridden functions: sngcpp::ast::Node::Write

Calls: sngcpp::ast::AliasDeclarationNode::Write , sngcpp::ast::Node::Write , sngcpp::ast::Writer::GetBinaryWriter

Called by: sngcpp::ast::AliasDeclarationNode::Write


top | up | prev | next