[Issue 9400] New: initializing enum T[n] with a single value changes its type to T

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Jan 26 01:41:04 PST 2013


http://d.puremagic.com/issues/show_bug.cgi?id=9400

           Summary: initializing enum T[n] with a single value changes its
                    type to T
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: nilsbossung at googlemail.com


--- Comment #0 from Nils <nilsbossung at googlemail.com> 2013-01-26 01:41:03 PST ---
---
cat > test.d <<CODE
enum int[3] x = 42;
static assert(is(typeof(x) == int[3]));
CODE
dmd -c test.d
---
test.d(2): Error: static assert  (is(int == int[3u])) is false
---

-- 
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