[Issue 13201] Wrong "Warning: statement is not reachable" error with -w

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Wed Jul 30 03:40:28 PDT 2014


https://issues.dlang.org/show_bug.cgi?id=13201

Dragos Carp <dragoscarp at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Hardware|x86_64                      |All
                 OS|Linux                       |All
           Severity|major                       |regression

--- Comment #1 from Dragos Carp <dragoscarp at gmail.com> ---
Upgraded it to regression because following code successfully compiles with
dmd-2.065 (-w flag) and with dmd-2.066.0-b6 (-w flag) produces "Warning:
statement is not reachable" on "synchronized" line.

==============================

class Foo
{
}

class Bar
{
    Foo foo()
    {
        synchronized 
        {
            assert(0);
        }
    }
}

--


More information about the Digitalmars-d-bugs mailing list