Bug 4171 – std.random.uniform does not work for a range of characters
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
Other
OS
Linux
Creation time
2010-05-10T10:45:00Z
Last change time
2015-06-09T05:14:41Z
Assigned to
andrei
Creator
pelle.mansson
Comments
Comment #0 by pelle.mansson — 2010-05-10T10:45:34Z
import std.random;
void main() {
uniform('a', 'z');
}
results in
phobos/std/random.d(659): Error: cannot implicitly convert expression (cast(int)b - 1) of type int to char