Minor extension to cast syntax

Robert Fraser fraserofthenight at gmail.com
Wed Oct 31 13:12:41 PDT 2007


Mike Wrote:

> cast(int)(cast(float)(width - length * position) * scaling);
> cast(int, cast(float, width - length * position) * scaling);

First one looks cleaner to me, but maybe that's just because I'm used to it. I'm not against adding the syntax, but I'd never use it.



More information about the Digitalmars-d mailing list