diff options
Diffstat (limited to 'src/json_parser.zig')
-rw-r--r-- | src/json_parser.zig | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/json_parser.zig b/src/json_parser.zig index 956d23262..5eaf4d4d7 100644 --- a/src/json_parser.zig +++ b/src/json_parser.zig @@ -4,7 +4,7 @@ const js_lexer = bun.js_lexer; const importRecord = @import("import_record.zig"); const js_ast = bun.JSAst; const options = @import("options.zig"); - +const BabyList = @import("./baby_list.zig").BabyList; const fs = @import("fs.zig"); const bun = @import("bun"); const string = bun.string; @@ -605,7 +605,7 @@ pub fn toAST( return Expr.init( js_ast.E.Object, js_ast.E.Object{ - .properties = js_ast.BabyList(G.Property).init(properties[0..property_i]), + .properties = BabyList(G.Property).init(properties[0..property_i]), .is_single_line = property_i <= 1, }, logger.Loc.Empty, @@ -671,8 +671,8 @@ pub fn toAST( } } -const JSONParser = JSONLikeParser(js_lexer.JSONOptions{ .is_json = true }); -const RemoteJSONParser = JSONLikeParser(js_lexer.JSONOptions{ .is_json = true, .json_warn_duplicate_keys = false }); +const JSONParser = if (bun.fast_debug_build_mode) TSConfigParser else JSONLikeParser(js_lexer.JSONOptions{ .is_json = true }); +const RemoteJSONParser = if (bun.fast_debug_build_mode) TSConfigParser else JSONLikeParser(js_lexer.JSONOptions{ .is_json = true, .json_warn_duplicate_keys = false }); const DotEnvJSONParser = JSONLikeParser(js_lexer.JSONOptions{ .ignore_leading_escape_sequences = true, .ignore_trailing_escape_sequences = true, |