Block

final case class Block(statements: List[Expr], symbol: Symbol, evalType: Type, promoteToType: Option[Type]) extends Expr

Block of code

Contains zero or more statements

 {
   int x;
   { ... } // <- nested block

   long y = { "alice"; 1 + 2; }; // here last value is returned and assigned to `y`
 }
Value parameters:
statements

Statements included in the block

Companion:
object
trait Serializable
trait Product
trait Equals
class Expr
class Stat
class AST
class Object
trait Matchable
class Any

Value members

Concrete methods

def ++(other: Block): Block
Extension method from Block
def :+(other: AST): Block
Extension method from Block
override def visit[S, R](s: S, v: TreeVisitor[S, R]): Either[Throwable, R]
Definition Classes
override def withPromoteToType(t: Option[Type]): Block
Definition Classes

Inherited methods

def productElementNames: Iterator[String]
Inherited from:
Product
def productIterator: Iterator[Any]
Inherited from:
Product