Skip to content

derive on generic types #9

@qm3ster

Description

@qm3ster

It doesn't seem like it's possible to do

#[derive(Debug, XmlRead, XmlWrite)]
#[xml(tag = "Packet")]
struct Packet<T>
where
    T: XmlRead + XmlWrite,
{
    #[xml(flatten_text = "Command")]
    command: Command,
    #[xml(child = "DatabaseManager")]
    database_manager: T,
}

Would it be possible to move the trait bounds into the impl, the way serde does it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions