[Issue 4082] New: nothrow main() can throw

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Apr 12 04:26:42 PDT 2010


http://d.puremagic.com/issues/show_bug.cgi?id=4082

           Summary: nothrow main() can throw
           Product: D
           Version: future
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: bearophile_hugs at eml.cc


--- Comment #0 from bearophile_hugs at eml.cc 2010-04-12 04:26:37 PDT ---
This program compiles with dmd 2.043, and the main() throws, even if it's a
nothrow function:


struct Foo {
    ~this() { throw new Exception(""); }
}
nothrow void main() {
    Foo f;
    goto NEXT;
    NEXT:;
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list