Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!pdn!tscs!tct!chip From: chip@tct.uucp (Chip Salzenberg) Newsgroups: comp.std.c++ Subject: Re: Conversion to |void*| and back: A NO-BRAINER Keywords: Sun, C++ Message-ID: <27A087CA.10DD@tct.uucp> Date: 25 Jan 91 19:32:24 GMT References: <70023@microsoft.UUCP> <27975414.50A8@tct.uucp> <3453@lupine.NCD.COM> Organization: Teltronics/TCT, Sarasota, FL Lines: 24 According to rfg@NCD.COM (Ron Guilmette): >In article <27975414.50A8@tct.uucp> chip@tct.uucp (Chip Salzenberg) writes: >>The "Differences from ANSI C" section of the ARM (18.2) does not >>rescind that guarantee [T* -> void* -> T*]. Therefore, it must >>still hold in C++. > >That's a bad assumption. I have already noted other ommisions from >the list in 18.2. It is not a complete list. I'd like to ask that Ron, or any anyone else with a list of omissions in 1.82, post that list. It should prove interesting. I will conclude my discussion of |void *| thus: Even if if the ARM and/or the ANSI C++ standard do not require that the conversion of a |T *| to |void *| be reversible, *I* require it. This behavior is obviously useful, hard to get wrong, and an integral part of the programming model for which |void*| was invented. Any compiler that fails to provide this behavior will, in my opinion, have earned the label "brain damaged," and wll not live on my hard disk. -- Chip Salzenberg at Teltronics/TCT , "If Usenet exists, then what is its mailing address?" -- me "c/o The Daily Planet, Metropolis." -- Jeff Daiell