2 ms·
I've always wanted this solved uniformly for values and functions that return them. Say we have a type definition of an argument as T, then any call site could
by karmakaze 5y ago
I've always wanted this solved uniformly for values and functions that return them. Say we have a type definition of an argument as T, then any call site could instead pass in a function that returns T in its place.
Then this late-bind default would be an expression for a function returning T where T is the argument type. I would also like this to be extended to only evaluate once if at all.