LLVMContext();
~LLVMContext();
+ // Constant accessors
+ Constant* getNullValue(const Type* Ty);
+ Constant* getAllOnesValue(const Type* Ty);
+
// ConstantInt accessors
ConstantInt* getConstantIntTrue();
ConstantInt* getConstantIntFalse();
OpaqueType* getOpaqueType();
// StructType accessors
+ StructType* getStructType(bool isPacked=false);
StructType* getStructType(const std::vector<const Type*>& Params,
bool isPacked = false);
// PointerType accessors
PointerType* getPointerType(const Type* ElementType, unsigned AddressSpace);
- PointerType* getPointerTypeUnqualified(const Type* ElementType);
+ PointerType* getPointerTypeUnqual(const Type* ElementType);
// VectorType accessors
VectorType* getVectorType(const Type* ElementType, unsigned NumElements);
LLVMContext::LLVMContext() : pImpl(new LLVMContextImpl()) { }
LLVMContext::~LLVMContext() { delete pImpl; }
+// Constant accessors
+Constant* LLVMContext::getNullValue(const Type* Ty) {
+ return Constant::getNullValue(Ty);
+}
+
+Constant* LLVMContext::getAllOnesValue(const Type* Ty) {
+ return Constant::getAllOnesValue(Ty);
+}
+
// ConstantInt accessors.
ConstantInt* LLVMContext::getConstantIntTrue() {
return ConstantInt::getTrue();
}
// StructType accessors
+StructType* LLVMContext::getStructType(bool isPacked) {
+ return StructType::get(isPacked);
+}
+
StructType* LLVMContext::getStructType(const std::vector<const Type*>& Params,
bool isPacked) {
return StructType::get(Params, isPacked);
return PointerType::get(ElementType, AddressSpace);
}
-PointerType* LLVMContext::getPointerTypeUnqualified(const Type* ElementType) {
+PointerType* LLVMContext::getPointerTypeUnqual(const Type* ElementType) {
return PointerType::getUnqual(ElementType);
}