title: assigning int literal to Long in java
body: <p>I see no clear rationale for happening this ..</p>
  
  <pre><code>public  class wrappers
  {
      public static void main(String []args)
      {
          short s1=32767; // (primitive) works fine without compile error
          short s2=32768;   fails as this is  beyond short's range
  
  
          Short s3=32767; //(wrapper) works fine without compile error
          Short s4=32768; fails as this is beyond short's range
  
          long l1 =34   // (wrapper)works fine (with_in_range)
  
  
          Long l2 =34    // fails, without 34L (with_in_range)
  
      }
  </code></pre>
  
  <p>I know that when you assign <code>int</code> literal for wrapper classes, <code>valueOf()</code> is called;</p>
  
  <p>while  for <code>Short(Wrapper)</code> this seems to work  but for <code>Long(wrapper)</code> above assignments in code fail.</p>
  
  <p>Are there any rules governing these wrapper classes' assignments? </p>