Debian Codegraph @

gcc/testsuite/g++.target/nvptx/exceptions-bad_cast-2.C

raw
1 /* 'std::bad_cast' exception, caught. */
2
3 /* Via the magic string "-std=*++" indicate that testing one (the default) C++ standard is sufficient. */
4 /* { dg-additional-options -fexceptions } */
5 /* { dg-additional-options -mno-fake-exceptions } */
6 /* { dg-additional-options -fdump-tree-optimized-raw } */
7
8 #include "../../../../libgomp/testsuite/libgomp.oacc-c++/exceptions-bad_cast-2.C"
9
10 /* { dg-final { scan-tree-dump-times {gimple_call <__cxa_bad_cast, } 1 optimized } }
11 Compilation fails:
12 { dg-regexp {[^\r\n]+: In function 'int main\(\)':[\r\n]+(?:[^\r\n]+: sorry, unimplemented: exception handling not supported[\r\n]+)+} }
13 (Note, using 'dg-regexp' instead of 'dg-message', as the former runs before the auto-mark-UNSUPPORTED.) */