[Issue 2195] New: Variable shadowing is not detected and reported
    d-bugmail at puremagic.com 
    d-bugmail at puremagic.com
       
    Sat Jul  5 08:22:15 PDT 2008
    
    
  
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 at digitalmars.com
        ReportedBy: 2korden at 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
    }
}
-- 
    
    
More information about the Digitalmars-d-bugs
mailing list