Files
c3c/test/test_suite/cast/cast_parse_fails.c3
2021-05-18 14:57:41 +02:00

14 lines
303 B
Plaintext

struct Foo { int a; }
func void test2()
{
int x = int({ 32 }); // #error: 'int' cannot use compound literal initialization, did you intend to use a cast
}
func void test3()
{
int x = int(32); // #error: A type cannot be followed by (), if you intended a cast, use (type)(expression)
}