Fixing name replacing and allowing the indexing of recursive table types