www.digitalmars.com         C & C++   DMDScript  

D.gnu - [Issue 1822] New: String slicing in 64-bit gdc causes spurious warnings

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

           Summary: String slicing in 64-bit gdc causes spurious warnings
           Product: DGCC aka GDC
           Version: 0.24
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: glue layer
        AssignedTo: dvdfrdmn users.sf.net
        ReportedBy: david acz.org


The warning does not occur with dmd or 32-bit gdc.

wconv.d:
import std.string;

void main()
{
    auto s = "hello world";
    auto pos = s.find(' ');
    auto hello = s[0 .. pos];
}

$ gdmd -w wconv
warning - wconv.d:7: Error: implicit conversion of expression (pos) of type
long to ulong can cause loss of data


-- 
Feb 08 2008
parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1822


Iain Buclaw <ibuclaw ubuntu.com> changed:

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



Fixed in hg commit 232 / release 0.25.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 01 2010