Can't recreate the error in a small test project (5 modules). I think the problem lies somewhere in between cyclic module imports, mixin struct definitions and maybe the actual size of the class(1k) and its complexity of interfaces(8).
One more thing: The out of memory is before it can tell there is an variable missing, although the error is also there when the variable is not missing.