Summary: DMD allows assignment to a scope variable
           Product: D
           Version: 1.037
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: accepts-invalid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]

The specs at say:
"Assignment to a scope, other than initialization, is not
allowed."  Nevertheless, the following code compiles:

void main()
  scope Object foo;
  foo = new Object;

Tested this in DMD 1.037, DMD 2.021, 2.019 and 1.033.


Reply via email to