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

           Summary: Should be illegal to throw a non-Throwable
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: clugd...@yahoo.com.au
            Blocks: 5402


--- Comment #0 from Don <clugd...@yahoo.com.au> 2011-01-13 00:36:35 PST ---
Exception chaining cannot work as long as it's legal to throw a non-Throwable.
(There is nothing to chain to!)
Even without exception chaining, this also creates a great deal of needless
complexity in the runtime.
This should be rejected at compile time:

void main()
{
  throw new Object;
}

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

Reply via email to