8015686: {Int|Long}SummaryStatistics toString() throws IllegalFormatConversionException
authormduigou
Fri, 31 May 2013 11:06:04 -0700
changeset 17927 dc3d1b30cb78
parent 17922 d56eec572de5
child 17928 717ffe79604d
8015686: {Int|Long}SummaryStatistics toString() throws IllegalFormatConversionException Reviewed-by: dholmes, alanb, psandoz
jdk/src/share/classes/java/util/IntSummaryStatistics.java
jdk/src/share/classes/java/util/LongSummaryStatistics.java
--- a/jdk/src/share/classes/java/util/IntSummaryStatistics.java	Fri May 31 12:17:30 2013 +0100
+++ b/jdk/src/share/classes/java/util/IntSummaryStatistics.java	Fri May 31 11:06:04 2013 -0700
@@ -159,7 +159,7 @@
      */
     public String toString() {
         return String.format(
-            "%s{count=%d, sum=%d, min=%d, average=%d, max=%d}",
+            "%s{count=%d, sum=%d, min=%d, average=%f, max=%d}",
             this.getClass().getSimpleName(),
             getCount(),
             getSum(),
--- a/jdk/src/share/classes/java/util/LongSummaryStatistics.java	Fri May 31 12:17:30 2013 +0100
+++ b/jdk/src/share/classes/java/util/LongSummaryStatistics.java	Fri May 31 11:06:04 2013 -0700
@@ -171,7 +171,7 @@
      */
     public String toString() {
         return String.format(
-            "%s{count=%d, sum=%d, min=%d, average=%d, max=%d}",
+            "%s{count=%d, sum=%d, min=%d, average=%f, max=%d}",
             this.getClass().getSimpleName(),
             getCount(),
             getSum(),