Dynamic Function Arrays ?
You can declare a function pointer type like so:
[edited by - cgoat on March 26, 2003 10:08:07 AM]
[edited by - cgoat on March 26, 2003 10:08:30 AM]
typedef RETURN_TYPE (*PointerType)(ARG_TYPES);
Then you can use it like anything else:std::vector<PointerType> aFunctionVector;aFunctionVector.push_back(&FunctionOne);(*aFunctionVector[0])(1); // Call the function
[edited by - cgoat on March 26, 2003 10:08:07 AM]
[edited by - cgoat on March 26, 2003 10:08:30 AM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement