]> git.lyx.org Git - features.git/commit
Make iparserdocstream more like std::istream
authorGeorg Baum <baum@lyx.org>
Tue, 22 Apr 2014 20:03:31 +0000 (22:03 +0200)
committerGeorg Baum <baum@lyx.org>
Tue, 22 Apr 2014 20:03:31 +0000 (22:03 +0200)
commit0c0e16c61cb01555277c8605e970ace1f4fdce1b
tree55c98077809b200f0e8a2bcbd33356e40faaac33
parente7b16d961f5e4fc1a8bc888917702494e405eba4
Make iparserdocstream more like std::istream

In C++98 std::istream does not use an operator bool(), but an operator
void*() instead, which prevents some unwanted conversions (this is one
possible implementation of the safe bool idiom).
In C++11 std::istream uses explicit operator bool, which prevents the unwanted
conversions using a new language feature.

This change does not have any effect on correct code, but prevents some
mistakes.
src/tex2lyx/Parser.h