File tree Expand file tree Collapse file tree 2 files changed +30
-1
lines changed
src/librustdoc/html/highlight/fixtures Expand file tree Collapse file tree 2 files changed +30
-1
lines changed Original file line number Diff line number Diff line change 3232 }
3333}
3434
35- < span class ="macro "> macro_rules! </ span > bar {
35+ < span class ="macro "> macro_rules!</ span > bar {
3636 (< span class ="macro-nonterminal "> $foo</ span > :tt) => {};
3737}
3838</ code > </ pre >
Original file line number Diff line number Diff line change 1+ // We need this option to be enabled for the `foo` macro declaration to ensure
2+ // that the link on the ident is not including whitespace characters.
3+
4+ //@ compile-flags: -Zunstable-options --generate-link-to-definition
5+ #![ crate_name = "foo" ]
6+
7+ // @has 'src/foo/source-code-highlight.rs.html'
8+
9+ // @hasraw - '<a href="../../foo/macro.foo.html">foo</a>'
10+ #[ macro_export]
11+ macro_rules! foo {
12+ ( ) => { }
13+ }
14+
15+ // @hasraw - '<span class="macro">foo!</span>'
16+ foo ! { }
17+
18+ // @hasraw - '<a href="../../foo/fn.f.html">f</a>'
19+ #[ rustfmt:: skip]
20+ pub fn f ( ) { }
21+ // @hasraw - '<a href="../../foo/struct.Bar.html">Bar</a>'
22+ // @hasraw - '<a href="../../foo/struct.Bar.html">Bar</a>'
23+ // @hasraw - '<a href="{{channel}}/std/primitive.u32.html">u32</a>'
24+ #[ rustfmt:: skip]
25+ pub struct Bar ( u32 ) ;
26+ // @hasraw - '<a href="../../foo/enum.Foo.html">Foo</a>'
27+ pub enum Foo {
28+ A ,
29+ }
You can’t perform that action at this time.
0 commit comments