LibJS: Use FlyString in PropertyKey instead of DeprecatedFlyString

This required dealing with *substantial* fallout.
This commit is contained in:
Andreas Kling 2025-03-18 18:08:02 -05:00 committed by Andreas Kling
commit 46a5710238
Notes: github-actions[bot] 2025-03-24 22:28:26 +00:00
110 changed files with 985 additions and 987 deletions

View file

@ -9,7 +9,7 @@
#pragma once
#include <AK/DeprecatedFlyString.h>
#include <AK/FlyString.h>
#include <AK/Function.h>
#include <AK/HashMap.h>
#include <AK/RefCounted.h>
@ -197,8 +197,8 @@ public:
u32 execution_generation() const { return m_execution_generation; }
void finish_execution_generation() { ++m_execution_generation; }
ThrowCompletionOr<Reference> resolve_binding(DeprecatedFlyString const&, Environment* = nullptr);
ThrowCompletionOr<Reference> get_identifier_reference(Environment*, DeprecatedFlyString, bool strict, size_t hops = 0);
ThrowCompletionOr<Reference> resolve_binding(FlyString const&, Environment* = nullptr);
ThrowCompletionOr<Reference> get_identifier_reference(Environment*, FlyString, bool strict, size_t hops = 0);
// 5.2.3.2 Throw an Exception, https://tc39.es/ecma262/#sec-throw-an-exception
template<typename T, typename... Args>
@ -274,7 +274,7 @@ public:
Function<HashMap<PropertyKey, Value>(SourceTextModule&)> host_get_import_meta_properties;
Function<void(Object*, SourceTextModule const&)> host_finalize_import_meta;
Function<Vector<ByteString>()> host_get_supported_import_attributes;
Function<Vector<String>()> host_get_supported_import_attributes;
void set_dynamic_imports_allowed(bool value) { m_dynamic_imports_allowed = value; }
@ -335,12 +335,12 @@ private:
struct StoredModule {
ImportedModuleReferrer referrer;
ByteString filename;
ByteString type;
String type;
GC::Root<Module> module;
bool has_once_started_linking { false };
};
StoredModule* get_stored_module(ImportedModuleReferrer const& script_or_module, ByteString const& filename, ByteString const& type);
StoredModule* get_stored_module(ImportedModuleReferrer const& script_or_module, ByteString const& filename, String const& type);
Vector<StoredModule> m_loaded_modules;