Skip to content
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 fails with .... #52

Open
Brane2 opened this issue Aug 28, 2018 · 3 comments
Open

make fails with .... #52

Brane2 opened this issue Aug 28, 2018 · 3 comments
Assignees

Comments

@Brane2
Copy link

Brane2 commented Aug 28, 2018

error: ‘*’ in boolean context, suggest ‘&&’ instead [-Werror=int-in-bool-context]

How dead is this project anyway ?

@atamazov
Copy link
Contributor

/cc @bensander @nhaustov

atamazov added a commit that referenced this issue Aug 30, 2018
Multiplication has higher precedence than ternary operator. So `a[0] * numElems` is computed first and used as the 1st operand of `?:`. This seems semantically wrong and also causes the warning (because the 1st operand of `?:` has boolean context). Parntheses around "a[0]" are not actually required, but with these the code looks clearer to me.
atamazov added a commit that referenced this issue Aug 30, 2018
@atamazov atamazov self-assigned this Aug 30, 2018
@atamazov
Copy link
Contributor

@Brane2 Please get latest master and check if it works fine now.

@tschwinge
Copy link

I'm confirming that this issue has been resolved by #53. (I didn't verify the code changes in detail.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants