Skip to content

Compile-time If Bugfix

Compare
Choose a tag to compare
@zhiayang zhiayang released this 04 Oct 17:13
· 1732 commits to deedd4e496ec2062aab741dbd220e49deaf4b689 since this release

Oops, fixed a bug where the first branch of an #if had scoping issues where the declarations were not correctly placed at the top-level scope.

Also, there are obvious security implications for being able to #run arbitrary code at compile-time, eg. #run system("rm -rf /*") (thanks, sim642), especially from an imported library.

We'll probably disable calling out to external functions during compile time, or have some way to change that (flag, or directive on imports, or something).