home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!know!cass.ma02.bull.com!think.com!spool.mu.edu!sgiblab!munnari.oz.au!sol.deakin.OZ.AU!news.cs.uow.edu.au!cssc-syd.tansu.com.au!pete
- From: pete@cssc-syd.tansu.com.au (Peter Alexander Merel)
- Newsgroups: comp.lang.c++
- Subject: Proposal - enhancement for switch statement.
- Summary: switch could be painlessly beefed up
- Message-ID: <1992Nov15.190830.11622@cssc-syd.tansu.com.au>
- Date: 15 Nov 92 19:08:30 GMT
- Organization: AOTC - CSSC
- Lines: 20
-
- Before I describe what occurred to me, yes folks I know that a switch is not
- as useful as a virtual function.
-
- But what I'd like for a snippet I'm working on at the moment would be for
- switch to use operator== rather than relying on conversion to int, so that
- I could use it to test cases on objects rather than building an industrial
- strength if statement.
-
- And no, the class in question won't go onto int.
-
- This should be language compatible with the C usage, and not too hard
- for translaters to do just by translating into the aforementioned
- industrial if.
-
- Any chance?
-
- --
- Internet: pete@cssc-syd.tansu.com.au UUCP: {uunet,mcvax}!munnari!cssc-syd!pete
- Snail: 1/18-20 Orion Road, Lane Cove NSW 2066 Australia Phone: +61 2 911 3130
- I am a big pond in a small fish.
-