Amber
Amber copied to clipboard
[Feature] Compiler flags for any block
I think using compiler flags only for functions is too restrictive and should be broaden to all blocks.
For example this code:
main {
let x = "asd"
echo x as Num
}
Raises warning that it's not recommended to do such a cast and recommends adding allow_absurd_cast compiler flag for suppression, but it's not possible currently
so the proposed syntax would be:
main {
let x = "asd"
#[allow_absurd_cast]
echo x as num
}
To sum things up. I understand that this feature should be implemented for statements as well as for blocks