A tour of Luce
Twelve chapters, meant to be read in order. They assume you can program in something and nothing else. By the end you will have written a program that takes command-line arguments, builds a map, handles a file that would not open, and gives its memory back.
Every sample here is a whole program. You can copy any of them into a file, run loom luce thatfile.luc, and get exactly the output printed underneath it — that is checked when this site is built, not claimed.
If you already program in Luce, the guides go deeper on the parts that are unusual and the reference is where the exact rules live.
Hello, LuceBuild the toolchain, compile a program, run it.
Values and typesInt, Float, Bool, String, and the rule that there are no implicit conversions.
Control flowif, elif, else, while, for, and the two shapes the parser refuses to guess at.
Functions and structsfunc, parameters, returns, and value structs with namespaced functions.
Lists, maps and arraysThe four heap objects, their methods, and how you walk them.
StringsImmutable UTF-8, f-strings, slicing, and where the rest of the string library lives.
MemoryScope ownership: no collector, no reference counting, and four words to learn.
AbsenceT?, none, narrowing, and else — saying that a thing might not be there.
FailureT!, try, catch and error — and the rule that decides between a trap and an error.
ModulesA file is a module; the standard library lives under std.
The outside worldPrinting, arguments, files, and the terminal — every effect is a host service.
Where to go nextWhat you have seen, what you have not, and where each of them is written down.