Gennaro Prota writes: > On 08 Dec 2002 15:09:32 +0100, Gabriel Dos Reis > <[EMAIL PROTECTED]> wrote: > > >Gennaro Prota <[EMAIL PROTECTED]> writes: > > > >[...] > > > >| If void* is not a "pointer to an object" then reinterpret_cast<void*> > >| is invalid. Otherwise it just yields an undefined result. > > I should have said "unspecified", sorry. > > > I haven't > >| found a definition of "pointer to object" in the standard; anyhow > >| certainly void is not an object type. > > > >void* is the generic type of "pointer to object." > > Well, as I said I don't find any definition of the expression "pointer > to object" (though, of course, I do know that you can point to an > object through a void*). In any case, do you agree that at least the > result is unspecified?
3.9.2p1 says you may have: "pointers to void or objects or functions ... of a given type" Which implies that a pointer to void is not a pointer to an object of a given type. Also 1.8 says "An object is a region of storage." and "An object has a type (3.9). The term object type refers to the type with which the object is created." so void is not an object type, since you cannot create objects of type void, as it "is an incomplete type that cannot be completed." (3.9.1p9) Anthony -- Anthony Williams Senior Software Engineer, Beran Instruments Ltd. Remove NOSPAM when replying, for timely response. _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost