Comment Comment by revskill One of most frequent usage of a type system is literal types.Haskell, Rust,... and modern programming languages fail to do it. The only exception is Typescript.For example, simple way to adding a extended boolean type:type MyBoolean = null | true | false.Ortype MyRange = 3 | 4 | 5Curious. parent revskill 3 years ago
Haskell, Rust,... and modern programming languages fail to do it. The only exception is Typescript.
For example, simple way to adding a extended boolean type:
type MyBoolean = null | true | false.
Or
type MyRange = 3 | 4 | 5
Curious.