Bug 5797 – std.math.approxEqual should accept const arguments
Status
RESOLVED
Resolution
WORKSFORME
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
Other
OS
All
Creation time
2011-03-30T12:52:00Z
Last change time
2013-01-22T19:17:27Z
Assigned to
nobody
Creator
magnus
Comments
Comment #0 by magnus — 2011-03-30T12:52:52Z
At present, approxEqual doesn't accept const arguments. The following fails for me, for example (DMD 2.052, OS X):
import std.math;
void main() {
const uint[] a = [1, 2, 3];
approxEqual(a, a);
}
The same naturally holds for any other similar function in Phobos that *can* take const arguments (i.e., they probably should), I assume?