diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2010-03-30 20:24:48 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2010-03-30 20:24:48 +0000 |
commit | c50c27cca870fa033f3694a29ae78cc1821889e6 (patch) | |
tree | af51eec7f9a5980d187532d92f6f4ea36646c8a6 /clang/lib/Sema/SemaExpr.cpp | |
parent | 04c713dd4515087eccbc1c57677a8bbeebb67e35 (diff) | |
download | bcm5719-llvm-c50c27cca870fa033f3694a29ae78cc1821889e6.tar.gz bcm5719-llvm-c50c27cca870fa033f3694a29ae78cc1821889e6.zip |
the big refactoring bits of PR3782.
This introduces FunctionType::ExtInfo to hold the calling convention and the
noreturn attribute. The next patch will extend it to include the regparm
attribute and fix the bug.
llvm-svn: 99920
Diffstat (limited to 'clang/lib/Sema/SemaExpr.cpp')
-rw-r--r-- | clang/lib/Sema/SemaExpr.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/lib/Sema/SemaExpr.cpp b/clang/lib/Sema/SemaExpr.cpp index 4bf26a5224e..0c9b3bd44bf 100644 --- a/clang/lib/Sema/SemaExpr.cpp +++ b/clang/lib/Sema/SemaExpr.cpp @@ -6851,8 +6851,8 @@ void Sema::ActOnBlockArguments(Declarator &ParamInfo, Scope *CurScope) { // The parameter list is optional, if there was none, assume (). if (!T->isFunctionType()) - T = Context.getFunctionType(T, 0, 0, false, 0, false, false, 0, 0, false, - CC_Default); + T = Context.getFunctionType(T, 0, 0, false, 0, false, false, 0, 0, + FunctionType::ExtInfo()); CurBlock->hasPrototype = true; CurBlock->isVariadic = false; @@ -6977,11 +6977,11 @@ Sema::OwningExprResult Sema::ActOnBlockStmtExpr(SourceLocation CaretLoc, QualType BlockTy; if (!BSI->hasPrototype) BlockTy = Context.getFunctionType(RetTy, 0, 0, false, 0, false, false, 0, 0, - NoReturn, CC_Default); + FunctionType::ExtInfo(NoReturn, CC_Default)); else BlockTy = Context.getFunctionType(RetTy, ArgTypes.data(), ArgTypes.size(), BSI->isVariadic, 0, false, false, 0, 0, - NoReturn, CC_Default); + FunctionType::ExtInfo(NoReturn, CC_Default)); // FIXME: Check that return/parameter types are complete/non-abstract DiagnoseUnusedParameters(BSI->Params.begin(), BSI->Params.end()); |