Closed
Bug 1289934
Opened 8 years ago
Closed 8 years ago
Minor Intl code-fixes
Categories
(Core :: JavaScript: Internationalization API, defect)
Core
JavaScript: Internationalization API
Tracking
()
RESOLVED
FIXED
mozilla51
Tracking | Status | |
---|---|---|
firefox51 | --- | fixed |
People
(Reporter: Waldo, Assigned: Waldo)
References
Details
Attachments
(2 files)
5.03 KB,
patch
|
sfink
:
review+
|
Details | Diff | Splinter Review |
3.14 KB,
patch
|
sfink
:
review+
|
Details | Diff | Splinter Review |
Some little things noticed looking at the code with gandalf today. Shouldn't require any deep ICU knowledge to understand.
Assignee | ||
Comment 1•8 years ago
|
||
First up, convert a runtime deleter-function into a compile-time template parameter. We could also use UniquePtr here, but UniquePtr also requires a deleter function be a runtime-provided thing, like the existing class here does.
Attachment #8775356 -
Flags: review?(sphink)
Assignee | ||
Comment 2•8 years ago
|
||
It happens that both these issues are only theoretical. ucal_getType fails only if ucal_open failed, right now, in our in-tree ICU. And ucal_getType only returns statically-allocated strings, in in-tree ICU. But better to eliminate risk that this could change in the future.
Attachment #8775358 -
Flags: review?(sphink)
Updated•8 years ago
|
Attachment #8775356 -
Flags: review?(sphink) → review+
Updated•8 years ago
|
Attachment #8775358 -
Flags: review?(sphink) → review+
Pushed by jwalden@mit.edu: https://hg.mozilla.org/integration/mozilla-inbound/rev/c39c56bc1833 Simplify ScopedICUObject to store deleter function as a template parameter, not as a runtime variable. r=sfink https://hg.mozilla.org/integration/mozilla-inbound/rev/2251dbd1b3c8 Implement more-correct error handling if ucal_getType fails. (It can't with current ICU, at least our in-tree copy. But best be safe for the future.) Also don't assume ucal_getType's return value on success outlives the corresponding UCalendar*. (Again, no problem with current ICU, still worth fixing.) r=sfink
Comment 4•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/c39c56bc1833 https://hg.mozilla.org/mozilla-central/rev/2251dbd1b3c8
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox51:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
Blocks: 1300925
You need to log in
before you can comment on or make changes to this bug.
Description
•