diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-06-17 22:50:06 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-06-17 22:50:06 +0000 |
commit | 0ffd9ffb633ca4886c7db4dd12dc36bdad3d797c (patch) | |
tree | 5eb5663995e1352ad9eb66794b1586af3d512488 /include/clang | |
parent | f5cecfbdcd20be224861f9e67c5973a9a2b61512 (diff) |
Implement correct name lookup inside an initializer of a C++ class static data member.
Fixes "test/CXX/basic/basic.lookup/basic.lookup.unqual/p13.cpp" test case.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@73652 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang')
-rw-r--r-- | include/clang/Parse/Action.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/clang/Parse/Action.h b/include/clang/Parse/Action.h index f1207e4f0f..ba480c5b7c 100644 --- a/include/clang/Parse/Action.h +++ b/include/clang/Parse/Action.h @@ -248,6 +248,19 @@ public: virtual void ActOnCXXExitDeclaratorScope(Scope *S, const CXXScopeSpec &SS) { } + /// ActOnCXXEnterDeclInitializer - Invoked when we are about to parse an + /// initializer for the declaration 'Dcl'. + /// After this method is called, according to [C++ 3.4.1p13], if 'Dcl' is a + /// static data member of class X, names should be looked up in the scope of + /// class X. + virtual void ActOnCXXEnterDeclInitializer(Scope *S, DeclPtrTy Dcl) { + } + + /// ActOnCXXExitDeclInitializer - Invoked after we are finished parsing an + /// initializer for the declaration 'Dcl'. + virtual void ActOnCXXExitDeclInitializer(Scope *S, DeclPtrTy Dcl) { + } + /// ActOnDeclarator - This callback is invoked when a declarator is parsed and /// 'Init' specifies the initializer if any. This is for things like: /// "int X = 4" or "typedef int foo". |