D aliases vs. C typedefs

Chris Cain via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Tue Jun 10 16:47:43 PDT 2014


On Tuesday, 10 June 2014 at 22:00:34 UTC, Ali Çehreli wrote:
> http://stackoverflow.com/questions/10758811/c-syntax-for-functions-returning-function-pointers
>
>   int (*(*(*f3)(int))(double))(float);
>
> "f3 is a ..."
>
> Ali

f3 is a pointer to a function taking an int returning a pointer 
to a  function taking a double returning a pointer to a function 
taking in a float and finally returning an int.

Read via spiral method. Someone else once said (I think it was 
Walter?) that you declare it how you use it. But in this case, I 
don't see the baseball bat hitting the programmer who wrote the 
code, so I'm not sure if that's true...


More information about the Digitalmars-d-learn mailing list