Call function by pointer and set parametrs in memory block

Posted by Ellesmess Glain on Stack Overflow See other posts from Stack Overflow or by Ellesmess Glain
Published on 2011-01-17T10:27:14Z Indexed on 2011/01/17 11:53 UTC
Read the original article Hit count: 122

Filed under:
|

Hi, I've little problem :

I'm solving problem with calling function by pointer and passing to it parameters in continuous memory block. My goal is to have function named e.g

CallFunc(void * func,void *params, unsigned int param_length);

that I'll send function pointer, pointer to function's parameters and eventually parameters length and this calling function will call passed function with it's parameters.

I will like write this in C/C++, but if somebody has idea, how this resolve in other language, that supports DLL generation and exportet functions, it will be fine too.

Thanks for answers, Ellesmess

P.S. > I'm sorry about my English, but I'm Czech, thanks :o)

© Stack Overflow or respective owner

Related posts about c++

Related posts about c