mirror of
https://github.com/cc65/cc65.git
synced 2024-12-23 19:29:37 +00:00
15 lines
310 B
C
15 lines
310 B
C
|
/* Demonstrates that floating point constants are allowed in a limited way.
|
||
|
Value will be converted to an int, with a warning if precision is lost. */
|
||
|
|
||
|
int a = 3.0;
|
||
|
int b = 23.1;
|
||
|
int c = -5.0;
|
||
|
|
||
|
int main(void)
|
||
|
{
|
||
|
if (a != 3) return 1;
|
||
|
if (b != 23) return 2;
|
||
|
if (c != -5) return 3;
|
||
|
return 0;
|
||
|
}
|