Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consistency for PID and zone identifiers #121

Open
chrysn opened this issue Sep 10, 2024 · 1 comment
Open

Consistency for PID and zone identifiers #121

chrysn opened this issue Sep 10, 2024 · 1 comment
Labels
wait-for-breaking-0.10 Change that is held for the 0.10 release, for it is a breaking change

Comments

@chrysn
Copy link
Member

chrysn commented Sep 10, 2024

Right now, we have KernelPid which is i16 internally (and converts into an i16 without preserving the implied "it is positive and not zero" property), but also interface identifiers which in GNRC are inherently PID bound but expressed as NonZero in gnrc::nib because the underlying gnrc_ipv6_nib_nc_get_iface returns a C unsigned int (which, remind you, is not usize but basically an arbitrary type, and 32-bit long on some 64-bit systems)

It may be worth considering whether we can and should unify those. Practically, I don't expect interface identifiers to exceed 127 anyway on RIOT systems :-)

@chrysn chrysn added the wait-for-breaking-0.10 Change that is held for the 0.10 release, for it is a breaking change label Sep 10, 2024
@chrysn
Copy link
Member Author

chrysn commented Sep 10, 2024

In use, a usize will be practical when https://gitlab.com/twittner/minicbor/-/merge_requests/48 is merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wait-for-breaking-0.10 Change that is held for the 0.10 release, for it is a breaking change
Projects
None yet
Development

No branches or pull requests

1 participant