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

Fix '-Wbitwise-instead-of-logical' in fbpcf/engine/SecretShareEngine.cpp #465

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

r-barnes
Copy link
Contributor

@r-barnes r-barnes commented Jan 7, 2023

Summary:
LLVM-15 requires that we differentiate between && and & as well as || and |. Logical operations are done with && and || and bitwise operations are done with & and |. Confusing the two makes code harder to read and may lead to subtle bugs.

  • If you approve of this diff, please use the "Accept & Ship" button :-)

Reviewed By: dmm-fb

Differential Revision: D42374505

Summary:
LLVM-15 requires that we differentiate between `&&` and `&` as well as `||` and `|`. Logical operations are done with `&&` and `||` and bitwise operations are done with `&` and `|`. Confusing the two makes code harder to read and may lead to subtle bugs.

 - If you approve of this diff, please use the "Accept & Ship" button :-)

Reviewed By: dmm-fb

Differential Revision: D42374505

fbshipit-source-id: 7d4a3d7a70b0acf5603ece36b53ea556d695303f
@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported labels Jan 7, 2023
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D42374505

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants