OLD | NEW |
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 | 180 |
181 Expression* rewrite() const { return rewrite_; } | 181 Expression* rewrite() const { return rewrite_; } |
182 void set_rewrite(Expression* expr) { rewrite_ = expr; } | 182 void set_rewrite(Expression* expr) { rewrite_ = expr; } |
183 | 183 |
184 StaticType* type() { return &type_; } | 184 StaticType* type() { return &type_; } |
185 | 185 |
186 private: | 186 private: |
187 Scope* scope_; | 187 Scope* scope_; |
188 Handle<String> name_; | 188 Handle<String> name_; |
189 Mode mode_; | 189 Mode mode_; |
190 bool is_valid_LHS_; | |
191 Kind kind_; | 190 Kind kind_; |
192 | 191 |
193 Variable* local_if_not_shadowed_; | 192 Variable* local_if_not_shadowed_; |
194 | 193 |
195 // Usage info. | |
196 bool is_accessed_from_inner_scope_; // set by variable resolver | |
197 bool is_used_; | |
198 | |
199 // Static type information | 194 // Static type information |
200 StaticType type_; | 195 StaticType type_; |
201 | 196 |
202 // Code generation. | 197 // Code generation. |
203 // rewrite_ is usually a Slot or a Property, but may be any expression. | 198 // rewrite_ is usually a Slot or a Property, but may be any expression. |
204 Expression* rewrite_; | 199 Expression* rewrite_; |
| 200 |
| 201 // Valid as a LHS? (const and this are not valid LHS, for example) |
| 202 bool is_valid_LHS_; |
| 203 |
| 204 // Usage info. |
| 205 bool is_accessed_from_inner_scope_; // set by variable resolver |
| 206 bool is_used_; |
205 }; | 207 }; |
206 | 208 |
207 | 209 |
208 } } // namespace v8::internal | 210 } } // namespace v8::internal |
209 | 211 |
210 #endif // V8_VARIABLES_H_ | 212 #endif // V8_VARIABLES_H_ |
OLD | NEW |