| Index: pkg/analysis_server/lib/src/services/index/store/codec.dart
|
| diff --git a/pkg/analysis_server/lib/src/services/index/store/codec.dart b/pkg/analysis_server/lib/src/services/index/store/codec.dart
|
| index d340abc6592c60857666eb1664cbef3f657f5583..c6cf992389a07884e4e2ce0100bd822bef45981e 100644
|
| --- a/pkg/analysis_server/lib/src/services/index/store/codec.dart
|
| +++ b/pkg/analysis_server/lib/src/services/index/store/codec.dart
|
| @@ -104,8 +104,13 @@ class ElementCodec {
|
| * file paths instead of [Element] location URIs.
|
| */
|
| int encode(Element element, bool forKey) {
|
| - ElementLocationImpl location = element.location;
|
| + if (element is NameElement) {
|
| + String name = element.name;
|
| + int nameId = _stringCodec.encode(name);
|
| + return _encodePath(<int>[nameId]);
|
| + }
|
| // check the location has a cached id
|
| + ElementLocationImpl location = element.location;
|
| if (!identical(location.indexOwner, this)) {
|
| location.indexKeyId = null;
|
| location.indexLocationId = null;
|
|
|