5 ms·
I will definitely give it a try. Even after many years of not using terralang I still cannot forget what a good of an idea it is. Nelua seems like a more prag
by 6d65 5y ago
I will definitely give it a try.
Even after many years of not using terralang I still cannot forget what a good of an idea it is.
Nelua seems like a more pragmatic implementation of similar ideas, but generates C code instead of embedding the llvm. And doesn't generate code at runtime. But still, things like ecotypes should be possible.
It will be interesting to play with the compile time lua scripting. Also, as mentioned in the other comments not sure about the GC. But there seems to be a manual memory management option.
But still, looks great, kudos to the author, keep up the great work.
PS: If I would implemented it, I would deviate a bit from Lua and replace local with let. It's highly subjective but I think it would make code "prettier"(whatever that means)
- scythe 5y agoAs long as we're bikeshedding, I've often thought that Lua should warm up to using `my` as a keyword in place of `local`. `let` doesn't convey that it's a scope keyword (LISP heritage notwithstanding), while `local` is long and `loc` is an eyesore.
- 6d65 5y agoEyesore is a precise word for the local keyword, from what I see the variable names in scripts are usually short, and the local keyword seems to draw more attention than the variable names themselves. Of course this can be alleviated with syntax highlighting that would slightly mute the local keyword. And, people using Lua they day probably learn to ignore the keyword automatically.
- 6d65 5y agoBy ecotypes i meant exotypes(see https://cs.stanford.edu/~zdevito/pldi083-devito.pdf https://cs.stanford.edu/~zdevito/pldi083-devito.pdf)
- stephen82 5y ago> PS: If I would implemented it, I would deviate a bit from Lua and replace local with let. It's highly subjective but I think it would make code "prettier"(whatever that means) The idea behind it is to have the lowest syntax barrier possible for Lua developers so they can migrate from Lua to Nelua without a sweat.
- 6d65 5y agoYep, it makes sense. With the popularity of Roblox with the young people, and it using Lua for scripting, Lua can see a renaissance of some sorts.
- mst 5y agoCould you macro up an alias if you wanted to?
- edubart 5y agoYou could change the language grammar through the preprocessor to accept "let" as an alias for "local". But I recommend people get used to Lua syntax because the metaprogramming will be done in Lua anyway, thus both programming and metaprogramming contexts have similar syntax.