mirror of
https://github.com/rust-lang/rust.git
synced 2025-04-13 12:36:47 +00:00
amend to Switch can_eq
and can_sub
to DefineOpaqueTypes::Yes
This commit is contained in:
parent
169a045dca
commit
ba316a902d
@ -5,7 +5,7 @@ fn fine(x: impl Into<u32>) -> impl Into<u32> { x }
|
||||
|
||||
fn bad_in_ret_position(x: impl Into<u32>) -> impl Into<impl Debug> { x }
|
||||
//~^ ERROR nested `impl Trait` is not allowed
|
||||
//~| ERROR the trait bound `impl Debug: From<impl Into<u32>>` is not satisfied
|
||||
//~| ERROR the trait bound `impl Into<u32>: Into<impl Debug>` is not satisfied
|
||||
|
||||
fn bad_in_fn_syntax(x: fn() -> impl Into<impl Debug>) {}
|
||||
//~^ ERROR nested `impl Trait` is not allowed
|
||||
@ -18,7 +18,7 @@ struct X;
|
||||
impl X {
|
||||
fn bad(x: impl Into<u32>) -> impl Into<impl Debug> { x }
|
||||
//~^ ERROR nested `impl Trait` is not allowed
|
||||
//~| ERROR the trait bound `impl Debug: From<impl Into<u32>>` is not satisfied
|
||||
//~| ERROR the trait bound `impl Into<u32>: Into<impl Debug>` is not satisfied
|
||||
}
|
||||
|
||||
fn allowed_in_assoc_type() -> impl Iterator<Item=impl Fn()> {
|
||||
|
Loading…
Reference in New Issue
Block a user