{"id":29383450,"url":"https://github.com/thep1geon/nomi","last_synced_at":"2025-07-10T04:10:09.060Z","repository":{"id":294330142,"uuid":"986382092","full_name":"thep1geon/nomi","owner":"thep1geon","description":"The Nomi Compiler Project. What's starting as a compiler written in Zig will eventually be a self-hosted compiler with a custom assembler and linker all written in Nomi. The plan is to write an OS one day with my own toolchain, everything written from scratch by me.","archived":false,"fork":false,"pushed_at":"2025-07-06T15:16:19.000Z","size":62,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-06T16:29:10.706Z","etag":null,"topics":["compiler","wip","zig","ziglang"],"latest_commit_sha":null,"homepage":"https://github.com/thep1geon/nomi","language":"Zig","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/thep1geon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"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}},"created_at":"2025-05-19T14:21:25.000Z","updated_at":"2025-07-06T15:16:22.000Z","dependencies_parsed_at":"2025-07-06T16:23:25.685Z","dependency_job_id":"627c987a-86eb-41f9-b6cd-003914074761","html_url":"https://github.com/thep1geon/nomi","commit_stats":null,"previous_names":["thep1geon/compiler","thep1geon/nomi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/thep1geon/nomi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thep1geon%2Fnomi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thep1geon%2Fnomi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thep1geon%2Fnomi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thep1geon%2Fnomi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thep1geon","download_url":"https://codeload.github.com/thep1geon/nomi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thep1geon%2Fnomi/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264526961,"owners_count":23623194,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["compiler","wip","zig","ziglang"],"created_at":"2025-07-10T04:02:32.015Z","updated_at":"2025-07-10T04:10:09.032Z","avatar_url":"https://github.com/thep1geon.png","language":"Zig","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nomi\n\n## The State of Nomi\n\nRight now, Nomi is in its very early stages of development, and everything is subject\nto change. Any questions can be asked here on GitHub or through email, \nhauptmaverick@gmail.com.\n\n## About\n\nI've been wanting to write a compiler for a very long time now, and this is my\nfirst honest attempt at it. I've decided to pivot from making a C compiler to just\nstarting with my own language. I want to keep C compatiblity and interop, but the\nlanguage will look more high level than C. I'm going for a Zig-esque language but\nhandcrafted. Not there is anything wrong with Zig or that I feel like I can make\na better Zig, but I want to append / amend C. The plans are evolving, but there\nare a few things I want to implement into my take on a language with heavy inspiration\nfrom C:\n\n- [ ] **Interfaces**\n- [ ] **Better type system to allow for things like generics without macros**\n- [ ] Optionals builtin to the language\n- [ ] Better error system (errors as types)\n- [ ] Slices\n- [ ] **Defer**\n- [ ] Custom backend (for shits and giggles)\n\n*Note: the ones in bold are more important to me*\n\nOf course the first compiler for my language (which I have yet to name) will be \nwritten in Zig. But there are definitely plans to helf-host my language and bootstrap\nthe compiler.\n\nEverything will be written from scratch only relying on the Zig standard library.\nThough, there will not be any effort to make this cross-platform. This project is\npurely for learning and will jumpstart future ideas of writing an OS in this\nlanguage one day.\n\n## TODO List\n\n- [x] Better printing of compiler types (~Location~, ~ast~, ~Token~)\n    - [x] Rework how the AST is represented internally\n- [ ] Improve error system for compiler internals.\n- [ ] Start work on IR layer to abstract frontend and backend\n- [ ] Semantic Analysis\n    - [ ] Type system\n- [ ] External functions from Nomi (written in FASM) (extern func sys_exit(i32) void;)\n- [ ] Start work on user declared functions and calling user declared functions\n- [ ] More types (\"Strings\", specific integer types)\n- [ ] Variables\n- [ ] Functions which takes args\n- [ ] Hello, World! (No libc)\n- [ ] x86_64-Linux Backend\n- [ ] x86-Freestanding Backend\n\n## Getting Started\n\n### Dependencies\n\n- Zig v0.14.1\n- Fasm  v1.73.32\n- ld linker v2.44.0\n\n### Building the Compiler\n\nTo get started with using the compiler, for what very little it can do right now,\nyou need to first build the compiler. You can build the compiler with this command:\n\n```bash\nzig build # Build the compiler\n```\n\n### Using the Compiler\n\n```bash\n./zig-out/bin/nomic main.nom main.o # Run the compiler and output as main.o\nld main.o -o main # Link main.o to an ELF executable\n./main # Run the newly compiled executable\necho $? # to see the exit code of main\n        # The output should be 42 if main.nom was not updated\n```\n\nThere are plans to rework this process. But this is the simplest way of handling\nit so far. The compiler will output a straight executable eventually, don't worry\n\n## What can the compiler do right now?\n\nCurrently, the compiler only supports one function being in a file. Within that\nfunction, you can call external functions (nothing is checked yet) which take one\nargument which is a number with a bit-width greater than 32. We don't link with libc,\nso the only functions you can call are the ones hardcoded in the assembly file\ngenerated behind the scenes before it's assembled by the compiler.\n\nThe compiler will emit an object file for you to link yourself. There are plans\nto change this in the future, but this lets me do something else before I introduce\ncompiling multiple files or mixing files and object files. Basically, everything\nin the compiler will improve at once. We have to allow for more options to parsed\nand then we can emit an executable file. But this is not much of a priority right now.\n\n## What's in a name?\n\n### Noh-mee\n\nThe name Nomi comes from a few different places. Most notably, it is heavily\ninspired by my girlfriend's nickname, _Nemo_. Nomi is a loose combination of her\nnickname and her real name. Nomi also has a few meanings I think are very neat.\nThe two meanings that stand out to me are beautiful (Hebrew and Japanese) and ocean (Japanese).\nBoth meanings are perfect and accurately reflect her and her names.\n\nA motto I've come up with is: \"Built from beauty for power\"\n\n## LICENSE\n\nThe Nomi project is licensed under the MIT License and everything it says.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthep1geon%2Fnomi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthep1geon%2Fnomi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthep1geon%2Fnomi/lists"}