| 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 692 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 703 // Returns true if 'function' is found, and false if the iterator ends | 703 // Returns true if 'function' is found, and false if the iterator ends |
| 704 // without finding it. | 704 // without finding it. |
| 705 bool Find(JSFunction* function) { | 705 bool Find(JSFunction* function) { |
| 706 JSFunction* next_function; | 706 JSFunction* next_function; |
| 707 do { | 707 do { |
| 708 next_function = next(); | 708 next_function = next(); |
| 709 if (next_function == function) return true; | 709 if (next_function == function) return true; |
| 710 } while (next_function != NULL); | 710 } while (next_function != NULL); |
| 711 return false; | 711 return false; |
| 712 } | 712 } |
| 713 |
| 713 private: | 714 private: |
| 714 void GetFunctions() { | 715 void GetFunctions() { |
| 715 functions_.Rewind(0); | 716 functions_.Rewind(0); |
| 716 if (frame_iterator_.done()) return; | 717 if (frame_iterator_.done()) return; |
| 717 JavaScriptFrame* frame = frame_iterator_.frame(); | 718 JavaScriptFrame* frame = frame_iterator_.frame(); |
| 718 frame->GetFunctions(&functions_); | 719 frame->GetFunctions(&functions_); |
| 719 ASSERT(functions_.length() > 0); | 720 ASSERT(functions_.length() > 0); |
| 720 frame_iterator_.Advance(); | 721 frame_iterator_.Advance(); |
| 721 index_ = functions_.length() - 1; | 722 index_ = functions_.length() - 1; |
| 722 } | 723 } |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 794 } | 795 } |
| 795 | 796 |
| 796 | 797 |
| 797 const AccessorDescriptor Accessors::ObjectPrototype = { | 798 const AccessorDescriptor Accessors::ObjectPrototype = { |
| 798 ObjectGetPrototype, | 799 ObjectGetPrototype, |
| 799 ObjectSetPrototype, | 800 ObjectSetPrototype, |
| 800 0 | 801 0 |
| 801 }; | 802 }; |
| 802 | 803 |
| 803 } } // namespace v8::internal | 804 } } // namespace v8::internal |
| OLD | NEW |