* g++.old-deja/g++.pt/ptrmem5.C: New test.
authorAlexandre Oliva <oliva@dcc.unicamp.br>
Sun, 20 Dec 1998 07:45:13 +0000 (07:45 +0000)
committerAlexandre Oliva <oliva@gcc.gnu.org>
Sun, 20 Dec 1998 07:45:13 +0000 (07:45 +0000)
From-SVN: r24385

gcc/testsuite/ChangeLog
gcc/testsuite/g++.old-deja/g++.pt/ptrmem5.C [new file with mode: 0644]

index 3c43d9337f0cbfea5792167dbd9b9ee36d0bd304..3978ce366a74b919bba273c8e172850163c504c7 100644 (file)
@@ -1,3 +1,7 @@
+1998-12-20  Alexandre Oliva  <oliva@dcc.unicamp.br>
+
+       * g++.old-deja/g++.pt/ptrmem5.C: New test.
+
 1998-12-15  Alexandre Oliva  <oliva@dcc.unicamp.br>
 
        * g++.old-deja/g++.other/conv5.C: New test.
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/ptrmem5.C b/gcc/testsuite/g++.old-deja/g++.pt/ptrmem5.C
new file mode 100644 (file)
index 0000000..c9e6c9b
--- /dev/null
@@ -0,0 +1,17 @@
+// Build don't link:
+
+// Based on testcase by adriang@campbellsoft.com
+
+struct Null {
+  template <typename T> operator T*() { return 0; }
+  template <typename C, typename T> operator T C::*() { return 0; }
+#if WORK_AROUND
+  typedef int pmf();
+  template <typename C> operator pmf C::* () { return 0; }
+#endif
+} NULL;
+
+int *pd = NULL;
+int (*pf)() = NULL;
+int Null::*pmd = NULL;
+int (Null::*pmf)() = NULL; // gets bogus error - cannot convert - XFAIL *-*-*