www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 5343] New: dmd crashes by the use of template with -g compiler switch

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

           Summary: dmd crashes by the use of template with -g compiler
                    switch
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Severity: critical
          Priority: P5
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: zan77137 nifty.com


--- Comment #0 from SHOO <zan77137 nifty.com> 2010-12-11 05:07:40 PST ---
This code crashes dmd at trunk(r795):
---------------
module main;
import std.typecons;

struct S(E)
{
    immutable E x; // Workaround: Remove immutable.
}
enum A{a,b,c}          // Workaround: alias int A;
alias Tuple!(A) TA;    // Workaround: Remove this line.
alias S!(A) SA;        // Workaround: Exchange of declaration order with TA.

void main()
{
}
---------------

Result:
$ dmd -g -run main
(dmd crashes!)

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Dec 11 2010
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=5343


Don <clugdbug yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-valid-code
                 CC|                            |clugdbug yahoo.com.au
           Severity|critical                    |regression


--- Comment #1 from Don <clugdbug yahoo.com.au> 2010-12-11 08:40:03 PST ---
Worked on DMD2.050.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Dec 11 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=5343



--- Comment #2 from Don <clugdbug yahoo.com.au> 2010-12-11 21:46:31 PST ---
Reduces test case:

struct Tuple(Specs...)
{    
    Specs[0] field;
}    

struct S(E)
{
    immutable E x; // Workaround: Remove immutable.
}
enum A{a,b,c}          // Workaround: alias int A;
alias Tuple!(A) TA;    // Workaround: Remove this line.
alias S!(A) SA;        // Workaround: Exchange of declaration order with TA.

void main()
{
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Dec 11 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=5343



--- Comment #3 from Don <clugdbug yahoo.com.au> 2010-12-11 21:57:14 PST ---
Seems to have just been fixed in svn 798.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Dec 11 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=5343


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |bugzilla digitalmars.com
         Resolution|                            |FIXED


--- Comment #4 from Walter Bright <bugzilla digitalmars.com> 2010-12-11
23:11:19 PST ---
Right, it doesn't happen with the latest source.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Dec 11 2010
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=5343



--- Comment #5 from SHOO <zan77137 nifty.com> 2010-12-12 02:55:23 PST ---
Because this bug was enbug and this must be fixed by next release, I raised
importance.
Thanks for the swift response.

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