www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 1783] New: DMD 1.025 asserts on code with struct, template, and alias

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

           Summary: DMD 1.025 asserts on code with struct, template, and
                    alias
           Product: D
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: WinstonEwert gmail.com


The Code:

module test;

template T()
{
}

struct S
{
    alias T!() data;
}

unittest
{
    S.data.V;
}

The Result:
dmd: mtype.c:4262: virtual Expression* TypeStruct::dotExp(Scope*, Expression*,
Identifier*): Assertion `d' failed.
Aborted (core dumped)

I'm running on Ubuntu, using Tango. I have to pass -unittest to induce the
failure (naturally)


-- 
Jan 11 2008
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1783


matti.niemenmaa+dbugzilla iki.fi changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-invalid-code, ice-on-
                   |                            |valid-code
         OS/Version|Linux                       |All
           Platform|PC                          |All
            Version|unspecified                 |1.025





-------
The unittest block and V aren't necessary, any access to data is enough:

template T() {}

struct S {
    alias T!() data;
}

void main() {
    S.data;
}


-- 
Jan 12 2008
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1783


matti.niemenmaa+dbugzilla iki.fi changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
           Keywords|ice-on-valid-code           |
         Resolution|                            |FIXED





-------
Fixed in DMD 1.026.


-- 
Jan 21 2008
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1783






Fixed dmd 1.026 and 2.010


-- 
Feb 16 2008