We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d19f69c commit 33d1368Copy full SHA for 33d1368
tests/source/issue_4257.rs
@@ -0,0 +1,13 @@
1
+#![feature(generic_associated_types)]
2
+#![allow(incomplete_features)]
3
+
4
+trait Trait<T> {
5
+ type Type<'a> where T: 'a;
6
+ fn foo(x: &T) -> Self::Type<'_>;
7
+}
8
+impl<T> Trait<T> for () {
9
+ type Type<'a> where T: 'a = &'a T;
10
+ fn foo(x: &T) -> Self::Type<'_> {
11
+ x
12
+ }
13
tests/target/issue_4257.rs
@@ -0,0 +1,18 @@
+ type Type<'a>
+ where
+ T: 'a;
+ T: 'a,
14
+ = &'a T;
15
16
17
18
0 commit comments