Boost logo

Boost :

Subject: Re: [boost] [wave][function] Suppressing gcc-4.4.1 warnings
From: Peter Dimov (pdimov_at_[hidden])
Date: 2009-11-07 07:08:51

Jeffrey Bosboom wrote:
> Gottlob Frege wrote:
>> 2. What is left for reinterpret_cast to do? casting to/from ints to
>> pointers, etc? (useful in lockfree programming, etc). Which would
>> be better accomplished with unions I suppose.
> Casting from pointer-to-function to pointer-to-object types (e.g.,
> void*) is conditionally-supported for reinterpret_cast, and there's a
> guarantee that if both directions are supported, you can call through
> the pointer after casting it back to its original type. static_cast
> can't do this. (There's also the question of why you'd do this at all --

To cast the return value of dlsym to the proper type.

Boost list run by bdawes at, gregod at, cpdaniel at, john at