File tree Expand file tree Collapse file tree 4 files changed +34
-7
lines changed
Expand file tree Collapse file tree 4 files changed +34
-7
lines changed Original file line number Diff line number Diff line change @@ -42,10 +42,13 @@ pub fn panic(
4242 w .print ("Unable to dump stack trace: debug info stripped\n " , .{}) catch {};
4343 break :blk ;
4444 }
45- std .debug .writeCurrentStackTrace (.{ .first_address = ret_addr }, w , .no_color ) catch | err | {
46- w .print ("Unable to dump stack trace: {t}\n " , .{err }) catch {};
47- break :blk ;
48- };
45+
46+ if (builtin .zig_version .minor != 15 ) {
47+ std .debug .writeCurrentStackTrace (.{ .first_address = ret_addr }, w , .no_color ) catch | err | {
48+ w .print ("Unable to dump stack trace: {t}\n " , .{err }) catch {};
49+ break :blk ;
50+ };
51+ }
4952 }
5053
5154 if (builtin .mode == .Debug ) @breakpoint ();
Original file line number Diff line number Diff line change 1+ const builtin = @import ("builtin" );
12const std = @import ("std" );
23const super = @import ("superhtml" );
34
@@ -107,7 +108,14 @@ fn checkFile(
107108 defer _ = arena_impl .reset (.retain_capacity );
108109 const arena = arena_impl .allocator ();
109110
110- const in_bytes = try base_dir .readFileAllocOptions (
111+ const in_bytes = if (builtin .zig_version .minor == 15 ) try base_dir .readFileAllocOptions (
112+ arena ,
113+ sub_path ,
114+ super .max_size ,
115+ null ,
116+ .of (u8 ),
117+ 0 ,
118+ ) else try base_dir .readFileAllocOptions (
111119 sub_path ,
112120 arena ,
113121 .limited (super .max_size ),
Original file line number Diff line number Diff line change 1+ const builtin = @import ("builtin" );
12const std = @import ("std" );
23const Allocator = std .mem .Allocator ;
34const Writer = std .Io .Writer ;
@@ -118,7 +119,14 @@ fn formatFile(
118119 defer _ = arena_impl .reset (.retain_capacity );
119120 const arena = arena_impl .allocator ();
120121
121- const in_bytes = try base_dir .readFileAllocOptions (
122+ const in_bytes = if (builtin .zig_version .minor == 15 ) try base_dir .readFileAllocOptions (
123+ arena ,
124+ sub_path ,
125+ super .max_size ,
126+ null ,
127+ .of (u8 ),
128+ 0 ,
129+ ) else try base_dir .readFileAllocOptions (
122130 sub_path ,
123131 arena ,
124132 .limited (super .max_size ),
Original file line number Diff line number Diff line change 1+ const builtin = @import ("builtin" );
12const std = @import ("std" );
23const super = @import ("superhtml" );
34
@@ -55,7 +56,14 @@ fn printInterfaceFromFile(
5556 defer _ = arena_impl .reset (.retain_capacity );
5657 const arena = arena_impl .allocator ();
5758
58- const in_bytes = try base_dir .readFileAllocOptions (
59+ const in_bytes = if (builtin .zig_version .minor == 15 ) try base_dir .readFileAllocOptions (
60+ arena ,
61+ sub_path ,
62+ super .max_size ,
63+ null ,
64+ .of (u8 ),
65+ 0 ,
66+ ) else try base_dir .readFileAllocOptions (
5967 sub_path ,
6068 arena ,
6169 .limited (super .max_size ),
You can’t perform that action at this time.
0 commit comments