| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 | 279 |
| 280 void AddMapIfMissing(Handle<Map> map, Zone* zone) { | 280 void AddMapIfMissing(Handle<Map> map, Zone* zone) { |
| 281 map = Map::CurrentMapForDeprecated(map); | 281 map = Map::CurrentMapForDeprecated(map); |
| 282 for (int i = 0; i < length(); ++i) { | 282 for (int i = 0; i < length(); ++i) { |
| 283 if (at(i).is_identical_to(map)) return; | 283 if (at(i).is_identical_to(map)) return; |
| 284 } | 284 } |
| 285 Add(map, zone); | 285 Add(map, zone); |
| 286 } | 286 } |
| 287 | 287 |
| 288 void Add(Handle<Map> handle, Zone* zone) { | 288 void Add(Handle<Map> handle, Zone* zone) { |
| 289 ASSERT(!handle->is_deprecated()); |
| 289 list_.Add(handle.location(), zone); | 290 list_.Add(handle.location(), zone); |
| 290 } | 291 } |
| 291 | 292 |
| 292 Handle<Map> at(int i) const { | 293 Handle<Map> at(int i) const { |
| 293 return Handle<Map>(list_.at(i)); | 294 return Handle<Map>(list_.at(i)); |
| 294 } | 295 } |
| 295 | 296 |
| 296 Handle<Map> first() const { return at(0); } | 297 Handle<Map> first() const { return at(0); } |
| 297 Handle<Map> last() const { return at(length() - 1); } | 298 Handle<Map> last() const { return at(length() - 1); } |
| 298 | 299 |
| (...skipping 2764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3063 private: | 3064 private: |
| 3064 Isolate* isolate_; | 3065 Isolate* isolate_; |
| 3065 Zone* zone_; | 3066 Zone* zone_; |
| 3066 Visitor visitor_; | 3067 Visitor visitor_; |
| 3067 }; | 3068 }; |
| 3068 | 3069 |
| 3069 | 3070 |
| 3070 } } // namespace v8::internal | 3071 } } // namespace v8::internal |
| 3071 | 3072 |
| 3072 #endif // V8_AST_H_ | 3073 #endif // V8_AST_H_ |
| OLD | NEW |