public class SwitchBlock_c extends AbstractBlock_c implements SwitchBlock
SwitchBlock
is a list of statements within a switch.Term.Instance
statements
exceptions, reachable
Constructor and Description |
---|
SwitchBlock_c(Position pos,
java.util.List<Stmt> statements) |
SwitchBlock_c(Position pos,
java.util.List<Stmt> statements,
Ext ext) |
Modifier and Type | Method and Description |
---|---|
Node |
copy(NodeFactory nf)
Produce a copy of this node using the given NodeFactory.
|
Context |
enterScope(Context c)
A
SwitchBlock differs from a normal block in that
declarations made in the context of the switch block are in the scope
following the switch block. |
acceptCFG, append, firstChild, prepend, prettyPrint, reconstruct, statements, statements, statements, toString, visitChildren
exceptionCheck, exceptions, exceptions, exceptions, extRewrite, listChild, reachable, reachable, reachable
addDecls, buildTypes, buildTypesEnter, checkConstants, childExpectedType, copy, copy, copyIfNeeded, del, del, disambiguate, disambiguateEnter, disambiguateOverride, dump, dump, dump, dump, dump, enterChildScope, error, error, error, exceptionCheckEnter, ext, ext, ext, ext, extRewriteEnter, isDisambiguated, isTypeChecked, lang, position, position, position, prettyPrint, prettyPrint, prettyPrint, prettyPrint, print, printBlock, printSubStmt, throwTypes, translate, typeCheck, typeCheckEnter, typeCheckOverride, visit, visitChild, visitEdge, visitList
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
append, prepend, statements, statements
exceptions, exceptions, reachable, reachable
del, del, dump, error, error, ext, ext, ext, ext, isDisambiguated, isTypeChecked, position, position, visit, visitEdge
addDecls, buildTypes, buildTypesEnter, checkConstants, childExpectedType, copy, disambiguate, disambiguateEnter, disambiguateOverride, dump, dump, dump, dump, enterChildScope, exceptionCheck, exceptionCheckEnter, extRewrite, extRewriteEnter, lang, prettyPrint, prettyPrint, prettyPrint, prettyPrint, prettyPrint, throwTypes, translate, typeCheck, typeCheckEnter, typeCheckOverride, visitChild, visitChildren, visitList
public Context enterScope(Context c)
SwitchBlock
differs from a normal block in that
declarations made in the context of the switch block are in the scope
following the switch block. For example
switch (i) { case 0: int i = 4; case 1: // i is in scope, but may not have been initialized. ... }
enterScope
in interface NodeOps
enterScope
in class AbstractBlock_c
c
- the current Context
Context
to be used for visiting this node.