Skip to content

regression: conflicting implementations of trait Visitable for type Box<_> #127341

Closed
@Mark-Simulacrum

Description

@Mark-Simulacrum

Not entirely clear if this is caused by a new impl in std or trait solver changes.

[INFO] [stdout] error[E0119]: conflicting implementations of trait `Visitable` for type `Box<_>`
[INFO] [stdout]   --> src/std_impls.rs:49:1
[INFO] [stdout]    |
[INFO] [stdout] 25 | / impl<C: 'static> Visitable for C
[INFO] [stdout] 26 | | where
[INFO] [stdout] 27 | |     for<'a> &'a C: IntoIterator,
[INFO] [stdout] 28 | |     for<'a> <&'a C as IntoIterator>::Item: AsVisitable<'a>,
[INFO] [stdout]    | |___________________________________________________________- first implementation here
[INFO] [stdout] ...
[INFO] [stdout] 49 |   impl<T: Visitable> Visitable for Box<T> {
[INFO] [stdout]    |   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ conflicting implementation for `Box<_>`
[INFO] [stdout]    |
[INFO] [stdout]    = note: downstream crates may implement trait `std_impls::AsVisitable<'a>` for type `<&'a std::boxed::Box<_> as std::iter::IntoIterator>::Item`

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-typesRelevant to the types team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions