T/type keyword
T <type name> String s // type variable . String ps // private variable [rationale: dot is used for hidden files and folders in Unix] F (s) // constructor .s = s F get_s_len() // type function R .s.len
[Because
Tand
typeare keywords in 11l, use can use
Tyand
type_nameinstead.]
Type aliases
T Tuple2[T Ty] = Tuple[Ty, Ty]
T/type subkeywords
T.enum/
type.enumis used to declare an enumeration, a distinct type that consists of a set of named constants called the enumerator list.
T.enum TokenCategory NAME KEYWORD CONSTANT TEST_CATEGORY = 10[Enumerators
NAME,
KEYWORDand
CONSTANThave values 0, 1 and 2 respectively.]
T/
typealso has subkeywords
baseand
interface, but they are not supported yet.
Why T/type?