mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:38:12 +00:00
LibJS: Make ScriptOrModule use WeakPtr instead of raw pointers
This commit is contained in:
parent
6ee597369d
commit
85cf80507f
9 changed files with 23 additions and 18 deletions
|
@ -16,7 +16,9 @@
|
|||
namespace JS {
|
||||
|
||||
// 16.1.4 Script Records, https://tc39.es/ecma262/#sec-script-records
|
||||
class Script : public RefCounted<Script> {
|
||||
class Script
|
||||
: public RefCounted<Script>
|
||||
, public Weakable<Script> {
|
||||
public:
|
||||
~Script();
|
||||
static Result<NonnullRefPtr<Script>, Vector<Parser::Error>> parse(StringView source_text, Realm&, StringView filename = {});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue