| 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 computer.highlights2; | 5 library computer.highlights2; |
| 6 | 6 |
| 7 import 'package:analysis_server/src/protocol.dart' hide Element; | 7 import 'package:analysis_server/src/protocol.dart' hide Element; |
| 8 import 'package:analyzer/src/generated/ast.dart'; | 8 import 'package:analyzer/src/generated/ast.dart'; |
| 9 import 'package:analyzer/src/generated/element.dart'; | 9 import 'package:analyzer/src/generated/element.dart'; |
| 10 import 'package:analyzer/src/generated/scanner.dart'; | 10 import 'package:analyzer/src/generated/scanner.dart'; |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 void _addIdentifierRegion(SimpleIdentifier node) { | 56 void _addIdentifierRegion(SimpleIdentifier node) { |
| 57 if (_addIdentifierRegion_keyword(node)) { | 57 if (_addIdentifierRegion_keyword(node)) { |
| 58 return; | 58 return; |
| 59 } | 59 } |
| 60 if (_addIdentifierRegion_class(node)) { | 60 if (_addIdentifierRegion_class(node)) { |
| 61 return; | 61 return; |
| 62 } | 62 } |
| 63 if (_addIdentifierRegion_constructor(node)) { | 63 if (_addIdentifierRegion_constructor(node)) { |
| 64 return; | 64 return; |
| 65 } | 65 } |
| 66 if (_addIdentifierRegion_dynamicLocal(node)) { | |
| 67 return; | |
| 68 } | |
| 69 if (_addIdentifierRegion_getterSetterDeclaration(node)) { | 66 if (_addIdentifierRegion_getterSetterDeclaration(node)) { |
| 70 return; | 67 return; |
| 71 } | 68 } |
| 72 if (_addIdentifierRegion_field(node)) { | 69 if (_addIdentifierRegion_field(node)) { |
| 73 return; | 70 return; |
| 74 } | 71 } |
| 72 if (_addIdentifierRegion_dynamicLocal(node)) { |
| 73 return; |
| 74 } |
| 75 if (_addIdentifierRegion_function(node)) { | 75 if (_addIdentifierRegion_function(node)) { |
| 76 return; | 76 return; |
| 77 } | 77 } |
| 78 if (_addIdentifierRegion_functionTypeAlias(node)) { | 78 if (_addIdentifierRegion_functionTypeAlias(node)) { |
| 79 return; | 79 return; |
| 80 } | 80 } |
| 81 if (_addIdentifierRegion_importPrefix(node)) { | 81 if (_addIdentifierRegion_importPrefix(node)) { |
| 82 return; | 82 return; |
| 83 } | 83 } |
| 84 if (_addIdentifierRegion_label(node)) { | 84 if (_addIdentifierRegion_label(node)) { |
| (...skipping 676 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 761 void _addRegions_functionBody(FunctionBody node) { | 761 void _addRegions_functionBody(FunctionBody node) { |
| 762 Token keyword = node.keyword; | 762 Token keyword = node.keyword; |
| 763 if (keyword != null) { | 763 if (keyword != null) { |
| 764 Token star = node.star; | 764 Token star = node.star; |
| 765 int offset = keyword.offset; | 765 int offset = keyword.offset; |
| 766 int end = star != null ? star.end : keyword.end; | 766 int end = star != null ? star.end : keyword.end; |
| 767 computer._addRegion(offset, end - offset, HighlightRegionType.BUILT_IN); | 767 computer._addRegion(offset, end - offset, HighlightRegionType.BUILT_IN); |
| 768 } | 768 } |
| 769 } | 769 } |
| 770 } | 770 } |
| OLD | NEW |