[ANN] Cratera v2.1.0-p1

86 views
Skip to first unread message

Soni "They/Them" L.

unread,
Jun 12, 2024, 11:33:11 AMJun 12
to Lua mailing list
Cratera is a programming language and object system built on Lua. It is
inspired by Elixir, Rust, Java(*), and ofc Lua itself. It attempts to
play to Lua's strengths, that is, metatables, while bringing its own
features to the tables, namely traits. Cratera traits are most similar
to Elixir protocols, while the name is borrowed from Rust.

Traits are a way to group and identify functionality of an object,
similar to Java interfaces, but their biggest feature is how they deal
with name conflicts. For example, method bucket in trait MapBucket (as
would be used to find the bucket for a key in a hashmap) does not
conflict with method bucket in trait Fluid (as would be used to take a
bucket of the fluid).

But perhaps most importantly, if you hit hard at the Lua, it makes a
Cratera.

(Note: This is a pre-release, feedback is welcome. Also the Java
"inspiration" isn't intentional but more of an accident of how
everything works, we have a distinction between primitives (strings,
numbers, bare tables, etc) and objects (cratera objects) and so you
can't use primitives as hashmap keys, tho maybe you should be using bare
tables for those anyway.)

README:
https://soniex2.autistic.space/git-repos/cratera.git/tree/README.md?h=v2.1.0-p1
Tree: https://soniex2.autistic.space/git-repos/cratera.git/tree/?h=v2.1.0-p1
Clone URL: https://soniex2.autistic.space/git-repos/cratera.git

Martin Eden

unread,
Jun 12, 2024, 9:15:48 PMJun 12
to lu...@googlegroups.com
On 2024-06-12 17:33, Soni "They/Them" L. wrote:
> if you hit hard at the Lua, it makes a Cratera

:-)


Reply all
Reply to author
Forward
0 new messages