News for hackers. Stuff that matters.
Re:Uniform Structured Syntax, Metaprogramming and Run-Time C... by Veedrac on Wednesday June 19, 2019 @09:39AM (#20223210)
The point my first comment made is that you don't need to analyse a query at runtime, you just need to provide functions. I will agree again that Lisp makes REPLs easier to write than does C++, but a CL with Lua syntax could still, just as easily, provide functions and expose a REPL. It's the same solution, just without the unjustified AST transformations.
Re:Uniform Structured Syntax, Metaprogramming and Run-Time C... by m00natic on Wednesday June 19, 2019 @11:08AM (#20224026)
How can you provide a REPL language without analyzing it at runtime? Write Lua random syntax in the REPL? Not a great improvement over C++. Not to mention that you'll probably use something like `eval` which is not compilation thus inferior.

By the way, even your original example - I can't see how it can work honestly. How can you identify fields through (lambda) parameter names only (no mention of types either)? Probably the least boilerplate-heavy solution would be stringly typed.

Re:Uniform Structured Syntax, Metaprogramming and Run-Time C... by Veedrac on Wednesday June 19, 2019 @02:49PM (#20226096)
A Lua REPL is hardly worse than a Lisp one.

> something like `eval` which is not compilation thus inferior

I honestly don't know what that means. Turning text into code is compilation; there is no difference between the two in that regard, except perhaps that in the Lisp DSL case it's more manual.

> How can you identify fields through (lambda) parameter names only (no mention of types either)?

Not familiar enough with Lua, but in Python you just use keyword arguments.