gcc/testsuite/g++.dg/other/conversion1.C
raw| 1 | // PR C++/2213 |
| 2 | // Origin: [email protected] |
| 3 | // Copyright (C), 2002 Free Software Foundation |
| 4 | // Contributed by Gabriel Dos Reis <[email protected]> |
| 5 | |
| 6 | // { dg-do compile } |
| 7 | |
| 8 | class QObject |
| 9 | { |
| 10 | }; |
| 11 | |
| 12 | int main() |
| 13 | { |
| 14 | long long m; |
| 15 | |
| 16 | (void (QObject::*)()) m; // { dg-error "3:invalid cast" } |
| 17 | } |