Match

sealed case class Match(selector: Tree, cases: List[(List[IntLiteral], Tree)], default: Tree)(tpe: Type)(pos: Position) extends Tree

A break-free switch (without fallthrough behavior). Unlike a JavaScript switch, it can be used in expression position. It supports alternatives explicitly (hence the List[IntLiteral] in cases), whereas in a switch one would use the fallthrough behavior to implement alternatives. (This is not a pattern matching construct like in Scala.)

trait Product
trait Equals
class Tree
class IRNode
class Object
trait Matchable
class Any

Value members

Inherited methods

Inherited from
Product
def show: String
Inherited from
IRNode

Concrete fields

val tpe: Type

Implicits

Implicits

implicit val pos: Position