google / google/zerocopy

Add `byteorder` type methods to extract native value without performing byteorder swap

Open
#445 1 comment 0 reactions 0 assignees View on GitHub
compatibility-nonbreaking
Dominant language
Rust
Stars
2.6k
Forks
179
Avg merge
1d 19h
Merged PRs (30d)
29

Description

These should probably be named `to_bits` to be consistent with the methods of the same name on `f32` and `f64`. The alternative would be something like `get_native`, but I worry that that's too close to `get`, and it'd be too much of a footgun - it'd be easy to reach for it without realizing that it doesn't perform an endianness swap.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.