https://issues.dlang.org/show_bug.cgi?id=7386
KytoDragon <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #4 from KytoDragon <[email protected]> --- (In reply to anonymous4 from comment #3) > It feels like version is a lightweight feature and is processed early as it > doesn't depend much on semantics of the surrounding code, while static if > tends to be processed on later stages as it needs module that passed most > semantic checks. > As a workaround the original example can simply use static if everywhere; > static if can inspect versions too: see issue 7417 There are few bugs related to static if (see https://issues.dlang.org/show_bug.cgi?id=20905), so replacing all versions with static if is not currently possible. --
