home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.std.c++
- Path: sparky!uunet!munnari.oz.au!metro!extro.ucc.su.OZ.AU!maxtal
- From: maxtal@extro.ucc.su.OZ.AU (John MAX Skaller)
- Subject: Re: Zero-length structures and pointer comparisons
- Message-ID: <1992Dec19.203242.21236@ucc.su.OZ.AU>
- Sender: news@ucc.su.OZ.AU
- Nntp-Posting-Host: extro.ucc.su.oz.au
- Organization: MAXTAL P/L C/- University Computing Centre, Sydney
- References: <1992Dec07.222242.18703@microsoft.com> <1992Dec8.103218.27689@lth.se> <KANZE.92Dec10165804@slsvdnt.us-es.sel.de>
- Date: Sat, 19 Dec 1992 20:32:42 GMT
- Lines: 31
-
- In article <KANZE.92Dec10165804@slsvdnt.us-es.sel.de> kanze@us-es.sel.de (James Kanze) writes:
- >|> alternative is of course to dismiss the idea as not worth the trouble.
- >
- >I favor the latter case.
-
- I think that MANY collections will be collections of pointers.
- MANY of these types of collections will rely on there existing some
- total ordering. SOME of these will also require some that
-
- p==q <==> ptrcmpeq(p,q)==0
-
- where I used ptrcmpeq to denote the version of ptrcmp that supports
- the above identity, whereas plain ptrcmp need not, and might
- always return 0.
-
- (A third version, ptrcmppo might also preserve partial ordering of <.)
-
- Therefore I think it is worth persuing the issue,
- especially as the 'ptrcmp' idea is an extension to the library,
- and thus might be acceptable to the committee, whereas changing
- the status of < might not.
-
- In fact I believe the status of == must be downgraded,
- even at the expense of C compataibility, and that will be a tough
- enough battle as it is.
-
- --
- ;----------------------------------------------------------------------
- JOHN (MAX) SKALLER, maxtal@extro.ucc.su.oz.au
- Maxtal Pty Ltd, 6 MacKay St ASHFIELD, NSW 2131, AUSTRALIA
- ;--------------- SCIENTIFIC AND ENGINEERING SOFTWARE ------------------
-