title: No error on import static Singleton in java
body: <p>I have followed Singleton:</p>
  
  <pre><code>public class GameConfig {
  
      private static GameConfig mGameConfig = null;
  
      private String mStr = "Boo";
  
      public static GameConfig getInstance(){
  
      if(mGameConfig == null){
          mGameConfig = new GameConfig();
      }
  
      return mGameConfig;
  }
  
      private GameConfig(){}
  
      public String getStr() {
        return mStr;
      }
  }
  </code></pre>
  
  <p>Now I try to do some experiment:</p>
  
  <p>Lets say I have other class <code>User</code> that goes to use this singelton:</p>
  
  <pre><code>public class User{
  
    ....
  
    private void init(){
      String str = GameConfig.getInstance().getStr();
    }
  
  }
  </code></pre>
  
  <p>So far so good.</p>
  
  <p>I'll take above mentioned class <code>User</code> and add <code>import static</code>:</p>
  
  <pre><code>import static com.app.utils.GameConfig.getInstance; // no error, why?? 
  
  public class User{
  
    ....
  
    private void init(){
      String str = GameConfig.getInstance().getStr();
  
      //  I can't type 
      // String str = getStr(); !!
      // getInstance return instance
    }
  }
  </code></pre>