Interface Stmt

All Superinterfaces:
Indexable, Serializable
All Known Implementing Classes:
AssignLiteral, AssignStmt, Binary, Cast, Catch, Copy, DefinitionStmt, FieldStmt, Goto, If, InstanceOf, Invoke, JumpStmt, LoadArray, LoadField, LookupSwitch, Monitor, New, Nop, Return, StoreArray, StoreField, SwitchStmt, TableSwitch, Throw, Unary

public interface Stmt extends Indexable, Serializable
Representation of statements in Tai-e IR.
  • Method Details

    • getIndex

      int getIndex()
      Specified by:
      getIndex in interface Indexable
      Returns:
      the index of this Stmt in the container IR.
    • setIndex

      void setIndex(int index)
    • getLineNumber

      int getLineNumber()
      Returns:
      the line number of this Stmt in the original source file. If the line number is unavailable, return -1.
    • setLineNumber

      void setLineNumber(int lineNumber)
    • getDef

      Optional<LValue> getDef()
      Returns:
      the (optional) left-value expression defined in this Stmt. In Tai-e IR, each Stmt can define at most one expression.
    • getUses

      Set<RValue> getUses()
      Returns:
      a list of right-value expressions used in this Stmt.
    • canFallThrough

      boolean canFallThrough()
      Returns:
      true if execution after this statement could continue at the following statement, otherwise false.
    • accept

      <T> T accept(StmtVisitor<T> visitor)