Bug 11425 – Broken shadowing variable diagnostic

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-11-02T21:20:00Z
Last change time
2013-11-17T02:50:50Z
Keywords
diagnostic, pull
Assigned to
nobody
Creator
andrej.mitrovich

Comments

Comment #0 by andrej.mitrovich — 2013-11-02T21:20:26Z
----- void main() { int x; { int x = 1; } } ----- $ dmd test.d > test.d(6): Error: is shadowing declaration test.main.x *What* is shadowing the declaration. It should print: > test.d(6): Error: 'x' is shadowing declaration test.main.x
Comment #1 by yebblies — 2013-11-16T23:34:40Z
Comment #2 by github-bugzilla — 2013-11-17T02:45:50Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/962bb2794f2a309005ecc2f89b44dd693ebca3d4 Fix Issue 11425 - Broken shadowing variable diagnostic https://github.com/D-Programming-Language/dmd/commit/e5605493f89b462703440baa5d32a0ae831264b8 Merge pull request #2793 from yebblies/issue11425 Issue 11425 - Broken shadowing variable diagnostic