authorgravatar for me@tadeo.caTadeo Kondrak <me@tadeo.ca> 2021-03-14 22:32:26-06:00
committergravatar for me@tadeo.caTadeo Kondrak <me@tadeo.ca> 2021-03-14 22:32:26-06:00
log277b01a089e059d63b6a01de011b666cc0702c38
tree4e03d14a0c3fe6510a948f5ca3159f67496b46e3
parenta502c160cd51ce3de80b3be945245b7a91967a85
signature Commit is signed but in an unrecognized format.

stage2 llvm bindings: rename LLVMBool to Bool


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

src/codegen/llvm/bindings.zig+10-10
...@@ -1,7 +1,7 @@...@@ -1,7 +1,7 @@
1//! We do this instead of @cImport because the self-hosted compiler is easier1//! We do this instead of @cImport because the self-hosted compiler is easier
2//! to bootstrap if it does not depend on translate-c.2//! to bootstrap if it does not depend on translate-c.
33
4const LLVMBool = bool;4const Bool = bool;
5pub const AttributeIndex = c_uint;5pub const AttributeIndex = c_uint;
66
7/// Make sure to use the *InContext functions instead of the global ones.7/// Make sure to use the *InContext functions instead of the global ones.
...@@ -22,13 +22,13 @@ pub const Context = opaque {...@@ -22,13 +22,13 @@ pub const Context = opaque {
22 extern fn LLVMVoidTypeInContext(C: *const Context) *const Type;22 extern fn LLVMVoidTypeInContext(C: *const Context) *const Type;
2323
24 pub const structType = LLVMStructTypeInContext;24 pub const structType = LLVMStructTypeInContext;
25 extern fn LLVMStructTypeInContext(C: *const Context, ElementTypes: [*]*const Type, ElementCount: c_uint, Packed: LLVMBool) *const Type;25 extern fn LLVMStructTypeInContext(C: *const Context, ElementTypes: [*]*const Type, ElementCount: c_uint, Packed: Bool) *const Type;
2626
27 pub const constString = LLVMConstStringInContext;27 pub const constString = LLVMConstStringInContext;
28 extern fn LLVMConstStringInContext(C: *const Context, Str: [*]const u8, Length: c_uint, DontNullTerminate: LLVMBool) *const Value;28 extern fn LLVMConstStringInContext(C: *const Context, Str: [*]const u8, Length: c_uint, DontNullTerminate: Bool) *const Value;
2929
30 pub const constStruct = LLVMConstStructInContext;30 pub const constStruct = LLVMConstStructInContext;
31 extern fn LLVMConstStructInContext(C: *const Context, ConstantVals: [*]*const Value, Count: c_uint, Packed: LLVMBool) *const Value;31 extern fn LLVMConstStructInContext(C: *const Context, ConstantVals: [*]*const Value, Count: c_uint, Packed: Bool) *const Value;
3232
33 pub const createBasicBlock = LLVMCreateBasicBlockInContext;33 pub const createBasicBlock = LLVMCreateBasicBlockInContext;
34 extern fn LLVMCreateBasicBlockInContext(C: *const Context, Name: [*:0]const u8) *const BasicBlock;34 extern fn LLVMCreateBasicBlockInContext(C: *const Context, Name: [*:0]const u8) *const BasicBlock;
...@@ -59,7 +59,7 @@ pub const Value = opaque {...@@ -59,7 +59,7 @@ pub const Value = opaque {
5959
60pub const Type = opaque {60pub const Type = opaque {
61 pub const functionType = LLVMFunctionType;61 pub const functionType = LLVMFunctionType;
62 extern fn LLVMFunctionType(ReturnType: *const Type, ParamTypes: ?[*]*const Type, ParamCount: c_uint, IsVarArg: LLVMBool) *const Type;62 extern fn LLVMFunctionType(ReturnType: *const Type, ParamTypes: ?[*]*const Type, ParamCount: c_uint, IsVarArg: Bool) *const Type;
6363
64 pub const constNull = LLVMConstNull;64 pub const constNull = LLVMConstNull;
65 extern fn LLVMConstNull(Ty: *const Type) *const Value;65 extern fn LLVMConstNull(Ty: *const Type) *const Value;
...@@ -68,7 +68,7 @@ pub const Type = opaque {...@@ -68,7 +68,7 @@ pub const Type = opaque {
68 extern fn LLVMConstAllOnes(Ty: *const Type) *const Value;68 extern fn LLVMConstAllOnes(Ty: *const Type) *const Value;
6969
70 pub const constInt = LLVMConstInt;70 pub const constInt = LLVMConstInt;
71 extern fn LLVMConstInt(IntTy: *const Type, N: c_ulonglong, SignExtend: LLVMBool) *const Value;71 extern fn LLVMConstInt(IntTy: *const Type, N: c_ulonglong, SignExtend: Bool) *const Value;
7272
73 pub const constArray = LLVMConstArray;73 pub const constArray = LLVMConstArray;
74 extern fn LLVMConstArray(ElementTy: *const Type, ConstantVals: ?[*]*const Value, Length: c_uint) *const Value;74 extern fn LLVMConstArray(ElementTy: *const Type, ConstantVals: ?[*]*const Value, Length: c_uint) *const Value;
...@@ -91,7 +91,7 @@ pub const Module = opaque {...@@ -91,7 +91,7 @@ pub const Module = opaque {
91 extern fn LLVMDisposeModule(*const Module) void;91 extern fn LLVMDisposeModule(*const Module) void;
9292
93 pub const verify = LLVMVerifyModule;93 pub const verify = LLVMVerifyModule;
94 extern fn LLVMVerifyModule(*const Module, Action: VerifierFailureAction, OutMessage: *[*:0]const u8) LLVMBool;94 extern fn LLVMVerifyModule(*const Module, Action: VerifierFailureAction, OutMessage: *[*:0]const u8) Bool;
9595
96 pub const addFunction = LLVMAddFunction;96 pub const addFunction = LLVMAddFunction;
97 extern fn LLVMAddFunction(*const Module, Name: [*:0]const u8, FunctionTy: *const Type) *const Value;97 extern fn LLVMAddFunction(*const Module, Name: [*:0]const u8, FunctionTy: *const Type) *const Value;
...@@ -191,7 +191,7 @@ pub const Builder = opaque {...@@ -191,7 +191,7 @@ pub const Builder = opaque {
191 extern fn LLVMBuildNUWSub(*const Builder, LHS: *const Value, RHS: *const Value, Name: [*:0]const u8) *const Value;191 extern fn LLVMBuildNUWSub(*const Builder, LHS: *const Value, RHS: *const Value, Name: [*:0]const u8) *const Value;
192192
193 pub const buildIntCast2 = LLVMBuildIntCast2;193 pub const buildIntCast2 = LLVMBuildIntCast2;
194 extern fn LLVMBuildIntCast2(*const Builder, Val: *const Value, DestTy: *const Type, IsSigned: LLVMBool, Name: [*:0]const u8) *const Value;194 extern fn LLVMBuildIntCast2(*const Builder, Val: *const Value, DestTy: *const Type, IsSigned: Bool, Name: [*:0]const u8) *const Value;
195195
196 pub const buildBitCast = LLVMBuildBitCast;196 pub const buildBitCast = LLVMBuildBitCast;
197 extern fn LLVMBuildBitCast(*const Builder, Val: *const Value, DestTy: *const Type, Name: [*:0]const u8) *const Value;197 extern fn LLVMBuildBitCast(*const Builder, Val: *const Value, DestTy: *const Type, Name: [*:0]const u8) *const Value;
...@@ -258,7 +258,7 @@ pub const TargetMachine = opaque {...@@ -258,7 +258,7 @@ pub const TargetMachine = opaque {
258 Filename: [*:0]const u8,258 Filename: [*:0]const u8,
259 codegen: CodeGenFileType,259 codegen: CodeGenFileType,
260 ErrorMessage: *[*:0]const u8,260 ErrorMessage: *[*:0]const u8,
261 ) LLVMBool;261 ) Bool;
262};262};
263263
264pub const CodeMode = extern enum {264pub const CodeMode = extern enum {
...@@ -295,7 +295,7 @@ pub const CodeGenFileType = extern enum {...@@ -295,7 +295,7 @@ pub const CodeGenFileType = extern enum {
295295
296pub const Target = opaque {296pub const Target = opaque {
297 pub const getFromTriple = LLVMGetTargetFromTriple;297 pub const getFromTriple = LLVMGetTargetFromTriple;
298 extern fn LLVMGetTargetFromTriple(Triple: [*:0]const u8, T: **const Target, ErrorMessage: *[*:0]const u8) LLVMBool;298 extern fn LLVMGetTargetFromTriple(Triple: [*:0]const u8, T: **const Target, ErrorMessage: *[*:0]const u8) Bool;
299};299};
300300
301extern fn LLVMInitializeAArch64TargetInfo() void;301extern fn LLVMInitializeAArch64TargetInfo() void;