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

Side by Side Diff: pkg/analyzer/lib/src/task/incremental_element_builder.dart

Issue 2489363002: Rename setters synthetic/static to isSynthetic/isStatic. (Closed)
Patch Set: Created 4 years, 1 month 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
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.task.incremental_element_builder; 5 library analyzer.src.task.incremental_element_builder;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 8
9 import 'package:analyzer/dart/ast/ast.dart'; 9 import 'package:analyzer/dart/ast/ast.dart';
10 import 'package:analyzer/dart/ast/token.dart'; 10 import 'package:analyzer/dart/ast/token.dart';
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after
375 classElement.accessors = newAccessors; 375 classElement.accessors = newAccessors;
376 classElement.constructors = classElementHolder.constructors; 376 classElement.constructors = classElementHolder.constructors;
377 classElement.fields = newFields.values.toList(); 377 classElement.fields = newFields.values.toList();
378 classElement.methods = classElementHolder.methods; 378 classElement.methods = classElementHolder.methods;
379 classElement.version++; 379 classElement.version++;
380 classElementHolder.validate(); 380 classElementHolder.validate();
381 // Ensure at least a default synthetic constructor. 381 // Ensure at least a default synthetic constructor.
382 if (classElement.constructors.isEmpty) { 382 if (classElement.constructors.isEmpty) {
383 ConstructorElementImpl constructor = 383 ConstructorElementImpl constructor =
384 new ConstructorElementImpl.forNode(null); 384 new ConstructorElementImpl.forNode(null);
385 constructor.synthetic = true; 385 constructor.isSynthetic = true;
386 classElement.constructors = <ConstructorElement>[constructor]; 386 classElement.constructors = <ConstructorElement>[constructor];
387 classDelta.addedConstructors.add(constructor); 387 classDelta.addedConstructors.add(constructor);
388 } 388 }
389 classDelta.hasUnnamedConstructorChange = 389 classDelta.hasUnnamedConstructorChange =
390 classDelta.addedConstructors.any((c) => c.name == '') || 390 classDelta.addedConstructors.any((c) => c.name == '') ||
391 classDelta.removedConstructors.any((c) => c.name == ''); 391 classDelta.removedConstructors.any((c) => c.name == '');
392 // OK 392 // OK
393 return classDelta; 393 return classDelta;
394 } 394 }
395 395
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
775 } else if (element is ParameterElementImpl) { 775 } else if (element is ParameterElementImpl) {
776 element.setVisibleRange(newOffset, newLength); 776 element.setVisibleRange(newOffset, newLength);
777 } 777 }
778 } 778 }
779 } 779 }
780 } 780 }
781 } 781 }
782 super.visitElement(element); 782 super.visitElement(element);
783 } 783 }
784 } 784 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/task/dart.dart ('k') | pkg/analyzer/test/generated/analysis_context_factory.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698