Skip to content

two ScopedIpV4 having different interface_ids are considered as equal and lead to an unergonomic usage #445

@hrzlgnm

Description

@hrzlgnm

I was playing around with the addition of interface_ids to ScopedIpV4 and I've discovered an inconvenience.

Lets say we have have an existing entry of a ScopedIp and want to compare it with another ScopedIp that was just resolved and another InterfaceId was added to an ScopedIpV4, both values will be considered as equal and the InterfaceId update gets missed.

I'm not 100% sure but I suspect the trait Eq implementation falls back to ParitalEq here:

impl Eq for ScopedIpV4 {}

Which most likely leads to the observed behavior.

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