auto a = PData( [.1,.2,.3] ); assert( eq( a.as!(double[]), [.1,.2,.3] ) ); a = "hello"; assert( eq( a.as!string, "hello" ) );
See Implementation