rustdoc: Don't include the path for primitive methods in the search results
Displaying `std::u32::max_value` is misleading so just display `u32::max_value`.
This commit is contained in:
parent
5940150841
commit
616b101e3f
@ -587,9 +587,14 @@
|
||||
} else if (item.parent !== undefined) {
|
||||
var myparent = item.parent;
|
||||
var anchor = '#' + type + '.' + name;
|
||||
displayPath = item.path + '::' + myparent.name + '::';
|
||||
var parentType = itemTypes[myparent.ty];
|
||||
if (parentType === "primitive") {
|
||||
displayPath = myparent.name + '::';
|
||||
} else {
|
||||
displayPath = item.path + '::' + myparent.name + '::';
|
||||
}
|
||||
href = rootPath + item.path.replace(/::/g, '/') +
|
||||
'/' + itemTypes[myparent.ty] +
|
||||
'/' + parentType +
|
||||
'.' + myparent.name +
|
||||
'.html' + anchor;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user