In the cloned module, you'd probably have to make manual modifications to just include the code from the *other* module so files don't get included twice. (Or you could use 'if function_defined', 'if class_exists' to conditionally load files.) Not impossible, but also not as simple as just installing two copies of the module with different dirname.
I did not realize that classes and functions defined inside a module would be global. Is that a good idea, in general?
Regardless, absolutely you'd have to be careful since they are defined globally. Could you maybe provide examples of how to use the 'if function_defined', 'if class_exists' to conditionally load files? I would think that 'if function_NOT_defined' would be the way to go, but I don't know how to do that, either.
Also, could you use "include_once" or something like that instead?