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

Unified Diff: pkg/analyzer/lib/src/summary/summarize_ast.dart

Issue 2972233002: Don't summarize labels, remove resynthesis code for labels. (Closed)
Patch Set: Created 3 years, 5 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 | « pkg/analyzer/lib/src/summary/idl.dart ('k') | pkg/analyzer/test/src/summary/summary_common.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/summary/summarize_ast.dart
diff --git a/pkg/analyzer/lib/src/summary/summarize_ast.dart b/pkg/analyzer/lib/src/summary/summarize_ast.dart
index ec83c64d3f1375eb4a9f43d7acf8684df7272980..874fa4e50dffcb05e40250a363e2d6f46c8a34f0 100644
--- a/pkg/analyzer/lib/src/summary/summarize_ast.dart
+++ b/pkg/analyzer/lib/src/summary/summarize_ast.dart
@@ -235,12 +235,6 @@ class _SummarizeAstVisitor extends RecursiveAstVisitor {
<UnlinkedExportNonPublicBuilder>[];
/**
- * List of objects which should be written to
- * [UnlinkedExecutable.localLabels].
- */
- List<UnlinkedLabelBuilder> labels = <UnlinkedLabelBuilder>[];
-
- /**
* List of objects which should be written to [UnlinkedUnit.parts].
*/
final List<UnlinkedPartBuilder> parts = <UnlinkedPartBuilder>[];
@@ -703,11 +697,9 @@ class _SummarizeAstVisitor extends RecursiveAstVisitor {
}
}
List<UnlinkedExecutableBuilder> oldExecutables = executables;
- List<UnlinkedLabelBuilder> oldLabels = labels;
Map<int, int> oldLocalClosureIndexMap = _localClosureIndexMap;
bool oldSerializeClosureBodyExprs = _serializeClosureBodyExprs;
executables = <UnlinkedExecutableBuilder>[];
- labels = <UnlinkedLabelBuilder>[];
_localClosureIndexMap = <int, int>{};
_serializeClosureBodyExprs = serializeBodyExpr;
if (initializers != null) {
@@ -730,10 +722,8 @@ class _SummarizeAstVisitor extends RecursiveAstVisitor {
}
}
b.localFunctions = executables;
- b.localLabels = labels;
Map<int, int> localClosureIndexMap = _localClosureIndexMap;
executables = oldExecutables;
- labels = oldLabels;
_localClosureIndexMap = oldLocalClosureIndexMap;
_serializeClosureBodyExprs = oldSerializeClosureBodyExprs;
return localClosureIndexMap;
@@ -1304,19 +1294,6 @@ class _SummarizeAstVisitor extends RecursiveAstVisitor {
}
@override
- void visitLabel(Label node) {
- AstNode parent = node.parent;
- if (parent is! NamedExpression) {
- labels.add(new UnlinkedLabelBuilder(
- name: node.label.name,
- nameOffset: node.offset,
- isOnSwitchMember: parent is SwitchMember,
- isOnSwitchStatement: parent is LabeledStatement &&
- parent.statement is SwitchStatement));
- }
- }
-
- @override
void visitLibraryDirective(LibraryDirective node) {
libraryName =
node.name.components.map((SimpleIdentifier id) => id.name).join('.');
« no previous file with comments | « pkg/analyzer/lib/src/summary/idl.dart ('k') | pkg/analyzer/test/src/summary/summary_common.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698