www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2195] New: Variable shadowing is not detected and reported

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2195

           Summary: Variable shadowing is not detected and reported
           Product: D
           Version: unspecified
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: accepts-invalid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: 2korden gmail.com


Test case that fails as of 1.026 (earlist one I have) as well as latest one
(1.031 atm).

void main() {
    int[int] arr;
    int variable;
    foreach (i, j; arr) {
        int variable;  // shadowing is disallowed but not detected
    }
}


-- 
Jul 05 2008
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2195


Stewart Gordon <smjg iname.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |smjg iname.com
         Resolution|                            |DUPLICATE


--- Comment #1 from Stewart Gordon <smjg iname.com> 2010-08-19 06:28:38 PDT ---
*** This issue has been marked as a duplicate of issue 47 ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Aug 19 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2195


Stewart Gordon <smjg iname.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
            Version|1.00                        |D1 & D2
         Resolution|DUPLICATE                   |
           Severity|normal                      |regression


--- Comment #2 from Stewart Gordon <smjg iname.com> 2010-08-19 06:37:15 PDT ---
I was wrong, the bug has come back (1.063 and 2.048, Windows).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Aug 19 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2195


Don <clugdbug yahoo.com.au> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|regression                  |normal


--- Comment #3 from Don <clugdbug yahoo.com.au> 2010-08-31 02:43:31 PDT ---
(In reply to comment #2)
 I was wrong, the bug has come back (1.063 and 2.048, Windows).

I tested 0.165, 1.000, 1.020, 1.032, 1.041, 1.050, 1.060 and a few others. This is not a regression. The bug was never gone. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 31 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2195



--- Comment #4 from Stewart Gordon <smjg iname.com> 2010-08-31 04:21:58 PDT ---
(In reply to comment #3)
 (In reply to comment #2)
 I was wrong, the bug has come back (1.063 and 2.048, Windows).

I tested 0.165, 1.000, 1.020, 1.032, 1.041, 1.050, 1.060 and a few others. This is not a regression. The bug was never gone.

In that case, any clue why bug 47 was logged as fixed in 0.161, both on the bug page and in the changelog? -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 31 2010
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2195



--- Comment #5 from Don <clugdbug yahoo.com.au> 2010-08-31 04:37:13 PDT ---
(In reply to comment #4)
 (In reply to comment #3)
 (In reply to comment #2)
 I was wrong, the bug has come back (1.063 and 2.048, Windows).

I tested 0.165, 1.000, 1.020, 1.032, 1.041, 1.050, 1.060 and a few others. This is not a regression. The bug was never gone.

In that case, any clue why bug 47 was logged as fixed in 0.161, both on the bug page and in the changelog?

Bug 47 was fixed, and still is. This isn't a duplicate. It applies only with foreach(). -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Aug 31 2010