AST
node type EnhancedForStmt

General Info

Production
EnhancedForStmt : BranchTargetStmt ::= VariableDeclaration Expr Stmt;
Type Hierarchy:
java.lang.Object
  extended by beaver.Symbol
      extended by AST.ASTNode<ASTNode>
          extended by AST.Stmt
              extended by AST.BranchTargetStmt
                  extended by AST.EnhancedForStmt
All Implemented Interfaces:
BranchPropagation, VariableScope, java.lang.Cloneable, java.lang.Iterable<ASTNode>

Description

Source
Declared in Java1.5Frontend/EnhancedFor.ast at line 1

Member Filters

API level:

Aspect:

Constructors

 

Attributes

syn SimpleSet localLookupVariable(java.lang.String name)
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 50
Aspect
EnhancedFor
syn boolean targetOf(ContinueStmt stmt)
Specified by:targetOf in interface BranchPropagationSpecified by:targetOf in class BranchTargetStmt
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 75
Aspect
EnhancedFor
syn boolean targetOf(BreakStmt stmt)
Specified by:targetOf in interface BranchPropagationSpecified by:targetOf in class BranchTargetStmt
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 76
Aspect
EnhancedFor
syn boolean canCompleteNormally()
Overrides:canCompleteNormally in class Stmt
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 79
Aspect
EnhancedFor
syn boolean isDAafter(Variable v)
Overrides:isDAafter in class Stmt
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 83
Aspect
EnhancedFor
syn boolean isDUafter(Variable v)
Overrides:isDUafter in class Stmt
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 99
Aspect
EnhancedFor
syn boolean continueLabel()
Overrides:continueLabel in class Stmt
Source
Declared in Java1.4Frontend/NameCheck.jrag at line 401
Aspect
NameCheck
syn int cond_label()
Source
Declared in Java1.5Backend/EnhancedForCodegen.jrag at line 12
Aspect
EnhancedForToBytecode
syn int update_label()
Source
Declared in Java1.5Backend/EnhancedForCodegen.jrag at line 13
Aspect
EnhancedForToBytecode
syn int end_label()
Source
Declared in Java1.5Backend/EnhancedForCodegen.jrag at line 14
Aspect
EnhancedForToBytecode
syn int extraLocalIndex()
Source
Declared in Java1.5Backend/EnhancedForCodegen.jrag at line 16
Aspect
EnhancedForToBytecode
syn int break_label()
Overrides:break_label in class Stmt
Source
Declared in Java1.4Backend/CreateBCode.jrag at line 1398
Aspect
CreateBCode
syn int continue_label()
Overrides:continue_label in class Stmt
Source
Declared in Java1.4Backend/CreateBCode.jrag at line 1417
Aspect
CreateBCode
syn boolean modifiedInScope(Variable var)
Specified by:modifiedInScope in class Stmt
Source
Declared in Java7Frontend/PreciseRethrow.jrag at line 55
Aspect
PreciseRethrow
inh SimpleSet lookupVariable(java.lang.String name)
Specified by:lookupVariable in interface VariableScopeOverrides:lookupVariable in class Stmt
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 38
Aspect
EnhancedFor

Methods

public void flushCache()
Overrides:flushCache in class BranchTargetStmt
public EnhancedForStmt clone()
                      throws java.lang.CloneNotSupportedException
Overrides:clone in class BranchTargetStmt
Throws:
java.lang.CloneNotSupportedException
Overrides:copy in class ASTNode<ASTNode>
Create a deep copy of the AST subtree at this node. The copy is dangling, i.e. has no parent.
Overrides:fullCopy in class ASTNode<ASTNode>
Returns:
dangling copy of the subtree at this node
public void typeCheck()
Overrides:typeCheck in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 15
Aspect
EnhancedFor
public void toString(java.lang.StringBuffer s)
Overrides:toString in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 58
Aspect
EnhancedFor
public void createBCode(CodeGeneration gen)
Overrides:createBCode in class Stmt
Source
Declared in Java1.5Backend/EnhancedForCodegen.jrag at line 24
Aspect
EnhancedForToBytecode
public void init$Children()
Initializes the child array to the correct size. Initializes List and Opt nta children.
Overrides:init$Children in class BranchTargetStmt
protected int numChildren()
Overrides:numChildren in class BranchTargetStmt
public boolean mayHaveRewrite()
Overrides:mayHaveRewrite in class BranchTargetStmt
Replaces the VariableDeclaration child.
Parameters:
node - The new node to replace the VariableDeclaration child.
Retrieves the VariableDeclaration child.
Returns:
The current node used as the VariableDeclaration child.
Retrieves the VariableDeclaration child.

This method does not invoke AST transformations.

Returns:
The current node used as the VariableDeclaration child.
public void setExpr(Expr node)
Replaces the Expr child.
Parameters:
node - The new node to replace the Expr child.
public Expr getExpr()
Retrieves the Expr child.
Returns:
The current node used as the Expr child.
Retrieves the Expr child.

This method does not invoke AST transformations.

Returns:
The current node used as the Expr child.
public void setStmt(Stmt node)
Replaces the Stmt child.
Parameters:
node - The new node to replace the Stmt child.
public Stmt getStmt()
Retrieves the Stmt child.
Returns:
The current node used as the Stmt child.
Retrieves the Stmt child.

This method does not invoke AST transformations.

Returns:
The current node used as the Stmt child.
public SimpleSet Define_SimpleSet_lookupVariable(ASTNode caller,
                                                 ASTNode child,
                                                 java.lang.String name)
Overrides:Define_SimpleSet_lookupVariable in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 41
Overrides:Define_NameType_nameType in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 43
Overrides:Define_VariableScope_outerScope in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 48
public boolean Define_boolean_isMethodParameter(ASTNode caller,
                                                ASTNode child)
Overrides:Define_boolean_isMethodParameter in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 71
public boolean Define_boolean_isConstructorParameter(ASTNode caller,
                                                     ASTNode child)
Overrides:Define_boolean_isConstructorParameter in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 72
Overrides:Define_boolean_isExceptionHandlerParameter in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 73
public boolean Define_boolean_reachable(ASTNode caller,
                                        ASTNode child)
Overrides:Define_boolean_reachable in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 80
public boolean Define_boolean_isDAbefore(ASTNode caller,
                                         ASTNode child,
                                         Variable v)
Overrides:Define_boolean_isDAbefore in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 97
public boolean Define_boolean_isDUbefore(ASTNode caller,
                                         ASTNode child,
                                         Variable v)
Overrides:Define_boolean_isDUbefore in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 111
public boolean Define_boolean_insideLoop(ASTNode caller,
                                         ASTNode child)
Overrides:Define_boolean_insideLoop in class ASTNode<ASTNode>
Source
Declared in Java1.5Frontend/EnhancedFor.jrag at line 113
public int Define_int_localNum(ASTNode caller,
                               ASTNode child)
Overrides:Define_int_localNum in class ASTNode<ASTNode>
Source
Declared in Java1.5Backend/EnhancedForCodegen.jrag at line 18
Overrides:rewriteTo in class BranchTargetStmt

Fields

protected java.util.Map targetOf_ContinueStmt_values
protected java.util.Map targetOf_BreakStmt_values
protected boolean canCompleteNormally_value
protected java.util.Map isDAafter_Variable_values
protected java.util.Map isDUafter_Variable_values
protected boolean cond_label_computed
protected int cond_label_value
protected boolean update_label_computed
protected int update_label_value
protected boolean end_label_computed
protected int end_label_value
protected boolean extraLocalIndex_computed
protected int extraLocalIndex_value

Inherited Members

Attributes inherited from AST.BranchTargetStmt

Attributes inherited from AST.Stmt

Attributes inherited from AST.ASTNode

Methods inherited from class AST.BranchTargetStmt

Methods inherited from class AST.Stmt

Methods inherited from class AST.ASTNode

Methods inherited from class beaver.Symbol

getColumn
getEnd
getId
getLine
getStart
makePosition

Methods inherited from class java.lang.Object

equals
finalize
getClass
hashCode
notify
notifyAll
wait
wait
wait

Methods inherited from interface AST.VariableScope

Fields inherited from AST.BranchTargetStmt

Fields inherited from AST.Stmt

Fields inherited from AST.ASTNode

Fields inherited from beaver.Symbol

end
id
start
value