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

Unified Diff: runtime/vm/kernel_to_il.h

Issue 2628693004: TokenPositions on more nodes when running from Kernel (Closed)
Patch Set: Changes based on feedback Created 3 years, 11 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: runtime/vm/kernel_to_il.h
diff --git a/runtime/vm/kernel_to_il.h b/runtime/vm/kernel_to_il.h
index ec5bfd494c06b63eb02c5b143fefadf8f5ba75ad..fffded724402d37a3d7c0a493c8c4af34885e873 100644
--- a/runtime/vm/kernel_to_il.h
+++ b/runtime/vm/kernel_to_il.h
@@ -561,11 +561,13 @@ class ScopeBuilder : public RecursiveVisitor {
virtual void VisitConstructor(Constructor* node);
private:
- void EnterScope(TreeNode* node);
- void ExitScope();
+ void EnterScope(TreeNode* node, TokenPosition start_position);
+ void ExitScope(TokenPosition end_position);
const Type& TranslateVariableType(VariableDeclaration* variable);
- LocalVariable* MakeVariable(const dart::String& name,
+ LocalVariable* MakeVariable(TokenPosition declaration_pos,
+ TokenPosition token_pos,
+ const dart::String& name,
const AbstractType& type);
void AddParameters(FunctionNode* function, intptr_t pos = 0);
@@ -802,7 +804,7 @@ class FlowGraphBuilder : public ExpressionVisitor, public StatementVisitor {
Fragment NullConstant();
Fragment NativeCall(const dart::String* name, const Function* function);
Fragment PushArgument();
- Fragment Return();
+ Fragment Return(TokenPosition position);
Fragment StaticCall(TokenPosition position,
const Function& target,
intptr_t argument_count);
@@ -818,9 +820,9 @@ class FlowGraphBuilder : public ExpressionVisitor, public StatementVisitor {
Fragment StoreInstanceField(
intptr_t offset,
StoreBarrierType emit_store_barrier = kEmitStoreBarrier);
- Fragment StoreLocal(LocalVariable* variable);
+ Fragment StoreLocal(TokenPosition position, LocalVariable* variable);
Fragment StoreStaticField(const dart::Field& field);
- Fragment StringInterpolate();
+ Fragment StringInterpolate(TokenPosition position);
Fragment ThrowTypeError();
Fragment ThrowNoSuchMethodError();
Fragment BuildImplicitClosureCreation(const Function& target);

Powered by Google App Engine
This is Rietveld 408576698