diff options
| author | Michael Howell <michael@notriddle.com> | 2024-12-13 10:47:02 -0700 |
|---|---|---|
| committer | Michael Howell <michael@notriddle.com> | 2024-12-13 10:47:20 -0700 |
| commit | f068d8b809e09f4c685bddeebfe63e736a02d473 (patch) | |
| tree | a0f9dfb5015704c5b912efeabc6e0ae546e3753b /tests/rustdoc-js/impl-trait-inlining.js | |
| parent | 4847d6a9d07d4be9ba3196f6ad444af2d7bdde72 (diff) | |
| download | rust-f068d8b809e09f4c685bddeebfe63e736a02d473.tar.gz rust-f068d8b809e09f4c685bddeebfe63e736a02d473.zip | |
rustdoc-search: show `impl Trait` inline when unhighlighted
While normal generics can be skipped in this case, no-names need something to show here. Before: `TyCtxt, , Symbol -> bool` After: `TyCtxt, Into<DefId>, Symbol -> bool`
Diffstat (limited to 'tests/rustdoc-js/impl-trait-inlining.js')
| -rw-r--r-- | tests/rustdoc-js/impl-trait-inlining.js | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/tests/rustdoc-js/impl-trait-inlining.js b/tests/rustdoc-js/impl-trait-inlining.js new file mode 100644 index 00000000000..02c9853dd63 --- /dev/null +++ b/tests/rustdoc-js/impl-trait-inlining.js @@ -0,0 +1,25 @@ +// exact-check +// ignore-order + +const EXPECTED = [ + { + 'query': 'tyctxt, symbol -> bool', + 'others': [ + { + 'path': 'foo::TyCtxt', + 'name': 'has_attr', + 'displayType': "`TyCtxt`, Into<DefId>, `Symbol` -> `bool`", + }, + ], + }, + { + 'query': 'tyctxt, into<defid>, symbol -> bool', + 'others': [ + { + 'path': 'foo::TyCtxt', + 'name': 'has_attr', + 'displayType': "`TyCtxt`, `Into`<`DefId`>, `Symbol` -> `bool`", + }, + ], + }, +]; |
