[llvm] r174924 - DIBuilder: make the return type of createBasicType more specific
David Blaikie
dblaikie at gmail.com
Mon Feb 11 16:40:42 PST 2013
Author: dblaikie
Date: Mon Feb 11 18:40:41 2013
New Revision: 174924
URL: http://llvm.org/viewvc/llvm-project?rev=174924&view=rev
Log:
DIBuilder: make the return type of createBasicType more specific
Modified:
llvm/trunk/include/llvm/DIBuilder.h
llvm/trunk/lib/IR/DIBuilder.cpp
Modified: llvm/trunk/include/llvm/DIBuilder.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/DIBuilder.h?rev=174924&r1=174923&r2=174924&view=diff
==============================================================================
--- llvm/trunk/include/llvm/DIBuilder.h (original)
+++ llvm/trunk/include/llvm/DIBuilder.h Mon Feb 11 18:40:41 2013
@@ -28,6 +28,7 @@ namespace llvm {
class LLVMContext;
class MDNode;
class StringRef;
+ class DIBasicType;
class DIDescriptor;
class DIFile;
class DIEnumerator;
@@ -108,8 +109,8 @@ namespace llvm {
/// @param SizeInBits Size of the type.
/// @param AlignInBits Type alignment.
/// @param Encoding DWARF encoding code, e.g. dwarf::DW_ATE_float.
- DIType createBasicType(StringRef Name, uint64_t SizeInBits,
- uint64_t AlignInBits, unsigned Encoding);
+ DIBasicType createBasicType(StringRef Name, uint64_t SizeInBits,
+ uint64_t AlignInBits, unsigned Encoding);
/// createQualifiedType - Create debugging information entry for a qualified
/// type, e.g. 'const int'.
Modified: llvm/trunk/lib/IR/DIBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/DIBuilder.cpp?rev=174924&r1=174923&r2=174924&view=diff
==============================================================================
--- llvm/trunk/lib/IR/DIBuilder.cpp (original)
+++ llvm/trunk/lib/IR/DIBuilder.cpp Mon Feb 11 18:40:41 2013
@@ -162,9 +162,9 @@ DIType DIBuilder::createNullPtrType(Stri
/// createBasicType - Create debugging information entry for a basic
/// type, e.g 'char'.
-DIType DIBuilder::createBasicType(StringRef Name, uint64_t SizeInBits,
- uint64_t AlignInBits,
- unsigned Encoding) {
+DIBasicType
+DIBuilder::createBasicType(StringRef Name, uint64_t SizeInBits,
+ uint64_t AlignInBits, unsigned Encoding) {
assert(!Name.empty() && "Unable to create type without name");
// Basic types are encoded in DIBasicType format. Line number, filename,
// offset and flags are always empty here.
@@ -180,7 +180,7 @@ DIType DIBuilder::createBasicType(String
ConstantInt::get(Type::getInt32Ty(VMContext), 0), // Flags;
ConstantInt::get(Type::getInt32Ty(VMContext), Encoding)
};
- return DIType(MDNode::get(VMContext, Elts));
+ return DIBasicType(MDNode::get(VMContext, Elts));
}
/// createQualifiedType - Create debugging information entry for a qualified
More information about the llvm-commits
mailing list