diff options
Diffstat (limited to 'tests/rustdoc/generic-associated-types')
-rw-r--r-- | tests/rustdoc/generic-associated-types/issue-109488.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/rustdoc/generic-associated-types/issue-109488.rs b/tests/rustdoc/generic-associated-types/issue-109488.rs new file mode 100644 index 000000000..99ae8a6c3 --- /dev/null +++ b/tests/rustdoc/generic-associated-types/issue-109488.rs @@ -0,0 +1,18 @@ +// Make sure that we escape the arguments of the GAT projection even if we fail to compute +// the href of the corresponding trait (in this case it is private). +// Further, test that we also linkify the GAT arguments. + +// @has 'issue_109488/type.A.html' +// @has - '//pre[@class="rust item-decl"]' '<S as Tr>::P<Option<i32>>' +// @has - '//pre[@class="rust item-decl"]//a[@class="enum"]/@href' '{{channel}}/core/option/enum.Option.html' +pub type A = <S as Tr>::P<Option<i32>>; + +/*private*/ trait Tr { + type P<T>; +} + +pub struct S; + +impl Tr for S { + type P<T> = (); +} |