C : How to read that definition ....

Hello all,

I'd like to ask you to help me to understand this definition in "C"
Code:
int (*f (float (*) (long), char *)) (double);
How can I read this definition?
How can I call this function?

It's example from C programming, a modern approach (K.N.King)

Thank you very much.
Have a nice day.
Best regards,

Jozef
 
Why not just ask at a programming or C forum? Are you using FreeBSD?
 
Hello @DutchDaemon,

Yes, I'm using FreeBSD 9.1-RELEASE. I'm studying the C language. I thought, I can put that question here, sorry.

Jozef
 
Last edited by a moderator:
You can, but this is not really a forum where a lot of programmers hang out and share their experiences. So a dedicated programming forum might work better/faster.
 
Hi all,

Yesterday I found a great article about that issue.
c-faq.com/decl/spiral.anderson.html
Now I understand it, it's clear and easy :)
Thank you to all.
Have a nice day.

Jozef
 
Function pointers are quite ugly. I'd recommend not to use definitions like this directly in your code, instead wrap them in typedefs and put a comment above for yourself/others, describing the function it points to.
 
Back
Top