We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
error: calls in constants are limited to constant functions, struct and enum constructors
How can I make the generated new() constructor const-fn? E.g.:
new()
#[derive(new, Copy, Clone)] pub struct ColorHB { hue: Hue, #[new(value = "1.")] brightness: f32, }
The text was updated successfully, but these errors were encountered:
@nrc Can you please make the generated new method a const-fn? :)
new
Sorry, something went wrong.
const
No branches or pull requests
How can I make the generated
new()
constructor const-fn?E.g.:
The text was updated successfully, but these errors were encountered: