Removed internal code from TypeSubstitution header. It caused a chain of include problems, which have been corrected.