Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(129)

Side by Side Diff: pkg/analyzer/lib/src/generated/engine.dart

Issue 750953005: When the same contents is set for a source, we still need to reset its modification time. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/engine_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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:math" as math; 10 import "dart:math" as math;
(...skipping 2325 matching lines...) Expand 10 before | Expand all | Expand 10 after
2336 bool hintsEnabled = _options.hint; 2336 bool hintsEnabled = _options.hint;
2337 MapIterator<Source, SourceEntry> iterator = _cache.iterator(); 2337 MapIterator<Source, SourceEntry> iterator = _cache.iterator();
2338 while (iterator.moveNext()) { 2338 while (iterator.moveNext()) {
2339 Source source = iterator.key; 2339 Source source = iterator.key;
2340 SourceEntry sourceEntry = iterator.value; 2340 SourceEntry sourceEntry = iterator.value;
2341 for (DataDescriptor descriptor in sourceEntry.descriptors) { 2341 for (DataDescriptor descriptor in sourceEntry.descriptors) {
2342 if (descriptor == DartEntry.SOURCE_KIND) { 2342 if (descriptor == DartEntry.SOURCE_KIND) {
2343 // The source kind is always valid, so the state isn't interesting. 2343 // The source kind is always valid, so the state isn't interesting.
2344 continue; 2344 continue;
2345 } else if (descriptor == DartEntry.CONTAINING_LIBRARIES) { 2345 } else if (descriptor == DartEntry.CONTAINING_LIBRARIES) {
2346 // The list of containing libraries is always valid, so the state isn' t 2346 // The list of containing libraries is always valid, so the state
2347 // interesting. 2347 // isn't interesting.
2348 continue; 2348 continue;
2349 } else if (descriptor == DartEntry.PUBLIC_NAMESPACE) { 2349 } else if (descriptor == DartEntry.PUBLIC_NAMESPACE) {
2350 // The public namespace isn't computed by performAnalysisTask() 2350 // The public namespace isn't computed by performAnalysisTask()
2351 // and therefore isn't interesting. 2351 // and therefore isn't interesting.
2352 continue; 2352 continue;
2353 } else if (descriptor == HtmlEntry.ANGULAR_APPLICATION || 2353 } else if (descriptor == HtmlEntry.ANGULAR_APPLICATION ||
2354 descriptor == HtmlEntry.ANGULAR_COMPONENT || 2354 descriptor == HtmlEntry.ANGULAR_COMPONENT ||
2355 descriptor == HtmlEntry.ANGULAR_ENTRY || 2355 descriptor == HtmlEntry.ANGULAR_ENTRY ||
2356 descriptor == HtmlEntry.ANGULAR_ERRORS || 2356 descriptor == HtmlEntry.ANGULAR_ERRORS ||
2357 descriptor == HtmlEntry.POLYMER_BUILD_ERRORS || 2357 descriptor == HtmlEntry.POLYMER_BUILD_ERRORS ||
(...skipping 12 matching lines...) Expand all
2370 sourceEntry.getState(descriptor)); 2370 sourceEntry.getState(descriptor));
2371 } 2371 }
2372 if (sourceEntry is DartEntry) { 2372 if (sourceEntry is DartEntry) {
2373 // get library-specific values 2373 // get library-specific values
2374 List<Source> librarySources = getLibrariesContaining(source); 2374 List<Source> librarySources = getLibrariesContaining(source);
2375 for (Source librarySource in librarySources) { 2375 for (Source librarySource in librarySources) {
2376 for (DataDescriptor descriptor in sourceEntry.libraryDescriptors) { 2376 for (DataDescriptor descriptor in sourceEntry.libraryDescriptors) {
2377 if (descriptor == DartEntry.ANGULAR_ERRORS || 2377 if (descriptor == DartEntry.ANGULAR_ERRORS ||
2378 descriptor == DartEntry.BUILT_ELEMENT || 2378 descriptor == DartEntry.BUILT_ELEMENT ||
2379 descriptor == DartEntry.BUILT_UNIT) { 2379 descriptor == DartEntry.BUILT_UNIT) {
2380 // These values are not currently being computed, so their state i s 2380 // These values are not currently being computed, so their state
2381 // not interesting. 2381 // is not interesting.
2382 continue; 2382 continue;
2383 } else if (source.isInSystemLibrary && 2383 } else if (source.isInSystemLibrary &&
2384 !_generateSdkErrors && 2384 !_generateSdkErrors &&
2385 (descriptor == DartEntry.VERIFICATION_ERRORS || 2385 (descriptor == DartEntry.VERIFICATION_ERRORS ||
2386 descriptor == DartEntry.HINTS)) { 2386 descriptor == DartEntry.HINTS)) {
2387 continue; 2387 continue;
2388 } else if (!hintsEnabled && descriptor == DartEntry.HINTS) { 2388 } else if (!hintsEnabled && descriptor == DartEntry.HINTS) {
2389 continue; 2389 continue;
2390 } 2390 }
2391 callback( 2391 callback(
(...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after
2911 !_tryPoorMansIncrementalResolution(source, contents)) { 2911 !_tryPoorMansIncrementalResolution(source, contents)) {
2912 _sourceChanged(source); 2912 _sourceChanged(source);
2913 } 2913 }
2914 changed = true; 2914 changed = true;
2915 SourceEntry sourceEntry = _cache.get(source); 2915 SourceEntry sourceEntry = _cache.get(source);
2916 if (sourceEntry != null) { 2916 if (sourceEntry != null) {
2917 sourceEntry.modificationTime = 2917 sourceEntry.modificationTime =
2918 _contentCache.getModificationStamp(source); 2918 _contentCache.getModificationStamp(source);
2919 sourceEntry.setValue(SourceEntry.CONTENT, contents); 2919 sourceEntry.setValue(SourceEntry.CONTENT, contents);
2920 } 2920 }
2921 } else {
2922 SourceEntry sourceEntry = _cache.get(source);
2923 if (sourceEntry != null) {
2924 sourceEntry.modificationTime =
2925 _contentCache.getModificationStamp(source);
2926 }
2921 } 2927 }
2922 } else if (originalContents != null) { 2928 } else if (originalContents != null) {
2923 _incrementalAnalysisCache = 2929 _incrementalAnalysisCache =
2924 IncrementalAnalysisCache.clear(_incrementalAnalysisCache, source); 2930 IncrementalAnalysisCache.clear(_incrementalAnalysisCache, source);
2925 _sourceChanged(source); 2931 _sourceChanged(source);
2926 changed = true; 2932 changed = true;
2927 } 2933 }
2928 return changed; 2934 return changed;
2929 } 2935 }
2930 2936
(...skipping 12000 matching lines...) Expand 10 before | Expand all | Expand 10 after
14931 14937
14932 @override 14938 @override
14933 Object visitPolymerTagDartElement(PolymerTagDartElement element) { 14939 Object visitPolymerTagDartElement(PolymerTagDartElement element) {
14934 if (element.name == PolymerHtmlUnitBuilder_this._elementName) { 14940 if (element.name == PolymerHtmlUnitBuilder_this._elementName) {
14935 throw new PolymerHtmlUnitBuilder_FoundTagDartElementError( 14941 throw new PolymerHtmlUnitBuilder_FoundTagDartElementError(
14936 element as PolymerTagDartElementImpl); 14942 element as PolymerTagDartElementImpl);
14937 } 14943 }
14938 return null; 14944 return null;
14939 } 14945 }
14940 } 14946 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/engine_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698