[Issue 8289] Cannot declare functions returning anonymous enum if they have 'in' block.

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Dec 2 06:07:27 PST 2012


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


Andrej Mitrovic <andrej.mitrovich at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |andrej.mitrovich at gmail.com
         Resolution|                            |INVALID


--- Comment #1 from Andrej Mitrovic <andrej.mitrovich at gmail.com> 2012-12-02 06:07:23 PST ---
Maybe you're misreading the runtime assert error as a compiler error?

OTOH if you're trying to declare the return type as 'A', that won't work
because A is not a type.

Unfortunately DMD allows nonsense like this:

enum dummy(in int i) { }

The 'enum' here acts as a placeholder as if you've declared it 'auto'.

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