]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/g++.dg/tm/static_cast1.C
Implement N4514, C++ Extensions for Transactional Memory.
[thirdparty/gcc.git] / gcc / testsuite / g++.dg / tm / static_cast1.C
1 // The inverse of a transaction-safety conversion cannot be performed with
2 // static_cast.
3 // { dg-options "-fgnu-tm" }
4
5 typedef void (*TS)() transaction_safe;
6 void f()
7 {
8 static_cast<TS>(f); // { dg-error "static_cast" }
9 }