Constructor and Description |
---|
ThrowNode(int lineNumber,
long token,
int finish,
Expression expression,
boolean isSyntheticRethrow)
Constructor
|
Modifier and Type | Method and Description |
---|---|
Node |
accept(NodeVisitor<? extends LexicalContext> visitor)
Assist in IR navigation.
|
<R> R |
accept(TranslatorNodeVisitor<? extends LexicalContext,R> visitor)
Provides a means to navigate the IR.
|
Expression |
getExpression()
Get the expression that is being thrown by this node
|
boolean |
isCompletionValueNeverEmpty() |
boolean |
isSyntheticRethrow()
Is this a throw a synthetic rethrow in a synthetic catch-all block created when inlining
finally statements? In that case we never wrap whatever is thrown into an ECMAException, just
rethrow it.
|
boolean |
isTerminal()
Is this a terminal statement, i.e.
|
ThrowNode |
setExpression(Expression expression)
Reset the expression being thrown by this node
|
void |
toString(StringBuilder sb,
boolean printType)
Print logic that decides whether to show the optimistic type or not - for example it should
not be printed after just parse, when it hasn't been computed, or has been set to a trivially
provable value
|
getLineNumber, hasGoto, hasTerminalFlags
clone, equals, getFinish, getSourceOrder, getStart, getToken, hashCode, isAssignment, isLoop, isTokenType, tokenType, toString, toString
public ThrowNode(int lineNumber, long token, int finish, Expression expression, boolean isSyntheticRethrow)
lineNumber
- line numbertoken
- tokenfinish
- finishexpression
- expression to throwisSyntheticRethrow
- true if this throw node is part of a synthetic rethrow.public boolean isTerminal()
Statement
isTerminal
in interface Terminal
isTerminal
in class Statement
public Node accept(NodeVisitor<? extends LexicalContext> visitor)
public <R> R accept(TranslatorNodeVisitor<? extends LexicalContext,R> visitor)
Node
public void toString(StringBuilder sb, boolean printType)
Node
public Expression getExpression()
public ThrowNode setExpression(Expression expression)
expression
- new expressionpublic boolean isSyntheticRethrow()
public boolean isCompletionValueNeverEmpty()
isCompletionValueNeverEmpty
in class Statement
empty