[Issue 6484] compose can't take multi arg functions
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Fri Jun 6 11:40:32 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=6484
Justin Whear <justin at economicmodeling.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |justin at economicmodeling.com
--- Comment #3 from Justin Whear <justin at economicmodeling.com> ---
Kenji's made some recent changes to compose and I cannot reproduce in 2.065.
int f(int a){ return a; }
int g(int a){ return a; }
int h(int a,int b,int c){ return a * b * c; }
import std.functional;
alias compose!(f,g,h) F;
static assert(F(1,2,3) == f(g(h(1,2,3))));
--
More information about the Digitalmars-d-bugs
mailing list