www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 1261] New: Regression from overzealous error message

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1261

           Summary: Regression from overzealous error message
           Product: D
           Version: 1.005
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: regression
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: oskar.linde gmail.com


int[] test(int[2] x) { return x; }

Gives (with dmd 1.005 and later): 

Error: escaping reference to local x

Since static arrays (at least in Dv1) are passed by reference, the x above
wouldn't be local. The sample compiles fine with all D versions (that I've
tested) up to and including 1.004.

The regression was probably introduced by fixing issue 890.


-- 
Jun 07 2007
parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=1261


onlystupidspamhere yahoo.se changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED





Fixed in 1.017.


-- 
Jun 26 2007