/**
* Mostly a copy of super
*/
protected IScope getScope(EObject context, EReference reference) {
IScopeProvider scopeProvider = getScopeProvider();
if (scopeProvider == null)
throw new IllegalStateException("scopeProvider must not be null.");
try {
registerImportedNamesAdapter(context);
if (scopeProvider instanceof IScopeProviderWithNode) {
((IScopeProviderWithNode)scopeProvider).setNode(linkNode);
}
return scopeProvider.getScope(context, reference);
} finally {
unRegisterImportedNamesAdapter();
}
}