aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.mike/p4484.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.mike/p4484.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/p4484.C26
1 files changed, 26 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/p4484.C b/gcc/testsuite/g++.old-deja/g++.mike/p4484.C
new file mode 100644
index 00000000000..64aab160965
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.mike/p4484.C
@@ -0,0 +1,26 @@
+// Build don't link:
+// prms-id: 4484
+
+class A {
+ char buf[64];
+};
+
+typedef void (A::*pmf)();
+typedef void (A::*pmfc)() const;
+
+pmfc p = (pmfc)(pmf)0;
+
+class B {
+};
+
+class D : public A, public B {
+};
+
+typedef int (B::*bmfp)();
+typedef int (D::*dmfp)();
+
+bmfp foo;
+
+void bar(dmfp a) {
+ bar(foo);
+}