| 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 28 matching lines...) Expand all Loading... |
| 39 namespace v8 { | 39 namespace v8 { |
| 40 namespace internal { | 40 namespace internal { |
| 41 | 41 |
| 42 | 42 |
| 43 static Handle<Object> Invoke(bool construct, | 43 static Handle<Object> Invoke(bool construct, |
| 44 Handle<JSFunction> func, | 44 Handle<JSFunction> func, |
| 45 Handle<Object> receiver, | 45 Handle<Object> receiver, |
| 46 int argc, | 46 int argc, |
| 47 Object*** args, | 47 Object*** args, |
| 48 bool* has_pending_exception) { | 48 bool* has_pending_exception) { |
| 49 // Make sure we have a real function, not a boilerplate function. | |
| 50 ASSERT(!func->IsBoilerplate()); | |
| 51 | |
| 52 // Entering JavaScript. | 49 // Entering JavaScript. |
| 53 VMState state(JS); | 50 VMState state(JS); |
| 54 | 51 |
| 55 // Placeholder for return value. | 52 // Placeholder for return value. |
| 56 Object* value = reinterpret_cast<Object*>(kZapValue); | 53 Object* value = reinterpret_cast<Object*>(kZapValue); |
| 57 | 54 |
| 58 typedef Object* (*JSEntryFunction)( | 55 typedef Object* (*JSEntryFunction)( |
| 59 byte* entry, | 56 byte* entry, |
| 60 Object* function, | 57 Object* function, |
| 61 Object* receiver, | 58 Object* receiver, |
| (...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 695 // All allocation spaces other than NEW_SPACE have the same effect. | 692 // All allocation spaces other than NEW_SPACE have the same effect. |
| 696 Heap::CollectAllGarbage(false); | 693 Heap::CollectAllGarbage(false); |
| 697 return v8::Undefined(); | 694 return v8::Undefined(); |
| 698 } | 695 } |
| 699 | 696 |
| 700 | 697 |
| 701 static GCExtension kGCExtension; | 698 static GCExtension kGCExtension; |
| 702 v8::DeclareExtension kGCExtensionDeclaration(&kGCExtension); | 699 v8::DeclareExtension kGCExtensionDeclaration(&kGCExtension); |
| 703 | 700 |
| 704 } } // namespace v8::internal | 701 } } // namespace v8::internal |
| OLD | NEW |