add more tests

This commit is contained in:
Kyle Lin 2023-06-30 02:08:37 +08:00
parent 65e24a57bb
commit 1c6b237f9e
2 changed files with 9 additions and 1 deletions

View File

@ -1421,7 +1421,7 @@ fn check_redundant_explicit_link(
// For reference-style links we want to report only one error so unsuccessful // For reference-style links we want to report only one error so unsuccessful
// resolutions are cached, for other links we want to report an error every // resolutions are cached, for other links we want to report an error every
// time so they are not cached. // time so they are not cached.
matches!(ori_link.kind, LinkType::Reference | LinkType::Shortcut), matches!(ori_link.kind, LinkType::Reference),
) else { ) else {
return; return;
}; };

View File

@ -4,16 +4,24 @@ pub fn dummy_target() {}
/// [dummy_target](dummy_target) /// [dummy_target](dummy_target)
/// [`dummy_target`](dummy_target) /// [`dummy_target`](dummy_target)
///
/// [Vec](Vec) /// [Vec](Vec)
/// [`Vec`](Vec) /// [`Vec`](Vec)
/// [Vec](std::vec::Vec) /// [Vec](std::vec::Vec)
/// [`Vec`](std::vec::Vec) /// [`Vec`](std::vec::Vec)
/// [std::vec::Vec](Vec)
/// [`std::vec::Vec`](Vec)
/// [std::vec::Vec](std::vec::Vec) /// [std::vec::Vec](std::vec::Vec)
/// [`std::vec::Vec`](std::vec::Vec) /// [`std::vec::Vec`](std::vec::Vec)
///
/// [usize](usize) /// [usize](usize)
/// [`usize`](usize) /// [`usize`](usize)
/// [usize](std::primitive::usize)
/// [`usize`](std::primitive::usize)
/// [std::primitive::usize](usize) /// [std::primitive::usize](usize)
/// [`std::primitive::usize`](usize) /// [`std::primitive::usize`](usize)
/// [std::primitive::usize](std::primitive::usize)
/// [`std::primitive::usize`](std::primitive::usize)
pub fn should_warn() {} pub fn should_warn() {}
/// [`Vec<T>`](Vec) /// [`Vec<T>`](Vec)