You want to use AngelScript to develop the system, and then when everything is working ok, you want to transparently exchange the scripts for a C++ DLL, or perhaps a statically linked library.
Well, what you would need is to hide AngelScript from the main application in a wrapper class. This wrapper class will do all the compilation of script code, and supply function pointers for the main application to call. When you decide to switch to C++ code you continue to use the same interface, but instead of compiling scripts it loads a DLL and take the function pointers from that one instead.
Example:
class IDynamicCode{public: virtual int Initialize() = 0; virtual int Uninitialize() = 0; virtual void *GetProcAddress(const char *name) = 0;};
In the Initialize() function you create an AngelScript engine, load the scripts, and compile them. In GetProcAddress() you map the name to a function that calls the script function like in the example I showed earlier.
When you switch to DLL, the Initialize() function would load the DLL instead, and GetProcAddress() would call the global GetProcAddress() for the DLL.
www.AngelCode.com - game development and more...
AngelScript - free scripting library