Bug 3166 – "positive" -> "non-negative" in modulo operator description

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dlang.org
Product
D
Version
D2
Platform
All
OS
All
Creation time
2009-07-12T01:37:00Z
Last change time
2015-06-09T05:15:04Z
Keywords
spec
Assigned to
nobody
Creator
m.helvensteijn

Comments

Comment #0 by m.helvensteijn — 2009-07-12T01:37:06Z
"For integral operands of the % operator, the sign of the result is positive if the operands are positive, otherwise the sign of the result is implementation defined." should read "For integral operands of the % operator, the result is non-negative if the operands are non-negative. Otherwise, the sign of the result is implementation defined."
Comment #1 by smjg — 2009-07-13T14:19:38Z
Does it mean positive in the normal mathematical sense, or having the internal sign bit set to positive?
Comment #2 by smjg — 2009-07-13T14:21:45Z
Silly me, integral operands. Then it's correct except in the case where the right operand is zero.
Comment #3 by bugzilla — 2009-09-03T13:25:49Z
Fixed dmd 1.047 and 2.032