[issue21422] int << 0: return the number unmodified

Francisco Martín Brugué report at bugs.python.org
Mon May 12 20:17:45 CEST 2014

Francisco Martín Brugué added the comment:

sorry if it's trivial but shouldn't we add a 'shifted_true' test
some were to make sure that this behavior change gets noticed next time?

def test_shifted_true(self):
    self.assertEqual(True << 0, 1)
    self.assertEqual(True << 1, 2)

nosy: +francismb

Python tracker <report at bugs.python.org>

More information about the Python-bugs-list mailing list