texlive[61655] Build/source/libs/icu: more 10.0 to placate C++

commits+karl at tug.org commits+karl at tug.org
Wed Jan 19 00:09:54 CET 2022


Revision: 61655
          http://tug.org/svn/texlive?view=revision&revision=61655
Author:   karl
Date:     2022-01-19 00:09:53 +0100 (Wed, 19 Jan 2022)
Log Message:
-----------
more 10.0 to placate C++

Modified Paths:
--------------
    trunk/Build/source/libs/icu/TLpatches/patch-15-pow
    trunk/Build/source/libs/icu/icu-src/source/i18n/plurrule.cpp

Modified: trunk/Build/source/libs/icu/TLpatches/patch-15-pow
===================================================================
--- trunk/Build/source/libs/icu/TLpatches/patch-15-pow	2022-01-18 22:17:46 UTC (rev 61654)
+++ trunk/Build/source/libs/icu/TLpatches/patch-15-pow	2022-01-18 23:09:53 UTC (rev 61655)
@@ -2,9 +2,19 @@
 libs/icu/icu-src/source/i18n/plurrule.cpp:1884:90:
 error: call of overloaded 'pow(int, const int32_t&)' is ambiguous
 	per https://tug.org/pipermail/tlbuild/2022q1/005020.html.
+	-> https://github.com/unicode-org/icu/pull/1961
 
---- plurrule.cpp	(revision 61627)
+--- plurrule.cpp	(revision 61625)
 +++ plurrule.cpp	(working copy)
+@@ -1628,7 +1628,7 @@
+     init(n, v, f, e);
+     // check values. TODO make into unit test.
+     //            
+-    //            long visiblePower = (int) Math.pow(10, v);
++    //            long visiblePower = (int) Math.pow(10.0, v);
+     //            if (decimalDigits > visiblePower) {
+     //                throw new IllegalArgumentException();
+     //            }
 @@ -1881,7 +1881,7 @@
  
  double FixedDecimal::getPluralOperand(PluralOperand operand) const {
@@ -14,3 +24,20 @@
          case PLURAL_OPERAND_I: return (double) longValue();
          case PLURAL_OPERAND_F: return static_cast<double>(decimalDigits);
          case PLURAL_OPERAND_T: return static_cast<double>(decimalDigitsWithoutTrailingZeros);
+@@ -1932,14 +1932,14 @@
+ }
+ 
+ double FixedDecimal::doubleValue() const {
+-    return (isNegative ? -source : source) * pow(10, exponent);
++    return (isNegative ? -source : source) * pow(10.0, exponent);
+ }
+ 
+ int64_t FixedDecimal::longValue() const {
+     if (exponent == 0) {
+         return intValue;
+     } else {
+-        return (long) (pow(10, exponent) * intValue);
++        return (long) (pow(10.0, exponent) * intValue);
+     }
+ }
+ 

Modified: trunk/Build/source/libs/icu/icu-src/source/i18n/plurrule.cpp
===================================================================
--- trunk/Build/source/libs/icu/icu-src/source/i18n/plurrule.cpp	2022-01-18 22:17:46 UTC (rev 61654)
+++ trunk/Build/source/libs/icu/icu-src/source/i18n/plurrule.cpp	2022-01-18 23:09:53 UTC (rev 61655)
@@ -1628,7 +1628,7 @@
     init(n, v, f, e);
     // check values. TODO make into unit test.
     //            
-    //            long visiblePower = (int) Math.pow(10, v);
+    //            long visiblePower = (int) Math.pow(10.0, v);
     //            if (decimalDigits > visiblePower) {
     //                throw new IllegalArgumentException();
     //            }
@@ -1932,7 +1932,7 @@
 }
 
 double FixedDecimal::doubleValue() const {
-    return (isNegative ? -source : source) * pow(10, exponent);
+    return (isNegative ? -source : source) * pow(10.0, exponent);
 }
 
 int64_t FixedDecimal::longValue() const {
@@ -1939,7 +1939,7 @@
     if (exponent == 0) {
         return intValue;
     } else {
-        return (long) (pow(10, exponent) * intValue);
+        return (long) (pow(10.0, exponent) * intValue);
     }
 }
 



More information about the tex-live-commits mailing list.