Skip to content

Commit 951ee3e

Browse files
committed
---
yaml --- r: 156399 b: refs/heads/snap-stage3 c: f4a7d32 h: refs/heads/master i: 156397: 5f0bfce 156395: f136cac 156391: 66e4d36 156383: ebcb839 v: v3
1 parent f4cf1b7 commit 951ee3e

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: c29a7520e7fb4a5b4d4eccfc594e05793ef6688d
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 590a61f788e058d7ae95806f55258bce3ae45567
4+
refs/heads/snap-stage3: f4a7d32c8b53649d20735c8a90469b08fe7cc3dc
55
refs/heads/try: 6601b0501e31d08d3892a2d5a7d8a57ab120bf75
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/src/test/compile-fail/type-params-in-different-spaces-2.rs

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,25 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
// Test static calls to make sure that we align the Self and input
12+
// type parameters on a trait correctly.
13+
1114
trait Tr<T> {
1215
fn op(T) -> Self;
1316
}
1417

15-
// these compile as if Self: Tr<U>, even tho only Self: Tr<Self or T>
1618
trait A: Tr<Self> {
1719
fn test<U>(u: U) -> Self {
1820
Tr::op(u) //~ ERROR not implemented
1921
}
2022
}
23+
2124
trait B<T>: Tr<T> {
2225
fn test<U>(u: U) -> Self {
2326
Tr::op(u) //~ ERROR not implemented
2427
}
2528
}
2629

27-
impl<T> Tr<T> for T {
28-
fn op(t: T) -> T { t }
29-
}
30-
impl<T> A for T {}
31-
3230
fn main() {
33-
std::io::println(A::test((&7306634593706211700, 8)));
3431
}
3532

0 commit comments

Comments
 (0)