summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/cond3.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/cond3.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/cond3.C25
1 files changed, 25 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/cond3.C b/gcc/testsuite/g++.old-deja/g++.pt/cond3.C
new file mode 100644
index 000000000..e82b686e9
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.pt/cond3.C
@@ -0,0 +1,25 @@
+// { dg-do assemble }
+// Origin: Loring Holden <lsh@lsh.cs.brown.edu>
+
+template <class T>
+class REFptr {
+ public:
+ operator T* () const;
+};
+
+class CamFocus;
+typedef REFptr<CamFocus> CamFocusptr;
+
+class CamFocus {
+ protected:
+ static CamFocusptr _focus;
+ public :
+ static CamFocusptr &cur() { return _focus; }
+};
+
+void
+test()
+{
+ if (CamFocus::cur()) {
+ }
+}