Averest


ExprC Type

These are right-hand-side expressions of the MiniC language, i.e., expressions that may occur on the right-hand side of an assignment.

  • RhsVar(vn) is a variable with name vn.
  • ConstB(b) is the Cbool value b as a machine word.
  • ConstN(i) is the Cnat value i as a machine word.
  • ConstZ(i) is the Cint value i as a machine word.
  • Apply1(op1,e) is the application of the unary operator op1 to the MiniC expression e.
  • Apply2(op2,e1,e2) is the application of the binary operator op2 to the MiniC expressions e1 and e2.
  • CndExpr(e0,e1,e2) is a conditional expression that evaluates to e1 if e0 evaluates to true and otherwise it evaluates to e2.
  • FunApp(f,[|e1,...,en|]) is the application of function f to the argument expressions e1,...,en.
  • RhsArrAcc(lhs,e) refers to array element lhs[e].
  • RhsTupAcc(lhs,i) refers to tuple element lhs.i.
  • ArrNew [|e1,...,en|] constructs an array.
  • TupNew [|e1,...,en|] constructs a tuple.

Union cases

Union case Description

Apply1(Ops1, ExprC)

Full Usage: Apply1(Ops1, ExprC)

Parameters:

Item1 : Ops1
Item2 : ExprC

Apply2(Ops2, ExprC, ExprC)

Full Usage: Apply2(Ops2, ExprC, ExprC)

Parameters:

Item1 : Ops2
Item2 : ExprC
Item3 : ExprC

ArrNew ExprC[]

Full Usage: ArrNew ExprC[]

Parameters:

Item : ExprC[]

CndExpr(ExprC, ExprC, ExprC)

Full Usage: CndExpr(ExprC, ExprC, ExprC)

Parameters:

Item1 : ExprC
Item2 : ExprC
Item3 : ExprC

ConstB bool

Full Usage: ConstB bool

Parameters:
    Item : bool

Item : bool

ConstN int

Full Usage: ConstN int

Parameters:
    Item : int

Item : int

ConstZ int

Full Usage: ConstZ int

Parameters:
    Item : int

Item : int

FunApp(string, ExprC[])

Full Usage: FunApp(string, ExprC[])

Parameters:
    Item1 : string
    Item2 : ExprC[]

Item1 : string
Item2 : ExprC[]

RhsArrAcc(LhsExprC, ExprC)

Full Usage: RhsArrAcc(LhsExprC, ExprC)

Parameters:

Item1 : LhsExprC
Item2 : ExprC

RhsTupAcc(LhsExprC, int)

Full Usage: RhsTupAcc(LhsExprC, int)

Parameters:

Item1 : LhsExprC
Item2 : int

RhsVar string

Full Usage: RhsVar string

Parameters:
    Item : string

Item : string

TupNew ExprC[]

Full Usage: TupNew ExprC[]

Parameters:

Item : ExprC[]