changeset 49517:a7777856ae98

8200364: Remove unnecessary boxing via primitive wrapper valueOf(String) methods Reviewed-by: dfuchs, alanb
author martin
date Mon, 02 Apr 2018 17:09:29 -0700
parents 94ca39ef0b39
children ba93b3928e7c
files src/java.base/share/classes/java/text/ChoiceFormat.java src/java.logging/share/classes/java/util/logging/Logger.java
diffstat 2 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/java.base/share/classes/java/text/ChoiceFormat.java	Mon Apr 02 17:08:00 2018 -0700
+++ b/src/java.base/share/classes/java/text/ChoiceFormat.java	Mon Apr 02 17:09:29 2018 -0700
@@ -212,7 +212,7 @@
                 } else if (tempBuffer.equals("-\u221E")) {
                     startValue = Double.NEGATIVE_INFINITY;
                 } else {
-                    startValue = Double.valueOf(tempBuffer);
+                    startValue = Double.parseDouble(tempBuffer);
                 }
 
                 if (ch == '<' && startValue != Double.POSITIVE_INFINITY &&
--- a/src/java.logging/share/classes/java/util/logging/Logger.java	Mon Apr 02 17:08:00 2018 -0700
+++ b/src/java.logging/share/classes/java/util/logging/Logger.java	Mon Apr 02 17:09:29 2018 -0700
@@ -640,7 +640,7 @@
                     return System.getProperty(key);
                 }
             });
-            return Boolean.valueOf(s);
+            return Boolean.parseBoolean(s);
         }
     }