UnionUtils

org.encalmo.utils.UnionUtils
object UnionUtils

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
UnionUtils.type

Members list

Value members

Concrete methods

def isUnion[A](using evidence$1: Type[A], Quotes): Boolean

Check if a type is a union.

Check if a type is a union.

Attributes

def transformToMatchExpression[In](label: Expr[String], valueExpr: Expr[In], functionExpr: [A] => (x$1: Expr[String], x$2: Expr[A]) => Type[A] ?=> Expr[Any])(using evidence$1: Type[In], quotes: Quotes): Expr[Unit]

Visit an union and create a pattern match expression of each union type.

Visit an union and create a pattern match expression of each union type.

Attributes

Returns

Unit

def transformToMatchTerm(using cache: StatementsCache)[In : Type](label: String, valueTerm: cache.quotes.reflect.Term, functionExpr: [A] => (x$1: String, x$2: cache.quotes.reflect.Term) => Type[A] ?=> cache.quotes.reflect.Term): cache.quotes.reflect.Term

Visit an union and create a pattern match term of each union type.

Visit an union and create a pattern match term of each union type.

Attributes

Returns

Unit