How to understand these complicated pointer declarations? [duplicate]
Possible Duplicate:
Complex Declarations
Can someone help me to break this down, and help me to understand?
1) char *(*(*a[N])( ))( );
2) char (*开发者_开发问答 (*x[3]) ( ))[5];
3) char (*(*f( ))[ ]) ( );
The golden rule is. just use http://cdecl.org/:
declare a as array 5 of pointer to function returning pointer to function returning pointer to char
(I replacedN
with5
)declare x as array 3 of pointer to function returning pointer to array 5 of char
declare f as function returning pointer to array of pointer to function returning char
To understand how to interpret them yourself, this is a very good explanation from MSDN: Interpreting More Complex Declarators.
精彩评论