| 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 // This code was auto-generated, is not intended to be edited, and is subject to | 5 // This code was auto-generated, is not intended to be edited, and is subject to |
| 6 // significant change. Please see the README file for more information. | 6 // significant change. Please see the README file for more information. |
| 7 | 7 |
| 8 library engine; | 8 library engine; |
| 9 | 9 |
| 10 import 'dart:collection'; | 10 import 'dart:collection'; |
| (...skipping 8171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8182 * Invalidate all of the resolution information associated with the | 8182 * Invalidate all of the resolution information associated with the |
| 8183 * compilation unit. The flag [invalidateUris] should be `true` if the cached | 8183 * compilation unit. The flag [invalidateUris] should be `true` if the cached |
| 8184 * results of converting URIs to source files should also be invalidated. | 8184 * results of converting URIs to source files should also be invalidated. |
| 8185 */ | 8185 */ |
| 8186 void invalidateAllResolutionInformation(bool invalidateUris) { | 8186 void invalidateAllResolutionInformation(bool invalidateUris) { |
| 8187 if (getState(PARSED_UNIT) == CacheState.FLUSHED) { | 8187 if (getState(PARSED_UNIT) == CacheState.FLUSHED) { |
| 8188 ResolutionState state = _resolutionState; | 8188 ResolutionState state = _resolutionState; |
| 8189 while (state != null) { | 8189 while (state != null) { |
| 8190 if (state.getState(BUILT_UNIT) == CacheState.VALID) { | 8190 if (state.getState(BUILT_UNIT) == CacheState.VALID) { |
| 8191 CompilationUnit unit = state.getValue(BUILT_UNIT); | 8191 CompilationUnit unit = state.getValue(BUILT_UNIT); |
| 8192 ResolutionEraser.erase(unit); | 8192 setValue(PARSED_UNIT, unit.accept(new AstCloner())); |
| 8193 setValue(PARSED_UNIT, unit); | |
| 8194 break; | 8193 break; |
| 8195 } else if (state.getState(RESOLVED_UNIT) == CacheState.VALID) { | 8194 } else if (state.getState(RESOLVED_UNIT) == CacheState.VALID) { |
| 8196 CompilationUnit unit = state.getValue(RESOLVED_UNIT); | 8195 CompilationUnit unit = state.getValue(RESOLVED_UNIT); |
| 8197 ResolutionEraser.erase(unit); | 8196 setValue(PARSED_UNIT, unit.accept(new AstCloner())); |
| 8198 setValue(PARSED_UNIT, unit); | |
| 8199 break; | 8197 break; |
| 8200 } | 8198 } |
| 8201 state = state._nextState; | 8199 state = state._nextState; |
| 8202 } | 8200 } |
| 8203 } | 8201 } |
| 8204 _discardCachedResolutionInformation(invalidateUris); | 8202 _discardCachedResolutionInformation(invalidateUris); |
| 8205 } | 8203 } |
| 8206 | 8204 |
| 8207 /** | 8205 /** |
| 8208 * Return `true` if this data is safe to use in refactoring. | 8206 * Return `true` if this data is safe to use in refactoring. |
| (...skipping 5352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 13561 _index++; | 13559 _index++; |
| 13562 if (_index >= _manager._workQueues[_queueIndex].length) { | 13560 if (_index >= _manager._workQueues[_queueIndex].length) { |
| 13563 _index = 0; | 13561 _index = 0; |
| 13564 _queueIndex++; | 13562 _queueIndex++; |
| 13565 while (_queueIndex < _manager._workQueues.length && _manager._workQueues[_
queueIndex].isEmpty) { | 13563 while (_queueIndex < _manager._workQueues.length && _manager._workQueues[_
queueIndex].isEmpty) { |
| 13566 _queueIndex++; | 13564 _queueIndex++; |
| 13567 } | 13565 } |
| 13568 } | 13566 } |
| 13569 } | 13567 } |
| 13570 } | 13568 } |
| OLD | NEW |