• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[vJASS] Static if in Zinc

Status
Not open for further replies.
Level 20
Joined
Jul 6, 2009
Messages
1,885
I've got a small problem - i've started using Zinc and i get compile error when i try to use a static if outside a function. Am i doing something wrong or they generally don't work outside of functions in Zinc?
This, for example, gives a compile error saying that "static" is unexpected:
JASS:
//! zinc
library lol
{
    static if (true)
    {
    }

}
//! endzinc
While this works properly:
JASS:
//! zinc
library lol
{
    function lolz()
    {
        static if (true)
        {
        }
    }
}
//! endzinc
 
Status
Not open for further replies.
Top