[Issue 12248] New: Static arrays have no tail const

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Feb 25 02:31:53 PST 2014


https://d.puremagic.com/issues/show_bug.cgi?id=12248

           Summary: Static arrays have no tail const
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: thecybershadow at gmail.com


--- Comment #0 from Vladimir Panteleev <thecybershadow at gmail.com> 2014-02-25 12:31:51 EET ---
immutable(ubyte)[4] and immutable(ubyte[4]) are the same type. As a
consequence, this won't compile:

alias immutable(ubyte)[40] Hash;
Hash[] hashes;
hashes.sort;

.sort (std.algorithm.sort too) does not compile, as it thinks the array
contents is immutable.

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


More information about the Digitalmars-d-bugs mailing list