diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2024-08-27 18:59:29 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-08-27 18:59:29 +0200 |
| commit | 489eb230ddbcdf4ccd5b00db165a8844fac9c047 (patch) | |
| tree | b397a8e2cb3db9cf6392c7c28c0f424768c45f2f /compiler/rustc_errors/src/markdown | |
| parent | 02491259c2f54b026ac6be939de6b67c8c73c319 (diff) | |
| parent | 22cdd632f1a98830ead8f03cf7f227cc72d814a8 (diff) | |
Rollup merge of #129648 - nnethercote:unreachable_pub-2, r=Urgau
More `unreachable_pub` Add `unreachable_pub` checking to some more compiler crates. A follow-up to #126013. r? ``@Urgau``
Diffstat (limited to 'compiler/rustc_errors/src/markdown')
| -rw-r--r-- | compiler/rustc_errors/src/markdown/parse.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_errors/src/markdown/term.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_errors/src/markdown/parse.rs b/compiler/rustc_errors/src/markdown/parse.rs index 46f8959b6f2..b1db44dd215 100644 --- a/compiler/rustc_errors/src/markdown/parse.rs +++ b/compiler/rustc_errors/src/markdown/parse.rs @@ -74,7 +74,7 @@ enum ParseOpt { } /// Parse a buffer -pub fn entrypoint(txt: &str) -> MdStream<'_> { +pub(crate) fn entrypoint(txt: &str) -> MdStream<'_> { let ctx = Context { top_block: true, prev: Prev::Newline }; normalize(parse_recursive(txt.trim().as_bytes(), ctx), &mut Vec::new()) } diff --git a/compiler/rustc_errors/src/markdown/term.rs b/compiler/rustc_errors/src/markdown/term.rs index 06c1333d93d..579e00b8b85 100644 --- a/compiler/rustc_errors/src/markdown/term.rs +++ b/compiler/rustc_errors/src/markdown/term.rs @@ -15,7 +15,7 @@ thread_local! { } /// Print to terminal output to a buffer -pub fn entrypoint(stream: &MdStream<'_>, buf: &mut Buffer) -> io::Result<()> { +pub(crate) fn entrypoint(stream: &MdStream<'_>, buf: &mut Buffer) -> io::Result<()> { #[cfg(not(test))] if let Some((w, _)) = termize::dimensions() { WIDTH.with(|c| c.set(std::cmp::min(w, DEFAULT_COLUMN_WIDTH))); @@ -47,7 +47,7 @@ fn write_stream( Ok(()) } -pub fn write_tt(tt: &MdTree<'_>, buf: &mut Buffer, indent: usize) -> io::Result<()> { +fn write_tt(tt: &MdTree<'_>, buf: &mut Buffer, indent: usize) -> io::Result<()> { match tt { MdTree::CodeBlock { txt, lang: _ } => { buf.set_color(ColorSpec::new().set_dimmed(true))?; |
