File tree Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Original file line number Diff line number Diff line change 1+ // Ensure that no warning is emitted if the disambiguator is used for type alias.
2+ // Regression test for <https://github.com/rust-lang/rust/issues/146855>.
3+
4+ //@ check-pass
5+
6+ #![ deny( rustdoc:: broken_intra_doc_links) ]
7+
8+ pub struct Foo ;
9+ #[ allow( non_camel_case_types) ]
10+ pub type f32 = Foo ;
11+
12+ /// This function returns [`type@f32`]" and not [`prim@f32`].
13+ pub fn my_fn ( ) -> f32 { }
Original file line number Diff line number Diff line change 1+ // Ensure that no warning is emitted if the disambiguator is used for type alias.
2+ // Regression test for <https://github.com/rust-lang/rust/issues/146855>.
3+
4+ #![ crate_name = "foo" ]
5+
6+ pub struct Foo ;
7+ #[ allow( non_camel_case_types) ]
8+ pub type f32 = Foo ;
9+
10+ /// This function returns [`type@f32`] and not [bla][`prim@f32`].
11+ //@ has 'foo/fn.my_fn.html'
12+ //@ has - '//a[@href="type.f32.html"]' "f32"
13+ //@ has - '//a[@href="https://doc.rust-lang.org/nightly/std/primitive.f32.html"]' "bla"
14+ pub fn my_fn ( ) -> f32 { }
You can’t perform that action at this time.
0 commit comments