emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] scratch/merge-cedet-tests 4ab930b 225/316: C++: Deal with


From: Edward John Steere
Subject: [Emacs-diffs] scratch/merge-cedet-tests 4ab930b 225/316: C++: Deal with 'using' statements when calculating scope
Date: Fri, 27 Jan 2017 20:03:42 +0000 (UTC)

branch: scratch/merge-cedet-tests
commit 4ab930bc8617be1eca7492ec85471d37b6d4c9d5
Author: David Engster <address@hidden>
Commit: Edward John Steere <address@hidden>

    C++: Deal with 'using' statements when calculating scope
    
    * semantic/bovine/c.el (semantic-ctxt-scoped-types): Go through all
      tags around point and search them for using statements.  Before, we
      skipped the last one thinking that it would have to be function, but
      it could also be a type.
    
    * semantic/scope.el (semantic-completable-tags-from-type): When
      creating the list of completable types, pull in types which are
      referenced through 'using' statements.
    
    * tests/cedet/semantic/test/manual/cedet/testusing.cpp:
    * tests/cedet/semantic/test/manual/cedet/testusing.hh: Add tests for
      the above.
---
 test/manual/cedet/cedet/semantic/tests/testusing.hh |   16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/test/manual/cedet/cedet/semantic/tests/testusing.hh 
b/test/manual/cedet/cedet/semantic/tests/testusing.hh
index 61b5d08..471891a 100644
--- a/test/manual/cedet/cedet/semantic/tests/testusing.hh
+++ b/test/manual/cedet/cedet/semantic/tests/testusing.hh
@@ -123,6 +123,22 @@ namespace outer {
   }
 }
 
+// Namespace which pulls in one of its own nested namespaces
+namespace first {
+  class AAA1;
+  namespace second {
+    class AAA2;
+  }
+  // Elevate nested namespace into first one
+  using namespace second;
+}
+
+namespace third {
+  using namespace first;
+  class AAA3;
+}
+
+
 // Elevate the first struct into 'outer'
 // so that we can access it via 'outer::StructNested'
 namespace outer {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]