| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8_ARGUMENTS_H_ | 5 #ifndef V8_ARGUMENTS_H_ |
| 6 #define V8_ARGUMENTS_H_ | 6 #define V8_ARGUMENTS_H_ |
| 7 | 7 |
| 8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 // They are used to generate the Call() functions below | 67 // They are used to generate the Call() functions below |
| 68 // These aren't included in the list as they have duplicate signatures | 68 // These aren't included in the list as they have duplicate signatures |
| 69 // F(NamedPropertyEnumeratorCallback, ...) | 69 // F(NamedPropertyEnumeratorCallback, ...) |
| 70 // F(NamedPropertyGetterCallback, ...) | 70 // F(NamedPropertyGetterCallback, ...) |
| 71 | 71 |
| 72 #define FOR_EACH_CALLBACK_TABLE_MAPPING_0(F) \ | 72 #define FOR_EACH_CALLBACK_TABLE_MAPPING_0(F) \ |
| 73 F(IndexedPropertyEnumeratorCallback, v8::Array) \ | 73 F(IndexedPropertyEnumeratorCallback, v8::Array) \ |
| 74 | 74 |
| 75 #define FOR_EACH_CALLBACK_TABLE_MAPPING_1(F) \ | 75 #define FOR_EACH_CALLBACK_TABLE_MAPPING_1(F) \ |
| 76 F(AccessorGetterCallback, v8::Value, v8::Local<v8::String>) \ | 76 F(AccessorGetterCallback, v8::Value, v8::Local<v8::String>) \ |
| 77 F(AccessorSymbolGetterCallback, v8::Value, v8::Local<v8::Symbol>) \ |
| 78 F(GenericNamedPropertyGetterCallback, \ |
| 79 v8::Value, \ |
| 80 v8::Local<v8::Name>) \ |
| 77 F(NamedPropertyQueryCallback, \ | 81 F(NamedPropertyQueryCallback, \ |
| 78 v8::Integer, \ | 82 v8::Integer, \ |
| 79 v8::Local<v8::String>) \ | 83 v8::Local<v8::String>) \ |
| 84 F(GenericNamedPropertyQueryCallback, \ |
| 85 v8::Integer, \ |
| 86 v8::Local<v8::Name>) \ |
| 80 F(NamedPropertyDeleterCallback, \ | 87 F(NamedPropertyDeleterCallback, \ |
| 81 v8::Boolean, \ | 88 v8::Boolean, \ |
| 82 v8::Local<v8::String>) \ | 89 v8::Local<v8::String>) \ |
| 90 F(GenericNamedPropertyDeleterCallback, \ |
| 91 v8::Boolean, \ |
| 92 v8::Local<v8::Name>) \ |
| 83 F(IndexedPropertyGetterCallback, \ | 93 F(IndexedPropertyGetterCallback, \ |
| 84 v8::Value, \ | 94 v8::Value, \ |
| 85 uint32_t) \ | 95 uint32_t) \ |
| 86 F(IndexedPropertyQueryCallback, \ | 96 F(IndexedPropertyQueryCallback, \ |
| 87 v8::Integer, \ | 97 v8::Integer, \ |
| 88 uint32_t) \ | 98 uint32_t) \ |
| 89 F(IndexedPropertyDeleterCallback, \ | 99 F(IndexedPropertyDeleterCallback, \ |
| 90 v8::Boolean, \ | 100 v8::Boolean, \ |
| 91 uint32_t) \ | 101 uint32_t) \ |
| 92 | 102 |
| 93 #define FOR_EACH_CALLBACK_TABLE_MAPPING_2(F) \ | 103 #define FOR_EACH_CALLBACK_TABLE_MAPPING_2(F) \ |
| 94 F(NamedPropertySetterCallback, \ | 104 F(NamedPropertySetterCallback, \ |
| 95 v8::Value, \ | 105 v8::Value, \ |
| 96 v8::Local<v8::String>, \ | 106 v8::Local<v8::String>, \ |
| 97 v8::Local<v8::Value>) \ | 107 v8::Local<v8::Value>) \ |
| 108 F(GenericNamedPropertySetterCallback, \ |
| 109 v8::Value, \ |
| 110 v8::Local<v8::Name>, \ |
| 111 v8::Local<v8::Value>) \ |
| 98 F(IndexedPropertySetterCallback, \ | 112 F(IndexedPropertySetterCallback, \ |
| 99 v8::Value, \ | 113 v8::Value, \ |
| 100 uint32_t, \ | 114 uint32_t, \ |
| 101 v8::Local<v8::Value>) \ | 115 v8::Local<v8::Value>) \ |
| 102 | 116 |
| 103 #define FOR_EACH_CALLBACK_TABLE_MAPPING_2_VOID_RETURN(F) \ | 117 #define FOR_EACH_CALLBACK_TABLE_MAPPING_2_VOID_RETURN(F) \ |
| 104 F(AccessorSetterCallback, \ | 118 F(AccessorSetterCallback, \ |
| 105 void, \ | 119 void, \ |
| 106 v8::Local<v8::String>, \ | 120 v8::Local<v8::String>, \ |
| 107 v8::Local<v8::Value>) \ | 121 v8::Local<v8::Value>) \ |
| 122 F(AccessorSymbolSetterCallback, \ |
| 123 void, \ |
| 124 v8::Local<v8::Symbol>, \ |
| 125 v8::Local<v8::Value>) \ |
| 108 | 126 |
| 109 | 127 |
| 110 // Custom arguments replicate a small segment of stack that can be | 128 // Custom arguments replicate a small segment of stack that can be |
| 111 // accessed through an Arguments object the same way the actual stack | 129 // accessed through an Arguments object the same way the actual stack |
| 112 // can. | 130 // can. |
| 113 template<int kArrayLength> | 131 template<int kArrayLength> |
| 114 class CustomArgumentsBase : public Relocatable { | 132 class CustomArgumentsBase : public Relocatable { |
| 115 public: | 133 public: |
| 116 virtual inline void IterateInstance(ObjectVisitor* v) { | 134 virtual inline void IterateInstance(ObjectVisitor* v) { |
| 117 v->VisitPointers(values_, values_ + kArrayLength); | 135 v->VisitPointers(values_, values_ + kArrayLength); |
| (...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 295 #define RUNTIME_FUNCTION(Name) RUNTIME_FUNCTION_RETURNS_TYPE(Object*, Name) | 313 #define RUNTIME_FUNCTION(Name) RUNTIME_FUNCTION_RETURNS_TYPE(Object*, Name) |
| 296 #define RUNTIME_FUNCTION_RETURN_PAIR(Name) \ | 314 #define RUNTIME_FUNCTION_RETURN_PAIR(Name) \ |
| 297 RUNTIME_FUNCTION_RETURNS_TYPE(ObjectPair, Name) | 315 RUNTIME_FUNCTION_RETURNS_TYPE(ObjectPair, Name) |
| 298 | 316 |
| 299 #define RUNTIME_ARGUMENTS(isolate, args) \ | 317 #define RUNTIME_ARGUMENTS(isolate, args) \ |
| 300 args.length(), args.arguments(), isolate | 318 args.length(), args.arguments(), isolate |
| 301 | 319 |
| 302 } } // namespace v8::internal | 320 } } // namespace v8::internal |
| 303 | 321 |
| 304 #endif // V8_ARGUMENTS_H_ | 322 #endif // V8_ARGUMENTS_H_ |
| OLD | NEW |