diff options
author | Meador Inge <meadori@codesourcery.com> | 2012-06-16 03:34:49 +0000 |
---|---|---|
committer | Meador Inge <meadori@codesourcery.com> | 2012-06-16 03:34:49 +0000 |
commit | c5613b26a24a33d7450e3d0bf315c6ccc920ce7b (patch) | |
tree | fb0bf936909135582b7dfb9ebb4d7300ec0fddf8 /lib/Sema | |
parent | 860a319e62b0e256817a458396d191aa91c0787a (diff) |
Explicitly build __builtin_va_list.
The target specific __builtin_va_list types are now explicitly built instead
of injecting strings into the preprocessor input.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@158592 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema')
-rw-r--r-- | lib/Sema/Sema.cpp | 4 | ||||
-rw-r--r-- | lib/Sema/SemaDecl.cpp | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/lib/Sema/Sema.cpp b/lib/Sema/Sema.cpp index 39338f983e..6323589bd8 100644 --- a/lib/Sema/Sema.cpp +++ b/lib/Sema/Sema.cpp @@ -180,6 +180,10 @@ void Sema::Initialize() { if (IdResolver.begin(Protocol) == IdResolver.end()) PushOnScopeChains(Context.getObjCProtocolDecl(), TUScope); } + + DeclarationName BuiltinVaList = &Context.Idents.get("__builtin_va_list"); + if (IdResolver.begin(BuiltinVaList) == IdResolver.end()) + PushOnScopeChains(Context.getBuiltinVaListDecl(), TUScope); } Sema::~Sema() { diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp index be62818c20..d98ce6b0a6 100644 --- a/lib/Sema/SemaDecl.cpp +++ b/lib/Sema/SemaDecl.cpp @@ -3930,8 +3930,6 @@ Sema::ActOnTypedefNameDecl(Scope *S, DeclContext *DC, TypedefNameDecl *NewTD, Context.setsigjmp_bufDecl(NewTD); else if (II->isStr("ucontext_t")) Context.setucontext_tDecl(NewTD); - else if (II->isStr("__builtin_va_list")) - Context.setBuiltinVaListType(Context.getTypedefType(NewTD)); } return NewTD; |