Accessing a global static variable from another class
<p>I am working with code that has a global static variable (which is an object) and I need access to it from another class. I have always avoided global variables/functions in general so in this situation I am not sure how to go about it properly. </p>

<p>Just to clear my understand of things, in a global static variable has internal linkage, which means that any source file that includes this particular header will get its own copy of the variable? </p>

<p>EDIT: What I have tried so far is making a function which returns the address of the variable. Unfortunately, that does not seem to be working.</p>

<pre><code>// names were changed but the code is as follows. 
// There is of course other code in the header
namespace SomeNameSpace
{
    static anArray&lt;someObject&gt; variable;
}
</code></pre>

<blockquote>
  <p><strong>NOTE:</strong> I <em>cannot change the code</em> in the header where the global static variable is declared. I <em>can</em> add functions but I should try to avoid it if I can.</p>
</blockquote>
