O object

ConstSeq

extends Object with Serializable

Literal sequence of literal constant value expressions

Supertypes

Object, Serializable

Members

def 

unapply

[T] ( expr: Expr[Seq[T]] ) ( implicit  qctx: QuoteContext ) : Option[Seq[T]]

Matches literal sequence of literal constant value expressions and return a sequence of values.

Usage:

Matches literal sequence of literal constant value expressions and return a sequence of values.

Usage:

inline def sum(args: Int*): Int = ${ sumExpr('args) }
def sumExpr(argsExpr: Expr[Seq[Int]])(usingusing QuoteContext): Expr[Int] = argsExpr match
  case ConstSeq(args) =>
    // args: Seq[Int]
    ...
}