www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 11063] New: __MODULE__ in mixin crash dmd

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

           Summary: __MODULE__ in mixin crash dmd
           Product: D
           Version: D2
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: regression
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: code.viator gmail.com



file mixinmodulefail.d
[code]
import std.stdio;
void main() { mixin( "writeln( __MODULE__ );" ); }
[/code]

$ dmd mixinmodulefail.d 
Segmentation fault (core dumped)

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 18 2013
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=11063




$ uname -a

x86_64 x86_64 GNU/Linux

$ dmd -v
DMD64 D Compiler v2.063.2

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 18 2013
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=11063


safety0ff.bugz gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |safety0ff.bugz gmail.com



__MODULE__ alone causes a segfault here:

void main() { ( __MODULE__); }

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 18 2013
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=11063


hsteoh quickfur.ath.cx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |hsteoh quickfur.ath.cx
         Resolution|                            |WORKSFORME



Works on DMD git HEAD (2f59d8656a6b97e0bb285d6b5bbd5c9d5f69b9ad). I'll add a
test case to DMD to prevent future regression.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 18 2013
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=11063




https://github.com/D-Programming-Language/dmd/pull/2571

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Sep 18 2013
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=11063


Andrej Mitrovic <andrej.mitrovich gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |andrej.mitrovich gmail.com
         Resolution|WORKSFORME                  |DUPLICATE



09:09:05 PDT ---
*** This issue has been marked as a duplicate of issue 10695 ***

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