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

Side by Side Diff: pkg/analysis_server/lib/src/edit/edit_domain.dart

Issue 576703004: Send final problems even if 'validateOnly'. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Request expensive validation in 'checkFinalConditions'. Created 6 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 | Annotate | Revision Log
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 library edit.domain; 5 library edit.domain;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analysis_server/src/analysis_server.dart'; 9 import 'package:analysis_server/src/analysis_server.dart';
10 import 'package:analysis_server/src/constants.dart'; 10 import 'package:analysis_server/src/constants.dart';
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 if (params.validateOnly) { 227 if (params.validateOnly) {
228 finalStatus = new RefactoringStatus(); 228 finalStatus = new RefactoringStatus();
229 return _sendResultResponse(); 229 return _sendResultResponse();
230 } 230 }
231 // validation and create change 231 // validation and create change
232 refactoring.checkFinalConditions().then((_finalStatus) { 232 refactoring.checkFinalConditions().then((_finalStatus) {
233 finalStatus = _finalStatus; 233 finalStatus = _finalStatus;
234 if (_hasFatalError) { 234 if (_hasFatalError) {
235 return _sendResultResponse(); 235 return _sendResultResponse();
236 } 236 }
237 // create change
237 return refactoring.createChange().then((change) { 238 return refactoring.createChange().then((change) {
238 result.change = new SourceChange(change.message, edits: change.edits); 239 result.change = new SourceChange(change.message, edits: change.edits);
239 return _sendResultResponse(); 240 return _sendResultResponse();
240 }); 241 });
241 }); 242 });
242 }); 243 });
243 } 244 }
244 245
245 /** 246 /**
246 * Initializes this context to perform a refactoring with the specified 247 * Initializes this context to perform a refactoring with the specified
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
407 } 408 }
408 if (refactoring is RenameRefactoring) { 409 if (refactoring is RenameRefactoring) {
409 RenameRefactoring renameRefactoring = refactoring; 410 RenameRefactoring renameRefactoring = refactoring;
410 RenameOptions renameOptions = params.options; 411 RenameOptions renameOptions = params.options;
411 renameRefactoring.newName = renameOptions.newName; 412 renameRefactoring.newName = renameOptions.newName;
412 return renameRefactoring.checkNewName(); 413 return renameRefactoring.checkNewName();
413 } 414 }
414 return new RefactoringStatus(); 415 return new RefactoringStatus();
415 } 416 }
416 } 417 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698