src/share/classes/com/sun/tools/hat/internal/model/JavaLazyReadObject.java

Print this page
rev 10195 : 8048267: Replace uses of 'new Long()' with appropriate alternative across core classes
Reviewed-by: chegar, psandoz
Contributed-by: Otavio Santana <otaviojava@java.net>

@@ -100,11 +100,11 @@
     // make Integer or Long for given object ID
     protected static Number makeId(long id) {
         if ((id & ~Snapshot.SMALL_ID_MASK) == 0) {
             return new Integer((int)id);
         } else {
-            return new Long(id);
+            return id;
         }
     }
 
     // get ID as long value from Number
     protected static long getIdValue(Number num) {