[OT] The Usual Arithmetic Confusions
Walter Bright
newshound2 at digitalmars.com
Thu Feb 3 01:05:15 UTC 2022
On 2/2/2022 3:37 PM, Adam Ruppe wrote:
> D's behavior is worse than C's in actual use.
How?
> The value range propagation only works inside single expressions and is too
> conservative to help much in real code.
I find it works well. For example,
int i;
byte b = i & 0xFF;
passes without complaint with VRP. As does:
ubyte a, b, c;
a = b | c;
More information about the Digitalmars-d
mailing list