A callable
A function which calls pred after reversing the given parameters
alias gt = reverseArgs!(binaryFun!("a < b")); assert(gt(2, 1) && !gt(1, 1));
int x = 42; bool xyz(int a, int b) { return a * x < b / x; } auto foo = &xyz; foo(4, 5); alias zyx = reverseArgs!(foo); assert(zyx(5, 4) == foo(4, 5));
alias gt = reverseArgs!(binaryFun!("a < b")); assert(gt(2, 1) && !gt(1, 1)); int x = 42; bool xyz(int a, int b) { return a * x < b / x; } auto foo = &xyz; foo(4, 5); alias zyx = reverseArgs!(foo); assert(zyx(5, 4) == foo(4, 5));
int abc(int a, int b, int c) { return a * b + c; } alias cba = reverseArgs!abc; assert(abc(91, 17, 32) == cba(32, 17, 91));
int a(int a) { return a * 2; } alias _a = reverseArgs!a; assert(a(2) == _a(2));
int b() { return 4; } alias _b = reverseArgs!b; assert(b() == _b());
N-ary predicate that reverses the order of arguments, e.g., given pred(a, b, c), returns pred(c, b, a).