Package gw.lang.ir.statement
Class IRSwitchStatement
java.lang.Object
gw.lang.ir.IRElement
gw.lang.ir.IRStatement
gw.lang.ir.statement.IRSwitchStatement
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final boolean
private List<IRCaseClause>
private List<IRStatement>
private IRStatement
-
Constructor Summary
ConstructorsConstructorDescriptionIRSwitchStatement
(IRStatement init, List<IRCaseClause> cases, List<IRStatement> defaultStatements, boolean areLabelsConstant) -
Method Summary
Methods inherited from class gw.lang.ir.IRStatement
getOriginalSourceStatement, setOriginalSourceStatement
Methods inherited from class gw.lang.ir.IRElement
getLineNumber, getParent, isImplicit, maybeEraseStructuralSymbolTypes, maybeEraseStructuralType, maybeEraseStructuralType, maybeEraseStructuralTypes, setImplicit, setLineNumber, setParent, setParentToThis
-
Field Details
-
_areLabelsConstant
private final boolean _areLabelsConstant -
_init
-
_cases
-
_defaultStatements
-
-
Constructor Details
-
IRSwitchStatement
public IRSwitchStatement(IRStatement init, List<IRCaseClause> cases, List<IRStatement> defaultStatements, boolean areLabelsConstant)
-
-
Method Details
-
getInit
-
areLabelsConstant
public boolean areLabelsConstant() -
getCases
-
getDefaultStatements
-
getLeastSignificantTerminalStatement
The switch statement has a non-null terminal stmt iff: 1) There are no case stmts or all the the case stmts have non-break terminator and 2) The default stmt exists and has a non-break terminator- Specified by:
getLeastSignificantTerminalStatement
in classIRStatement
-