mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-20 06:59:47 +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
|
@ -27,7 +27,7 @@ WebIDL::ExceptionOr<GC::Ref<OscillatorNode>> OscillatorNode::create(JS::Realm& r
|
|||
WebIDL::ExceptionOr<GC::Ref<OscillatorNode>> OscillatorNode::construct_impl(JS::Realm& realm, GC::Ref<BaseAudioContext> context, OscillatorOptions const& options)
|
||||
{
|
||||
if (options.type == Bindings::OscillatorType::Custom && !options.periodic_wave)
|
||||
return WebIDL::InvalidStateError::create(realm, "Oscillator node type 'custom' requires PeriodicWave to be provided"_string);
|
||||
return WebIDL::InvalidStateError::create(realm, "Oscillator node type 'custom' requires PeriodicWave to be provided"_utf16);
|
||||
|
||||
auto node = realm.create<OscillatorNode>(realm, context, options);
|
||||
|
||||
|
@ -65,7 +65,7 @@ Bindings::OscillatorType OscillatorNode::type() const
|
|||
WebIDL::ExceptionOr<void> OscillatorNode::set_type(Bindings::OscillatorType type)
|
||||
{
|
||||
if (type == Bindings::OscillatorType::Custom && m_type != Bindings::OscillatorType::Custom)
|
||||
return WebIDL::InvalidStateError::create(realm(), "Oscillator node type cannot be changed to 'custom'"_string);
|
||||
return WebIDL::InvalidStateError::create(realm(), "Oscillator node type cannot be changed to 'custom'"_utf16);
|
||||
|
||||
// FIXME: An appropriate PeriodicWave should be set here based on the given type.
|
||||
set_periodic_wave(nullptr);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue