From -9173489066067481626
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,ccb40040597f37a7
X-Google-Attributes: gidf78e5,public
X-Google-ArrivalTime: 2003-03-11 09:15:01 PST
Path: archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-06!sn-xit-09!supernews.com!news.maxwell.syr.edu!news.alt.net!comp-std-cpp-robomod!not-for-mail
From: Hyman Rosen <hyrosen@mail.com>
Newsgroups: comp.std.c++
Subject: Re: Extending enums (was Re: Forward declaration of enum)
Date: Tue, 11 Mar 2003 11:14:04 CST
Organization: Altopia Corp. - Usenet Access - http://www.altopia.com
Lines: 17
Approved: Fergus Henderson <fjh@cs.mu.oz.au>, moderator of comp.std.c++
Message-ID: <HFeba.21313$gi1.5997@nwrdny02.gnilink.net>
References: <PNE21WKuwwiy-pn2-2YXh1K9td7dn@zamboni.stiscan.com> <memo.20030310212425.56925C@brangdon.madasafish.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Return-Path: <devnull@stump.algebra.com>
X-Authentication-Warning: mulga.cs.mu.OZ.AU: fjh set sender to devnull@stump.algebra.com using -f
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
Delivered-To: std-c++@ncar.ucar.edu
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4a) Gecko/20030302
X-Accept-Language: en-us, en
X-Complaints-To: abuse@verizon.net
X-Trace: nwrdny02.gnilink.net 1047361255 162.83.249.210 (Tue, 11 Mar 2003 00:40:55 EST)
NNTP-Posting-Date: Tue, 11 Mar 2003 00:40:55 EST
X-BadReturnPath: news@nwrdny02 rewritten as hyrosen@mail.com
  using "From" header
X-Spam-Status: No, hits=-1.3 required=10.0
	tests=MISSING_HEADERS,QUOTED_EMAIL_TEXT,REFERENCES,
	      SPAM_PHRASE_01_02,USER_AGENT,USER_AGENT_MOZILLA_UA,
	      X_ACCEPT_LANG,X_AUTH_WARNING
	version=2.43
X-Spam-Level: 
Xref: archiver1.google.com comp.std.c++:18255

Dave Harris wrote:
> If we have both kinds of overloading, we don't really know where to start.
> What you are suggesting here is a pretty major change, because of this.

Ada has this, as part of its general ability to overload by return type.
In fact, in Ada enumeration literals are considered to be parameterless
functions which return their enumerator. This makes them work in the same
way as other overloaded functions. Even when doing overloading by return
types, overload resolution isn't that complicated to implement. And the
problem was solved decdes ago.

---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.jamesd.demon.co.uk/csc/faq.html                       ]



