|
9 | 9 |
|
10 | 10 | // FIXME: spec the JSON output properly.
|
11 | 11 |
|
12 |
| -use crate::source_map::{SourceMap, FilePathMapping}; |
| 12 | +use syntax_pos::source_map::{SourceMap, FilePathMapping}; |
13 | 13 |
|
14 |
| -use errors::registry::Registry; |
15 |
| -use errors::{SubDiagnostic, CodeSuggestion}; |
16 |
| -use errors::{DiagnosticId, Applicability}; |
17 |
| -use errors::emitter::{Emitter, HumanReadableErrorType}; |
| 14 | +use crate::registry::Registry; |
| 15 | +use crate::{SubDiagnostic, CodeSuggestion}; |
| 16 | +use crate::{DiagnosticId, Applicability}; |
| 17 | +use crate::emitter::{Emitter, HumanReadableErrorType}; |
18 | 18 |
|
19 | 19 | use syntax_pos::{MacroBacktrace, Span, SpanLabel, MultiSpan};
|
20 |
| -use rustc_data_structures::sync::{self, Lrc}; |
| 20 | +use rustc_data_structures::sync::Lrc; |
21 | 21 | use std::io::{self, Write};
|
22 | 22 | use std::path::Path;
|
23 | 23 | use std::vec;
|
@@ -92,7 +92,7 @@ impl JsonEmitter {
|
92 | 92 | }
|
93 | 93 |
|
94 | 94 | impl Emitter for JsonEmitter {
|
95 |
| - fn emit_diagnostic(&mut self, diag: &errors::Diagnostic) { |
| 95 | + fn emit_diagnostic(&mut self, diag: &crate::Diagnostic) { |
96 | 96 | let data = Diagnostic::from_errors_diagnostic(diag, self);
|
97 | 97 | let result = if self.pretty {
|
98 | 98 | writeln!(&mut self.dst, "{}", as_pretty_json(&data))
|
@@ -212,7 +212,7 @@ struct ArtifactNotification<'a> {
|
212 | 212 | }
|
213 | 213 |
|
214 | 214 | impl Diagnostic {
|
215 |
| - fn from_errors_diagnostic(diag: &errors::Diagnostic, |
| 215 | + fn from_errors_diagnostic(diag: &crate::Diagnostic, |
216 | 216 | je: &JsonEmitter)
|
217 | 217 | -> Diagnostic {
|
218 | 218 | let sugg = diag.suggestions.iter().map(|sugg| {
|
|
0 commit comments