Dotty Documentation

0.10.0-bin-SNAPSHOT

object ValueClasses
extends Object

Methods that apply to user-defined value classes

[-] Constructors

[-] Members

[+] def evt2u ( cls: ClassSymbol ) ( implicit ctx: Context ) : Symbol

For a value class d, this returns the synthetic cast from ErasedValueType to the underlying type defined in the companion module. This method is added to the module and further described in [[ExtensionMethods]].

[+] def isCyclic ( cls: ClassSymbol ) ( implicit ctx: Context ) : Boolean

Whether a value class wraps itself

[+] def isDerivedValueClass ( sym: Symbol ) ( implicit ctx: Context ) : Boolean
[+] def isMethodWithExtension ( sym: Symbol ) ( implicit ctx: Context ) : Boolean
[+] def u2evt ( cls: ClassSymbol ) ( implicit ctx: Context ) : Symbol

For a value class d, this returns the synthetic cast from the underlying type to ErasedValueType defined in the companion module. This method is added to the module and further described in [[ExtensionMethods]].

[+] def underlyingOfValueClass ( sym: ClassSymbol ) ( implicit ctx: Context ) : Type

The unboxed type that underlies a derived value class

[+] def valueClassUnbox ( cls: ClassSymbol ) ( implicit ctx: Context ) : Symbol

The member of a derived value class that unboxes it.