On Saturday, 26 July 2014 at 20:49:30 UTC, seany wrote:
Can a function return a function in D? Sorry if i missed the
answer somewhere
Yup, you can return functions, delegates, or function pointers.
int function(int) returnsFunc1()
{
return function(int n) { return n; };
}
int function
On Saturday, 26 July 2014 at 20:49:30 UTC, seany wrote:
Can a function return a function in D? Sorry if i missed the
answer somewhere
Just alias your function signature:
```d
alias MyFunctionType = void function(int);
```
Example from my own code:
```d
alias DeserializeBody = TLObject functio