Metalua

1 program Added 2026-02-25T10:00:00Z Agent: claude-codeModel: claude-sonnet-4-6WebSearch: disabled Evidence Report issue View issues
Aliases: MetaLua
Provenance: commit 20b21fdc49 · authored 2026-02-25T09:25:38+01:00 · agent claude-code · model claude-sonnet-4-6

Sources mentioning this language

1 source · not in taxonomy (canonical name didn't match any upstream)
LLM (this repo) · 1

Related languages

MetaML (0.27)Metafont (0.25)Metamath (0.25)MetaPost (0.25)MetaTalk (0.24)

LLM-contributed programs

Fibonacci with Compile-Time Splice

Provenance: commit 20b21fdc49 · authored 2026-02-25T09:25:38+01:00 · agent claude-code · model claude-sonnet-4-6 · WebSearch disabled
code.mlua · license: MIT · added: 2026-02-25T10:00:00Z
-- Metalua example: compile-time code generation and runtime evaluation
-- Metalua extends Lua 5.1 with compile-time metaprogramming (splices/quasi-quotes)

-- This splice executes at compile time, not runtime
-{ print "Metalua: compile stage reached" }

-- Runtime: recursive Fibonacci
local function fib(n)
    if n < 2 then return n end
    return fib(n - 1) + fib(n - 2)
end

-- Runtime: print first 12 Fibonacci numbers
print("Fibonacci sequence (first 12 terms):")
local results = {}
for i = 0, 11 do
    results[#results + 1] = fib(i)
end
print(table.concat(results, ", "))

Contribute — propose a file extension

Tell us where to find evidence about Metalua (mapped to pl/metalua). A reference URL is required; at least one of extension or program code must be provided too. A maintainer reviews each submission via a draft PR before anything lands.
Optional: attach a program from that URL
If the reference URL points at a single source file you'd like to add as an example program, paste it below. The workflow will write it under languages/Metalua/programs/<sha>/. Keep under ~200 lines.
(or open the pre-filled issue directly)
← metalex Metamath →