diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2018-06-15 23:23:25 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2018-06-15 23:23:25 +0200 |
| commit | e28502edcadbf9ab6102493e8774f1af32df4eb9 (patch) | |
| tree | 641dd37c0782c78da2999a905d288746a14cb5e4 | |
| parent | 1dd1f95af835be787231b8609163581c761d974a (diff) | |
| download | rust-e28502edcadbf9ab6102493e8774f1af32df4eb9.tar.gz rust-e28502edcadbf9ab6102493e8774f1af32df4eb9.zip | |
Fix search fn keyword
| -rw-r--r-- | src/librustdoc/html/static/main.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/librustdoc/html/static/main.js b/src/librustdoc/html/static/main.js index ed6745cd7f5..bb996e00d35 100644 --- a/src/librustdoc/html/static/main.js +++ b/src/librustdoc/html/static/main.js @@ -465,6 +465,10 @@ var res = buildHrefAndPath(obj); obj.displayPath = pathSplitter(res[0]); obj.fullPath = obj.displayPath + obj.name; + if (obj.ty === TY_KEYWORD) { + // To be sure than it isn't considered as duplicate with items. + obj.fullPath += '|k'; + } obj.href = res[1]; out.push(obj); if (out.length >= MAX_RESULTS) { @@ -781,7 +785,7 @@ case "fn": return (name == "method" || name == "tymethod"); case "type": - return (name == "primitive"); + return (name == "primitive" || name == "keyword"); } // No match |
