简体   繁体   English

LLVM-C类型相等

[英]LLVM-C types equal

使用C接口连接LLVM时 ,如何确定两个LLVMTypeRef是否表示相同类型?

IIUC, if the two types were created in the same LLVMContext it should be the same pointer, since types are uniqued in LLVM. IIUC,如果两个类型是在相同的LLVMContext中创建的,则它应该是相同的指针,因为类型在LLVM中是唯一的。 C API functions use wrap to "convert" C++ Type to LLVMTypeRef , which just uses reinterpret_cast on the pointer. C API函数使用wrap将C ++ Type “转换”为LLVMTypeRef ,后者仅在指针上使用reinterpret_cast

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM