Blang/src/lib/Statement/GotoStatement.cpp

32 lines
622 B
C++

#include "Statement/GotoStatement.hpp"
LabelStatement* GotoStatement::getLabel(){
return _Label;
}
const LabelStatement* GotoStatement::getLabel() const{
return getLabel();
}
void GotoStatement::setLabel(LabelStatement* lbl){
_Label = lbl;
}
SourceLocation GotoStatement::getGotoLocation() const{
return _GotoLoc;
}
void GotoStatement::setGotoLocation(SourceLocation loc){
_GotoLoc = loc;
}
SourceLocation GotoStatement::getLabelLocation() const{
if(_Label)
return _Label->getLabelLocation();
}
void GotoStatement::setLabelLocation(SourceLocation loc){
if(_Label)
return _Label->setLabelLocation(loc);
}