rustdoc: remove the ! from macro URLs and titles
This commit is contained in:
@@ -2803,7 +2803,7 @@ pub struct Macro {
|
||||
|
||||
impl Clean<Item> for doctree::Macro {
|
||||
fn clean(&self, cx: &DocContext) -> Item {
|
||||
let name = format!("{}!", self.name.clean(cx));
|
||||
let name = self.name.clean(cx);
|
||||
Item {
|
||||
name: Some(name.clone()),
|
||||
attrs: self.attrs.clean(cx),
|
||||
@@ -2814,8 +2814,10 @@ impl Clean<Item> for doctree::Macro {
|
||||
def_id: cx.map.local_def_id(self.id),
|
||||
inner: MacroItem(Macro {
|
||||
source: format!("macro_rules! {} {{\n{}}}",
|
||||
name.trim_right_matches('!'), self.matchers.iter().map(|span|
|
||||
format!(" {} => {{ ... }};\n", span.to_src(cx))).collect::<String>()),
|
||||
name,
|
||||
self.matchers.iter().map(|span| {
|
||||
format!(" {} => {{ ... }};\n", span.to_src(cx))
|
||||
}).collect::<String>()),
|
||||
imported_from: self.imported_from.clean(cx),
|
||||
}),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user