Skip to content

Buffer is not usable as a trait object #18530

Closed
@lifthrasiir

Description

@lifthrasiir
let mut buf = std::io::BufReader::new(b"asdf");
let _: &mut Buffer = &mut buf; // error

As a side effect of #17704 (and I think @huonw has noted this possibility correctly), std::io::Buffer is no longer usable as a trait object. We need a separate trait and a blacket implementation for it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions