keid-lang / keid

Central repository for the Keid programming language
0 stars 1 forks source link

Implement metatypes for generic type constraints #73

Open lucasbaizer2 opened 1 year ago

lucasbaizer2 commented 1 year ago

There should be a predefined set of generic type constraints that either cannot be represented using type information with the current syntax. Here are some examples of "metatypes" that should be implemented:

foo<T: Number>, where Number is Add + Subtract + Divide + Multiply + ..., etc. foo<T: ToRef>, any type which can be used in conjunction with ref or deref.