[Issue 9690] New: cannot access to @disable'd symbol from inner function of another @disable'd

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Mar 11 07:49:09 PDT 2013


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

           Summary: cannot access to @disable'd symbol from inner function
                    of another @disable'd
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: minor
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: kekeniro2 at yahoo.co.jp


--- Comment #0 from kekeniro2 at yahoo.co.jp 2013-03-11 07:49:08 PDT ---
This code does not work.

@disable {
    void dep() { }
    void main() {
        dep();     // OK
        void inner() {
            dep(); // cannot call dep
        }
    }
}

When you replace '@disable' with 'deprecated', it works. ( even with -de )
I believe that both '@disable' and 'deprecated' should work in the same way.

-- 
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