Possible Duplicate:
Dynamically creating functions in c
Here is an example of what I'd like to do:
void attribute((constructor)) someFunction() {
// Would be nice to define C function "someFunction2" somehow here.
}
I know class_addMethod
allows adding C functions to Objective-C classes during runtime.
Is it possible to add C function to C main
space?
Please, don't tell me I'm wrong if I'm thinking about this way of doing things - I am interested in it rather for educational purposes.