Safer casts

Simen Kjaeraas simen.kjaras at gmail.com
Sun May 11 04:57:46 PDT 2008


On Sat, 10 May 2008 07:59:23 +0200, Janice Caron <caron800 at googlemail.com>  
wrote:
> 1) convert or downcast: cast(Foo)bar
> 2) reinterpret: cast!(Foo)bar
> 3) constancy: cast(invariant)bar, cast(!const)bar

For 3), what if I want to cast const(int*) to const(int)*?  
cast(const(int)*)cast(!const)foo?

-- Simen



More information about the Digitalmars-d mailing list