Summary: null implicitly converts to any other type on array
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Keywords: accepts-invalid, diagnostic
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from David Simcha <> 2010-11-10 12:06:42 PST ---
The following code compiles and shouldn't:

struct Foo {
    double num;

void main() {
    Foo[] foo = new Foo[5];
    foo[] = null;

It then fails at runtime with the following nonsensical error message:

object.Exception: lengths don't match for array copy

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to