Commit graph

4818 commits

Author SHA1 Message Date
Craig
ebbadebdfd ICU-22938 FiIx unit tests for 'und_Hant_CN' in C & J 2024-10-03 17:01:13 -07:00
Craig
109008da3b ICU-22723 ICU76: Update known issue references to cloned reports. BRS #27
See #3215
2024-09-25 15:46:23 -07:00
Tim Chevalier
2f348f4c7a ICU-22902 Remove support for Unsupported, Private & Reserved constructs
Matching PR #883 in the message-format-wg repo.

Also move spec tests for unsupported statements and expressions into new files
to serve as syntax error tests.
2024-09-20 17:29:07 -07:00
Oleksandr Hubanov
5f9f8b2053 ICU-22714 fix zos build, use OpenXL
See #3008
2024-09-20 17:12:28 -07:00
Tim Chevalier
8f82facca8 ICU-22898 MF2 parser bug fixes
ICU4C: Escape curly braces when serializing and normalizing
ICU4C: Escape '|' in patterns
ICU4C: When normalizing input, escape optionally-escaped characters in patterns
ICU4C/ICU4J: Allow trailing whitespace after a match
ICU4C: Fix parser to iterate over code points, not code units
Add tests with old reserved syntax as syntax-error tests
2024-09-20 16:22:34 -07:00
Chris Chapman
1c2a1c50b7 ICU-22896 updating tzdata to 2024b 2024-09-20 15:20:39 -07:00
Tim Chevalier
5991c9392c ICU-22890 MF2: Add ICU4C test for lone surrogates
Add a test to ICU4C for handling of lone surrogates.

Incidentally fix uninitialized-memory bug in MessageFormatter
(initialize `errors` to nullptr)

Co-authored-by: Frank Tang <ftang@chromium.org>
2024-09-19 14:28:02 -07:00
Tim Chevalier
23edf9cca6 ICU-22762 MF2: Add builder method to control error handling behavior
Add MessageFormatter::Builder::setErrorHandlingBehavior() method
and a new enum type MessageFormatter::UMFErrorHandlingBehavior
to denote strict or best-effort behavior.

The reason for adding a single method that takes an enum is to allow
for the possibility of more error handling modes in the future.

Co-authored-by: Markus Scherer <markus.icu@gmail.com>
2024-09-19 13:21:56 -07:00
Fredrik Roubert
55c5895923 ICU-22793 Clang-Tidy: google-readability-casting
https://releases.llvm.org/19.1.0/tools/clang/tools/extra/docs/clang-tidy/checks/google/readability-casting.html
2024-09-19 18:59:13 +02:00
Fredrik Roubert
0bf8a95309 ICU-22793 Remove superfluous return value typecasts to UBool. 2024-09-19 17:11:38 +02:00
Peter Edberg
07e0f7ee2f ICU-22318 Fix bad spacing in utxttest.cpp 2024-09-19 14:51:01 +02:00
Rich Gillam
1b33f5e30b ICU-22889 Implemented a recursion limit in the RBNF parsing code to match the one already present in the RBNF
formatting code.
2024-09-18 16:05:13 -07:00
Frank Tang
303b7e81d7 ICU-22897 Fix memory leak and int overflow
1. Rewrite to use LocalPointer to prevent memory leak
2. Rewrite the if/else to switch to make the logic clear
3. Delete the rule if not remember inside the rule set to fix memory
leak.
4. Check base value calculation to avoid int64_t overflow.
5. Add memory leak test
2024-09-18 14:40:13 -07:00
DraganBesevic
ce4b90e484 ICU-22723 Integrate CLDR 46 release beta1, part 3, source files 2024-09-18 10:41:49 -07:00
Tim Chevalier
747d5eef3b ICU-22834 Update tests to reflect MF2 schema in conformance repo
This also updates the spec tests from the current version of the MFWG
repository and removes some duplicate tests.
Spec tests now reflect the message-format-wg repo as of
5612f3b050

It also updates both the ICU4C and ICU4J parsers to follow the
current test schema in the conformance repository.

This includes adding code to both parsers to allow `src` to be
either a single string or an array of strings (per
https://github.com/unicode-org/conformance/pull/255 ),
and eliminating `srcs` in tests.

It also includes other changes to make updated spec tests pass:

ICU4C: Allow trailing whitespace for complex messages, due to spec change
ICU4C: Parse number literals correctly in Number::format
ICU4J: Allow trailing whitespace after complex body, per spec change
ICU4C: Fix bug that was assuming an .input variable can't have a reserved annotation
ICU4C: Fix bug where unsupported '.i' was parsed as an '.input'
ICU4C/ICU4J: Handle markup with space after the initial left curly brace
ICU4C: Check for duplicate variant errors
ICU4C/ICU4J: Handle leading whitespace in complex messages
ICU4J: Treat whitespace after .input keyword as optional
ICU4J: Don't format unannotated number literals as numbers
2024-09-18 07:46:29 -07:00
Robin Leroy
bfc53547d1 ICU-22879 Test the collator predicates in maps 2024-09-17 20:44:21 +02:00
Fredrik Roubert
b160feaac2 ICU-22879 Provide collator based predicates for use with STL algorithms. 2024-09-17 20:44:21 +02:00
Frank Tang
752da7303f ICU-22730 Fix int overflow inside CE Calendar 2024-09-11 22:07:01 -07:00
Fredrik Roubert
376f10db47 ICU-22843 Add a test case that's ambiguous to MSVC and fails to compile. 2024-09-12 00:36:49 +02:00
Markus Scherer
37b41495d7 ICU-22876 C++ UnicodeSet/USet easy item iteration
See #3120
2024-09-10 17:38:03 -07:00
Markus Scherer
f062f52c12 ICU-22294 UTS46 transitional=deprecated, change DEFAULT 2024-09-06 14:38:11 -07:00
Markus Scherer
415a7accc5 ICU-22707 adjust UTS46 for Unicode 16
See #3130
2024-09-06 10:00:11 -07:00
Frank Tang
63f29c621c ICU-22854 Add consistency test against Region API 2024-08-30 22:37:29 -07:00
Markus Scherer
6645cc4935 ICU-22843 UnicodeString::operator!=(string view) 2024-08-29 08:45:03 -07:00
Rich Gillam
967babdc5f ICU-22669 Fix circular dependency in DateTimePatternGenerator::addICUPatterns(). 2024-08-27 10:37:19 -07:00
Frank Tang
5e22f0076e ICU-22854 Implement subdivision validation 2024-08-22 11:02:36 -07:00
DraganBesevic
aabadf7289 ICU-22723 Integrate CLDR 46 release alpha2, part 5, exclude failing unit tests for exhaust tests; spaces <-> tabs 2024-08-22 08:22:56 -07:00
DraganBesevic
ebceedde21 ICU-22723 Integrate CLDR 46 release alpha0, part 3, source files 2024-08-22 08:22:56 -07:00
Markus Scherer
51e21af692 ICU-22707 Unicode 16 aug16 2024-08-19 17:15:00 -07:00
DraganBesevic
045350e7c1 ICU-22723 Integrate CLDR 46 release alpha0, part 4, fixes for exausting tests 2024-08-14 17:09:35 -07:00
DraganBesevic
d04154833c ICU-22723 Integrate CLDR 46 release alpha0, part 3, source files 2024-08-14 17:09:35 -07:00
Fredrik Roubert
37b2bc6999 ICU-22721 Use correct initializer list syntax.
This will make the code ever so slightly simpler but more importantly
make it possible to compile also when using -D_GLIBCXX_DEBUG.
2024-08-13 21:33:53 -07:00
Markus Scherer
72206495de ICU-22843 UnicodeString <-> std::u16string_view / wstring_view via templates 2024-08-13 09:10:01 -07:00
Tim Chevalier
57ed0a2a53 ICU-22794 MF2: Move .json files for tests into top-level testdata/ directory
Modify ICU4C and ICU4J test readers to handle all tests

Add `ignoreJava` and `ignoreCpp` properties to tests where needed

Includes parser bug fixes:

ICU4J: require a complex-body after declarations

ICU4J: Correctly parse the complex body after an unsupported statement

ICU4J: Handle date params in tests and remove default params for tests

ICU4J: Handle decimal params in tests

ICU4J: Require whitespace before variable/literal in reserved annotation

ICU4J: Require whitespace between options

ICU4J: Require a variable-expression in an .input declaration

ICU4J: don't require space between last key and pattern in variant

ICU4J: don't require space between selectors

ICU4J: allow whitespace after '=' in option

ICU4J: parse escape sequences in quoted literals according to grammar

ICU4J: allow whitespace within markup after attributes list
2024-08-08 09:14:44 -07:00
Elango Cheran
3663cc1e0f ICU-22707 Add support for property Modifier_Combining_Mark 2024-07-30 15:44:32 -07:00
Fredrik Roubert
10fe2a6110 ICU-22696 Add uhash support for std::string_view. 2024-07-30 06:45:43 +02:00
Fredrik Roubert
8891c070bd ICU-22696 Add implicit conversion from StringPiece to std::string_view.
This will allow ICU4C to seamlessly use std::string_view internally
while continuing to use StringPiece in the public API.
2024-07-30 06:45:33 +02:00
Elango Cheran
06c077bd35 ICU-22503 add property Indic_Conjunct_Break 2024-07-26 14:47:39 -07:00
Robin Leroy
20fdebcb35 ICU-22707 UTC-180? Give up on 16.0β rules, amend LB10 and LB21a instead. 2024-07-18 23:56:34 +00:00
Robin Leroy
cc64ec7c94 ICU-22707 feed more bits to the starving monkeys: ranlux48 rather than a 32-bit LCG 2024-07-18 23:56:34 +00:00
Robin Leroy
47a8ea4065 ICU-22707 smarter old monkeys: refine the partition on interesting sets 2024-07-18 23:56:34 +00:00
Robin Leroy
79f4745494 ICU-22707 UTC-179-C25 Limit LB21a to the Hebrew-hyphen-non-Hebrew case 2024-07-18 23:56:34 +00:00
Robin Leroy
83f3334b96 ICU-22707 UTC-179-C32 Upstream and improve the old Finnish tailoring LB20a from CLDR-3029 and ICU-8151 2024-07-18 23:56:34 +00:00
Robin Leroy
36fe0f0660 ICU-22707 UTC-179-C28 Simplify the UAX14 formulation 2024-07-18 23:56:34 +00:00
Robin Leroy
84ff5dacf8 ICU-22707 UTC-179-C28 LB19 change for simplified chinese 2024-07-18 23:56:34 +00:00
Robin Leroy
1513b66c32 ICU-22707 UTC-179-C35 Remove redundant rule, caught after UTC-179. Called out in review note in https://www.unicode.org/reports/tr14/tr14-52.html#LB25. 2024-07-18 23:56:34 +00:00
Robin Leroy
d3b361f23a ICU-22707 UTC-179-C35 LB25 alignment with the UAX14 formulation from 15.1 and earlier. 2024-07-18 23:56:34 +00:00
Robin Leroy
509f552e38 ICU-22707 UTC-179-C35 No regexes for old monkeys: Express LB25 using UAX14-style rules rather than a regex 2024-07-18 23:56:34 +00:00
Robin Leroy
9391cbb0b3 ICU-22707 Print random 🙈🙉🙊🐵🐒 rather than ... so that progress is visible when the screen is full and report monkey counts 2024-07-18 23:56:34 +00:00
Markus Scherer
f9d2d561a1 ICU-22707 disable UTS46 test for now 2024-07-18 23:56:34 +00:00