Reuse sys::unix::cmath on other platforms#84522
Conversation
|
r? @yaahc (rust-highfive has picked a reviewer for you, use r? to override) |
library/std/src/sys/unix/cmath.rs
Outdated
There was a problem hiding this comment.
These functions are used to implement methods of f32 and f64, so anything else then c_double = f64 and c_float = f32 would be wrong anyway. This makes the file reusable on platforms that don't have libc available.
This comment has been minimized.
This comment has been minimized.
|
Everything here looks good to me but I'm not super familiar with the platform abstraction modules yet so I'd like to get a second set of eyes on this before approving. cc @rust-lang/libs |
|
(Adding myself to the assignees so I won't forget to look at it tomorrow.) |
|
Looks good to me, other than the above comment. |
|
Looks like it's good to go then @bors r+ |
|
📌 Commit 26fb1e3 has been approved by |
Reuse `sys::unix::cmath` on other platforms Reuse `sys::unix::cmath` on all non-`windows` platforms. `unix` is chosen as the canonical location instead of `unsupported` or `common` because `unsupported` doesn't make sense semantically and `common` is reserved for code that is supported on all platforms. Also `unix` is already the home of some non-`windows` code that is technically not exclusive to `unix` like `unix::path`.
|
☀️ Test successful - checks-actions |
Reuse
sys::unix::cmathon all non-windowsplatforms.unixis chosen as the canonical location instead ofunsupportedorcommonbecauseunsupporteddoesn't make sense semantically andcommonis reserved for code that is supported on all platforms. Alsounixis already the home of some non-windowscode that is technically not exclusive tounixlikeunix::path.