CxStatementFor

Description

sealed class Tinman.Core.Cx.Statements.CxStatementFor

A statement that loops over a body statement zero or more times:

for (int i = 0; i < n; i++)
  a += i;

for (; a < n;)
  ++a;

ICxStatementContainer.Statement returns the body statement of the loop.
ICxVariableContainer.Variable returns the loop variable definition.

Public / Constructors

Cx​Statement​For


public constructor CxStatementFor → (4)

statement in : CxStatement

[not-null]
See ICxStatementContainer.Statement.

condition in : CxExpression

[not-null]
See condition.

variable opt : CxVariable = null

See ICxVariableContainer.Variable.

increment opt : IBagConst<CxExpression> = null

The list of post-iteration expressions or null for an empty list. See Increment.

Creates a new instance of CxStatementFor.

Public / Attributes

Condition


[Constant]
public attribute Condition → (get)

value : CxExpression

[not-null]
The loop condition.

Returns the loop condition.

Increment


[Constant]
public attribute Increment → (get)

value : IVectorConst<CxExpression>

[not-null]
The list of post-iteration expressions.

Returns the expressions to evaluate after each loop iteration.