trait Kinds extends AnyRef
- Alphabetic
- By Inheritance
- Kinds
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
abstract
class
Kind extends AnyRef
The data structure describing the kind of a given type.
The data structure describing the kind of a given type.
Proper types are represented using ProperTypeKind.
Type constructors are represented using TypeConKind.
- case class KindErrors(arity: List[SymbolTable.SymPair] = Nil, variance: List[SymbolTable.SymPair] = Nil, strictness: List[SymbolTable.SymPair] = Nil) extends Product with Serializable
- class ProperTypeKind extends SymbolTable.Kind
- class TypeConKind extends SymbolTable.Kind
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- val NoKindErrors: SymbolTable.KindErrors
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
checkKindBounds0(tparams: List[SymbolTable.Symbol], targs: List[SymbolTable.Type], pre: SymbolTable.Type, owner: SymbolTable.Symbol, explainErrors: Boolean): List[(SymbolTable.Type, SymbolTable.Symbol, SymbolTable.KindErrors)]
Check well-kindedness of type application (assumes arities are already checked) -- @M
Check well-kindedness of type application (assumes arities are already checked) -- @M
This check is also performed when abstract type members become concrete (aka a "type alias") -- then tparams.length==1 (checked one type member at a time -- in that case, prefix is the name of the type alias)
Type application is just like value application: it's "contravariant" in the sense that the type parameters of the supplied type arguments must conform to the type parameters of the required type parameters:
- their bounds must be less strict
- variances must match (here, variances are absolute, the variance of a type parameter does not influence the variance of its higher-order parameters)
- @M TODO: are these conditions correct,sufficient&necessary?
e.g. class Iterable[t, m[+x <: t]] --> the application Iterable[Int, List] is okay, since List's type parameter is also covariant and its bounds are weaker than <: Int
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def kindsConform(tparams: List[SymbolTable.Symbol], targs: List[SymbolTable.Type], pre: SymbolTable.Type, owner: SymbolTable.Symbol): Boolean
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- object Kind
- object ProperTypeKind
- object TypeConKind
-
object
inferKind
Starting from a Symbol (sym) or a Type (tpe), infer the kind that classifies it (sym.tpeHK/tpe).