1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-18 21:35:06 +00:00
serenity/Userland/Libraries/LibWeb/Bindings
Timothy Flynn db2ba5f1d9 LibWeb: Initialize static web strings during main-thread VM creation
These are currently initialized in a [[gnu::constructor]], which has a
weird initialization order. These constructors are invoked before main()
and, incidentally, before any user-defined default constructors of the
static strings they are initializing.

This will become an issue when these strings are ported to FlyString,
which has a user-defined default constructor. In that scenario, when the
FlyString constructor is executed after the [[gnu::constructor]], the
strings will be "reset" to the empty string.

Instead of relying on a non-standard compiler extension here, let's just
initialize these strings explicitly during main-thread VM creation, as
this now happens in WebContent's main().
2023-03-18 19:50:45 +01:00
..
AudioConstructor.cpp LibWeb: Make factory method of DOM::ElementFactory fallible 2023-02-22 09:55:33 +01:00
AudioConstructor.h LibJS+Everywhere: Allow Cell::initialize overrides to throw OOM errors 2023-01-29 00:02:45 +00:00
ExceptionOrUtils.h LibWeb/WebIDL: Store SimpleException message as a String{,View} variant 2023-03-03 19:50:36 +00:00
HostDefined.cpp LibWeb: Move Web prototypes and constructors to new Intrinsics object 2022-10-01 21:05:32 +01:00
HostDefined.h LibWeb: Make HostDefined and Intrinsics free functions [[nodiscard]] 2022-10-09 10:14:57 +02:00
ImageConstructor.cpp LibWeb: Make factory method of DOM::ElementFactory fallible 2023-02-22 09:55:33 +01:00
ImageConstructor.h LibJS+Everywhere: Allow Cell::initialize overrides to throw OOM errors 2023-01-29 00:02:45 +00:00
Intrinsics.cpp LibWeb: Remove Intrinsics::cached_web_prototype 2023-01-10 16:08:14 +01:00
Intrinsics.h LibWeb: Support generating IDL namespaces 2023-03-15 12:48:25 -04:00
LegacyPlatformObject.cpp LibWeb: Restore proper functionality of legacy platform objects 2023-02-28 12:36:14 +01:00
LegacyPlatformObject.h LibWeb: Restore proper functionality of legacy platform objects 2023-02-28 12:36:14 +01:00
MainThreadVM.cpp LibWeb: Initialize static web strings during main-thread VM creation 2023-03-18 19:50:45 +01:00
MainThreadVM.h LibWeb: Move initialization of the MainThreadVM to WebContent's main() 2023-03-17 16:39:08 +00:00
OptionConstructor.cpp LibWeb: Make factory method of DOM::ElementFactory fallible 2023-02-22 09:55:33 +01:00
OptionConstructor.h LibJS+Everywhere: Allow Cell::initialize overrides to throw OOM errors 2023-01-29 00:02:45 +00:00
PlatformObject.cpp LibJS: Remove Object(Object& prototype) footgun 2022-12-14 15:11:57 +01:00
PlatformObject.h AK+Everywhere: Rename String to DeprecatedString 2022-12-06 08:54:33 +01:00