| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 490 | 490 |
| 491 class TranslationIterator BASE_EMBEDDED { | 491 class TranslationIterator BASE_EMBEDDED { |
| 492 public: | 492 public: |
| 493 TranslationIterator(ByteArray* buffer, int index) | 493 TranslationIterator(ByteArray* buffer, int index) |
| 494 : buffer_(buffer), index_(index) { | 494 : buffer_(buffer), index_(index) { |
| 495 ASSERT(index >= 0 && index < buffer->length()); | 495 ASSERT(index >= 0 && index < buffer->length()); |
| 496 } | 496 } |
| 497 | 497 |
| 498 int32_t Next(); | 498 int32_t Next(); |
| 499 | 499 |
| 500 bool HasNext() const { return index_ >= 0; } | 500 bool HasNext() const { return index_ < buffer_->length(); } |
| 501 | |
| 502 void Done() { index_ = -1; } | |
| 503 | 501 |
| 504 void Skip(int n) { | 502 void Skip(int n) { |
| 505 for (int i = 0; i < n; i++) Next(); | 503 for (int i = 0; i < n; i++) Next(); |
| 506 } | 504 } |
| 507 | 505 |
| 508 private: | 506 private: |
| 509 ByteArray* buffer_; | 507 ByteArray* buffer_; |
| 510 int index_; | 508 int index_; |
| 511 }; | 509 }; |
| 512 | 510 |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 715 Object** parameters_; | 713 Object** parameters_; |
| 716 Object** expression_stack_; | 714 Object** expression_stack_; |
| 717 | 715 |
| 718 friend class Deoptimizer; | 716 friend class Deoptimizer; |
| 719 }; | 717 }; |
| 720 #endif | 718 #endif |
| 721 | 719 |
| 722 } } // namespace v8::internal | 720 } } // namespace v8::internal |
| 723 | 721 |
| 724 #endif // V8_DEOPTIMIZER_H_ | 722 #endif // V8_DEOPTIMIZER_H_ |
| OLD | NEW |