Thread overview
[Issue 12640] Error inside a switch statement causes a spurious switch case fallthrough warning
[Issue 12640] @nogc introduces a spurious switch case fallthrough warning
Apr 25, 2014
Orvid King
Apr 25, 2014
Andrej Mitrovic
Apr 25, 2014
Andrej Mitrovic
Apr 25, 2014
Andrej Mitrovic
Apr 25, 2014
Andrej Mitrovic
Apr 25, 2014
Andrej Mitrovic
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

Orvid King <blah38621@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Hardware|x86                         |All

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |andrej.mitrovich@gmail.com

--- Comment #1 from Andrej Mitrovic <andrej.mitrovich@gmail.com> ---
This isn't really specific to @nogc, there are other cases where an error inside of a switch causes a fallthrough diagnostic.

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|@nogc introduces a spurious |Error inside a switch
                   |switch case fallthrough     |statement causes a spurious
                   |warning                     |switch case fallthrough
                   |                            |warning

--- Comment #2 from Andrej Mitrovic <andrej.mitrovich@gmail.com> ---
Changed title. Reduced test-case:

-----
void main()
{
    switch (1)
    {
        case 0:
            asdf;
            break;

        default:
    }
}
-----

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|Windows                     |All

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Assignee|nobody@puremagic.com        |andrej.mitrovich@gmail.com

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull

--- Comment #3 from Andrej Mitrovic <andrej.mitrovich@gmail.com> ---
https://github.com/D-Programming-Language/dmd/pull/3496

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

--- Comment #4 from github-bugzilla@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/567f589ebd6a49c2420c38a44e5469d47956f46c
Fix Issue 12640 - Avoid fallthrough diagnostics when the last case/default
statement in a switch failed semantic analysis.

https://github.com/D-Programming-Language/dmd/commit/c5ebee1dc7c41f53eaa9b86c44c6059fbd58ebad Merge pull request #3496 from AndrejMitrovic/Fix12640

Issue 12640 - Avoid fallthrough diagnostics when the last case/default statement failed.

--
April 25, 2014
https://issues.dlang.org/show_bug.cgi?id=12640

github-bugzilla@puremagic.com changed:

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

--