| Index: pkg/analyzer/lib/src/generated/index.dart
|
| diff --git a/pkg/analyzer/lib/src/generated/index.dart b/pkg/analyzer/lib/src/generated/index.dart
|
| index b5b5b101d79b91fad82ba80d161d08f6ebd526e6..92ed3883e7c2c9f61c577e22079d19d080ab5a1d 100644
|
| --- a/pkg/analyzer/lib/src/generated/index.dart
|
| +++ b/pkg/analyzer/lib/src/generated/index.dart
|
| @@ -1080,7 +1080,7 @@ class IndexContributor extends GeneralizingAstVisitor<Object> {
|
| Object visitMethodInvocation(MethodInvocation node) {
|
| SimpleIdentifier name = node.methodName;
|
| Element element = name.bestElement;
|
| - if (element is MethodElement) {
|
| + if (element is MethodElement || element is PropertyAccessorElement) {
|
| Location location = _createLocationFromNode(name);
|
| Relationship relationship;
|
| if (node.target != null) {
|
| @@ -1526,6 +1526,7 @@ class IndexHtmlUnitOperation implements IndexOperation {
|
| }
|
| AngularHtmlIndexContributor contributor = new AngularHtmlIndexContributor(_indexStore);
|
| unit.accept(contributor);
|
| + _indexStore.doneIndex();
|
| } catch (exception) {
|
| AnalysisEngine.instance.logger.logError2("Could not index ${unit.element.location}", exception);
|
| }
|
| @@ -1600,6 +1601,14 @@ abstract class IndexStore {
|
| void clear();
|
|
|
| /**
|
| + * Notifies that index store that the current Dart or HTML unit indexing is done.
|
| + *
|
| + * If this method is not invoked after corresponding "aboutToIndex*" invocation, all recorded
|
| + * information may be lost.
|
| + */
|
| + void doneIndex();
|
| +
|
| + /**
|
| * Return the locations of the elements that have the given relationship with the given element.
|
| * For example, if the element represents a method and the relationship is the is-referenced-by
|
| * relationship, then the returned locations will be all of the places where the method is
|
| @@ -1736,6 +1745,7 @@ class IndexUnitOperation implements IndexOperation {
|
| }
|
| unit.accept(new IndexContributor(_indexStore));
|
| unit.accept(new AngularDartIndexContributor(_indexStore));
|
| + _indexStore.doneIndex();
|
| } catch (exception) {
|
| AnalysisEngine.instance.logger.logError2("Could not index ${unit.element.location}", exception);
|
| }
|
| @@ -1997,6 +2007,10 @@ class MemoryIndexStoreImpl implements MemoryIndexStore {
|
| }
|
|
|
| @override
|
| + void doneIndex() {
|
| + }
|
| +
|
| + @override
|
| List<Location> getRelationships(Element element, Relationship relationship) {
|
| MemoryIndexStoreImpl_ElementRelationKey key = new MemoryIndexStoreImpl_ElementRelationKey(element, relationship);
|
| Set<Location> locations = _keyToLocations[key];
|
|
|