OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library engine.element; | 5 library engine.element; |
6 | 6 |
7 import 'dart:collection'; | 7 import 'dart:collection'; |
8 import 'dart:math' show min; | 8 import 'dart:math' show min; |
9 | 9 |
10 import 'package:analyzer/src/generated/utilities_general.dart'; | 10 import 'package:analyzer/src/generated/utilities_general.dart'; |
(...skipping 7254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7265 } | 7265 } |
7266 } | 7266 } |
7267 for (InterfaceType interfaceType in targetType.interfaces) { | 7267 for (InterfaceType interfaceType in targetType.interfaces) { |
7268 ExecutableElement member = _lookUpMemberInInterfaces( | 7268 ExecutableElement member = _lookUpMemberInInterfaces( |
7269 interfaceType, true, library, visitedInterfaces, getMember); | 7269 interfaceType, true, library, visitedInterfaces, getMember); |
7270 if (member != null) { | 7270 if (member != null) { |
7271 return member; | 7271 return member; |
7272 } | 7272 } |
7273 } | 7273 } |
7274 for (InterfaceType mixinType in targetType.mixins.reversed) { | 7274 for (InterfaceType mixinType in targetType.mixins.reversed) { |
7275 PropertyAccessorElement member = _lookUpMemberInInterfaces( | 7275 ExecutableElement member = _lookUpMemberInInterfaces( |
7276 mixinType, true, library, visitedInterfaces, getMember); | 7276 mixinType, true, library, visitedInterfaces, getMember); |
7277 if (member != null) { | 7277 if (member != null) { |
7278 return member; | 7278 return member; |
7279 } | 7279 } |
7280 } | 7280 } |
7281 InterfaceType superclass = targetType.superclass; | 7281 InterfaceType superclass = targetType.superclass; |
7282 if (superclass == null) { | 7282 if (superclass == null) { |
7283 return null; | 7283 return null; |
7284 } | 7284 } |
7285 return _lookUpMemberInInterfaces( | 7285 return _lookUpMemberInInterfaces( |
(...skipping 3851 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11137 | 11137 |
11138 @override | 11138 @override |
11139 void visitElement(Element element) { | 11139 void visitElement(Element element) { |
11140 int offset = element.nameOffset; | 11140 int offset = element.nameOffset; |
11141 if (offset != -1) { | 11141 if (offset != -1) { |
11142 map[offset] = element; | 11142 map[offset] = element; |
11143 } | 11143 } |
11144 super.visitElement(element); | 11144 super.visitElement(element); |
11145 } | 11145 } |
11146 } | 11146 } |
OLD | NEW |