[Issue 4664] Lambdas default arguments problems

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Aug 30 06:36:02 PDT 2010


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


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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |andrej.mitrovich at gmail.com


--- Comment #4 from Andrej Mitrovic <andrej.mitrovich at gmail.com> 2010-08-30 06:35:48 PDT ---
As a quick hack while this isn't fixed you can use this:

    auto lam1 = function (int x=5){ writeln(x); };
    auto lam2 = delegate (int x=10){ writeln(x); };

But this will only work with 2 lambdas at most, and it isn't very nice. :)

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