XD-11 - Support for parameterized modules

Probably not ready for merge yet. Please Review