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
x[0]
Describe the bug
Indexing (x[0]) should be disallowed on parametric signedness values, but no error is thrown.
Consider this code using parametric signedness:
fn is_even<S: bool, N: u32>(x: xN[S][N]) -> bool { x[0] == u1:0 }` let e = is_even(1:s8);
error: xN[is_signed=1] vs uN[1]: Could not deduce type for binary operation '=='
xN[is_signed=1] vs uN[1]: Could not deduce type for binary operation '=='
To Reproduce
Create a DSLX file with code like the above and try to build it as a library. Build before using is_even then try to build after using it.
is_even
Expected behavior
There should be an error like this: sN[8] Value to index is not an array.
sN[8] Value to index is not an array.
The text was updated successfully, but these errors were encountered:
cdleary
Successfully merging a pull request may close this issue.
Describe the bug
Indexing (
x[0]
) should be disallowed on parametric signedness values, but no error is thrown.Consider this code using parametric signedness:
error:
xN[is_signed=1] vs uN[1]: Could not deduce type for binary operation '=='
To Reproduce
Create a DSLX file with code like the above and try to build it as a library. Build before using
is_even
then try to build after using it.Expected behavior
There should be an error like this:
sN[8] Value to index is not an array.
The text was updated successfully, but these errors were encountered: