OT (partially): about promotion of integers

bearophile bearophileHUGS at lycos.com
Tue Dec 11 22:19:10 PST 2012


David Piepgrass:

> I do want overflow detection, yet I would not use a CheckedInt 
> in D for the same reason I do not usually use one in C++: 
> without compiler support, it is too expensive to detect 
> overflow.

Here I have listed several problems in a library-defined SafeInt, 
but Walter has expressed willingness to introduce intrinsics, to 
give some compiler support, so it's a start of a solution:

http://forum.dlang.org/thread/jhkbsghxjmdrxoxaevzm@forum.dlang.org

Bye,
bearophile


More information about the Digitalmars-d mailing list