On 08/06/14 11:02, monarch_dodra via Digitalmars-d-learn wrote:
Why would we ban uniform!T from accepting dchar? I see no reason for that.Let's just fix the bug by tweaking the internal check.
Yea, I came to the same conclusion while working on it. :-)The solution I have is (i) in uniform!"[]" check that !is(ResultType == dchar) before checking the condition for calling uniform!ResultType, and (ii) inside uniform!T, place
static if (is(T == dchar)) { return uniform!"[]"(T.min, T.max, rng); }