/minic

Mini C Compiler

Primary LanguageC

minic

Mini C Compiler

Work-in-progress C compiler inspired by this subset of the C grammar, implemented in C using mpc for parsing and grammar specification.

Building

Run mkdir obj, then nix-shell, and then make to build.

Notes

  • nix-shell requires Nix to build with LLVM; if needed, you can change the Makefile to avoid requiring LLVM for testing purposes.
  • For C++ auto-completion such as with ccls or clangd, install Bear and then run nix-shell and bear make to produce a compile_commands.json file.

Running

Run with ./minic.