authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2022-07-22 21:24:19-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2022-07-22 21:24:19-07:00
loga035d75a1750e59e43bb9122f33d8586ed1ee385
treed9ff0d084945eaf63455e2142066617f2da6d399
parent7502e490cb83a91133aa696e4ec0936022bee0c6

Autodoc: update to new ZIR

Fixes a merge conflict with 8e75ba653b03477229cf72211e8a8bfe7b071254 which removed ptr_type_simple and added overflow_arithmetic_ptr.

1 files changed, 10 insertions(+), 4 deletions(-)

src/Autodoc.zig+10-4
...@@ -1373,12 +1373,18 @@ fn walkInstruction(...@@ -1373,12 +1373,18 @@ fn walkInstruction(
13731373
1374 // return operand;1374 // return operand;
1375 // },1375 // },
1376 .ptr_type_simple => {1376 .overflow_arithmetic_ptr => {
1377 const ptr = data[inst_index].ptr_type_simple;1377 const un_node = data[inst_index].un_node;
1378 const elem_type_ref = try self.walkRef(file, parent_scope, ptr.elem_type, false);1378 const elem_type_ref = try self.walkRef(file, parent_scope, un_node.operand, false);
1379 const type_slot_index = self.types.items.len;1379 const type_slot_index = self.types.items.len;
1380 try self.types.append(self.arena, .{1380 try self.types.append(self.arena, .{
1381 .Pointer = .{ .size = ptr.size, .child = elem_type_ref.expr, .is_mutable = ptr.is_mutable, .is_volatile = ptr.is_volatile, .is_allowzero = ptr.is_allowzero },1381 .Pointer = .{
1382 .size = .One,
1383 .child = elem_type_ref.expr,
1384 .is_mutable = true,
1385 .is_volatile = false,
1386 .is_allowzero = false,
1387 },
1382 });1388 });
13831389
1384 return DocData.WalkResult{1390 return DocData.WalkResult{