[Issue 16578] bogus deprecation - switch skips declaration of variable

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Feb 11 02:22:44 UTC 2018


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

Seb <greensunny12 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |greensunny12 at gmail.com

--- Comment #1 from Seb <greensunny12 at gmail.com> ---
The problem seems to be due to the associative array.
Reduced a bit further:

---
import std.stdio;

void main()
{
    string[string] opts;
    switch (2)
    {
    case 0:
        opts["a"] = "";
        {
    case 1:
            break;
        }
    default:
    }
}
---

--


More information about the Digitalmars-d-bugs mailing list