1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:08:10 +00:00

LibJS: Add filename tracking to Script and Module

This will allow us to resolve modules dynamically loaded from a script.
This commit is contained in:
davidot 2022-01-18 19:21:42 +01:00 committed by Linus Groh
parent 57c5a59cab
commit 12c2f30c54
6 changed files with 22 additions and 10 deletions

View file

@ -8,9 +8,10 @@
namespace JS {
Module::Module(Realm& realm)
Module::Module(Realm& realm, StringView filename)
: m_vm(realm.vm())
, m_realm(make_handle(&realm))
, m_filename(filename)
{
}