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

Unified Diff: pkg/analyzer/lib/src/dart/ast/utilities.dart

Issue 1814663002: Fix and mark a class as deprecated (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/dart/ast/utilities.dart
diff --git a/pkg/analyzer/lib/src/dart/ast/utilities.dart b/pkg/analyzer/lib/src/dart/ast/utilities.dart
index 331d6d9c54b5fa89e3331a588a3d6102c0859710..b2e25cf2f9878e58def1933f4a72fba3f9300848 100644
--- a/pkg/analyzer/lib/src/dart/ast/utilities.dart
+++ b/pkg/analyzer/lib/src/dart/ast/utilities.dart
@@ -2588,6 +2588,7 @@ class ElementLocator_ElementMapper extends GeneralizingAstVisitor<Element> {
* mapping the old token stream to a new token stream, and preserving resolution
* results.
*/
+@deprecated
class IncrementalAstCloner implements AstVisitor<AstNode> {
/**
* The node to be replaced during the cloning process.
@@ -3101,18 +3102,21 @@ class IncrementalAstCloner implements AstVisitor<AstNode> {
_mapToken(node.implementsKeyword), _cloneNodeList(node.interfaces));
@override
- ImportDirective visitImportDirective(ImportDirective node) =>
- new ImportDirective(
- _cloneNode(node.documentationComment),
- _cloneNodeList(node.metadata),
- _mapToken(node.keyword),
- _cloneNode(node.uri),
- _cloneNodeList(node.configurations),
- _mapToken(node.deferredKeyword),
- _mapToken(node.asKeyword),
- _cloneNode(node.prefix),
- _cloneNodeList(node.combinators),
- _mapToken(node.semicolon));
+ ImportDirective visitImportDirective(ImportDirective node) {
+ ImportDirective copy = new ImportDirective(
+ _cloneNode(node.documentationComment),
+ _cloneNodeList(node.metadata),
+ _mapToken(node.keyword),
+ _cloneNode(node.uri),
+ _cloneNodeList(node.configurations),
+ _mapToken(node.deferredKeyword),
+ _mapToken(node.asKeyword),
+ _cloneNode(node.prefix),
+ _cloneNodeList(node.combinators),
+ _mapToken(node.semicolon));
+ copy.element = node.element;
+ return copy;
+ }
@override
IndexExpression visitIndexExpression(IndexExpression node) {
@@ -3190,13 +3194,16 @@ class IncrementalAstCloner implements AstVisitor<AstNode> {
_cloneNodeList(node.labels), _cloneNode(node.statement));
@override
- LibraryDirective visitLibraryDirective(LibraryDirective node) =>
- new LibraryDirective(
- _cloneNode(node.documentationComment),
- _cloneNodeList(node.metadata),
- _mapToken(node.libraryKeyword),
- _cloneNode(node.name),
- _mapToken(node.semicolon));
+ LibraryDirective visitLibraryDirective(LibraryDirective node) {
+ LibraryDirective copy = new LibraryDirective(
+ _cloneNode(node.documentationComment),
+ _cloneNodeList(node.metadata),
+ _mapToken(node.libraryKeyword),
+ _cloneNode(node.name),
+ _mapToken(node.semicolon));
+ copy.element = node.element;
+ return copy;
+ }
@override
LibraryIdentifier visitLibraryIdentifier(LibraryIdentifier node) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698