diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2021-04-13 11:51:58 -0700 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2021-04-15 19:06:39 -0700 |
| commit | 798ad631f3f9836de663bc6c728b415e0a13528f (patch) | |
| tree | 345fe3987200eedf7e00c905dc9e5e98f29ebaa9 /src/Compilation.zig | |
| parent | 6dba9bc6fc6741e51af86f71e3057cffed7406a6 (diff) | |
| download | zig-798ad631f3f9836de663bc6c728b415e0a13528f.tar.gz zig-798ad631f3f9836de663bc6c728b415e0a13528f.zip | |
stage2 start.zig: slight simplification
fewer required language features to allow this to work
Diffstat (limited to 'src/Compilation.zig')
| -rw-r--r-- | src/Compilation.zig | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig index cef24204d1..80feb378d1 100644 --- a/src/Compilation.zig +++ b/src/Compilation.zig @@ -3078,7 +3078,10 @@ pub fn generateBuiltinZigSource(comp: *Compilation, allocator: *Allocator) Alloc \\/// Zig version. When writing code that supports multiple versions of Zig, prefer \\/// feature detection (i.e. with `@hasDecl` or `@hasField`) over version checks. \\pub const zig_version = try std.SemanticVersion.parse("{s}"); + \\/// Temporary until self-hosted is feature complete. \\pub const zig_is_stage2 = {}; + \\/// Temporary until self-hosted supports the `cpu.arch` value. + \\pub const stage2_arch: std.Target.Cpu.Arch = .{}; \\ \\pub const output_mode = std.builtin.OutputMode.{}; \\pub const link_mode = std.builtin.LinkMode.{}; @@ -3093,6 +3096,7 @@ pub fn generateBuiltinZigSource(comp: *Compilation, allocator: *Allocator) Alloc , .{ build_options.version, !use_stage1, + std.zig.fmtId(@tagName(target.cpu.arch)), std.zig.fmtId(@tagName(comp.bin_file.options.output_mode)), std.zig.fmtId(@tagName(comp.bin_file.options.link_mode)), comp.bin_file.options.is_test, |
