I’ve been working on this language for about 4 months now. While not “complete”, it does have a number of nice features like virtual functions, type inference, etc.
I reckon it will not be truly useful until GC is added, and that’s what I’m currently working on.
Any feedback is welcome and appreciated!
2) The type-checker is fairly ad-hoc, and I admittedly didn't look much into the literature here. The general idea is that since variable/function/class field types are explicitly typed, every expression can be checked for violating it's expected type. Implementation-wise, this is facilitated using the visitor pattern [1]. For certain expressions, some extra flexibility is allowed - for example, assigning an object of a child class to a variable of the parent class is not a type error.
[1] https://github.com/neeilan/neeilang/blob/master/src/type-che...
Check out Dylan, a high performance dynamic language that compiles to LLVM. Check out this example:
https://opendylan.org/documentation/intro-dylan/multiple-dis...
This is how to do it: https://en.wikipedia.org/wiki/C3_linearization
Gives the language powerful uniqueness feature that the 'mainstream' languages don't have.
By feature set it looks close to D lang so asking.
Yet, have you considered to implement TypeScript instead?
Having native compiler of TS (or at least subset of it) would be beneficial.
I think implementing TypeScript natively would be a very interesting project, but the 'all valid JavaScript is valid TypeScript' part of the spec means you're also implementing an AOT JS compiler, which is much more challenging.