🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #731

Re: commom malloc/free practice breaks standard - author strikes back

#731
From: Rahul Dhesi
Date: Wed, 18 Oct 1989 06:09
20 lines
1232 bytes
>> ...any valid pointer can be converted to a pointer that
>> has less strict alignment and back, so that the result compares equal
>> to the original pointer,
> 
>I can only find this rule for OBJ* -> void* -> OBJ* and OBJ* -> char* -> OBJ*.
>Am I missing a section?

This may the key point.

I, like many others, rely on the gurus in comp.lang.c for much valuable
information.  Can somebody quote chapter and verse to show that the
standard does require the series of casts

     void * ->  OBJ *  ->  void *

to yield the original pointer?

Rahul Dhesi <dhesi%cirrusl@oliveb.ATC.olivetti.com>
UUCP:  oliveb!cirrusl!dhesi
Do not use From: address for reply if it contains "sun".
Technical Details
Message-ID: <992@cirrusl.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!gem.mps.ohio-state.edu!apple!bridge2!3comvax!tymix!cirrusl!sun505!dhesi
References: <1989Oct16.111059.3840@anucsd.oz>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!gem.mps.ohio-state.edu!apple!bridge2!3comvax!tymix!cirrusl!sun505!dhesi
From: dhesi@sun505.UUCP (Rahul Dhesi)
Newsgroups: comp.std.c,comp.lang.c
Subject: Re: commom malloc/free practice breaks standard - author strikes back
Message-ID: <992@cirrusl.UUCP>
Date: 18 Oct 89 06:09:28 GMT
References: <1989Oct16.111059.3840@anucsd.oz>
Sender: news@cirrusl.UUCP
Reply-To: dhesi%cirrusl@oliveb.ATC.olivetti.com (Rahul Dhesi)
Organization: Cirrus Logic Inc.
Lines: 20