Hello again!
I keep making detailed proposals for things where I either missed something or there's a good reason it can't work.
So I figured I should just do a rapid fire list and then things can easily be shot down without wasted effort.
If any of these strike you as potentially worth including, I can make a full proposal with pros/cons/considerations.
- Making
= optional in the definition of functions (or giving it a specific error message). Embarrassing to say but out of everything in the language, accidentally forgetting the = was what most tripped me up when I started writing Juniper.
- A
constraint keyword e.g. constraint ConstrainedType = { field : uint8 }, which would allow writing fun myExample(arg : a) : b where a : ConstrainedType.
- Inline type annotation e.g.
(float)0.0, allowing distinguishing between polymorphic constrained values, like the two floating-point types.
- Function overloading, which I believe is allowed in C++ already.
- Module extensions, e.g.
extends module List.
- Full dependent types
- Unique types
- Linear types
f and d suffixes for floating point literals.
- A non-sized (linked?) list type
- String interpolation e.g.
let a = 10u32; "Value: \(a)" that compiles to use snprintf.
Hello again!
I keep making detailed proposals for things where I either missed something or there's a good reason it can't work.
So I figured I should just do a rapid fire list and then things can easily be shot down without wasted effort.
If any of these strike you as potentially worth including, I can make a full proposal with pros/cons/considerations.
=optional in the definition of functions (or giving it a specific error message). Embarrassing to say but out of everything in the language, accidentally forgetting the=was what most tripped me up when I started writing Juniper.constraintkeyword e.g.constraint ConstrainedType = { field : uint8 }, which would allow writingfun myExample(arg : a) : b where a : ConstrainedType.(float)0.0, allowing distinguishing between polymorphic constrained values, like the two floating-point types.extends module List.fanddsuffixes for floating point literals.let a = 10u32; "Value: \(a)"that compiles to usesnprintf.