On 4/24/2012 15:25, rusi wrote:
On Apr 24, 4:06 pm, Thomas Rachel<nutznetz-0c1b6768-bfa9-48d5- [email protected]> wrote:Am 24.04.2012 08:02 schrieb rusi:On Apr 23, 9:34 am, Steven D'Aprano<steve [email protected]> wrote:"is" is never ill-defined. "is" always, without exception, returns True if the two operands are the same object, and False if they are not. This is literally the simplest operator in Python.Circular definition: In case you did not notice, 'is' and 'are' are (or is it is?) the same verb.Steven's definition tries not to define the "verb" "is", but it defines the meanung of the *operator* 'is'. He says that 'a is b' iff a and be are *the same objects*. We don't need to define the verb "to be", but the target of the definition is the entity "object" and its identity.Identity, sameness, equality and the verb to be are all about the same concept(s) and their definitions are *intrinsically* circular; see http://plato.stanford.edu/entries/identity/#2 And the seeming simplicity of the circular definitions hide the actual complexity of 'to be' for python: http://docs.python.org/reference/expressions.html#id26 (footnote 7) for math/philosophy: http://www.math.harvard.edu/~mazur/preprints/when_is_one.pdf
What you say is true in general, but not from an operational point of view, especially if we restrict the set of objects whose sameness or identity we want to check:
Let O be a set of tuples (id, data) where
{(id, data1), (id, data2)} subset O => data1 = data2
Def. (id1, data1) and (id2, data2) in O are /the same/ iff id1 = id2.
Now, it's easy to find a bijection between O and the set of Python's
objects which are in memory at any single point in time.
Anyway, you're being unnecessarily pedantic. Kiuhnm -- http://mail.python.org/mailman/listinfo/python-list
