On Thu, Apr 26, 2012 at 3:48 PM, John Nagle <na...@animats.com> wrote: > This assumes that everything is, internally, an object. In CPython, > that's the case, because Python is a naive interpreter and everything, > including numbers, is "boxed". That's not true of PyPy or Shed Skin. > So does "is" have to force the creation of a temporary boxed object?
Interesting point. Presumably the only types that can be unboxed are those for which identity vs equality is pretty much immaterial, so the question won't really matter. I'd be inclined to either have it return False if either/both is unboxed, or else return True if both are equal unboxed numbers, whichever is the most convenient to implement. My opinion doesn't matter-- My opinion doesn't matter-- My opinion doesn't matter, matter, matter, matter, matter! (WS Gilbert, "Ruddigore") ChrisA -- http://mail.python.org/mailman/listinfo/python-list