Thread overview
[Issue 11653] New: No error when forgetting break with range cases.
Nov 30, 2013
Shammah Chancellor
Dec 01, 2013
Kenji Hara
Dec 02, 2013
Kenji Hara
Dec 15, 2013
Rainer Schuetze
November 30, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11653

           Summary: No error when forgetting break with range cases.
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody@puremagic.com
        ReportedBy: shammah.chancellor@gmail.com


--- Comment #0 from Shammah Chancellor <shammah.chancellor@gmail.com> 2013-11-30 09:05:15 PST ---
void main()
{
  int test = 12412;
  int output = 0;
  switch(test)
  {
    case 1: case 100:
      output = 1;
      //break; //Oops..
    case 101: .. case 255:
      output = 2;
      break;
    default:
      output = 3;
  }
}

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 01, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11653


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |accepts-invalid, pull


--- Comment #1 from Kenji Hara <k.hara.pg@gmail.com> 2013-12-01 01:13:19 PST ---
(In reply to comment #0)
> void main()
> {
>   int test = 12412;
>   int output = 0;
>   switch(test)
>   {
>     case 1: case 100:
>       output = 1;
>       //break; //Oops..
>     case 101: .. case 255:
>       output = 2;
>       break;
>     default:
>       output = 3;
>   }
> }

The bug is that "switch case fallthrough" warning won't be reported even if -w/wi switch is specified.

https://github.com/D-Programming-Language/dmd/pull/2905 https://github.com/D-Programming-Language/druntime/pull/680

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 01, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11653



--- Comment #2 from github-bugzilla@puremagic.com 2013-12-01 01:43:00 PST ---
Commits pushed to master at https://github.com/D-Programming-Language/druntime

https://github.com/D-Programming-Language/druntime/commit/16be7e673385baf291c9bc025a7987173c29ea7c fix Issue 11653 - No error when forgetting break with range cases.

https://github.com/D-Programming-Language/druntime/commit/8cfd7f5d11953270ea11be304d0ca22c94d2bb0e Merge pull request #680 from 9rnsr/fix11653

Issue 11653 - No error when forgetting break with range cases.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 01, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11653



--- Comment #3 from github-bugzilla@puremagic.com 2013-12-01 14:54:30 PST ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/a8052199ad96ae791e4964213178a76d111de50d fix Issue 11653 - No error when forgetting break with range cases.

https://github.com/D-Programming-Language/dmd/commit/c8773c166b7a131aba9c4a2656dd20a3d4a170ac Merge pull request #2905 from 9rnsr/fix11653

Issue 11653 - No error when forgetting break with range cases

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 02, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11653


Kenji Hara <k.hara.pg@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
December 15, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11653


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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bearophile_hugs@eml.cc


--- Comment #4 from Rainer Schuetze <r.sagitario@gmx.de> 2013-12-15 06:01:56 PST ---
*** Issue 9642 has been marked as a duplicate of this issue. ***

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