LibJS: Forward-declare RegexTable and BasicBlock in Executable.h

Previously every file that included Executable.h (which is pretty much
most LibJS and LibHTML files, given that VM.h needs it) had the whole
definition of LibRegex, which was slowing down source parsing.
This commit is contained in:
Karol Kosek 2023-10-08 12:25:58 +02:00 committed by Andreas Kling
parent 426b7ffa41
commit 2ea45f4881
3 changed files with 4 additions and 2 deletions

View file

@ -4,7 +4,9 @@
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <LibJS/Bytecode/BasicBlock.h>
#include <LibJS/Bytecode/Executable.h>
#include <LibJS/Bytecode/RegexTable.h>
#include <LibJS/SourceCode.h>
namespace JS::Bytecode {

View file

@ -9,10 +9,9 @@
#include <AK/DeprecatedFlyString.h>
#include <AK/NonnullOwnPtr.h>
#include <AK/WeakPtr.h>
#include <LibJS/Bytecode/BasicBlock.h>
#include <LibJS/Bytecode/IdentifierTable.h>
#include <LibJS/Bytecode/RegexTable.h>
#include <LibJS/Bytecode/StringTable.h>
#include <LibJS/Forward.h>
namespace JS::Bytecode {

View file

@ -306,6 +306,7 @@ class Executable;
class Generator;
class Instruction;
class Interpreter;
class RegexTable;
class Register;
}