aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-12-14 06:51:39 +0000
committerJohn McCall <rjmccall@apple.com>2010-12-14 06:51:39 +0000
commit0e88aa7100da32acc63bc8a4dcb946ed517868f1 (patch)
tree1e40b8565309154c96cb5997ad4f615a0b8d6ff4 /lib/CodeGen
parent54eeba75d3914e457204a159a7888fc19e50a6dc (diff)
Factor out most of the extra state in a FunctionProtoType into a separate
class to be passed around. The line between argument and return types and everything else is kindof vague, but I think it's justifiable. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@121752 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen')
-rw-r--r--lib/CodeGen/CodeGenFunction.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/CodeGen/CodeGenFunction.cpp b/lib/CodeGen/CodeGenFunction.cpp
index 7bd0c3da9e..8a0d78cc21 100644
--- a/lib/CodeGen/CodeGenFunction.cpp
+++ b/lib/CodeGen/CodeGenFunction.cpp
@@ -250,13 +250,14 @@ void CodeGenFunction::StartFunction(GlobalDecl GD, QualType RetTy,
Builder.SetInsertPoint(EntryBB);
- QualType FnType = getContext().getFunctionType(RetTy, 0, 0, false, 0,
- false, false, 0, 0,
- /*FIXME?*/
- FunctionType::ExtInfo());
-
// Emit subprogram debug descriptor.
if (CGDebugInfo *DI = getDebugInfo()) {
+ // FIXME: what is going on here and why does it ignore all these
+ // interesting type properties?
+ QualType FnType =
+ getContext().getFunctionType(RetTy, 0, 0,
+ FunctionProtoType::ExtProtoInfo());
+
DI->setLocation(StartLoc);
DI->EmitFunctionStart(GD, FnType, CurFn, Builder);
}