| 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 1125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1136 function->shared()->set_expected_nof_properties(2); | 1136 function->shared()->set_expected_nof_properties(2); |
| 1137 Handle<JSObject> result = factory->NewJSObject(function); | 1137 Handle<JSObject> result = factory->NewJSObject(function); |
| 1138 | 1138 |
| 1139 native_context()->set_arguments_boilerplate(*result); | 1139 native_context()->set_arguments_boilerplate(*result); |
| 1140 // Note: length must be added as the first property and | 1140 // Note: length must be added as the first property and |
| 1141 // callee must be added as the second property. | 1141 // callee must be added as the second property. |
| 1142 CHECK_NOT_EMPTY_HANDLE(isolate, | 1142 CHECK_NOT_EMPTY_HANDLE(isolate, |
| 1143 JSObject::SetLocalPropertyIgnoreAttributes( | 1143 JSObject::SetLocalPropertyIgnoreAttributes( |
| 1144 result, factory->length_string(), | 1144 result, factory->length_string(), |
| 1145 factory->undefined_value(), DONT_ENUM, | 1145 factory->undefined_value(), DONT_ENUM, |
| 1146 Object::FORCE_TAGGED, JSReceiver::FORCE_FIELD)); | 1146 Object::FORCE_TAGGED, FORCE_FIELD)); |
| 1147 CHECK_NOT_EMPTY_HANDLE(isolate, | 1147 CHECK_NOT_EMPTY_HANDLE(isolate, |
| 1148 JSObject::SetLocalPropertyIgnoreAttributes( | 1148 JSObject::SetLocalPropertyIgnoreAttributes( |
| 1149 result, factory->callee_string(), | 1149 result, factory->callee_string(), |
| 1150 factory->undefined_value(), DONT_ENUM, | 1150 factory->undefined_value(), DONT_ENUM, |
| 1151 Object::FORCE_TAGGED, JSReceiver::FORCE_FIELD)); | 1151 Object::FORCE_TAGGED, FORCE_FIELD)); |
| 1152 | 1152 |
| 1153 #ifdef DEBUG | 1153 #ifdef DEBUG |
| 1154 LookupResult lookup(isolate); | 1154 LookupResult lookup(isolate); |
| 1155 result->LocalLookup(heap->callee_string(), &lookup); | 1155 result->LocalLookup(heap->callee_string(), &lookup); |
| 1156 ASSERT(lookup.IsField()); | 1156 ASSERT(lookup.IsField()); |
| 1157 ASSERT(lookup.GetFieldIndex().field_index() == Heap::kArgumentsCalleeIndex); | 1157 ASSERT(lookup.GetFieldIndex().field_index() == Heap::kArgumentsCalleeIndex); |
| 1158 | 1158 |
| 1159 result->LocalLookup(heap->length_string(), &lookup); | 1159 result->LocalLookup(heap->length_string(), &lookup); |
| 1160 ASSERT(lookup.IsField()); | 1160 ASSERT(lookup.IsField()); |
| 1161 ASSERT(lookup.GetFieldIndex().field_index() == Heap::kArgumentsLengthIndex); | 1161 ASSERT(lookup.GetFieldIndex().field_index() == Heap::kArgumentsLengthIndex); |
| (...skipping 1513 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2675 return from + sizeof(NestingCounterType); | 2675 return from + sizeof(NestingCounterType); |
| 2676 } | 2676 } |
| 2677 | 2677 |
| 2678 | 2678 |
| 2679 // Called when the top-level V8 mutex is destroyed. | 2679 // Called when the top-level V8 mutex is destroyed. |
| 2680 void Bootstrapper::FreeThreadResources() { | 2680 void Bootstrapper::FreeThreadResources() { |
| 2681 ASSERT(!IsActive()); | 2681 ASSERT(!IsActive()); |
| 2682 } | 2682 } |
| 2683 | 2683 |
| 2684 } } // namespace v8::internal | 2684 } } // namespace v8::internal |
| OLD | NEW |