From 7f700bd84e4a2d117ed9a39be928c3f6fbe50b71 Mon Sep 17 00:00:00 2001 From: Timothy Flynn Date: Sat, 11 Sep 2021 08:38:57 -0400 Subject: LibJS: Make GetNumberOption's "options" object a const reference --- Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.cpp | 2 +- Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'Userland/Libraries/LibJS') diff --git a/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.cpp b/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.cpp index a65968eb1e..61743443dc 100644 --- a/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.cpp +++ b/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.cpp @@ -690,7 +690,7 @@ Optional default_number_option(GlobalObject& global_object, Value value, in } // 9.2.15 GetNumberOption ( options, property, minimum, maximum, fallback ), https://tc39.es/ecma402/#sec-getnumberoption -Optional get_number_option(GlobalObject& global_object, Object& options, PropertyName const& property, int minimum, int maximum, Optional fallback) +Optional get_number_option(GlobalObject& global_object, Object const& options, PropertyName const& property, int minimum, int maximum, Optional fallback) { auto& vm = global_object.vm(); diff --git a/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.h b/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.h index 51900d939e..c2484bcc30 100644 --- a/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.h +++ b/Userland/Libraries/LibJS/Runtime/Intl/AbstractOperations.h @@ -48,7 +48,7 @@ Array* supported_locales(GlobalObject&, Vector const& requested_locales, Object* coerce_options_to_object(GlobalObject& global_object, Value options); Value get_option(GlobalObject& global_object, Object const& options, PropertyName const& property, Value::Type type, Vector const& values, Fallback fallback); Optional default_number_option(GlobalObject& global_object, Value value, int minimum, int maximum, Optional fallback); -Optional get_number_option(GlobalObject& global_object, Object& options, PropertyName const& property, int minimum, int maximum, Optional fallback); +Optional get_number_option(GlobalObject& global_object, Object const& options, PropertyName const& property, int minimum, int maximum, Optional fallback); Vector partition_pattern(StringView pattern); } -- cgit v1.2.3