| 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 1e62d4e4d4bfd79c086a71785335cb7f7b28b004..71a8395ba642c33e21f7bdf258a3513e1333e809 100644
|
| --- a/pkg/analyzer/lib/src/summary/summarize_ast.dart
|
| +++ b/pkg/analyzer/lib/src/summary/summarize_ast.dart
|
| @@ -221,6 +221,16 @@ class _SummarizeAstVisitor extends SimpleAstVisitor {
|
| UnlinkedDocumentationCommentBuilder libraryDocumentationComment;
|
|
|
| /**
|
| + * The number of slot ids which have been assigned to this compilation unit.
|
| + */
|
| + int numSlots = 0;
|
| +
|
| + /**
|
| + * Create a slot id for storing a propagated or inferred type.
|
| + */
|
| + int assignTypeSlot() => ++numSlots;
|
| +
|
| + /**
|
| * Build a [_Scope] object containing the names defined within the body of a
|
| * class declaration.
|
| */
|
| @@ -611,6 +621,10 @@ class _SummarizeAstVisitor extends SimpleAstVisitor {
|
| b.constExpr = serializeConstExpr(initializer);
|
| }
|
| }
|
| + if (variable.initializer != null &&
|
| + (variables.isFinal || variables.isConst)) {
|
| + b.propagatedTypeSlot = assignTypeSlot();
|
| + }
|
| this.variables.add(b);
|
| }
|
| }
|
|
|