diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2019-04-26 20:41:37 -0400 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-04-26 20:46:28 -0400 |
| commit | 2d6520d5d4cd912cdd20db6cfa155e871efc6f59 (patch) | |
| tree | 583e47f4af61d3950b34333d48e738733b5e107a /src/userland.cpp | |
| parent | ac3946620cebfc706255a86103a14c6cb08cff97 (diff) | |
| download | zig-2d6520d5d4cd912cdd20db6cfa155e871efc6f59.tar.gz zig-2d6520d5d4cd912cdd20db6cfa155e871efc6f59.zip | |
zig fmt is built directly into stage1 rather than child process
Previously, `zig fmt` on the stage1 compiler (which is what we currently
ship) would perform what equates to `zig run std/special/fmt_runner.zig`
Now, `zig fmt` is implemented with the hybrid zig/C++ strategy outlined
by #1964.
This means Zig no longer has to ship some of the stage2 .zig files, and
there is no longer a delay when running `zig fmt` for the first time.
Diffstat (limited to 'src/userland.cpp')
| -rw-r--r-- | src/userland.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/userland.cpp b/src/userland.cpp index fad1450f0d..20740711e5 100644 --- a/src/userland.cpp +++ b/src/userland.cpp @@ -37,3 +37,8 @@ void stage2_render_ast(struct Stage2Ast *ast, FILE *output_file) { const char *msg = "stage0 called stage2_render_ast"; stage2_panic(msg, strlen(msg)); } + +int stage2_fmt(int argc, char **argv) { + const char *msg = "stage0 called stage2_fmt"; + stage2_panic(msg, strlen(msg)); +} |
