Stop using translate_args in the new solver
This commit is contained in:
parent
99cb42c296
commit
20699fe6b2
7 changed files with 167 additions and 56 deletions
|
@ -0,0 +1,24 @@
|
|||
//@ check-pass
|
||||
//@ revisions: current next
|
||||
//@ ignore-compare-mode-next-solver (explicit revisions)
|
||||
//@[next] compile-flags: -Znext-solver
|
||||
|
||||
// Tests that rebasing from the concrete impl to the default impl also processes the
|
||||
// `[u32; 0]: IntoIterator<Item = ?U>` predicate to constrain the `?U` impl arg.
|
||||
|
||||
#![feature(specialization)]
|
||||
//~^ WARN the feature `specialization` is incomplete
|
||||
|
||||
trait Spec {
|
||||
type Assoc;
|
||||
}
|
||||
|
||||
default impl<T, U> Spec for T where T: IntoIterator<Item = U> {
|
||||
type Assoc = U;
|
||||
}
|
||||
|
||||
impl<T> Spec for [T; 0] {}
|
||||
|
||||
fn main() {
|
||||
let x: <[u32; 0] as Spec>::Assoc = 1;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue