Suppose we have following C++ code:
auto found = std::lower_bound(container.begin(), container.end(), val);
return found != container.begin() && found != container.end();
How can I tell from a debugger which operand of &&
operator was false
-- a left one or a right one, or actually both?
I wish I could use print
, but for some reason it fails:
(gdb) p found != container.end()
Cannot resolve function operator!= to any overloaded instance