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
Because const fn does not support if-else branches:
const fn
#[inline] pub /*const*/ fn new($($elem_name: bool),*) -> Self { $id($(Self::bool_to_internal($elem_name)),*) } #[inline] /* const */ fn bool_to_internal(x: bool) -> $elem_ty { if x { !(0 as $elem_ty) } else { 0 as $elem_ty } } #[inline] pub /*const*/ fn splat(value: bool) -> Self { let value = Self::bool_to_internal(value); $id($({ #[allow(non_camel_case_types, dead_code)] struct $elem_name; value }),*) }
EDIT: this issue will make sense as soon as I send the boolean vector PR.
The text was updated successfully, but these errors were encountered:
if
match
Thanks to @rkruppe's suggestion boolean vectors now have const constructors in #338 .
Sorry, something went wrong.
No branches or pull requests
Because
const fn
does not support if-else branches:EDIT: this issue will make sense as soon as I send the boolean vector PR.
The text was updated successfully, but these errors were encountered: