diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2010-11-30 17:35:24 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2010-11-30 17:35:24 +0000 |
commit | 67aba816901503d9cf7ba699525fa62cc7f8e5e4 (patch) | |
tree | cdf41986024677632d6c4ca9e373b01d1d481b29 /lib/Sema/SemaExpr.cpp | |
parent | 7e4857931bfe27bb355275bc7ec1eaa44612dfff (diff) |
Such function decls,as objc's objc_msgSend, builtins in
a specific language. We are adding such language info. by
extensing Builtins.def and via a language flag added
to LIBBUILTIN/BUILTIN and check for that when deciding
a name is builtin or not. Implements //rdar://8689273.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120429 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
-rw-r--r-- | lib/Sema/SemaExpr.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 39a51c1acd..c115061164 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -4305,13 +4305,8 @@ Sema::BuildResolvedCallExpr(Expr *Fn, NamedDecl *NDecl, if (CheckFunctionCall(FDecl, TheCall)) return ExprError(); - if (unsigned BuiltinID = FDecl->getBuiltinID()) { - // When not in Objective-C mode, there is no builtin 'id' type. - // We won't have pre-defined library functions which use this type. - if (getLangOptions().ObjC1 || - Context.BuiltinInfo.GetTypeString(BuiltinID)[0] != 'G') - return CheckBuiltinFunctionCall(BuiltinID, TheCall); - } + if (unsigned BuiltinID = FDecl->getBuiltinID()) + return CheckBuiltinFunctionCall(BuiltinID, TheCall); } else if (NDecl) { if (CheckBlockCall(NDecl, TheCall)) return ExprError(); |