I think something is missing here. It doesn't convert fun(int, ufcs) to ufcs.fun(int) as in the examples. It converts fun(ufcs, int) to ufcs.fun(int). We need is a solution to this: fun(T)(arg1, ... ufcs!T, ... argN)