DescriptionMake one-bit bit fields unsigned.
VC++ 2015 gives the following warning when compiling jsoncpp:
json_value.cpp(480): warning C4463: overflow; assigning 1 to bit-field
that can only hold values from -1 to 0
This warning is correct. A signed one-bit value can only hold 0 and -1.
This is true on gcc and clang, but only VC++ 2015 warns about it.
The code works because the stored value is never compared against 1 or
printed, but the current code is likely to cause surprises or bugs in the
future and should be fixed.
R=cpu@chromium.org
BUG=440500
Committed: https://crrev.com/707c3acd012287f3b4897bedaf57c60fbd4044bd
Cr-Commit-Position: refs/heads/master@{#325330}
Patch Set 1 #
Total comments: 1
Patch Set 2 : Adding patch file for changes to value.h #Patch Set 3 : Update patch file #Patch Set 4 : Updating README.chromium and putting all changes in patch file. #
Messages
Total messages: 23 (7 generated)
|