Cosmos is compiled by the self-hosted compiler in compiler/src
and runs on SWI-Prolog. The active compiler has no Lua dependency.
See the current compiler user guide for language syntax, classes, protocols, modules, applications, the REPL, and host integration.
Compile a program on Windows:
cs.cmd input.co output.pl module_nameOr invoke the platform directly:
swipl -q -s compiler/platform/cli.pl -- input.co output.pl module_nameRebuild and test:
node compiler/build.mjs
node --test tests/compiler/compiler.test.mjsThe retired Lua compiler and its historical documentation are isolated under
legacy/lua-compiler. Nothing in the active compiler,
launcher, tests, or installer requires that folder.