fix Issue 9406 - (Regression: 2.061) Stack overflow from a forward reference error
Fix unnecessary forward reference error.

In DotTemplateInstanceExp, needsTypeInference is used to determine whether the instance is really a function call or not. But the template is yet not actually instantiated, so onemember->toAlias() might fail. In this case, TemplateInstance::toAlias() tried to run its semantic.
Merge pull request #1576 from 9rnsr/fix9406

Issue 9406 - (Regression: 2.061) Stack overflow from a forward reference error