Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/librustdoc/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ pub(crate) fn create_config(
lint_cap,
scrape_examples_options,
expanded_args,
remap_path_prefix,
..
}: RustdocOptions,
RenderOptions { document_private, .. }: &RenderOptions,
Expand Down Expand Up @@ -247,6 +248,7 @@ pub(crate) fn create_config(
describe_lints,
crate_name,
test,
remap_path_prefix,
..Options::default()
};

Expand Down
10 changes: 10 additions & 0 deletions tests/rustdoc-ui/remap-path-prefix-lint.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Regression test for remapped paths in rustdoc errors
// <https://github.com/rust-lang/rust/issues/69264>.

//@ compile-flags:-Z unstable-options --remap-path-prefix={{src-base}}=remapped_path
//@ rustc-env:RUST_BACKTRACE=0

#![deny(rustdoc::invalid_html_tags)]

/// </script>
pub struct Bar;
14 changes: 14 additions & 0 deletions tests/rustdoc-ui/remap-path-prefix-lint.stderr
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
error: unopened HTML tag `script`
--> remapped_path/remap-path-prefix-lint.rs:9:5
|
LL | /// </script>
| ^^^^^^^^^
|
note: the lint level is defined here
--> remapped_path/remap-path-prefix-lint.rs:7:9
|
LL | #![deny(rustdoc::invalid_html_tags)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^

error: aborting due to 1 previous error

Loading