[PATCH] D46631: [LLVM-C] Correct types in Go bindings
Robert Widmann via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 8 23:47:32 PDT 2018
CodaFi created this revision.
CodaFi added a reviewer: whitequark.
Herald added a subscriber: llvm-commits.
Fixes a test failure introduced in https://reviews.llvm.org/rL331114.
Repository:
rL LLVM
https://reviews.llvm.org/D46631
Files:
bindings/go/llvm/dibuilder.go
Index: bindings/go/llvm/dibuilder.go
===================================================================
--- bindings/go/llvm/dibuilder.go
+++ bindings/go/llvm/dibuilder.go
@@ -297,7 +297,7 @@
d.ref,
name,
C.size_t(len(t.Name)),
- C.ulong(t.SizeInBits),
+ C.uint64_t(t.SizeInBits),
C.unsigned(t.Encoding),
)
return Metadata{C: result}
@@ -319,8 +319,8 @@
result := C.LLVMDIBuilderCreatePointerType(
d.ref,
t.Pointee.C,
- C.ulong(t.SizeInBits),
- C.unsigned(t.AlignInBits),
+ C.uint64_t(t.SizeInBits),
+ C.uint32_t(t.AlignInBits),
C.unsigned(t.AddressSpace),
name,
C.size_t(len(t.Name)),
@@ -381,8 +381,8 @@
C.size_t(len(t.Name)),
t.File.C,
C.unsigned(t.Line),
- C.ulong(t.SizeInBits),
- C.unsigned(t.AlignInBits),
+ C.uint64_t(t.SizeInBits),
+ C.uint32_t(t.AlignInBits),
C.LLVMDIFlags(t.Flags),
t.DerivedFrom.C,
elements,
@@ -424,8 +424,8 @@
t.File.C,
C.unsigned(t.Line),
C.unsigned(t.RuntimeLang),
- C.ulong(t.SizeInBits),
- C.unsigned(t.AlignInBits),
+ C.uint64_t(t.SizeInBits),
+ C.uint32_t(t.AlignInBits),
C.LLVMDIFlags(t.Flags),
uniqueID,
C.size_t(len(t.UniqueID)),
@@ -456,9 +456,9 @@
C.size_t(len(t.Name)),
t.File.C,
C.unsigned(t.Line),
- C.ulong(t.SizeInBits),
- C.unsigned(t.AlignInBits),
- C.ulong(t.OffsetInBits),
+ C.uint64_t(t.SizeInBits),
+ C.uint32_t(t.AlignInBits),
+ C.uint64_t(t.OffsetInBits),
C.LLVMDIFlags(t.Flags),
t.Type.C,
)
@@ -488,8 +488,8 @@
subscripts, length := llvmMetadataRefs(subscriptsSlice)
result := C.LLVMDIBuilderCreateArrayType(
d.ref,
- C.ulong(t.SizeInBits),
- C.unsigned(t.AlignInBits),
+ C.uint64_t(t.SizeInBits),
+ C.uint32_t(t.AlignInBits),
t.ElementType.C,
subscripts,
length,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46631.145868.patch
Type: text/x-patch
Size: 1747 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180509/f89d4ec7/attachment.bin>
More information about the llvm-commits
mailing list