Skip to content

List of types

You write the program body as a class (the shape of a program). Otherwise, when you define your own type, you use one of struct, record, enum, interface, or union. Apart from a static class that holds methods (Extension methods), class is supported for declaration only; creating one or reading and writing it errors (struct and record).

PageForms that compileForms that don’t compileContents
Primitive types51
Arrays5319An array holds a fixed number of values of the same type, decided in advance.
Enums74
struct and record369
Tuples104
union (sum type)84A union is a base declared with abstract record, together with the record types that inherit from it.
Generics2911
Interfaces239