| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 analyzer.src.context.context; | 5 library analyzer.src.context.context; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 import 'dart:collection'; | 8 import 'dart:collection'; |
| 9 | 9 |
| 10 import 'package:analyzer/instrumentation/instrumentation.dart'; | 10 import 'package:analyzer/instrumentation/instrumentation.dart'; |
| (...skipping 1076 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1087 // IMPORT_SOURCE_CLOSURE | 1087 // IMPORT_SOURCE_CLOSURE |
| 1088 setValue(INCLUDED_PARTS, Source.EMPTY_LIST); | 1088 setValue(INCLUDED_PARTS, Source.EMPTY_LIST); |
| 1089 setValue(IS_CLIENT, true); | 1089 setValue(IS_CLIENT, true); |
| 1090 setValue(IS_LAUNCHABLE, false); | 1090 setValue(IS_LAUNCHABLE, false); |
| 1091 setValue(LIBRARY_ELEMENT, library); | 1091 setValue(LIBRARY_ELEMENT, library); |
| 1092 setValue(LIBRARY_ELEMENT1, library); | 1092 setValue(LIBRARY_ELEMENT1, library); |
| 1093 setValue(LIBRARY_ELEMENT2, library); | 1093 setValue(LIBRARY_ELEMENT2, library); |
| 1094 setValue(LIBRARY_ELEMENT3, library); | 1094 setValue(LIBRARY_ELEMENT3, library); |
| 1095 setValue(LIBRARY_ELEMENT4, library); | 1095 setValue(LIBRARY_ELEMENT4, library); |
| 1096 setValue(LIBRARY_ELEMENT5, library); | 1096 setValue(LIBRARY_ELEMENT5, library); |
| 1097 setValue(LIBRARY_ELEMENT6, library); | |
| 1098 setValue(LINE_INFO, new LineInfo(<int>[0])); | 1097 setValue(LINE_INFO, new LineInfo(<int>[0])); |
| 1099 setValue(PARSE_ERRORS, AnalysisError.NO_ERRORS); | 1098 setValue(PARSE_ERRORS, AnalysisError.NO_ERRORS); |
| 1100 entry.setState(PARSED_UNIT, CacheState.FLUSHED); | 1099 entry.setState(PARSED_UNIT, CacheState.FLUSHED); |
| 1101 entry.setState(RESOLVE_TYPE_NAMES_ERRORS, CacheState.FLUSHED); | 1100 entry.setState(RESOLVE_TYPE_NAMES_ERRORS, CacheState.FLUSHED); |
| 1102 setValue(SCAN_ERRORS, AnalysisError.NO_ERRORS); | 1101 setValue(SCAN_ERRORS, AnalysisError.NO_ERRORS); |
| 1103 setValue(SOURCE_KIND, SourceKind.LIBRARY); | 1102 setValue(SOURCE_KIND, SourceKind.LIBRARY); |
| 1104 entry.setState(TOKEN_STREAM, CacheState.FLUSHED); | 1103 entry.setState(TOKEN_STREAM, CacheState.FLUSHED); |
| 1105 setValue(UNITS, <Source>[librarySource]); | 1104 setValue(UNITS, <Source>[librarySource]); |
| 1106 | 1105 |
| 1107 LibrarySpecificUnit unit = | 1106 LibrarySpecificUnit unit = |
| (...skipping 915 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2023 new PendingFuture<T>(_context, target, computeValue); | 2022 new PendingFuture<T>(_context, target, computeValue); |
| 2024 if (!pendingFuture.evaluate(entry)) { | 2023 if (!pendingFuture.evaluate(entry)) { |
| 2025 _context._pendingFutureTargets | 2024 _context._pendingFutureTargets |
| 2026 .putIfAbsent(target, () => <PendingFuture>[]) | 2025 .putIfAbsent(target, () => <PendingFuture>[]) |
| 2027 .add(pendingFuture); | 2026 .add(pendingFuture); |
| 2028 scheduleComputation(); | 2027 scheduleComputation(); |
| 2029 } | 2028 } |
| 2030 return pendingFuture.future; | 2029 return pendingFuture.future; |
| 2031 } | 2030 } |
| 2032 } | 2031 } |
| OLD | NEW |