Is all this Invarient **** er... stuff, premature optimisation?

Tomas Lindquist Olsen tomas at famolsen.dk
Mon Apr 28 10:57:19 PDT 2008


Bill Baxter wrote:

... snip ...

> 
> That stuff like this compiles and seems to work is why we really need to 
> make at least one alternative version of cast.  One would be for 
> relative safe run-of-the-mill casts, like casting float to int, or 
> casting Object to some class (and checking for null),  and the other 
> category would be for dangerous big red flags kind of things like the 
> above.  Using the run-of-the-mill cast in the above situation would not 
> be allowed.

Amen to that !!!



More information about the Digitalmars-d mailing list