473,568 Members | 2,907 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

<> and DeprecationWarn ing

Hi,

the <> inequality test operator has been deprecated for a loooooong time.

Is there a reason that it doesn't trigger a DeprecationWarn ing?

$ python2.2 -Wall -c "print 0 <> 0"
0
$ python2.3 -Wall -c "print 0 <> 0"
False

Or is the only reason that is has never been implemented?
IANACS, but this doesn't seem very complicated to implement to me...

yours,
Gerrit.

--
196. If a man put out the eye of another man, his eye shall be put out.
-- 1780 BC, Hammurabi, Code of Law
--
Asperger Syndroom - een persoonlijke benadering:
http://people.nl.linux.org/~gerrit/
Kom in verzet tegen dit kabinet:
http://www.sp.nl/

Jul 18 '05
77 5219

Gerrit> Is there a difference between obsolescent, obsolete and
Gerrit> deprecated?

Yes, but it's sort of like the Eskimos ("arctic native americans"?) having
several different words for "snow". The subtle differences are lost on
people who've never seen snow. ;-)

Dictionary.com (via Google) shows these relevant (and related) definitions:

obsolescent - Being in the process of passing out of use or usefulness;
becoming obsolete. (Also, in a biological sense "gradually
disappearing".

obsolete - No longer in use or outmoded in design, style, or
construction (two definitions).

deprecate - To express disapproval of; deplore, or to belittle;
depreciate.

Of these, deprecate's computer meaning seems to be quite far from it's
using in non-computer English. Further down the page, it shows a couple
more-to-our-needs definitions of deprecate:

Said of a program or feature that is considered obsolescent and in the
process of being phased out, usually in favour of a specified
replacement. Deprecated features can, unfortunately, linger on for many
years. This term appears with distressing frequency in standards
documents when the committees writing the documents realise that large
amounts of extant (and presumably happily working) code depend on the
feature(s) that have passed out of favour. (from The Free On-line
Dictionary of Computing)

Said of a program or feature that is considered obsolescent and in the
process of being phased out, usually in favor of a specified
replacement. Deprecated features can, unfortunately, linger on for many
years. This term appears with distressing frequency in standards
documents when the committees writing the documents realize that large
amounts of extant (and presumably happily working) code depend on the
feature(s) that have passed out of favor. (from the Jargon File)

In the context of discussions about '<>', I think "obsolecent " and
"deprecated " mean roughly the same thing, though "deprecated " suggests a
more formal notion. In Python, if a language feature is deprecated, there
is generally a specified sunset period. As Barry suggests, even though '<>'
is obsolescent, it's likely to be around for a long while.

One might speculate that as 3.0 nears, the last release or two in the 2.x
line might provide a way for programmers to run their code with a __future__
import something like

from __future__ import deprecated_in_3

or if the effect is desired more globally, to specify a --three or -3 flag
on the interpreter command line.

Skip

Jul 18 '05 #11

"Skip Montanaro" <sk**@pobox.com > wrote in message
news:ma******** *************** **************@ python.org...
In the context of discussions about '<>', I think "obsolecent " and
"deprecated " mean roughly the same thing, though "deprecated " suggests a
more formal notion. In Python, if a language feature is deprecated, there
is generally a specified sunset period. As Barry suggests, even though '<>'
is obsolescent, it's likely to be around for a long while.


In Fortran, it's the other way round. Heinous constructs like computed
GOTOs are obsolesecent in Fortran 90 and removed in Fortran 95,
whilst COMMON blocks are merely deprecated.

As you suggest, the subtle distinctions that may exist probably have to give
way to locally accepted usage.
Jul 18 '05 #12
On Mon, 2003-10-20 at 13:59, Erik Max Francis wrote:
Now comes the argument over whether _obsolescent_ and _deprecated_ are
synonymous in this context :-).


Technically, I'd say they aren't because <> constructs don't generate
deprecation warnings.

-Barry
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iQCVAwUAP5Qve3E jvBPtnXfVAQKqqQ P9F8Cssp43inCQT 5SG8FKKjBrZQ6ko dJZX
D0MTBEtFR/BMnXo5ZRSaTgd16 jwKc8c60ZNC48WT Iij9pmQB0Qvi/JSHwIrJcI1r
wjfh/B3O6BQXHtiqtJty Mhgt5kdYtJgDo5U KE2TOHjppu3/5zPSmtfDROm6nEL BG
wyAtPIi2EsE=
=LwG0
-----END PGP SIGNATURE-----

Jul 18 '05 #13
Barry Warsaw <ba***@python.o rg> wrote previously:
|I'm confident there's no way <> can be officially deprecated

Heck, we true believers should be more ambitious: Deprecate the
heretical '!=' pseudo-assignment!

Jul 18 '05 #14
Barry Warsaw wrote:
On Mon, 2003-10-20 at 13:59, Erik Max Francis wrote:
Now comes the argument over whether _obsolescent_ and _deprecated_ are
synonymous in this context :-).


Technically, I'd say they aren't because <> constructs don't generate
deprecation warnings.


So let's introduce obsolescence warnings...!-)
Alex

Jul 18 '05 #15
Barry Warsaw wrote:
Technically, I'd say they aren't because <> constructs don't generate
deprecation warnings.


I was being semifacetious. In my experience, usually they are used in
different ways. Deprecation is a stricter form of obsolescence.
Obsolescent just means that the feature should no longer be used, since
it has been replaced by superior forms. Deprecated means that an
obsolescent form has actually been marked for future removal. A
deprecated feature can be removed, an obsolescent feature can become
deprecated.

--
Erik Max Francis && ma*@alcyone.com && http://www.alcyone.com/max/
__ San Jose, CA, USA && 37 20 N 121 53 W && &tSftDotIotE
/ \ If you're not besides me / I'll do your best / To carry on
\__/ India Arie
Jul 18 '05 #16
On Mon, 2003-10-20 at 14:45, Lulu of the Lotus-Eaters wrote:
Barry Warsaw <ba***@python.o rg> wrote previously:
|I'm confident there's no way <> can be officially deprecated

Heck, we true believers should be more ambitious: Deprecate the
heretical '!=' pseudo-assignment!


Now there's a bold and enlightened Pythoneer! Three cheers!

-Barry
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iQCVAwUAP5Q6BnE jvBPtnXfVAQIW3Q P/YfcIce7L8JJ/oWwjbY49wTjUHd2 j6lGm
zTwhC3rUs7ISpCk Ztt0O0Yj+vOTPmL IgAZopbRu/VGxJo5JMOmigWxx I+f9PEliI
H0Hs/Ly9GDcXntyF71w9 rAHK0oOiSgCZttd HeybADcPx/x0bTw+kOD1Q96rh RejT
EXAAk/uAg3Y=
=9DHp
-----END PGP SIGNATURE-----

Jul 18 '05 #17
On Mon, 2003-10-20 at 15:09, Alex Martelli wrote:
Barry Warsaw wrote:
On Mon, 2003-10-20 at 13:59, Erik Max Francis wrote:
Now comes the argument over whether _obsolescent_ and _deprecated_ are
synonymous in this context :-).


Technically, I'd say they aren't because <> constructs don't generate
deprecation warnings.


So let's introduce obsolescence warnings...!-)


class
SilentPendingMi sguidedObsolesc enceSuggestion( PendingDeprecat ionWarning):
pass

:)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iQCVAwUAP5Q6X3E jvBPtnXfVAQJ9mA P/f51+7+eVX3gKDWV ifqI3sDM4MNv8Y3 45
Tk0kvPsqKEYpM60 U2DrkVmpVCinkuE QnP+9nBbNye7M/30VRt8VGqbBpNjd NCvSu
mJPjt51kjd4cQae jSHY7/3Kr0Fn8SXHVXvKR cXegadX27ZuFQj2 sonsIuRtfWnTm
yk36wyRta4M=
=KW/x
-----END PGP SIGNATURE-----

Jul 18 '05 #18
Dnia Mon, 20 Oct 2003 11:44:17 -0400, Barry Warsaw napisa³(a):
> the <> inequality test operator has been deprecated for a loooooong tim=

e.
Who said that?


Well, Guido doesn't like it, but Just does, so that cancels out the Van
Rossum vote <wink>. I'm on Just's side though, but this is about as
religious an argument as Pythoneers get. I'm confident there's no way
<> can be officially deprecated as long as Python 2.x is alive.


Is there any outline to mark it as deprecated in docs and the code
somewhere between 2.x and 3.0? I know that this is _distant future_,
but we can think about it and maybe vote. I'm on Guido's side not
because I don't like it, but because I think that Python doesn't need
two 'not equal' operators. It reminds me about ruby and its methods
for built-in classes which are doubled in some cases. This is nothing more
than a pollution.
--
[ Wojtek Walczak - gminick (at) underground.org .pl ]
[ <http://gminick.linuxse curity.pl/> ]
[ "...rozmait e zwroty, matowe od patyny dawnosci." ]

Jul 18 '05 #19
Skip Montanaro fed this fish to the penguins on Monday 20 October 2003
10:08 am:

Yes, but it's sort of like the Eskimos ("arctic native americans"?)
{Continuing the previous response -- I don't know of any way to
retrieve for editing a message that has been "sent" from KNode; unlike
Agent's outbox}

I think my dislike for != is that Python /does/ have a NOT keyword,
unlike C, where the ! alone is "not".

So I guess that I'm saying I'd have preferred to see

x not == y
(though this is where folks complaining about == vs = get the advantage)
vs
x != y

Though I feel comfortable with

x <> y
(it's faster to type, among other things -- left-shift, rock the right
hand over the ., keys -- vs right-shift, 1, move from right-shift to =)

-- =============== =============== =============== =============== == <
wl*****@ix.netc om.com | Wulfraed Dennis Lee Bieber KD6MOG <
wu******@dm.net | Bestiaria Support Staff <
=============== =============== =============== =============== == <
Bestiaria Home Page: http://www.beastie.dm.net/ <
Home Page: http://www.dm.net/~wulfraed/ <


Jul 18 '05 #20

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
3197
by: Eshrath | last post by:
Hi, What I am trying to do: ======================= I need to form a table in html using the xsl but the table that is formed is quite long and cannot be viewed in our application. So we are writing one object in C# which will take the entire table tag contents and renders. Ie., we need to pass "<table>………… <thead>……</thead>. <tr>.<td>...
2
10548
by: Donald Firesmith | last post by:
I am having trouble having Google Adsense code stored in XSL converted properly into HTML. The <> unfortunately become &lt; and &gt; and then no longer work. XSL code is: <script type="text/javascript"> <!]> </script> <script type="text/javascript"
1
5433
by: RJN | last post by:
Hi I'm using XMLTextReader to parse the contents of XML. I have issues when the xml content itself has some special characters like & ,> etc. <CompanyName>Johnson & Jhonson</CompanyName> <EmployeeStrength>> 1000</EmployeeStrength> When I do a Xmltextreader.read() and then check the contents of the xml node by...
1
1651
by: JezB | last post by:
I'm binding a DataGrid web-control to data fetched from a database. However some of my data fields contain text that is within <...> characters - I notice that everything between the <> is suppressed in the grid. How can I resolve this ?
1
2687
by: RJN | last post by:
Hi I'm using XMLTextReader to parse the contents of XML. I have issues when the xml content itself has some special characters like & ,> etc. <CompanyName>Johnson & Jhonson</CompanyName> <EmployeeStrength>> 1000</EmployeeStrength> When I do a Xmltextreader.read() and then check the contents of the xml node by...
1
2293
by: mike | last post by:
I've got some code like this: gametype_id = Request.Form("gametype_id") response.write "<br>gametype_id from form>" & gametype_id & "<" response.write "<br>gametype_id from database>" & rs_state("gametype_id") & "<" if gametype_id = "" then gametype_id = rs_state("gametype_id") 'could be NULL and make
3
3357
by: ajay2552 | last post by:
Hi, I have a query. All html tags start with < and end with >. Suppose i want to display either '<' or '>' or say some text like '<Company>' in html how do i do it? One method is to use &lt, &gt ,&ltCompany&gt to display '<', '>' and '<Company>' respectively. But is there any freeware code available which could implement the above...
14
3127
by: Michael | last post by:
Since the include function is called from within a PHP script, why does the included file have to identify itself as a PHP again by enclosing its code in <?php... <?> One would assume that the PHP interpreter works like any other, that is, it first expands all the include files, and then parses the resulting text. Can anyone help with an...
3
1766
by: Josh Valino | last post by:
Hi, I have a client that has our product and in one of the aspx files, there is code like this: <%= SomePublicProperty %> where the public property returns a string. In the test environment at the client's site, the value is being REsponse.Written as expected. In their production environment, it is not. No errors or anything. It's...
0
7693
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7916
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7660
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
1
5498
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5217
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3651
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3631
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2101
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1207
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.