[Issue 2810] Forward reference to an auto function

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Sep 29 02:45:34 PDT 2009


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


Stewart Gordon <smjg at iname.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |spec


--- Comment #4 from Stewart Gordon <smjg at iname.com> 2009-09-29 02:45:33 PDT ---
But there is no forward reference in the original testcase.  I think what
you've just described is a completely separate bug.

BTW I've just checked the spec (both D1 and D2), and it appears that functions
with auto return type aren't meant to work, so maybe this technically isn't
rejects-valid after all.

Decl:
        StorageClasses Decl
        BasicType Declarators ;
        BasicType Declarator FunctionBody
    AutoDeclaration

AutoDeclaration:
    StorageClasses Identifier = AssignExpression ;

But this seems an arbitrary restriction, given that you can create autotype
functions using literals.

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