Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #79743

Re: id == vs is

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail
From Denis McMahon <denismfmcmahon@gmail.com>
Newsgroups comp.lang.python
Subject Re: id == vs is
Date Mon, 27 Oct 2014 01:47:40 +0000 (UTC)
Organization A noiseless patient Spider
Lines 13
Message-ID <m2k87s$mgr$2@dont-email.me> (permalink)
References <mailman.15206.1414368757.18130.python-list@python.org>
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding 8bit
Injection-Date Mon, 27 Oct 2014 01:47:40 +0000 (UTC)
Injection-Info mx02.eternal-september.org; posting-host="66ffcfa4470a58bcddbdcd1913f98ab4"; logging-data="23067"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+jNeFZL/6gzeIkpCNikcHZu/awyBXaQqc="
User-Agent Pan/0.136 (I'm far too busy being delicious; GIT 926a150 git://git.gnome.org/pan2)
Cancel-Lock sha1:SznDlRDz/huD1XzL3XHdLw2jfss=
Xref csiph.com comp.lang.python:79743

Show key headers only | View raw


On Sun, 26 Oct 2014 17:12:29 -0700, Dan Stromberg wrote:

> Are the following two expressions the same?
> 
> x is y
> 
> Id(x) == id(y)

No, although if "Id" and "id" were the same function, they might be 
equivalent in some cases. 

-- 
Denis McMahon, denismfmcmahon@gmail.com

Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

id == vs is Dan Stromberg <drsalists@gmail.com> - 2014-10-26 17:12 -0700
  Re: id == vs is Denis McMahon <denismfmcmahon@gmail.com> - 2014-10-27 01:47 +0000

csiph-web