Closed
Bug 1604188
Opened 6 years ago
Closed 6 years ago
Replace unreachable String functions calling MOZ_ASSERT_UNREACHABLE/MOZ_CRASH with if-constexpr
Categories
(Core :: JavaScript Engine, task, P1)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla74
People
(Reporter: anba, Assigned: anba)
Details
Attachments
(1 file)
For example we can avoid writing this Final_Sigma function:
static Latin1Char Final_Sigma(const Latin1Char* chars, size_t length,
size_t index) {
MOZ_ASSERT_UNREACHABLE("U+03A3 is not a Latin-1 character");
return 0;
}
when the call sites use if-constexpr to only call Final_Sigma for char16_t.
| Assignee | ||
Comment 1•6 years ago
|
||
Instead of using MOZ_CRASH/MOZ_ASSERT_UNREACHABLE for unreachable functions, we can
now use if-constexpr to avoid generating the unreachable calls in the first place.
Updated•6 years ago
|
Priority: -- → P1
Pushed by apavel@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/1dfdd760665d
Replace unreachable string functions with if-constexpr code. r=jandem,jwalden
Comment 3•6 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox74:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla74
Updated•6 years ago
|
You need to log in
before you can comment on or make changes to this bug.
Description
•