Boost logo

Boost Users :

Subject: Re: [Boost-users] boost::bind and Motif
From: Richard (legalize+jeeves_at_[hidden])
Date: 2012-05-14 17:37:18


[Please do not mail me a copy of your followup]

boost-users_at_[hidden] spake the secret code
<20120505152720.GD12377_at_[hidden]> thusly:

>On Fri, May 04, 2012 at 05:04:00PM +0000, Richard wrote:
>> static_cast<T*>(p) where p is void* works perfectly fine. It is
>> always valid to cast a void* to any other type and that's what
>> static_cast<> does -- performs the cast when it is allowed by the
>> rules of the language.
>
>Might it be C that allows arbitrary casts, but only guarantees proper
>semantics if the type is the correct one?

static_cast<> is purely a C++ construct and is not present in C.

-- 
"The Direct3D Graphics Pipeline" -- DirectX 9 version available for download
 <http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>
      Legalize Adulthood! <http://legalizeadulthood.wordpress.com>

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net