The use of an operand of type bool with the ++ operator is deprecated (see [expr.pre.incr] and [expr.post.incr]).