diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.brendan/scope4.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.brendan/scope4.C | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/scope4.C b/gcc/testsuite/g++.old-deja/g++.brendan/scope4.C new file mode 100644 index 000000000..2729ca6e6 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.brendan/scope4.C @@ -0,0 +1,31 @@ +// { dg-do assemble } +// GROUPS passed scoping +class BitString { +public: + int i; + int length() const; +}; + +typedef BitString BS; + +class V { +public: + class BitString { + public: + static int x(const ::BitString& value); + static int y(const class ::BitString& value); // should be parsed ok + static int z(const BS& value); + }; +}; + +int +V::BitString::x(const ::BitString& value) +{ return value.length(); } + +int +V::BitString::y(const class ::BitString& value) // should be parsed ok +{ return value.length(); } + +int +V::BitString::z(const BS& value) +{ return value.length(); } |