Peter Edberg
89fe16ef3b
ICU-22142 Deprecate ICU4C createMetricTon/getMetricTon, ICU4J METRIC_TON
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "HH:mm" "13:13" 2, TestICUParse) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "dddd MMM yyyy" "15 Jan 2007" 1, TestICUConstruction) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "dddd MMM yyyy" "15 Jan 2007" 1, TestICUFormat) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "dddd MMM yyyy" "15 Jan 2007" 1, TestICUParse) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (sw_KE, "dddd MMM yyyy" "15 Jan 2007" 1, TestICUConstruction) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (sw_KE, "dddd MMM yyyy" "15 Jan 2007" 1, TestICUFormat) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (sw_KE, "dddd MMM yyyy" "15 Jan 2007" 1, TestICUParse) (push) Blocked by required conditions
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x64, Debug, x64) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x64, Release, x64) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x86, Debug, Win32) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x86, Release, Win32) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-cygwin-gcc (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (icuserv) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (idna) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-test (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (bidi) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (collator) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (convert) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (csdet) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (format) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (normalize) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbbi) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbnf) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbnfp) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbnfrt) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (regex) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (spoof) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (translit) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (utility) (push) Waiting to run
Scorecard supply-chain security / Scorecard analysis (push) Waiting to run
2025-04-05 10:04:01 -07:00
Tim Chevalier
d0e30acc68
ICU-23059 ICU4C MF2: Spec test updates
...
GHA CI Valgrind / clang-valgrind-intltest (spoof) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (translit) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_IDNA=1) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_LEGACY_CONVERSION=1 -DUCONFIG_NO_NORMALIZATION=1 -DUCONFIG_NO_BREAK_ITERATION=1 -DUCONFIG_NO_IDNA=1 -DUCONFIG_NO_COLLATION=1 -DUCONFIG_NO_FORMATTING=1 -DUCONFIG_NO_MF2=1 -DUCONFIG_NO_TRANSLITERATION=1 -DUCONFIG_NO_REG… (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_LEGACY_CONVERSION=1) (push) Has been cancelled
GHA ICU4C / icu4c-without-collation-rule-strings (push) Has been cancelled
GHA ICU4C / icu4c-icuexportdata (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (rbbi) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-test (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (bidi) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (collator) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (convert) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (csdet) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (format) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (rbnfrt) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (regex) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_MF2=1) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_NORMALIZATION=1) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_REGULAR_EXPRESSIONS=1) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_SERVICE=1) (push) Has been cancelled
GHA ICU4C / uconfig-header-tests (-DUCONFIG_NO_TRANSLITERATION=1) (push) Has been cancelled
GHA ICU4C / unicode-update-tools (push) Has been cancelled
GHA ICU4C / icu4c-test-samples (push) Has been cancelled
GHA ICU4C / icu4c-uconfig-no-conversion (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (icuserv) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (idna) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (normalize) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (rbnf) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (rbnfp) (push) Has been cancelled
GHA CI Valgrind / clang-valgrind-intltest (utility) (push) Has been cancelled
Update spec tests to current version from message-format-wg
- Update parser for changed name-start grammar rule
- Validate number literals in :number implementation (since parser no longer does this)
- Disallow `:number`/`:integer` select option set from variable
See https://github.com/unicode-org/message-format-wg/pull/1016
As part of this, un-skip tests where the `bad-option` error is
expected, and implement validating digit size options
(pending PR https://github.com/unicode-org/icu/pull/2973 is intended
to do this more fully)
2025-03-27 15:20:49 -07:00
Frank Tang
ad0df7e4c8
ICU-22817 Use LocalPointer/Memory/Array to clarify ownership transfer
...
GHA ICU Merge CI / icu4j-converterperf (TestCharsetEncoderICU, korean, UTF-8) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-converterperf (TestCharsetEncoderICU, korean, csiso2022kr) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-converterperf (TestCharsetEncoderICU, s-chinese, EUC-CN) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-converterperf (TestCharsetEncoderICU, s-chinese, UTF-8) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "HH:mm Z" "13:13 -0800" 5, TestICUConstruction) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "HH:mm Z" "13:13 -0800" 5, TestICUFormat) (push) Blocked by required conditions
GHA ICU Merge CI / icu4j-dateformatperf (en_US, "HH:mm Z" "13:13 -0800" 5, TestICUParse) (push) Blocked by required conditions
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x64, Debug, x64) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x64, Release, x64) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x86, Debug, Win32) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-msvc-postmerge (x86, Release, Win32) (push) Waiting to run
GHA ICU Merge CI / icu4c-windows-cygwin-gcc (push) Waiting to run
GHA CI Valgrind / clang-valgrind-test (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (csdet) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (format) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (bidi) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (collator) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (convert) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (icuserv) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (idna) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (normalize) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbbi) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbnf) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbnfp) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (rbnfrt) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (regex) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (spoof) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (translit) (push) Waiting to run
GHA CI Valgrind / clang-valgrind-intltest (utility) (push) Waiting to run
Scorecard supply-chain security / Scorecard analysis (push) Waiting to run
See #3443
2025-03-24 16:24:02 -07:00
Frank Tang
b65650bc5f
ICU-23077 Correct the internalGet call inside Calendar
...
See #3439
2025-03-19 16:22:43 -07:00
Steve Lawrence
3edd9c828a
ICU-22303 Support parsing infinity/NaN when decimal pattern match is required
...
If a DecimalFormat pattern contains a decimal point and
setDecimalPatternMatchRequired is true, then DecimalFormat parse() fails
to parse infinity/NaN representations. This is because infinity/NaN
parsing does not set the HAS_DECIMAL_SEPARATOR_FLAG and so the
RequireDecimalSeparatorValidator fails.
This modifies the RequireDecimalSeparatorValidator so that it does not
fail if the INFINITY or NAN flags are set, making it so decimal
separators are not required if the infinity/NaN representations are
parsed.
2025-03-19 16:19:41 -07:00
Frank Tang
255eb4ef3e
ICU-23069 Fix Hebrew calendar calculation
...
See #3438
2025-03-19 13:45:52 -07:00
Frank Tang
cdf52396dc
ICU-22817 Fix memory leak in basictz by using LocalPointer
...
See https://github.com/LuMingYinDetect/icu_defects/blob/main/icu_1.png
2025-03-18 14:03:29 -07:00
Frank Tang
545bf260e1
ICU-22817 Fix potential memory leak by using LocalPointer
...
See https://github.com/LuMingYinDetect/icu_defects/blob/main/icu_10.png
2025-03-18 14:02:55 -07:00
Frank Tang
ba0f39b592
ICU-22817 Use LocalArray to fix memory leak
2025-03-18 12:21:23 -07:00
Tim Chevalier
c5b7dce96b
ICU-23073 Use string_view constants for option names and formatter names
2025-03-13 10:21:46 -07:00
Tim Chevalier
0748442ed6
ICU-23059 ICU4C MF2: Update spec tests
...
This updates the MF2 spec tests to 943479b602
with the following exceptions:
- functions/currency.json and functions/math.json are omitted because these are not yet implemented
- bidi.json will be handled in a future PR
- u-options.json will be handled in a future PR
Changes include:
* `:integer` now returns a value encapsulating the rounded numeric value of the argument, rather than
the value itself.
* Fallbacks are handled according to the current spec.
* Fallback values are not passed into functions.
* Characters inside literal fallbacks are properly escaped.
* The test runner skips null values properly.
* The test runner handles boolean `expErrors` in defaultTestProperties.
* `:string` normalizes its input and normalizeNFC() has been refactored so it can be called there.
2025-02-25 12:24:07 -08:00
Fredrik Roubert
61b2dbc980
ICU-22901 Replace fixed size buffer with CharString.
2025-02-14 21:42:22 +01:00
Fredrik Roubert
3f5fd0df73
ICU-22901 Update ulocimp_canonicalize() &co. to use std::string_view.
2025-02-13 15:50:54 +01:00
Younies Mahmoud
35c9778781
ICU-22781 Support Arbitrary Constant Unit Formatting
...
See #3381
2025-02-12 01:45:16 +01:00
Frank Tang
59af52bb6f
ICU-23043 Propogate error in Calendar.
2025-02-11 15:14:27 -08:00
Mihai Nita
339ebb368f
ICU-22781 Data generated with the concentr/perbillion on, code update
...
Following the steps in docs/processes/release/tasks/updating-measure-unit.md
2025-02-10 10:46:19 -08:00
Tim Chevalier
7b8110f003
ICU-22907 MF2: Finish updating spec tests and implement required test functions
...
Implement :test:format, :test:select, and :test:function, which are
required by the new `pattern-selection.json` tests.
Change the internal value representation in the formatter in order to
support some of the test cases (binding the results of selectors to a
variable).
2025-02-08 21:42:03 -06:00
Vladyslav Yeremeichuk
624a26030b
ICU-22950 Do not initialize currency redundantly
...
resolveCurrency() slows down simple number formatting requests like:
for (int i = 0; i < 9999; i++) u_snprintf_u(buff, 100, u"%d", i);
Since we don't use currency here, we can skip its initialization.
2025-02-07 14:45:43 -08:00
Fredrik Roubert
ee8806e87c
ICU-22954 Make UCollator predicates usable without U_SHOW_CPLUSPLUS_API.
...
Until now, the implementation of the UCollator predicates has been using
UnicodeString and StringPiece as convenient wrappers for converting from
standard C++ data types to ICU4C data types.
But as that doesn't work when the client uses ICU4C built without
U_SHOW_CPLUSPLUS_API this is now changed to instead perform these
conversions directly.
(It's a bit more code, but does just the same thing in the end.)
2025-02-07 20:14:20 +01:00
Younies Mahmoud
362a4aa94b
ICU-23032 Update MeasureUnit documentation for forIdentifier
method
...
See #3360
2025-02-06 16:37:58 +01:00
Younies Mahmoud
697f7c0e00
ICU-22781 Fix &Improve MeasureUnit identifier generation for constant denominators (C++)
...
See #3364
2025-02-06 12:06:58 +01:00
Rich Gillam
f9ee689d7a
ICU-22922 Promoted all @draft ICU 75 APIs to @stable ICU 75.
2025-02-05 13:02:56 -08:00
Frank Tang
0112e4292e
ICU-22962 Fix int32_t overflow issue when month is large
2025-02-04 15:39:32 -08:00
Frank Tang
ede201c305
ICU-22994 Use C++ typeid() instead of Calendar::getType() for calendar type comparison
...
See #3310
2025-01-31 15:19:55 +01:00
Arthur O'Dwyer
fb64693c28
ICU-22920 Avoid "return by const value" antipattern
...
Returning a const-qualified prvalue doesn't do anything useful, but it does
turn an assignment such as `v = rb.getLocale();` from a move-assignment
into a copy-assignment (because it's forbidden to move-from a const value,
even if it's a const prvalue). Each affected site was diagnosed mechanically
by my fork of Clang. E.g.:
warning: 'const' type qualifier on return type is a bad idea [-Wqual-class-return-type]
391 | const Locale ResourceBundle::getLocale(ULocDataLocaleType type, UErrorCode &status) const
| ^~~~~
2025-01-30 10:58:25 -08:00
Burkov Egor
d61ec78c93
ICU-23011 Add else branch for remove possible CWE-476
2025-01-30 10:54:19 -08:00
Frank Tang
7153a3db52
ICU-23006 Fix Chinese Calendar getActualMaximize
...
See #3348
2025-01-28 16:34:26 -08:00
Frank Tang
4fc1b7e7f6
ICU-22991 Simplified Grego code
...
Use timeToFields instead of dayToFields
ICU-22991 Revert back gregoimp interface change
2025-01-24 17:13:51 -08:00
Younies Mahmoud
d70b252cdc
ICU-22781 Add support for converting units with constant denominators (C++)
...
See #3347
2025-01-25 01:45:49 +01:00
Younies Mahmoud
ba4d4d3ac2
ICU-22781 Adding support for constant denominators (C++)
...
See #3337
2025-01-24 02:06:43 +01:00
George Rhoten
2d6a4185c3
ICU-22979 Support inverse rule for [] span in RBNF
2025-01-15 08:56:08 -08:00
Tim Chevalier
f8aa68b0c1
ICU-22940 MF2 ICU4C: Error checking improvements in parser
...
Improve checking for OOM errors when allocating UnicodeSets,
per post-merge comments on https://github.com/unicode-org/icu/pull/3236
2025-01-09 18:00:43 -08:00
Frank Tang
9eafd8ca3e
ICU-22991 Reduce Calendar object size
...
See #3327
2025-01-08 12:26:35 -08:00
Frank Tang
6091406a3a
ICU-22991 Reduce fStamp to 8 bits
...
See #3323
2025-01-06 18:38:17 -08:00
Frank Yung-Fong Tang
4c3622f218
ICU-23000 Replace CharString for LocaleBased
...
See #3321
2025-01-06 14:09:30 -08:00
Frank Tang
93ce388619
ICU-23002 Fix int64_t overflow in NFRule::parseRuleDescriptor
...
See #3324
2025-01-03 15:48:24 -08:00
Frank Tang
841e88bc8c
ICU-22991 Remove unused private fIsSet
...
This field is removed in Java 24 years ago. Save 24 bytes per Calendar
object.
2024-12-23 14:58:56 -08:00
Frank Tang
e515c84645
ICU-22991 Remove unnecessary overload in Calendar
2024-12-23 12:52:11 -08:00
Frank Tang
ff31805f56
ICU-22991 Change fIsTimeSet fAreFieldsSet fAreAllFieldsSet fAreFieldsVirtuallySet fIsSet fStamp to private
...
https://docs.google.com/document/d/1RqP3s7Y1YLahqopNcuadl3DT-DMIZ7ASXZbSy7M2mFE/edit?tab=t.0#heading=h.lok0fhe381qa
2024-12-23 12:51:13 -08:00
Markus Scherer
c0a3fe15d4
ICU-22954 Partially revert PR #3295 U_ICU_NAMESPACE_OR_INTERNAL, header-only localpointer
...
This partially reverts commit 3527b3d320
.
Making LocalPointer header-only, with a different namespace when compiling internally,
turned out to be problematic.
2024-12-23 11:17:14 -08:00
Markus Scherer
38b6d7fe5a
ICU-22954 Revert PR #3295 make all LocalXyzPointer header-only
...
This reverts commit 5bdb4c44af
.
Making LocalPointer header-only, with a different namespace when compiling internally,
turned out to be problematic.
2024-12-23 11:17:14 -08:00
Frank Tang
7546622f87
ICU-22991 Remove unnecessary computeGregorianAndDOWFields private
...
Move the DOW calculation into computeWeekFields
2024-12-20 16:33:53 -08:00
Frank Tang
4c9ef1a31b
ICU-22962 Fix int overflow in Calendar::handleComputeJulianDay
2024-12-20 16:12:58 -08:00
Markus Scherer
70409090de
ICU-22954 make all LocalXyzPointer header-only
2024-12-19 17:40:33 -08:00
Markus Scherer
8655718531
ICU-22954 U_ICU_NAMESPACE_OR_INTERNAL, header-only localpointer
...
header-only parts of char16ptr.h
2024-12-19 17:40:33 -08:00
Frank Tang
a7291c4e51
ICU-22962 Fix int32 overflow in Chinese Calendar
2024-12-16 18:02:05 -08:00
Frank Tang
81d047524c
ICU-22991 Remove protected direct access to fStamp
2024-12-16 13:17:40 -08:00
Tim Chevalier
1b8118049f
ICU-22940 MF2 ICU4C: Update for bidi support
...
Per https://github.com/unicode-org/message-format-wg/pull/884
2024-12-11 12:32:25 -08:00
Tim Chevalier
62b95bb5f9
ICU-22908 MF2: Update spec tests and update implementation for recent spec changes
...
Updating the spec tests requires two implementation changes:
* Match on variables rather than expressions --
see https://github.com/unicode-org/message-format-wg/pull/877
* Require attribute values to be literals (if present) --
see https://github.com/unicode-org/message-format-wg/pull/894
This updates the spec tests to commit 6c3704f41a9c24427126429fb43992b03609dfc8
in https://github.com/unicode-org/message-format-wg/ . Any changes
following that commit will be addressed in a future PR.
2024-12-09 09:38:28 -08:00
Frank Tang
2e57f07cdf
ICU-22736 Address Markus' feedback
2024-12-06 16:24:57 -08:00