A scheme inspired s-expression based functional language
- Shell 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
The whole-file read buffer, the value stack and the symbol table leave the bss for MAP_NORESERVE mappings made in rt_init, so a program no longer asks for 330 MiB at execve; asm2 streams its records and lin2 re-reads objects and builds the image in place; write-file! takes a list of bytes; the native compiler bounds -j by the machine's memory. Conflicts with what main gained since 2026-09-27: - runtime-text: main's hashed, weak symbol table has five symtab references, each now loads symtab_base. The heap floor and heap/8 forced growth were already on main ( |
||
| bin | ||
| examples | ||
| lib | ||
| scripts | ||
| src | ||
| .gitignore | ||
| LICENSE | ||
| README | ||
| VERSION | ||
# Talc - translate, assemble, link, compile Talc is a programming language and toolchain that turns .talc programs into something a computer can run. Those tools are a translator, assembler, linker and a front-end compiler that can call all three of these. Talc the name was a suggestion by a user on the Discord server for "Extractions & Ire". Otherwise, I would have just called it programming language. The language takes inspiration from Scheme but it doesn't follow any of the Scheme standards and is opinionated about where it departs. Expressions are written in prefix notation as is the custom for lisp/scheme family of languages. There is no C and no dependency on libc. It runs on a 64-bit Linux system and can also build UEFI firmware applications like bootloaders. ## Attribution Despite instructing a clanker to assemble this library over a number of weeks, it doesn't really feel like mine or anybody in particular. Additionally, this wouldn't have been possible by a single individual because the people who blazed this trail with nothing other than intuition didn't have a robot they could just ask to do it. Furthermore, there are definitely transliterations in this library where the LLM undoubtedly reached to the already existing C implementations on how to build and test this. For portions that I could find I think it's appropriate to mention it and should anybody see other strong correlations between certain codes and other libraries I'd appreciate reporting it to also have some way to trace parts this language and anything built using it back to where the real idea came from. ## Bootstrapping - Stage0 - Takes hex ASCII and converts to bytes - Stage1 - Above with labels for jump distance calculation - Stage2 - Assembler that can read mnemonics, mov, jmp - Stage3 - Tiny core language, only compiles gen1 - gen1 - Tiny core with garbage collection - gen2 - Primitive language extensions, built via gen2 - gen3 - Runtime and garbage collection - gen4 - Current toolchain with libraries ## Installing Any x86-64 Linux system will do. Even though the compiler is self-hosting you will still need a shell and filesystem available to actually install and run it. First build the toolchain > scripts/bootstrap.sh Then install the binaries to a PREFIX directory > scripts/install.sh $HOME/.local/talc ## Usage > compiler <program-file.talc> <program-name> [<library-dir> ...] The output file is a Linux ELF binary and can be run like any executable