HPCC-8842 Fix problems with module inheritance

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>