Here’s a handy guide to reading C declarations, where things can get very confusing very quickly. Quick — what’s being declared in the line “int (*(*vtable)[])();
” ?
Categories
Here’s a handy guide to reading C declarations, where things can get very confusing very quickly. Quick — what’s being declared in the line “int (*(*vtable)[])();
” ?
3 replies on “How to Read C Declarations”
Ya know what that declaration says to me? “Thank god you don’t program in C anymore” :)
[…] I was planning on coming up with excuse to link to this (via here) […]
I haven’t programmed seriously in C/C++ for a decade or more…but it’s still simple: “vtable” is a pointer locating an array of pointers to functions returning int.