top | up | prev | next

AssignmentStatementNode Class

Definition at line 319 of Statement.hpp

Constructors

AssignmentStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_)
AssignmentStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node* targetExpr_, Node* sourceExpr_)

Member Functions

void Accept(Visitor& visitor) override
Node* Clone(CloneContext& cloneContext) const override
void Read(AstReader& reader) override
const Node* SourceExpr() const
Node* SourceExpr()
const Node* TargetExpr() const
Node* TargetExpr()
void Write(AstWriter& writer) override

Member Variables

std::unique_ptr<Node> sourceExpr
std::unique_ptr<Node> targetExpr

Constructor Details

AssignmentStatementNode Constructor

sngcm::ast::AssignmentStatementNode::AssignmentStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_)

Definition at line 655 of Statement.cpp :
 655 :
 656 StatementNode(NodeType::assignmentStatementNodespan_moduleId_)targetExpr()sourceExpr()
 657 {
 658 }


Declaration at line 322 of Statement.hpp


AssignmentStatementNode Constructor

sngcm::ast::AssignmentStatementNode::AssignmentStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node * targetExpr_, Node * sourceExpr_)

Definition at line 660 of Statement.cpp :
 660 :
 661 StatementNode(NodeType::assignmentStatementNodespan_moduleId_)targetExpr(targetExpr_)sourceExpr(sourceExpr_)
 662 {
 663     targetExpr->SetParent(this);
 664     sourceExpr->SetParent(this);
 665 }


Declaration at line 323 of Statement.hpp


Member Function Details

Accept Member Function

void sngcm::ast::AssignmentStatementNode::Accept(Visitor & visitor) override

Definition at line 673 of Statement.cpp :
 674 {
 675     visitor.Visit(*this);
 676 }


Declaration at line 325 of Statement.hpp

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

Calls: sngcm::ast::Visitor::Visit


Clone Member Function

Node * sngcm::ast::AssignmentStatementNode::Clone(CloneContext & cloneContext) const override

Definition at line 667 of Statement.cpp :
 668 {
 669     AssignmentStatementNode* clone = new AssignmentStatementNode(GetSpan()ModuleId()targetExpr->Clone(cloneContext)sourceExpr->Clone(cloneContext));
 670     return clone;
 671 }


Declaration at line 324 of Statement.hpp

Base class overridden functions: sngcm::ast::Node::Clone

Calls: sngcm::ast::AssignmentStatementNode::Clone , sngcm::ast::Node::GetSpan , sngcm::ast::Node::ModuleId

Called by: sngcm::ast::AssignmentStatementNode::Clone


Read Member Function

void sngcm::ast::AssignmentStatementNode::Read(AstReader & reader) override

Definition at line 685 of Statement.cpp :
 686 {
 687     StatementNode::Read(reader);
 688     targetExpr.reset(reader.ReadNode());
 689     targetExpr->SetParent(this);
 690     sourceExpr.reset(reader.ReadNode());
 691     sourceExpr->SetParent(this);
 692 }


Declaration at line 327 of Statement.hpp

Base class overridden functions: sngcm::ast::Node::Read , sngcm::ast::StatementNode::Read

Calls: sngcm::ast::AstReader::ReadNode , sngcm::ast::Node::SetParent , sngcm::ast::StatementNode::Read


SourceExpr Member Function

const Node * sngcm::ast::AssignmentStatementNode::SourceExpr() const

Definition at line 330 of Statement.hpp :
330 { return sourceExpr.get(); }


SourceExpr Member Function

Node * sngcm::ast::AssignmentStatementNode::SourceExpr()

Definition at line 331 of Statement.hpp :
331 { return sourceExpr.get(); }

Called by: sngcm::ast::SourceWriter::Visit


TargetExpr Member Function

const Node * sngcm::ast::AssignmentStatementNode::TargetExpr() const

Definition at line 328 of Statement.hpp :
328 { return targetExpr.get(); }


TargetExpr Member Function

Node * sngcm::ast::AssignmentStatementNode::TargetExpr()

Definition at line 329 of Statement.hpp :
329 { return targetExpr.get(); }

Called by: sngcm::ast::SourceWriter::Visit


Write Member Function

void sngcm::ast::AssignmentStatementNode::Write(AstWriter & writer) override

Definition at line 678 of Statement.cpp :
 679 {
 680     StatementNode::Write(writer);
 681     writer.Write(targetExpr.get());
 682     writer.Write(sourceExpr.get());
 683 }


Declaration at line 326 of Statement.hpp

Base class overridden functions: sngcm::ast::Node::Write , sngcm::ast::StatementNode::Write

Calls: sngcm::ast::StatementNode::Write


top | up | prev | next