{"id":16694510,"url":"https://github.com/foxfriends/trilogy","last_synced_at":"2026-01-21T21:33:15.704Z","repository":{"id":65449839,"uuid":"583210766","full_name":"foxfriends/trilogy","owner":"foxfriends","description":"Actually just three programming languages in a trenchcoat","archived":false,"fork":false,"pushed_at":"2026-01-11T04:03:58.000Z","size":5052,"stargazers_count":3,"open_issues_count":8,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-11T06:47:40.638Z","etag":null,"topics":["effect-handlers","functional-programming","imperative-programming","logic-programming","programming-language"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/foxfriends.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"foxfriends","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2022-12-29T05:03:28.000Z","updated_at":"2026-01-11T04:04:02.000Z","dependencies_parsed_at":"2023-02-18T18:15:35.394Z","dependency_job_id":"67e9c069-9f3b-4b00-9f66-405750c8f5a8","html_url":"https://github.com/foxfriends/trilogy","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/foxfriends/trilogy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxfriends%2Ftrilogy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxfriends%2Ftrilogy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxfriends%2Ftrilogy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxfriends%2Ftrilogy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/foxfriends","download_url":"https://codeload.github.com/foxfriends/trilogy/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxfriends%2Ftrilogy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28644089,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-21T21:29:11.980Z","status":"ssl_error","status_checked_at":"2026-01-21T21:24:31.872Z","response_time":86,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["effect-handlers","functional-programming","imperative-programming","logic-programming","programming-language"],"created_at":"2024-10-12T16:46:21.060Z","updated_at":"2026-01-21T21:33:15.692Z","avatar_url":"https://github.com/foxfriends.png","language":"Rust","readme":"# Trilogy\n\n[![Spec](https://github.com/foxfriends/trilogy/actions/workflows/spec.yml/badge.svg)](https://github.com/foxfriends/trilogy/actions/workflows/spec.yml)\n[![Rust CI](https://github.com/foxfriends/trilogy/actions/workflows/rust.yml/badge.svg)](https://github.com/foxfriends/trilogy/actions/workflows/rust.yml)\n[![C CI](https://github.com/foxfriends/trilogy/actions/workflows/c.yml/badge.svg)](https://github.com/foxfriends/trilogy/actions/workflows/c.yml)\n\nMy (approximately) third attempt at building a programming language[^1][^2].\n\nAlso a programming language that more closely resembles three languages\nat once than any one single language.\n\nAlso an exploration into a bunch of ideas in language theory (or at least my own\nideas of them) that I am finding come in sets of three.\n\nThat makes a trilogy. Hopefully I produce something useful. Third time's the charm!\n\n[^1]: First few were school projects, WLP4 (a subset of C), and Joos (a subset of Java), and maybe a few others. Though technically I did (attempt to) implement them (with friends), they aren't *my* languages, so I cannot provide the source code.\n[^2]: The first I could call my own was [Lumber](https://github.com/foxfriends/lumber), an experiment at a logic programming language, but much was found lacking in performance and practicality.\n\n## Status\n\nThe v0.0 \"barely functioning\" version of Trilogy was completed in 2023, using a custom bytecode virtual machine.\nWhile it did succeed at its [original goal](https://github.com/foxfriends/advent-of-code/tree/main/2023), there\nwere numerous flaws with performance, memory usage, and bugs in general.\n\nA v0.1 version is now in the works, backed by LLVM for a more robust and performant implementation and better\nFFI to native libraries.\n\n- [x] Read some papers and instructions on programming languages\n    - https://www.eff-lang.org/handlers-tutorial.pdf\n    - http://www.math.bas.bg/bantchev/place/iswim/j-explanation.pdf\n    - http://www.math.bas.bg/bantchev/place/iswim/j.pdf\n    - https://cs.ru.nl/~dfrumin/notes/delim.html\n    - https://www.cs.cmu.edu/~rwh/students/filinski.pdf\n    - https://homepages.inf.ed.ac.uk/slindley/papers/effmondel-jfp.pdf\n    - https://caml.inria.fr/pub/papers/xleroy-applicative_functors-popl95.pdf\n    - https://doc.rust-lang.org/reference/\n    - https://github.com/HigherOrderCO/HVM\n    - https://www.sciencedirect.com/science/article/pii/S0890540197926432/pdf?md5=30965cec6dd7605a865bbec4076f65e4\u0026pid=1-s2.0-S0890540197926432-main.pdf\n    - https://www.sciencedirect.com/science/article/pii/S1571066115000705/pdf?md5=3b9f68cbe5525034208dfacfb8b0e099\u0026pid=1-s2.0-S1571066115000705-main.pdf\n    - https://arxiv.org/pdf/2504.18920\n- [x] Design the language: Check out the [spec](./spec/)!\n- [x] Read the [book](https://craftinginterpreters.com/)\n- [x] Specify the language (Living document)\n- [ ] Implement the language:\n    - [x] Scanning\n    - [x] Parsing\n    - [x] Syntactic analysis\n    - [x] Name resolution\n    - [x] ~~Bytecode generation~~\n    - [x] ~~Virtual machine~~\n    - [x] ~~Garbage collector~~\n    - [x] LLVM code generation\n    - [ ] Extensive testing\n    - [ ] Standard library (in progress)\n- [ ] Implement the ecosystem\n    - [ ] Formatter\n    - [ ] Linter\n    - [ ] LSP\n    - [ ] DAP\n- [ ] Future experimental ideas:\n    - [ ] Try out IC based VM (HVM)\n","funding_links":["https://github.com/sponsors/foxfriends"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoxfriends%2Ftrilogy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffoxfriends%2Ftrilogy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoxfriends%2Ftrilogy/lists"}