authorchloe caruso <git@paperclover.net> 2024-11-19 02:26:01-08:00
committerchloe caruso <git@paperclover.net> 2024-11-19 02:26:01-08:00
log6a36a7d112bef93e6ceba5477a5427e96eed6175
tree67a422777cc3c4b9869d26a3dfe6d3d0e4ad1e93
parentd0dcd18fdc6d392a08e9449f59bc9f2d2049f720
signature Commit is signed but in an unrecognized format.

zig upgrade


8 files changed, 13 insertions(+), 11 deletions(-)

build.zig.zon+2-2
......@@ -2,12 +2,12 @@
22 .name = "",
33 .version = "0.0.0",
44
5 .minimum_zig_version = "0.14.0-dev.2034+56996a280",
5 .minimum_zig_version = "0.14.0-dev.2254+73f2671c7",
66
77 .dependencies = .{
88 // Used to determine unicode properties to tokenize identifiers
99 .zg = .{
10 .url = "https://codeberg.org/dude_the_builder/zg/archive/c425c9c8511bf92e14b8b612d1d16e774b186f2e.tar.gz",
10 .url = "https://codeberg.org/atman/zg/archive/c425c9c8511bf92e14b8b612d1d16e774b186f2e.tar.gz",
1111 .hash = "1220c79009f1e443b015db4de6e5319432538ead2fea10d271f3f35d3ae83c996789",
1212 },
1313 // Optional: Used for tracing
src/core/Ast.zig+1-1
......@@ -360,7 +360,7 @@ pub const Node = struct {
360360 });
361361
362362 pub const Data = union {
363 none: struct { Unused = .zero, Unused = .zero },
363 none: struct { a: Unused = .zero, b: Unused = .zero },
364364 function: struct {
365365 /// A `Fn`
366366 extra: ExtraIndex,
src/core/Sema.zig+2-2
......@@ -172,7 +172,7 @@ const Frame = struct {
172172 data: Data,
173173
174174 const Data = union {
175 pub const none = .{ .undefined = {} };
175 pub const none: Data = .{ .undefined = {} };
176176
177177 undefined: void,
178178 conditional: Conditional,
......@@ -961,7 +961,7 @@ fn stepInner(s: *Sema, comptime tag: Hir.Tag) Error!InstructionKind.fromTag(tag)
961961 const data: Hir.Func = s.frame.currentPayload(.func);
962962 const reserve = try s.scratch.reserveMulti(
963963 s.arena(),
964 .{ .params = Type, .captures = Air.Inst.Ref },
964 FunctionReserve.input,
965965 .{ data.params.len, data.captures.len },
966966 );
967967 if (data.captures.len > 0) @panic("TODO: captures");
src/core/Transform.zig+1-1
......@@ -368,7 +368,7 @@ const BuiltIn = struct {
368368 value: Inst.Ref,
369369};
370370
371const built_in_ids = std.StaticStringMap(BuiltIn).initComptime(.{
371const built_in_ids = std.StaticStringMap(BuiltIn).initComptime([_]struct { []const u8, BuiltIn }{
372372 .{ "void", .{ .value = .void, .type = .void } },
373373 .{ "true", .{ .value = .bool_true, .type = .bool_type } },
374374 .{ "false", .{ .value = .bool_false, .type = .bool_type } },
src/core/mod.zig+1-1
......@@ -25,7 +25,7 @@ pub const unicode_props = @import("unicode_props.zig");
2525// sort-lines: end
2626
2727// The rest of this file is small utility functions, which are not specific to
28// any of the above namespaces. Remember Zig discourages namespaces like `utils`.
28// any of the above namespaces. Remember, Zig discourages namespaces like `utils`.
2929
3030pub const runtime_safety = switch (@import("builtin").mode) {
3131 .Debug, .ReleaseSafe => true,
src/core/stack.zig+2
......@@ -104,6 +104,8 @@ pub fn Stack(comptime Base: type) type {
104104 starts: [fields.len]u32,
105105 lengths: [fields.len]u32,
106106
107 pub const input = types;
108
107109 fn Type(comptime field: FieldEnum) type {
108110 return @field(types, @tagName(field));
109111 }
src/deps/quickjs/build.zig+3-3
......@@ -146,10 +146,10 @@ pub fn build(b: *Build) !void {
146146 .optimize = optimize,
147147 .link_libc = true,
148148 });
149 const module2 = translate_libc.addModule("quickjs-libc");
149 const module_libc = translate_libc.addModule("quickjs-libc");
150150 if (pthread.pthreads) |pt| translate_libc.addIncludePath(pt.include);
151 module2.linkLibrary(libquickjs);
152 module2.linkLibrary(libquickjs_libc);
151 module_libc.linkLibrary(libquickjs);
152 module_libc.linkLibrary(libquickjs_libc);
153153}
154154
155155fn runQjsc(b: *Build, qjsc: *Build.Step.Compile, in: Build.LazyPath) Build.LazyPath {
src/main.zig+1-1
......@@ -41,7 +41,7 @@ const top_level_commands: []const Command.ListItem = &.{
4141 .name = "run",
4242 .description = "Create executable and run with QuickJS",
4343 .cli = .{
44 .options = general_compiler_options ++ .{
44 .options = general_compiler_options ++ [_]Cli.Option{
4545 .{ .name = "--dump-code", .desc = "Dump compiled JavaScript to standard out" },
4646 },
4747 .positionals = .single,