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

Error C4296: '<': expression is always false #981

Closed
brandonpon96 opened this issue Jun 24, 2019 · 1 comment · Fixed by #982
Closed

Error C4296: '<': expression is always false #981

brandonpon96 opened this issue Jun 24, 2019 · 1 comment · Fixed by #982
Labels

Comments

@brandonpon96
Copy link

Building bond version 8.0.1 using vc14 version compiler produces the error shown below:

1>d:\dbs\cx\azma\bond.cpp.oncorext.8.0.1\lib\native\inc\bond\core\protocol.h(200): error C4296: '<': expression is always false

Please advise, thanks.

@chwarr chwarr added the bug label Jun 25, 2019
chwarr added a commit to chwarr/bond that referenced this issue Jun 25, 2019
Adds a spot suppression for MSVC warning C4296: '<' : expression is
always false. MSVC's "always constant" warnings tend to trigger on
tempalted code based on the specific instantiation's values,
disregarding that the template itself it not always constant.

Fixes microsoft#981
chwarr added a commit to chwarr/bond that referenced this issue Jun 25, 2019
Adds a spot suppression for MSVC warning C4296: '<' : expression is
always false. MSVC's "always constant" warnings tend to trigger on
tempalted code based on the specific instantiation's values,
disregarding that the template itself it not always constant.

Fixes microsoft#981
@chwarr
Copy link
Member

chwarr commented Jun 25, 2019

I've coded a fix for this. It's ready for review.

You may run into more instances of these, depending on exactly how you exercise Bond's templates. If you do, feel free to submit a PR with a similar fix directly.

chwarr added a commit that referenced this issue Sep 12, 2019
Adds a spot suppression for MSVC warning C4296: '<' : expression is
always false. MSVC's "always constant" warnings tend to trigger on
tempalted code based on the specific instantiation's values,
disregarding that the template itself it not always constant.

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

Successfully merging a pull request may close this issue.

2 participants