Wire up macro-injected imports and move some structs above the gigantic parser type to reduce bun compile time a little

This commit is contained in:
Jarred Sumner
2021-09-30 13:49:46 -07:00
parent ec256209a8
commit 4cdc8939ab
3 changed files with 536 additions and 428 deletions

View File

@@ -1551,6 +1551,7 @@ pub fn castObj(obj: js.JSObjectRef, comptime Type: type) *Type {
}
const JSNode = @import("../../js_ast.zig").Macro.JSNode;
const LazyPropertiesObject = @import("../../js_ast.zig").Macro.LazyPropertiesObject;
const ModuleNamespace = @import("../../js_ast.zig").Macro.ModuleNamespace;
pub const JSPrivateDataPtr = TaggedPointerUnion(.{
ResolveError,
BuildError,
@@ -1562,6 +1563,7 @@ pub const JSPrivateDataPtr = TaggedPointerUnion(.{
Router,
JSNode,
LazyPropertiesObject,
ModuleNamespace,
});
pub inline fn GetJSPrivateData(comptime Type: type, ref: js.JSObjectRef) ?*Type {