bitwise on boolean
This commit is contained in:
parent
f68024543f
commit
7fc409eecc
1 changed files with 2 additions and 2 deletions
|
|
@ -784,8 +784,8 @@ inline std::istream& ParseNormalFloat(std::istream& is, bool negate_value,
|
|||
if (val.isInfinity()) {
|
||||
// Fail the parse. Emulate standard behaviour by setting the value to
|
||||
// the closest normal value, and set the fail bit on the stream.
|
||||
value.set_value((value.isNegative() | negate_value) ? T::lowest()
|
||||
: T::max());
|
||||
value.set_value((value.isNegative() || negate_value) ? T::lowest()
|
||||
: T::max());
|
||||
is.setstate(std::ios_base::failbit);
|
||||
}
|
||||
return is;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue