[Issue 1513] New: try/catch/finally misbehavior on windows

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Sep 17 21:32:26 PDT 2007


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

           Summary: try/catch/finally misbehavior on windows
           Product: D
           Version: 1.021
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla at digitalmars.com
        ReportedBy: braddr at puremagic.com


bug.d
--------
import std.stdio;

void main()
{
    try
    {
        try
        {
            try
            {
            }
            finally
            {
                writefln("throw ex1");
                throw new Exception("ex 1");
            }

        }
        finally
        {
            writefln("throw ex2");
            throw new Exception("ex 2");
        }
    }
    finally
    {
        writefln("throw ex3");
        throw new Exception("ex 3");
    }
}
-------

dmd 1.021 on windows outputs:
$ ./bug
throw ex1
throw ex2
Error: ex2

dmd 1.021 on linux outputs:
$ ./bug
throw ex1
throw ex2
throw ex3
Error: ex3


-- 



More information about the Digitalmars-d-bugs mailing list