[Issue 7390] Problem in generating switch cases with a static foreach

2017-04-24 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7390

Nick Treleaven  changed:

   What|Removed |Added

 CC||n...@geany.org

--- Comment #4 from Nick Treleaven  ---
(In reply to bearophile_hugs from comment #0)
> switch (c) { // OK
> foreach (X; xy) {
> case X: break;
> }
> default: break;
> }

The foreach break line above should error, this seems to be the bug. Still
present with 2.074.

> switch (c) {
> case 'z': break;
> foreach (X; xy) {
> case X: break;
> }
> default: break; // Error: switch case fallthrough
> }
> }

This is correct.

--


[Issue 7390] Problem in generating switch cases with a static foreach

2012-03-18 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=7390


d...@dawgfoto.de changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||d...@dawgfoto.de
 Resolution||DUPLICATE


--- Comment #1 from d...@dawgfoto.de 2012-03-18 10:15:00 PDT ---
This seems to be fixed with Bug 6518.

*** This issue has been marked as a duplicate of issue 6518 ***

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


[Issue 7390] Problem in generating switch cases with a static foreach

2012-03-18 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=7390



--- Comment #2 from bearophile_h...@eml.cc 2012-03-18 12:43:43 PDT ---
I am seeing the case fallthrough error still, on Windows. This bug seems not
fixed.

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


[Issue 7390] Problem in generating switch cases with a static foreach

2012-03-18 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=7390


bearophile_h...@eml.cc changed:

   What|Removed |Added

 Status|RESOLVED|REOPENED
 Resolution|DUPLICATE   |


--- Comment #3 from bearophile_h...@eml.cc 2012-03-18 12:55:30 PDT ---
To see the wrong error message you need to compile with -w or -wi  (confirmed
on x86-64 linux too by Zor).

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