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

Unified Diff: pkg/front_end/lib/src/fasta/kernel/kernel_ast_factory.dart

Issue 2828693003: Add local type inference logic for integer literals. (Closed)
Patch Set: Minor clean-ups Created 3 years, 8 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
Index: pkg/front_end/lib/src/fasta/kernel/kernel_ast_factory.dart
diff --git a/pkg/front_end/lib/src/fasta/kernel/kernel_ast_factory.dart b/pkg/front_end/lib/src/fasta/kernel/kernel_ast_factory.dart
index 8d41521a25a019ab71c191a137ec06ffd3a79d1d..e0275f863ce79ea42d8d2eddb07134b54b0f67d2 100644
--- a/pkg/front_end/lib/src/fasta/kernel/kernel_ast_factory.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/kernel_ast_factory.dart
@@ -41,7 +41,8 @@ class KernelAstFactory implements AstFactory {
KernelVariableDeclaration variableDeclaration(String name,
{DartType type,
Expression initializer,
- int charOffset,
+ int charOffset = TreeNode.noOffset,
ahe 2017/04/20 09:45:29 Perhaps this should be a required parameter?
Paul Berry 2017/04/20 09:52:57 I don't know--does it make sense for a variableDec
ahe 2017/04/20 11:38:24 I think both of those are mistakes that would be c
+ int equalsCharOffset = TreeNode.noOffset,
bool isFinal: false,
bool isConst: false}) {
return new KernelVariableDeclaration(name,
@@ -49,6 +50,7 @@ class KernelAstFactory implements AstFactory {
initializer: initializer,
isFinal: isFinal,
isConst: isConst)
- ..fileEqualsOffset = charOffset;
+ ..fileOffset = charOffset
+ ..fileEqualsOffset = equalsCharOffset;
}
}

Powered by Google App Engine
This is Rietveld 408576698