check that the bool(expr) is True/False and not expr is True/False. Fixes #14