Gregofi / mjolnir

Functional programming language without exotic syntax, written in Rust.
2 stars 0 forks source link

Add Generics #4

Closed Gregofi closed 6 months ago

Gregofi commented 7 months ago

Add generic types, allow things like enum List[T] { Nil, Cons(T, List[T]) }.

Investigate how other languages without inheritance do with generics, for example Haskell. Because, as of now, we would just use them for containers. Function could have generic types, but they would not be able to do anything with them, since the type is "Nothing".

For functions we will have traits.