www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 14437] New: Double scope(failure) ignored

https://issues.dlang.org/show_bug.cgi?id=14437

          Issue ID: 14437
           Summary: Double scope(failure) ignored
           Product: D
           Version: D1 & D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: minor
          Priority: P1
         Component: DMD
          Assignee: nobody puremagic.com
          Reporter: david.eckardt sociomantic.com

import std.c.stdio;

void main() {
    scope (failure){scope (failure) puts("1");}
    scope (failure) scope (failure) puts("2");
    scope (exit)    scope (failure) puts("3");
    throw new Exception("abc");
}

***

prints "2" although it shouldn't. It does not print "1" or "3".

--
Apr 10 2015