-
Notifications
You must be signed in to change notification settings - Fork 98
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
Make functions in this crate const
?
#310
Comments
The stabilization definitely would make it possible for some of these functions to work in I think the better solution is to just move the math functions from |
I am going to close this since I don't think we will make any changes in this crate's public API. I brought the topic of const float math up on Zulip since I don't think it has been discussed too much before https://rust-lang.zulipchat.com/#narrow/channel/146212-t-compiler.2Fconst-eval/topic/Const.20float.20math (feel free to drop by there if you have any interest working on it) |
Makes sense. I might drop by there later to help work on this, could be fun! |
I'd wait for 1.83 (beta now): rust-lang/rust#129195 |
Note that the Zulip discussion didn’t particularly reach a conclusion in favor of this plan, and in particular RalfJ opined that it is likely unsound:
Also, applications may benefit from access to this same kind of determinism. For example, today I use Supporting |
What you think about 2-level implementation?
pub const fn try_sin() -> Result<f32, Error> {};
pub fn sin() -> f32 {} |
Now that
const_float_arithmetic
has been stabilized, will the functions in this crate be madeconst
where possible? Or is this not in scope due to MSRV policy?The text was updated successfully, but these errors were encountered: