[ANN] Luam: A minimalist, procedural Lua dialect for CAD (Luametry)‏

Ben Sivan <[email protected]>
Newsgroups gmane.comp.lang.lua.general
Message-ID <CAC1hj9CppCjPgOqQV0VZui+NmP2XJYAk7_wraUbgcPkR6PFMnQ@mail.gmail.com>
Hello everyone,

I’ve been working on a project called *Luam*, a dialect of Lua designed for
high-performance procedural workflows. To demonstrate its utility, I’ve
built *Luametry*, a parametric CAD tool that leverages the Manifold library
for 3D geometry generation.

As a long-time admirer of Lua’s minimalism, my goal with Luam was to
further constrain the language for a specific domain. In many ways, Luam is
a "subtractive" dialect; I found that by removing certain features and
standardizing others, I could create a more predictable environment for 3D
modeling.

Key design choices in *Luam* include:

   -

   *Strict Procedural API:* I have removed standard OOP features and
   metatable-based "classes" to enforce a consistent, flat procedural style
   that maps cleanly to the underlying C++ geometry engine.
   -

   *Boolean Strictness:* To eliminate ambiguity in complex CAD logic, I’ve
   removed nil as a truthy/falsy value in conditionals, requiring explicit
   boolean evaluations.
   -

   *Syntactic Simplification:* I’ve removed multiline comments to keep the
   lexer and scripts as simple as possible, while adding modern multiline
   string support for data embedding.
   -

   *Local by Default:* To prevent accidental global state leakage in
   large-scale procedural assemblies, variables are scoped locally by default.
   -

   *Enhanced REPL:* Improved the interactive experience with native cursor
   navigation and line editing, moving away from the standard ^D character
   echoes.

The intent is to provide a "safety-first" environment for users focused on
generating 3D data, where the side effects of global variables or complex
object hierarchies can lead to unexpected geometry errors.

I would be very interested to hear the community’s thoughts on this
approach to domain-specific simplification.

*Luam Core:* https://github.com/BenSiv/luam
<https://www.google.com/search?q=https://github.com/BenSiv/luam>

*Luametry (CAD implementation):* https://github.com/BenSiv/luametry

Thank you to the Lua team and this community for providing such an elegant
foundation.

Best regards,

Ben Sivan

-- 
You received this message because you are subscribed to the Google Groups "lua-l" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion visit https://groups.google.com/d/msgid/lua-l/CAC1hj9CppCjPgOqQV0VZui%2BNmP2XJYAk7_wraUbgcPkR6PFMnQ%40mail.gmail.com.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.