title: Why does Eclipse create a Boolean object rather than a primitive type on "create local variable"?
body: <p>I just debugged code and saw a strange behavior of Eclipse Mars.2 Release (4.5.2). I've done something like</p>
  
  <pre><code>debug1 = aMethod();
  
  private boolean aMethod() {(...)};
  </code></pre>
  
  <p>Of course the IDE gives a warning that debug1 can't be resolved to a variable and provides the quick fix "create local variable debug1". I use this very often if I have to debug code I'm not familiar with. I just can create a few debug variables without checking what the particular method returns. </p>
  
  <p>However, I recognized that Eclipse changes the above code to</p>
  
  <pre><code>Boolean debug1 = aMethod();
  </code></pre>
  
  <p>So, it creates a Boolean-object variable rather than a primitive type. Shouldn't the object be the special case rather than the default behavior? Why is it the default behavior then? </p>