Tangent: I wish the Amulet project would have gotten more momentum to keep going as a compile-to-Lua option. LunarML seems to still be chipping away though.
Past the “import” statement, the “An Overview of YueScript” (the first sub-section of the Introduction) shows new language additions. I compared them recently on my microblog entry “Yuescript first impressions”:
I just discovered Yuescript, which is like MoonScript with more features. I have mixed feelings.
I like features like pipelines (much cleaner than repeated assignment or nested parentheses in function calls) and compile-time macros. The sugar for multiple and destructuring assignment is handy.
I find the additional operators unnecessary, and not worth their cognitive overhead. The ? operator was already used as sugar for a parameter-free function call. The [] operator could easily have been a function in a library instead.
One of the trade-offs for this much syntactic sugar is some syntactic ambiguity. An opinionated formatter could resolve some of this.
Tangent: I wish the Amulet project would have gotten more momentum to keep going as a compile-to-Lua option. LunarML seems to still be chipping away though.
The link doesn’t explain how the project is different from MoonScript, which also compiles to Lua, or in what way it’s a “dialect”. Does anyone know?
Past the “import” statement, the “An Overview of YueScript” (the first sub-section of the Introduction) shows new language additions. I compared them recently on my microblog entry “Yuescript first impressions”: