mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-19 06:29:43 +00:00
LibJS+LibWeb: Port interned bytecode strings to UTF-16
This was almost a no-op, except we intern JS exception messages. So the bulk of this patch is porting exception messages to UTF-16.
This commit is contained in:
parent
cf61171864
commit
70db474cf0
Notes:
github-actions[bot]
2025-08-14 08:28:16 +00:00
Author: https://github.com/trflynn89
Commit: 70db474cf0
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5845
Reviewed-by: https://github.com/gmta ✅
162 changed files with 1405 additions and 1422 deletions
|
@ -90,7 +90,7 @@ void CanvasPath::bezier_curve_to(double cp1x, double cp1y, double cp2x, double c
|
|||
WebIDL::ExceptionOr<void> CanvasPath::arc(float x, float y, float radius, float start_angle, float end_angle, bool counter_clockwise)
|
||||
{
|
||||
if (radius < 0)
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), MUST(String::formatted("The radius provided ({}) is negative.", radius)));
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), Utf16String::formatted("The radius provided ({}) is negative.", radius));
|
||||
return ellipse(x, y, radius, radius, 0, start_angle, end_angle, counter_clockwise);
|
||||
}
|
||||
|
||||
|
@ -103,9 +103,9 @@ WebIDL::ExceptionOr<void> CanvasPath::ellipse(float x, float y, float radius_x,
|
|||
|
||||
// 2. If either radiusX or radiusY are negative, then throw an "IndexSizeError" DOMException.
|
||||
if (radius_x < 0)
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), MUST(String::formatted("The major-axis radius provided ({}) is negative.", radius_x)));
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), Utf16String::formatted("The major-axis radius provided ({}) is negative.", radius_x));
|
||||
if (radius_y < 0)
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), MUST(String::formatted("The minor-axis radius provided ({}) is negative.", radius_y)));
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), Utf16String::formatted("The minor-axis radius provided ({}) is negative.", radius_y));
|
||||
|
||||
// "If counterclockwise is false and endAngle − startAngle is greater than or equal to 2π,
|
||||
// or, if counterclockwise is true and startAngle − endAngle is greater than or equal to 2π,
|
||||
|
@ -198,7 +198,7 @@ WebIDL::ExceptionOr<void> CanvasPath::arc_to(double x1, double y1, double x2, do
|
|||
|
||||
// 3. If radius is negative, then throw an "IndexSizeError" DOMException.
|
||||
if (radius < 0)
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), MUST(String::formatted("The radius provided ({}) is negative.", radius)));
|
||||
return WebIDL::IndexSizeError::create(m_self->realm(), Utf16String::formatted("The radius provided ({}) is negative.", radius));
|
||||
|
||||
auto transform = active_transform();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue