Skip to content

Add trait bounds to new methodsΒ #49

@rfuest

Description

@rfuest

At the moment the new methods in I2CInterface and SPIInterface don't have any trait bounds, which makes it possible to create instances of these types which don't implement the WriteOnlyCommand trait. This makes the display interface unusable, but doesn't generate an error immediately. Requiring the necessary traits when new is called would generate better compiler errors and make it easier to pinpoint the cause of the error by users.

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