Index: pkg/kernel/lib/text/ast_to_text.dart |
diff --git a/pkg/kernel/lib/text/ast_to_text.dart b/pkg/kernel/lib/text/ast_to_text.dart |
index 01cdeb83055ff4555e0cdf9bd5272eaaf5ba680a..a0e722740c670be7aacd0a04f5999c75583fdc53 100644 |
--- a/pkg/kernel/lib/text/ast_to_text.dart |
+++ b/pkg/kernel/lib/text/ast_to_text.dart |
@@ -991,6 +991,12 @@ class Printer extends Visitor<Null> { |
visitVariableGet(VariableGet node) { |
writeVariableReference(node.variable); |
+ if (node.promotedType != null) { |
+ writeSymbol('{'); |
+ writeNode(node.promotedType); |
+ writeSymbol('}'); |
+ state = WORD; |
+ } |
} |
visitVariableSet(VariableSet node) { |
@@ -1389,6 +1395,9 @@ class Printer extends Visitor<Null> { |
} |
visitFunctionType(FunctionType node) { |
+ if (state == WORD) { |
+ ensureSpace(); |
+ } |
writeTypeParameterList(node.typeParameters); |
writeSymbol('('); |
var positional = node.positionalParameters; |