hawkins / druid

🧙 A systems-level programming language with a focus on integrated build systems and deploying to native and web assembly at once
https://twitch.tv/druidlang
2 stars 0 forks source link

Druid compiler toolchain CLI #4

Open hawkins opened 6 years ago

hawkins commented 6 years ago

We need a tool to use that will:

Effectively this CLI will pass fork to several child processes, the first of which will call the preprocessor on the file, then pipe to lexer, then pipe to parser, then pipe to compiler.

For no reason beyond a Druid casting magic on the file to make it do things, pretend this CLI is called cast:

$ cast hello.druid --verbose
* preprocessing hello.druid
  * summoned ./echo.druid
    * summoned :math
  * summoned :io
* parse check successful
* compiled to web assembly 
* done in 0.27 sec
hawkins commented 6 years ago

This is synonymous with $ gcc