Are global static variables within a file comparable to a local static variable within a function? : <p>I know declaring a global variable as STATIC will make it visible to the current file. Does the variable retain its data every time functions are called within the file?</p>

<p>For example,</p>

<p>Let's say some file calls func1() below, which modifies the static global variable data and then calls func2() which modifies it again.</p>

<p>The next time a file calls func1(), will it be modifying a new data variable struct? or will it preserve the previous data that was modified in the first call?</p>

<pre><code>STATIC MY_DATA  Data1;

void func1( ){
   //modify Data1
   func2(Data1);
}

void func2 (MY_DATA data){
    // modify data 
}
</code></pre>
