Closed wilberton closed 4 years ago
Appreciate you taking the time to try out the language, and thanks for the feedback, definitely helpful!
1+2. I hear you. I'm trying to find the right balance between good parser error recovery and not bothering users about whitespace issues. Once the language server is ready (#14) we should get a better idea of how to make this trade-off. If I do end up dropping the whitespace requirement, multi-line comments+single line ifs should be easy to support. 3+4+6. Correct, these are on the roadmap. Lambda functions should be fairly straightforward (mostly just parser changes and making sure that we can still recover from errors), closures are harder and won't be added for a while: some more thought around memory management/closure lifetimes is needed.
I've filed #16 to outline what I'm looking for in terms of contributions, let me know if you see anything that you'd be interested in helping out with.
I've got one more: type names - I really prefer i8, u8, i16, u16, f32, f64 etc. I think it fits the data oriented philosophy well, plus I like being explicit about what my code is doing. I'm still getting used to inferred return types, I find them quite nice when writing code, but find they make it harder to read unfamiliar code because I need to look much further to figure out what something is doing.
Both are fair points.
I wonder what you (and others) think of the following counter argument though. Primitives in Muon are well defined; the only thing that one must remember is short == 16 bits, int == 32 bits and long == 64 bits. Learning the above mapping is a minuscule amount of effort required on the part of the programmer, considering all the things one must learn to become proficient in a language. On the upside, types like int, long, etc. are easier to mentally parse. i32, i64, etc. feel a tiny bit noisier to me, especially in the context of a declaration, e.g.:
count i32, capacity i32, capacityMask u32
vs
count int, capacity int, capacityMask uint
After having paid the upfront cost of fully internalizing the above mapping, I think I can read/understand the second line a tiny bit quicker.
Closing, feel free to reopen if needed.
Ok, so I've spent a few evenings toying around with the language and hacking on the compiler and here's a summary of my thoughts.
Firstly, on the whole I think the language is very well designed. It strikes just the right balance for me between simplicity and expressiveness. There are a few things I'd like to see that I think would improve it, but there are certainly no egregious design decisions that would immediately turn me away. I'm a game developer, so my use cases are mostly around writing games, or tools for games. My ideal language would be something like C99, but with the addition of generics, sane function pointer syntax, lambdas, no makefile nonsense and fast compile times. Muon seems to be tantalizingly close.
The main pain points I've hit with muon so far are:
if x {blah}
was allowed, that would be good too.So yeah, hopefully that's helpful feedback. Also I would be happy to contribute if you're looking for people to help.