summaryrefslogtreecommitdiffstats
path: root/tests/ui/issues/issue-25679.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/issues/issue-25679.rs')
-rw-r--r--tests/ui/issues/issue-25679.rs20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/ui/issues/issue-25679.rs b/tests/ui/issues/issue-25679.rs
new file mode 100644
index 000000000..b548da988
--- /dev/null
+++ b/tests/ui/issues/issue-25679.rs
@@ -0,0 +1,20 @@
+// run-pass
+trait Device {
+ type Resources;
+}
+#[allow(unused_tuple_struct_fields)]
+struct Foo<D, R>(D, R);
+
+impl<D: Device> Foo<D, D::Resources> {
+ fn present(&self) {}
+}
+
+struct Res;
+struct Dev;
+
+impl Device for Dev { type Resources = Res; }
+
+fn main() {
+ let foo = Foo(Dev, Res);
+ foo.present();
+}