🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c++
Article #481

Re: Proposed Enhancement to select/case (yes, I know...)

#481
From: Karl Heuer
Date: Wed, 05 Sep 1990 00:33
18 lines
1349 bytes
In article <1420@lupine.NCD.COM> rfg@NCD.COM (Ron Guilmette) writes:
>Regarding "case lists", it seems clear that a simple syntax, i.e.:
>	case FOO,BAR:
>won't work because the separator comma could be parsed as the normal comma
>operator, which would mess up everything.

It would mean that, in the unlikely event that the user *wants* a comma
operator in a case label, he has to parenthesize the expression.  No different
from the existing situation with function arguments or initializer lists,
except that it's a minor incompatibility with the existing language.

>Right.  Given that this feature has already been in g++ for some time,
>you may consider it "prior art".

Is there any particular reason this got added to g++ but not gcc?  It would
seem to be equally useful in both.

Karl W. Z. Heuer (karl@kelp.ima.isc.com or ima!kelp!karl), The Walking Lint
Technical Details
Message-ID: <17629@haddock.ima.isc.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watserv1!watmath!att!ima!haddock!karl
References: <BURLEY.90Aug30030645@world.std.com> <1420@lupine.NCD.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watserv1!watmath!att!ima!haddock!karl
From: karl@haddock.ima.isc.com (Karl Heuer)
Newsgroups: comp.std.c++,comp.std.c
Subject: Re: Proposed Enhancement to select/case (yes, I know...)
Message-ID: <17629@haddock.ima.isc.com>
Date: 5 Sep 90 00:33:22 GMT
References: <BURLEY.90Aug30030645@world.std.com> <1420@lupine.NCD.COM>
Reply-To: karl@kelp.ima.isc.com (Karl Heuer)
Organization: Interactive Systems, Cambridge, MA 02138-5302
Lines: 18