www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 6003] New: BigInt length and conversion properties problems

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6003

           Summary: BigInt length and conversion properties problems
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: nobody puremagic.com
        ReportedBy: paul.d.anderson comcast.net



17:36:06 PDT ---
When I try to compile this code:

import std.bigint;

void main() {
    BigInt big = BigInt(123456);
    int size = big.uintLength();
    int value = big.toInt();
}

I get the following errors:

TestToInt.d(5): Error: no property 'uintLength' for type 'BigInt'
TestToInt.d(5): Error: function expected before (), not __error of type int
TestToInt.d(6): Error: no property 'toInt' for type 'BigInt'
TestToInt.d(6): Error: function expected before (), not __error of type int

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 14 2011
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6003


kennytm gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kennytm gmail.com



Not reproducible.

BTW, '.toInt()' currently returns a 'long'. Shouldn't it be an 'int'?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 14 2011
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6003




22:02:46 PDT ---
Sorry. I was using an old version of the compiler. When I updated the compiler
the file compiled as expected.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 16 2011
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6003


Paul D. Anderson <paul.d.anderson comcast.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 16 2011