Index: runtime/vm/scopes.h |
=================================================================== |
--- runtime/vm/scopes.h (revision 28998) |
+++ runtime/vm/scopes.h (working copy) |
@@ -27,7 +27,7 @@ |
: token_pos_(token_pos), |
name_(name), |
owner_(NULL), |
- type_(type), |
+ type_(&type), |
regis
2013/10/22 23:17:20
Why change this now? We usually do not store a poi
hausner
2013/10/22 23:22:18
Because I have to change the type of a variable af
|
const_value_(NULL), |
is_final_(false), |
is_captured_(false), |
@@ -45,7 +45,11 @@ |
owner_ = owner; |
} |
- const AbstractType& type() const { return type_; } |
+ const AbstractType& type() const { return *type_; } |
+ void set_type(const AbstractType& value) { |
+ ASSERT(value.IsZoneHandle()); |
+ type_ = &value; |
+ } |
bool is_final() const { return is_final_; } |
void set_is_final() { is_final_ = true; } |
@@ -101,7 +105,7 @@ |
const String& name_; |
LocalScope* owner_; // Local scope declaring this variable. |
- const AbstractType& type_; // Declaration type of local variable. |
+ const AbstractType* type_; // Declaration type of local variable. |
const Instance* const_value_; // NULL or compile-time const value. |