Re:The “Clockwise/Spiral Rule”
by xg15 on Sunday November 23, 2014 @09:47AM
(#8648901)
I'm no C expert, but couldn't you contain the madness for a good part with a sane code convention and smart use of typedefs? It looks to me as if the part where everything breaks down is mostly with "nested" function pointer types like in the "ultimate" example of the tutorial.
(The syntax of "simple" function pointers is quirky as well, but without recursion, you might get the hang of it after a short time)
So, couldn't you avoid much of the confusion by mandating that function pointers may refer to other function pointers only through typedefs?
So, couldn't you avoid much of the confusion by mandating that function pointers may refer to other function pointers only through typedefs?
Of course this wouldn't work for legacy code...