Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ICU-22939 DRAFT: WIP on function composition #3228

Draft
wants to merge 37 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
e7e256e
WIP on function composition
catamorphism Oct 1, 2024
8cae40c
Fix warnings
catamorphism Oct 1, 2024
71209d9
Fix leaks
catamorphism Oct 1, 2024
c8d28b3
Fix doc comments and move InternalValue to a private header file
catamorphism Oct 1, 2024
a9d3547
Extend InternalValue and eliminate ResolvedSelector
catamorphism Oct 1, 2024
135fec0
Comments; renaming fields to be more informative
catamorphism Oct 1, 2024
04b9cf2
Remove commented-out code
catamorphism Oct 1, 2024
c048313
Fix leaks
catamorphism Oct 2, 2024
fe9f635
Remove unused method
catamorphism Oct 2, 2024
2c4705a
Fix warning
catamorphism Oct 2, 2024
bb2ecdb
Tests pass
catamorphism Oct 3, 2024
8d875ed
Fixed leaks
catamorphism Oct 4, 2024
0510d0a
Refactor
catamorphism Oct 4, 2024
25e563f
Remove FormattedPlaceholder and FormattedValue (no longer used)
catamorphism Oct 4, 2024
243bafe
Re-add default formatters by type
catamorphism Oct 4, 2024
acafbc6
Rename functions
catamorphism Oct 4, 2024
037b027
Comments
catamorphism Oct 4, 2024
f82c921
Bring back FunctionFactory
catamorphism Oct 7, 2024
10dfe45
Un-ignore a test; add comments
catamorphism Oct 7, 2024
a2f4a59
Add doc comments
catamorphism Oct 7, 2024
df5e654
Add test
catamorphism Oct 14, 2024
abf6c80
Fix ListValue
catamorphism Oct 15, 2024
81d9acf
Add u-options tests
catamorphism Oct 15, 2024
a51dc3e
Fix output checking
catamorphism Oct 15, 2024
1abcef0
Function context and u:options
catamorphism Oct 15, 2024
b12bf30
Fix date/time style bug
catamorphism Oct 15, 2024
0cf0fc8
Fix test
catamorphism Oct 16, 2024
50aea15
Fix datetime options bug
catamorphism Oct 16, 2024
6f140bb
Remove FunctionFactory again
catamorphism Oct 16, 2024
c100e35
Re-add ResourceManager test
catamorphism Oct 16, 2024
c199c1c
Make Function::call() return a LocalPointer
catamorphism Oct 17, 2024
f62fc64
Use an array of indices for `prefs` in `selectKeys()`
catamorphism Oct 17, 2024
603bffa
Add comment about isSelectable()
catamorphism Oct 17, 2024
740ca4f
Remove use of std::string
catamorphism Oct 17, 2024
e15e62b
Remove uses of new/delete
catamorphism Oct 17, 2024
5343da5
Implement call-by-need; tests pass
catamorphism Oct 23, 2024
7459872
depstest: add messageformat2_evaluation.o to ignore list (for spuriou…
catamorphism Oct 25, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
626 changes: 302 additions & 324 deletions icu4c/source/i18n/messageformat2.cpp

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions icu4c/source/i18n/messageformat2_allocation.h
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,18 @@ namespace message2 {
return result;
}

template<typename T>
inline T* create(const T& node, UErrorCode& status) {
if (U_FAILURE(status)) {
return nullptr;
}
T* result = new T(node);
if (result == nullptr) {
status = U_MEMORY_ALLOCATION_ERROR;
}
return result;
}

} // namespace message2

U_NAMESPACE_END
Expand Down
Loading
Loading