P
Pier Paolo
does the author come from pascal development ?Grant said:I recently inherited some older C code and saw something I haven't really
seen before. I noticed it as it fails to compile at my home computer, as it
has a newer (4.x vs 3.x ) gcc compiler.
Its a private function, inside a function. Something like this.
void myFunc(...) {
static void myPrivateFunc(...) {
}
...
return;
}
I assume its failing to compile, because the private function is declared
static. I guess what I'm comfused at is I havent' really seen functions
declared in functions before. Could this have been done for performance
reasons or something? The original author has about 5 different C files,
each with one of these private functions, they all do about the same thing.
There basically some masking and quit math on the function parameters.