Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/g++.dg/DRs/dr1207-1.C @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | |
children |
rev | line source |
---|---|
145 | 1 // DR 1207 |
2 // PR c++/52869 | |
3 // { dg-do compile { target c++11 } } | |
4 | |
5 struct S { | |
6 void f() { } | |
7 void g() noexcept(noexcept(f())) { } | |
8 void h() noexcept(noexcept(this->f())) { } | |
9 }; | |
10 | |
11 struct Nyan { | |
12 Nyan &operator++() noexcept { return *this; } | |
13 void omg() noexcept(noexcept(++*this)) {} | |
14 }; | |
15 | |
16 template <class T> | |
17 class Test{ | |
18 T count; | |
19 Test (T arg) {count=arg;} | |
20 void fetch() { } | |
21 T inc () noexcept(noexcept(this->fetch())) {return ++count;} | |
22 T dec () noexcept(noexcept(fetch())) { return --count;} | |
23 }; |