[Issue 6023] New: std.random.uniform and std.bigint.BigInt compilation error
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon May 16 22:04:30 PDT 2011
http://d.puremagic.com/issues/show_bug.cgi?id=6023
Summary: std.random.uniform and std.bigint.BigInt compilation
error
Product: D
Version: D2
Platform: Other
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Phobos
AssignedTo: nobody at puremagic.com
ReportedBy: dpx.infinity at gmail.com
--- Comment #0 from Vladimir Matveev <dpx.infinity at gmail.com> 2011-05-16 22:00:21 PDT ---
uniform function from standard library doesn't work correctly with standard
BigInt. There are no indications anywhere that it shouldn't work, so I think it
is a bug.
Code sample:
import std.stdio;
import std.bigint;
import std.random;
void main() {
BigInt x = uniform!"[]"(BigInt(1), BigInt(1000));
writefln("%s", x);
}
Compilation error:
/usr/include/d/dmd/phobos/std/conv.d(322): Error: function
std.bigint.BigInt.toString (void delegate(const(char)[]) sink, string
formatString) const is not callable using argument types ()
/usr/include/d/dmd/phobos/std/conv.d(322): Error: expected 2 function
arguments, not 0
Linux i686, dmd 2.052
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list