Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/g++.dg/cpp0x/trailing8.C @ 152:2b5abeee2509
update gcc11
author | anatofuz |
---|---|
date | Mon, 25 May 2020 07:50:57 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
// PR c++/54359 // { dg-require-effective-target c++11 } int& ref(int& x) { return x; } const int& ref(const int& x) { return x; } class A { int x; int f() const; auto test1() const -> decltype(this); auto test2() const -> decltype(ref(x)); auto test3() const -> decltype(f()); }; auto A::test1() const -> decltype(this) { return this; } auto A::test2() const -> decltype(ref(x)) { return ref(x); } auto A::test3() const -> decltype(f()) { return f(); }