Skip to content

Commit a3285fc

Browse files
committed
Feature(compiler): Display code-span for Internal errors like Unsupported error
1 parent 233bbe0 commit a3285fc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/cli.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ try {
101101
]);
102102
} catch (e) {
103103
if (e instanceof UnsupportedError) {
104-
ts.sys.write(ts.formatDiagnostic(e.toDiagnostic(), DiagnosticHostInstance));
104+
ts.sys.write(ts.formatDiagnosticsWithColorAndContext([e.toDiagnostic()], DiagnosticHostInstance));
105105
ts.sys.exit(ts.ExitStatus.DiagnosticsPresent_OutputsSkipped);
106106
}
107107

0 commit comments

Comments
 (0)