-
Notifications
You must be signed in to change notification settings - Fork 13.4k
C API type mismatch in ArrayType initializer #56496
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
Please excuse my ignorance: is it as simple as changing https://github.com/llvm/llvm-project/blob/d71a8ad/llvm/lib/IR/Core.cpp#L778-L780 |
No, that would be an ABI break. Instead LLVMArrayType2 with the new type would have to be added. |
Fixes llvm/llvm-project#56496. As mentioned in the issue, new functions LLVMArrayType2 and LLVMGetArrayLength2 are created so as to not break the old API. The old methods are then marked as deprecated and callers are updated. Differential Revision: https://reviews.llvm.org/D143700
Fixes llvm/llvm-project#56496. As mentioned in the issue, new functions LLVMArrayType2 and LLVMGetArrayLength2 are created so as to not break the old API. The old methods are then marked as deprecated and callers are updated. Differential Revision: https://reviews.llvm.org/D143700
https://github.com/llvm/llvm-project/blob/23d8eca/llvm/include/llvm/IR/DerivedTypes.h#L372-L373
https://github.com/llvm/llvm-project/blob/23d8eca/llvm/include/llvm-c/Core.h#L1429-L1437
C++ API use
uint64_t
and C API usesunsigned
and thus gets truncated when trying to create largerArrayType
sThe text was updated successfully, but these errors were encountered: