From d9db6bec42783ed0b1cacb605575a8e4884dc904 Mon Sep 17 00:00:00 2001 From: Matthew Olsson Date: Mon, 6 Jul 2020 16:57:22 -0700 Subject: LibJS: Move global symbol map from SymbolObject to Interpreter This allows different instances of the Interpreter to have their own global symbols. Also makes Symbol non-copyable and non-moveable. --- Libraries/LibJS/Runtime/SymbolObject.h | 35 ---------------------------------- 1 file changed, 35 deletions(-) (limited to 'Libraries/LibJS/Runtime/SymbolObject.h') diff --git a/Libraries/LibJS/Runtime/SymbolObject.h b/Libraries/LibJS/Runtime/SymbolObject.h index 763354b233..31e5a3e87e 100644 --- a/Libraries/LibJS/Runtime/SymbolObject.h +++ b/Libraries/LibJS/Runtime/SymbolObject.h @@ -46,51 +46,16 @@ public: const String& description() const { return m_symbol.description(); } bool is_global() const { return m_symbol.is_global(); } - static Value get_global(Interpreter&, String description); - virtual Value value_of() const override { return Value(&m_symbol); } - static void initialize_well_known_symbols(Interpreter&); - static void gather_symbol_roots(HashTable& roots); - - static Value well_known_iterator() { return s_well_known_iterator; }; - static Value well_known_async_terator() { return s_well_known_async_terator; }; - static Value well_known_match() { return s_well_known_match; }; - static Value well_known_match_all() { return s_well_known_match_all; }; - static Value well_known_replace() { return s_well_known_replace; }; - static Value well_known_search() { return s_well_known_search; }; - static Value well_known_split() { return s_well_known_split; }; - static Value well_known_has_instance() { return s_well_known_has_instance; }; - static Value well_known_is_concat_spreadable() { return s_well_known_is_concat_spreadable; }; - static Value well_known_unscopables() { return s_well_known_unscopables; }; - static Value well_known_species() { return s_well_known_species; }; - static Value well_known_to_primtive() { return s_well_known_to_primtive; }; - static Value well_known_to_string_tag() { return s_well_known_to_string_tag; }; - private: virtual void visit_children(Visitor&) override; virtual bool is_symbol_object() const override { return true; } Symbol& m_symbol; - - static HashMap s_global_symbol_map; - - static Value s_well_known_iterator; - static Value s_well_known_async_terator; - static Value s_well_known_match; - static Value s_well_known_match_all; - static Value s_well_known_replace; - static Value s_well_known_search; - static Value s_well_known_split; - static Value s_well_known_has_instance; - static Value s_well_known_is_concat_spreadable; - static Value s_well_known_unscopables; - static Value s_well_known_species; - static Value s_well_known_to_primtive; - static Value s_well_known_to_string_tag; }; } -- cgit v1.2.3