You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The uutils version of od does not support the fL output format specifier. It means "format the output as a floating point number, using sizeof(long double) bytes to interpret each number in the input". For more information, see: https://www.gnu.org/software/coreutils/manual/html_node/od-invocation.html
GNU od:
$ : | od -tfL
0000000
uutils od:
$ : | ./target/debug/od -tfL
./target/debug/od: unexpected char 'L' in format specification 'fL'
Is there a reason this hasn't been touched in a while? Does the difficulty lie in supporting 128 bit floats, which are not in the Rust standard library? Would we have to use an external crate to support them?
I suspect that's indeed the reason. We already have an external library for f16 (half), so another one for f128 makes sense to me. An RFC for both types is being worked on, but might take a while to land.
It mentions the f128 crate which seems to be GCC only if I understand correctly? Maybe this just needs to be delayed until that RFC comes through then...
I looked around a little as well, and many promising crates like rug are just wrappers around some GNU libraries. I'm not sure if using such crates go against the philosophy of this project, since they're not pure-rust. Furthermore, I read that installing rug on windows is not straightforward, and I'm guessing this project supports windows.
I would also agree that waiting for official Rust std lib support sounds like the best option for now.
The uutils version of
od
does not support thefL
output format specifier. It means "format the output as a floating point number, usingsizeof(long double)
bytes to interpret each number in the input". For more information, see: https://www.gnu.org/software/coreutils/manual/html_node/od-invocation.htmlGNU od:
uutils od:
Here's the relevant part of the code:
coreutils/src/uu/od/src/parse_formats.rs
Line 233 in b14e396
The text was updated successfully, but these errors were encountered: