In an attempt to overcome my desire for perfection, I decided to open the source of my long-term project Machete for public viewing. Machete is my own ECMAScript 5 standard dialect or, as it is often called, JavaScript.
Main features
More understandable lambda expressions
var succinct = \(x, y) x + y; var verbose = function (x, y) { return x + y; };
Iteration support with foreach loop and generators
var numbers = generator { yield1; yield2; yield3; }; foreach (var n in numbers) { Output.write(n); } foreach (var e in ["Array", " objects", " are", " iterable", "!"]) { Output.write(e); } foreach (var ch in"Strings are iterable!") { Output.write(ch); }
Implementation
the compiler is written in F # using the FParsec library
the runtime environment is written in C # and is managed by .NET
There are currently more than 400 tests, and many more are being developed.
Machete is the product of several years of research, design and programming. I posted it on github, so please come in and fork the project. I would really like to increase the number of tests and tests from the community would be invaluable. ')
Repository Link: GitHub Repository For Machete