Skip to content

Commit a917532

Browse files
authored
Merge pull request #11085 from ziglang/llvm-debug-info
stage2 LLVM debug info
2 parents 935d208 + fb4ad37 commit a917532

12 files changed

+1417
-81
lines changed

doc/langref.html.in

+1-1
Original file line numberDiff line numberDiff line change
@@ -1317,7 +1317,7 @@ const @"identifier with spaces in it" = 0xff;
13171317
const @"1SmallStep4Man" = 112358;
13181318

13191319
const c = @import("std").c;
1320-
pub extern "c" fn @"error"() anyopaque;
1320+
pub extern "c" fn @"error"() void;
13211321
pub extern "c" fn @"fstat$INODE64"(fd: c.fd_t, buf: *c.Stat) c_int;
13221322

13231323
const Color = enum {

lib/std/dwarf.zig

+15
Original file line numberDiff line numberDiff line change
@@ -226,6 +226,21 @@ pub const LNCT = struct {
226226
pub const hi_user = 0x3fff;
227227
};
228228

229+
pub const CC = enum(u8) {
230+
normal = 0x1,
231+
program = 0x2,
232+
nocall = 0x3,
233+
234+
pass_by_reference = 0x4,
235+
pass_by_value = 0x5,
236+
237+
lo_user = 0x40,
238+
hi_user = 0xff,
239+
240+
GNU_renesas_sh = 0x40,
241+
GNU_borland_fastcall_i386 = 0x41,
242+
};
243+
229244
const PcRange = struct {
230245
start: u64,
231246
end: u64,

src/Compilation.zig

+1-1
Original file line numberDiff line numberDiff line change
@@ -898,7 +898,7 @@ pub fn create(gpa: Allocator, options: InitOptions) !*Compilation {
898898
// We put the `Compilation` itself in the arena. Freeing the arena will free the module.
899899
// It's initialized later after we prepare the initialization options.
900900
const comp = try arena.create(Compilation);
901-
const root_name = try arena.dupe(u8, options.root_name);
901+
const root_name = try arena.dupeZ(u8, options.root_name);
902902

903903
const ofmt = options.object_format orelse options.target.getObjectFormat();
904904

src/Sema.zig

+1-1
Original file line numberDiff line numberDiff line change
@@ -12399,7 +12399,7 @@ fn zirTypeName(sema: *Sema, block: *Block, inst: Zir.Inst.Index) CompileError!Ai
1239912399
var anon_decl = try block.startAnonDecl(LazySrcLoc.unneeded);
1240012400
defer anon_decl.deinit();
1240112401

12402-
const bytes = try ty.nameAlloc(anon_decl.arena());
12402+
const bytes = try ty.nameAllocArena(anon_decl.arena());
1240312403

1240412404
const new_decl = try anon_decl.finish(
1240512405
try Type.Tag.array_u8_sentinel_0.create(anon_decl.arena(), bytes.len),

0 commit comments

Comments
 (0)