summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2022-12-04 18:02:33 +0000
committerAndreas Kling <kling@serenityos.org>2022-12-06 08:54:33 +0100
commit6e19ab2bbce0b113b628e6f8e9b5c0640053933e (patch)
tree372d21b2f5dcff112f5d0089559c6af5798680d4 /Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp
parentf74251606d74b504a1379ebb893fdb5529054ea5 (diff)
downloadserenity-6e19ab2bbce0b113b628e6f8e9b5c0640053933e.zip
AK+Everywhere: Rename String to DeprecatedString
We have a new, improved string type coming up in AK (OOM aware, no null state), and while it's going to use UTF-8, the name UTF8String is a mouthful - so let's free up the String name by renaming the existing class. Making the old one have an annoying name will hopefully also help with quick adoption :^)
Diffstat (limited to 'Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp')
-rw-r--r--Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp b/Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp
index 407feac4ce..35bb08f32b 100644
--- a/Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp
+++ b/Userland/Libraries/LibWeb/Bindings/LegacyPlatformObject.cpp
@@ -30,7 +30,7 @@ JS::ThrowCompletionOr<bool> LegacyPlatformObject::is_named_property_exposed_on_o
// 1. If P is not a supported property name of O, then return false.
// NOTE: This is in it's own variable to enforce the type.
// FIXME: Can this throw?
- Vector<String> supported_property_names = this->supported_property_names();
+ Vector<DeprecatedString> supported_property_names = this->supported_property_names();
auto property_key_string = property_key.to_string();
if (!supported_property_names.contains_slow(property_key_string))
return false;
@@ -195,7 +195,7 @@ JS::ThrowCompletionOr<bool> LegacyPlatformObject::internal_define_own_property(J
// 1. Let creating be true if P is not a supported property name, and false otherwise.
// NOTE: This is in it's own variable to enforce the type.
// FIXME: Can this throw?
- Vector<String> supported_property_names = this->supported_property_names();
+ Vector<DeprecatedString> supported_property_names = this->supported_property_names();
[[maybe_unused]] bool creating = !supported_property_names.contains_slow(property_name_as_string);
// NOTE: This has to be done manually instead of using Object::has_own_property, as that would use the overridden internal_get_own_property.
@@ -269,7 +269,7 @@ JS::ThrowCompletionOr<JS::MarkedVector<JS::Value>> LegacyPlatformObject::interna
for (u64 index = 0; index <= NumericLimits<u32>::max(); ++index) {
if (is_supported_property_index(index))
- keys.append(js_string(vm, String::number(index)));
+ keys.append(js_string(vm, DeprecatedString::number(index)));
else
break;
}
@@ -307,7 +307,7 @@ JS::Value LegacyPlatformObject::named_item_value(FlyString const&) const
return JS::js_undefined();
}
-Vector<String> LegacyPlatformObject::supported_property_names() const
+Vector<DeprecatedString> LegacyPlatformObject::supported_property_names() const
{
return {};
}