Why D is not popular enough?

Marco Leise via Digitalmars-d digitalmars-d at puremagic.com
Fri Aug 19 08:01:58 PDT 2016


Am Fri, 19 Aug 2016 13:36:05 +0000
schrieb Adam D. Ruppe <destructionator at gmail.com>:

> On Friday, 19 August 2016 at 08:31:39 UTC, Marco Leise wrote:
> > If we hypothetically switched to a ubyte+ubyte=ubyte semantic, 
> > then code like this breaks silently:  
> 
> However, if it took the entire statement into account, it could 
> handle that... by my rule, it would see there's a float in there 
> and thus automatically cast a and b to float before doing 
> anything.

Float math is slow compared to integer math and precision loss
occurs when this rule is also applied to (u)int and (u)long
with only the deprecated (as per amd64 spec) real type being
large enough for 64-bit integers.

-- 
Marco



More information about the Digitalmars-d mailing list