Also handle <blockquote> and <q> HTML tags

This commit is contained in:
Guillaume Gomez 2024-03-13 19:31:01 +01:00
parent cd36b25c4f
commit 03d7ae8153
3 changed files with 12 additions and 0 deletions

View File

@ -611,6 +611,10 @@ fn check_doc<'a, Events: Iterator<Item = (pulldown_cmark::Event<'a>, Range<usize
code_level += 1;
} else if tag.starts_with("</code") {
code_level -= 1;
} else if tag.starts_with("<blockquote") || tag.starts_with("<q") {
blockquote_level += 1;
} else if tag.starts_with("</blockquote") || tag.starts_with("</q") {
blockquote_level -= 1;
}
},
Start(BlockQuote) => blockquote_level += 1,

View File

@ -5,4 +5,8 @@
//~^ ERROR: item in documentation is missing backticks
///
/// > AvisynthPluginInit3 may be called more than once with different IScriptEnvironments.
///
/// <blockquote>bla AvisynthPluginInit3 bla</blockquote>
///
/// <q>bla AvisynthPluginInit3 bla</q>
pub struct Foo;

View File

@ -5,4 +5,8 @@
//~^ ERROR: item in documentation is missing backticks
///
/// > AvisynthPluginInit3 may be called more than once with different IScriptEnvironments.
///
/// <blockquote>bla AvisynthPluginInit3 bla</blockquote>
///
/// <q>bla AvisynthPluginInit3 bla</q>
pub struct Foo;