Why is this an issue?

A static variable's initializer refers to another variable that does not have a defined order of initialization relative to the first. This means that the initialization may or may not work as expected depending on how the tool chooses to schedule the initializers.

How to fix it

Code examples

Noncompliant code example

package p;
  int i = 1;
endpackage

module fly;
  import p::i;
  int j = i; // Noncompliant: Initializer for static variable 'j' refers to another static variable 'i' which will be initialized in an indeterminate order
endmodule