authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-02-14 23:17:11-05:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-02-14 23:17:11-05:00
loge025c70166d96d7a75a5039415321745f51f1f58
treec960eb35f458e7182c80cccd5153e51d525ad4c4
parentd6e0d82c328b4f9d733364382cce0941a601e91a
signature Commit is signed but in an unrecognized format.

stage2: fix llvm.zig with opaque types back to single-item pointer


2 files changed, 12 insertions(+), 12 deletions(-)

src-self-hosted/llvm.zig+10-10
...@@ -11,16 +11,16 @@ const assert = @import("std").debug.assert;...@@ -11,16 +11,16 @@ const assert = @import("std").debug.assert;
11pub const AttributeIndex = c_uint;11pub const AttributeIndex = c_uint;
12pub const Bool = c_int;12pub const Bool = c_int;
1313
14pub const Builder = c.LLVMBuilderRef.Child;14pub const Builder = c.LLVMBuilderRef.Child.Child;
15pub const Context = c.LLVMContextRef.Child;15pub const Context = c.LLVMContextRef.Child.Child;
16pub const Module = c.LLVMModuleRef.Child;16pub const Module = c.LLVMModuleRef.Child.Child;
17pub const Value = c.LLVMValueRef.Child;17pub const Value = c.LLVMValueRef.Child.Child;
18pub const Type = c.LLVMTypeRef.Child;18pub const Type = c.LLVMTypeRef.Child.Child;
19pub const BasicBlock = c.LLVMBasicBlockRef.Child;19pub const BasicBlock = c.LLVMBasicBlockRef.Child.Child;
20pub const Attribute = c.LLVMAttributeRef.Child;20pub const Attribute = c.LLVMAttributeRef.Child.Child;
21pub const Target = c.LLVMTargetRef.Child;21pub const Target = c.LLVMTargetRef.Child.Child;
22pub const TargetMachine = c.LLVMTargetMachineRef.Child;22pub const TargetMachine = c.LLVMTargetMachineRef.Child.Child;
23pub const TargetData = c.LLVMTargetDataRef.Child;23pub const TargetData = c.LLVMTargetDataRef.Child.Child;
24pub const DIBuilder = c.ZigLLVMDIBuilder;24pub const DIBuilder = c.ZigLLVMDIBuilder;
25pub const DIFile = c.ZigLLVMDIFile;25pub const DIFile = c.ZigLLVMDIFile;
26pub const DICompileUnit = c.ZigLLVMDICompileUnit;26pub const DICompileUnit = c.ZigLLVMDICompileUnit;
src-self-hosted/value.zig+2-2
...@@ -283,8 +283,8 @@ pub const Value = struct {...@@ -283,8 +283,8 @@ pub const Value = struct {
283 comp.gpa().destroy(self);283 comp.gpa().destroy(self);
284 }284 }
285285
286 pub fn getLlvmConst(self: *Bool, ofile: *ObjectFile) ?*llvm.Value {286 pub fn getLlvmConst(self: *Bool, ofile: *ObjectFile) !?*llvm.Value {
287 const llvm_type = llvm.Int1TypeInContext(ofile.context);287 const llvm_type = llvm.Int1TypeInContext(ofile.context) orelse return error.OutOfMemory;
288 if (self.x) {288 if (self.x) {
289 return llvm.ConstAllOnes(llvm_type);289 return llvm.ConstAllOnes(llvm_type);
290 } else {290 } else {