www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 1534] New: Can't mix in a case statement.

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

           Summary: Can't mix in a case statement.
           Product: D
           Version: 1.021
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: aziz.kerim gmail.com


switch(1)
{
mixin("case 0:{}");
case 1:
case 2:
default:
}

Getting this error many times until the compiler aborts aborts:
bla.d(...): found 'EOF' instead of statement


-- 
Sep 26 2007
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1534


thomas-dloop kuehne.cn changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         OS/Version|Linux                       |All
           Platform|PC                          |All





Added to DStress as
http://dstress.kuehne.cn/run/m/mixin_37_A.d
http://dstress.kuehne.cn/run/m/mixin_37_B.d


-- 
Sep 30 2007
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1534


Rainer Schuetze <r.sagitario gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch
                 CC|                            |r.sagitario gmx.de



PDT ---
This also happens for DMD 2.032 and before, but here is a patch against that
version:

Index: parse.c
===================================================================
--- parse.c    (revision 196)
+++ parse.c    (working copy)
   -3720,6 +3720,7   
         statements = new Statements();
         while (token.value != TOKcase &&
            token.value != TOKdefault &&
+           token.value != TOKeof &&
            token.value != TOKrcurly)
         {
         statements->push(parseStatement(PSsemi | PScurlyscope));
   -3755,6 +3756,7   
         statements = new Statements();
         while (token.value != TOKcase &&
            token.value != TOKdefault &&
+           token.value != TOKeof &&
            token.value != TOKrcurly)
         {
         statements->push(parseStatement(PSsemi | PScurlyscope));

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


Rainer Schuetze <r.sagitario gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |matti.niemenmaa+dbugzilla i
                   |                            |ki.fi



PDT ---
*** Issue 2288 has been marked as a duplicate of this issue. ***

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


Don <clugdbug yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |clugdbug yahoo.com.au
         Resolution|                            |FIXED



Fixed DMD1.050 and DMD2.035.

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