From 960f9ccb2e700332dc576163b62c518120c73f15 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Fri, 22 May 2020 19:23:35 +0200 Subject: fix: SWC lexer settings and silent errors (#5752) This commit changes how error occurring in SWC are handled. Changed lexer settings to properly handle TS decorators. Changed output of SWC error to annotate with position in file. --- cli/module_graph.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'cli/module_graph.rs') diff --git a/cli/module_graph.rs b/cli/module_graph.rs index c63e6848f..8e423265c 100644 --- a/cli/module_graph.rs +++ b/cli/module_graph.rs @@ -188,6 +188,7 @@ impl ModuleGraphLoader { }; let (import_descs, ref_descs) = analyze_dependencies_and_references( + &specifier, &source_code, self.analyze_dynamic_imports, )?; @@ -402,6 +403,7 @@ impl ModuleGraphLoader { } let (import_descs, ref_descs) = analyze_dependencies_and_references( + &module_specifier.to_string(), &source_code, self.analyze_dynamic_imports, )?; -- cgit v1.2.3