mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
Change cast and int rules: constant folding always starts. Promotion using left side on all operands to bit width. Implicit narrowing to max size on right hand side.
This commit is contained in:
committed by
Christoffer Lerno
parent
8a7f37e4d3
commit
07595df412
@@ -13,6 +13,6 @@ func void test2()
|
||||
func void test3()
|
||||
{
|
||||
uint myUInt = 1;
|
||||
int* p2 = cast(myUInt as int*);
|
||||
int* p2 = cast(myUInt as int*); // #error: Cannot cast 'uint' to 'int*'.
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user