X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Flibrustdoc%2Fcore.rs;h=6b2cb53b8f1f05f5cc3eaa05729b8ac78da600c8;hb=c65547337831babea8d9052b960649309263df36;hp=68e4618328077cc6030e309c031703c4ed14186b;hpb=3ac79c718475fd29b8be34dde667b683390c2aee;p=rust.git diff --git a/src/librustdoc/core.rs b/src/librustdoc/core.rs index 68e46183280..6b2cb53b8f1 100644 --- a/src/librustdoc/core.rs +++ b/src/librustdoc/core.rs @@ -258,9 +258,9 @@ fn is_doc_reachable(&self, did: DefId) -> bool { /// Creates a new diagnostic `Handler` that can be used to emit warnings and errors. /// -/// If the given `error_format` is `ErrorOutputType::Json` and no `CodeMap` is given, a new one +/// If the given `error_format` is `ErrorOutputType::Json` and no `SourceMap` is given, a new one /// will be created for the handler. -pub fn new_handler(error_format: ErrorOutputType, codemap: Option>) +pub fn new_handler(error_format: ErrorOutputType, codemap: Option>) -> errors::Handler { // rustdoc doesn't override (or allow to override) anything from this that is relevant here, so @@ -277,7 +277,7 @@ pub fn new_handler(error_format: ErrorOutputType, codemap: Option { let codemap = codemap.unwrap_or_else( - || Lrc::new(codemap::CodeMap::new(sessopts.file_path_mapping()))); + || Lrc::new(codemap::SourceMap::new(sessopts.file_path_mapping()))); Box::new( JsonEmitter::stderr( None, @@ -387,7 +387,7 @@ pub fn run_core(search_paths: SearchPaths, ..Options::default() }; driver::spawn_thread_pool(sessopts, move |sessopts| { - let codemap = Lrc::new(codemap::CodeMap::new(sessopts.file_path_mapping())); + let codemap = Lrc::new(codemap::SourceMap::new(sessopts.file_path_mapping())); let diagnostic_handler = new_handler(error_format, Some(codemap.clone())); let mut sess = session::build_session_(