TypeMatchModule

scala.quoted.runtime.QuoteMatching.TypeMatchModule

Attributes

Source
QuoteMatching.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
TypeMatch.type

Members list

Value members

Abstract methods

def unapply[TypeBindings, Tup <: Tuple](scrutinee: Type[_ <: AnyKind])(using pattern: Type[_ <: AnyKind]): Option[Tup]

Pattern matches an the scrutineeType against the patternType and returns a tuple with the matched holes if successful.

Pattern matches an the scrutineeType against the patternType and returns a tuple with the matched holes if successful.

Value parameters

pattern

Type[?] containing the pattern tree

scrutinee

Type[?] on which we are pattern matching

Attributes

Returns

None if it did not match, Some(tup) if it matched where tup contains `Type[Ti]``

Source
QuoteMatching.scala