diff options
Diffstat (limited to 'gcc/testsuite/g++.dg/ext/is_base_of_diagnostic.C')
-rw-r--r-- | gcc/testsuite/g++.dg/ext/is_base_of_diagnostic.C | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/ext/is_base_of_diagnostic.C b/gcc/testsuite/g++.dg/ext/is_base_of_diagnostic.C new file mode 100644 index 000000000..8cb1ce38f --- /dev/null +++ b/gcc/testsuite/g++.dg/ext/is_base_of_diagnostic.C @@ -0,0 +1,15 @@ +class A +{ }; + +class B; + +union C +{ }; + +union D; + +void f() +{ + __is_base_of(A, B); // { dg-error "incomplete type" } + __is_base_of(C, D); +} |