Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit fbbae87

Browse filesBrowse files
committed
crashes to ui
1 parent 283c81f commit fbbae87
Copy full SHA for fbbae87

File tree

Expand file treeCollapse file tree

6 files changed

+85
-32
lines changed
Filter options
Expand file treeCollapse file tree

6 files changed

+85
-32
lines changed

‎tests/crashes/102252.rs

Copy file name to clipboardExpand all lines: tests/crashes/102252.rs
-14Lines changed: 0 additions & 14 deletions
This file was deleted.

‎tests/crashes/126268.rs

Copy file name to clipboardExpand all lines: tests/crashes/126268.rs
-18Lines changed: 0 additions & 18 deletions
This file was deleted.
+20Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// This test previous triggered an assertion that there are no inference variables
2+
// returned by `wf::obligations`. Overflow when normalizing
3+
// `Self: Iterator<Item = <Self as Iterator>::Item>` resulted in overflow which then
4+
// caused us to return an infer var.
5+
//
6+
// This assert has now been removed.
7+
#![feature(min_specialization, rustc_attrs)]
8+
9+
#[rustc_specialization_trait]
10+
pub trait Trait {}
11+
12+
struct Struct
13+
//~^ ERROR overflow evaluating the requirement `<Struct as Iterator>::Item == _`
14+
where
15+
Self: Iterator<Item = <Self as Iterator>::Item>, {}
16+
17+
impl Trait for Struct {}
18+
//~^ ERROR `Struct` is not an iterator
19+
20+
fn main() {}
+26Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
error[E0275]: overflow evaluating the requirement `<Struct as Iterator>::Item == _`
2+
--> $DIR/fuzzing-ice-102252.rs:12:1
3+
|
4+
LL | struct Struct
5+
| ^^^^^^^^^^^^^
6+
7+
error[E0277]: `Struct` is not an iterator
8+
--> $DIR/fuzzing-ice-102252.rs:17:16
9+
|
10+
LL | impl Trait for Struct {}
11+
| ^^^^^^ `Struct` is not an iterator
12+
|
13+
= help: the trait `Iterator` is not implemented for `Struct`
14+
note: required by a bound in `Struct`
15+
--> $DIR/fuzzing-ice-102252.rs:15:11
16+
|
17+
LL | struct Struct
18+
| ------ required by a bound in this struct
19+
...
20+
LL | Self: Iterator<Item = <Self as Iterator>::Item>, {}
21+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `Struct`
22+
23+
error: aborting due to 2 previous errors
24+
25+
Some errors have detailed explanations: E0275, E0277.
26+
For more information about an error, try `rustc --explain E0275`.
+25Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// This test previous triggered an assertion that there are no inference variables
2+
// returned by `wf::obligations`. We ended up with an infer var as we failed to
3+
// normalize `R::Elem`.
4+
//
5+
// This assert has now been removed.
6+
#![feature(min_specialization)]
7+
8+
trait Trait {}
9+
10+
impl<T> Trait for T {}
11+
12+
trait Data {
13+
type Elem;
14+
}
15+
16+
struct DatasetIter<'a, R: Data> {
17+
data: &'a R::Elem,
18+
}
19+
20+
pub struct ArrayBase {}
21+
22+
impl<'a> Trait for DatasetIter<'a, ArrayBase> {}
23+
//~^ ERROR specialization impl does not specialize any associated items
24+
25+
fn main() {}
+14Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
error: specialization impl does not specialize any associated items
2+
--> $DIR/fuzzing-ice-126268.rs:22:1
3+
|
4+
LL | impl<'a> Trait for DatasetIter<'a, ArrayBase> {}
5+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6+
|
7+
note: impl is a specialization of this impl
8+
--> $DIR/fuzzing-ice-126268.rs:10:1
9+
|
10+
LL | impl<T> Trait for T {}
11+
| ^^^^^^^^^^^^^^^^^^^
12+
13+
error: aborting due to 1 previous error
14+

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.