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

Side by Side Diff: pkg/analyzer/lib/src/context/context.dart

Issue 1309543011: Add support for assert statements with messages to the analyzer. Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address review comments. Created 5 years, 3 months 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
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/ast.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) 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 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 void set analysisOptions(AnalysisOptions options) { 245 void set analysisOptions(AnalysisOptions options) {
246 bool needsRecompute = this._options.analyzeFunctionBodiesPredicate != 246 bool needsRecompute = this._options.analyzeFunctionBodiesPredicate !=
247 options.analyzeFunctionBodiesPredicate || 247 options.analyzeFunctionBodiesPredicate ||
248 this._options.generateImplicitErrors != 248 this._options.generateImplicitErrors !=
249 options.generateImplicitErrors || 249 options.generateImplicitErrors ||
250 this._options.generateSdkErrors != options.generateSdkErrors || 250 this._options.generateSdkErrors != options.generateSdkErrors ||
251 this._options.dart2jsHint != options.dart2jsHint || 251 this._options.dart2jsHint != options.dart2jsHint ||
252 (this._options.hint && !options.hint) || 252 (this._options.hint && !options.hint) ||
253 (this._options.lint && !options.lint) || 253 (this._options.lint && !options.lint) ||
254 this._options.preserveComments != options.preserveComments || 254 this._options.preserveComments != options.preserveComments ||
255 this._options.enableAssertMessage != options.enableAssertMessage ||
255 this._options.enableStrictCallChecks != 256 this._options.enableStrictCallChecks !=
256 options.enableStrictCallChecks || 257 options.enableStrictCallChecks ||
257 this._options.enableSuperMixins != options.enableSuperMixins; 258 this._options.enableSuperMixins != options.enableSuperMixins;
258 int cacheSize = options.cacheSize; 259 int cacheSize = options.cacheSize;
259 if (this._options.cacheSize != cacheSize) { 260 if (this._options.cacheSize != cacheSize) {
260 this._options.cacheSize = cacheSize; 261 this._options.cacheSize = cacheSize;
261 } 262 }
262 this._options.analyzeFunctionBodiesPredicate = 263 this._options.analyzeFunctionBodiesPredicate =
263 options.analyzeFunctionBodiesPredicate; 264 options.analyzeFunctionBodiesPredicate;
264 this._options.generateImplicitErrors = options.generateImplicitErrors; 265 this._options.generateImplicitErrors = options.generateImplicitErrors;
265 this._options.generateSdkErrors = options.generateSdkErrors; 266 this._options.generateSdkErrors = options.generateSdkErrors;
266 this._options.dart2jsHint = options.dart2jsHint; 267 this._options.dart2jsHint = options.dart2jsHint;
268 this._options.enableAssertMessage = options.enableAssertMessage;
267 this._options.enableStrictCallChecks = options.enableStrictCallChecks; 269 this._options.enableStrictCallChecks = options.enableStrictCallChecks;
268 this._options.enableSuperMixins = options.enableSuperMixins; 270 this._options.enableSuperMixins = options.enableSuperMixins;
269 this._options.hint = options.hint; 271 this._options.hint = options.hint;
270 this._options.incremental = options.incremental; 272 this._options.incremental = options.incremental;
271 this._options.incrementalApi = options.incrementalApi; 273 this._options.incrementalApi = options.incrementalApi;
272 this._options.incrementalValidation = options.incrementalValidation; 274 this._options.incrementalValidation = options.incrementalValidation;
273 this._options.lint = options.lint; 275 this._options.lint = options.lint;
274 this._options.preserveComments = options.preserveComments; 276 this._options.preserveComments = options.preserveComments;
275 if (needsRecompute) { 277 if (needsRecompute) {
276 for (WorkManager workManager in workManagers) { 278 for (WorkManager workManager in workManagers) {
(...skipping 1817 matching lines...) Expand 10 before | Expand all | Expand 10 after
2094 new PendingFuture<T>(_context, target, computeValue); 2096 new PendingFuture<T>(_context, target, computeValue);
2095 if (!pendingFuture.evaluate(entry)) { 2097 if (!pendingFuture.evaluate(entry)) {
2096 _context._pendingFutureTargets 2098 _context._pendingFutureTargets
2097 .putIfAbsent(target, () => <PendingFuture>[]) 2099 .putIfAbsent(target, () => <PendingFuture>[])
2098 .add(pendingFuture); 2100 .add(pendingFuture);
2099 scheduleComputation(); 2101 scheduleComputation();
2100 } 2102 }
2101 return pendingFuture.future; 2103 return pendingFuture.future;
2102 } 2104 }
2103 } 2105 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/generated/ast.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698