re PR c++/57064 ([clarification requested] Which overload with ref-qualifier should...
authorJason Merrill <jason@gcc.gnu.org>
Thu, 25 Apr 2013 16:24:49 +0000 (12:24 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Thu, 25 Apr 2013 16:24:49 +0000 (12:24 -0400)
PR c++/57064
* g++.dg/cpp0x/ref-qual9.C: New.

From-SVN: r198311

gcc/testsuite/g++.dg/cpp0x/ref-qual9.C [new file with mode: 0644]

diff --git a/gcc/testsuite/g++.dg/cpp0x/ref-qual9.C b/gcc/testsuite/g++.dg/cpp0x/ref-qual9.C
new file mode 100644 (file)
index 0000000..cdb8d68
--- /dev/null
@@ -0,0 +1,14 @@
+// PR c++/57064
+// { dg-require-effective-target c++11 }
+
+template <class T> T&& move(T& t);
+
+struct A {
+  void p() &;
+  int p() &&;
+};
+
+void g(A &&a)
+{
+  int i = move(a).p();
+}