| 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 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 211 static Handle<JSArray> NewJSArray(int init_length, | 211 static Handle<JSArray> NewJSArray(int init_length, |
| 212 PretenureFlag pretenure = NOT_TENURED); | 212 PretenureFlag pretenure = NOT_TENURED); |
| 213 | 213 |
| 214 static Handle<JSArray> NewJSArrayWithElements( | 214 static Handle<JSArray> NewJSArrayWithElements( |
| 215 Handle<FixedArray> elements, | 215 Handle<FixedArray> elements, |
| 216 PretenureFlag pretenure = NOT_TENURED); | 216 PretenureFlag pretenure = NOT_TENURED); |
| 217 | 217 |
| 218 static Handle<JSFunction> NewFunction(Handle<String> name, | 218 static Handle<JSFunction> NewFunction(Handle<String> name, |
| 219 Handle<Object> prototype); | 219 Handle<Object> prototype); |
| 220 | 220 |
| 221 static Handle<JSFunction> NewFunctionWithoutPrototype(Handle<String> name); |
| 222 |
| 221 static Handle<JSFunction> NewFunction(Handle<Object> super, bool is_global); | 223 static Handle<JSFunction> NewFunction(Handle<Object> super, bool is_global); |
| 222 | 224 |
| 223 static Handle<JSFunction> BaseNewFunctionFromSharedFunctionInfo( | 225 static Handle<JSFunction> BaseNewFunctionFromSharedFunctionInfo( |
| 224 Handle<SharedFunctionInfo> function_info, | 226 Handle<SharedFunctionInfo> function_info, |
| 225 Handle<Map> function_map, | 227 Handle<Map> function_map, |
| 226 PretenureFlag pretenure); | 228 PretenureFlag pretenure); |
| 227 | 229 |
| 228 static Handle<JSFunction> NewFunctionFromSharedFunctionInfo( | 230 static Handle<JSFunction> NewFunctionFromSharedFunctionInfo( |
| 229 Handle<SharedFunctionInfo> function_info, | 231 Handle<SharedFunctionInfo> function_info, |
| 230 Handle<Context> context, | 232 Handle<Context> context, |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 284 Handle<SharedFunctionInfo> shared, Handle<Object> prototype); | 286 Handle<SharedFunctionInfo> shared, Handle<Object> prototype); |
| 285 | 287 |
| 286 | 288 |
| 287 static Handle<JSFunction> NewFunctionWithPrototype(Handle<String> name, | 289 static Handle<JSFunction> NewFunctionWithPrototype(Handle<String> name, |
| 288 InstanceType type, | 290 InstanceType type, |
| 289 int instance_size, | 291 int instance_size, |
| 290 Handle<JSObject> prototype, | 292 Handle<JSObject> prototype, |
| 291 Handle<Code> code, | 293 Handle<Code> code, |
| 292 bool force_initial_map); | 294 bool force_initial_map); |
| 293 | 295 |
| 296 static Handle<JSFunction> NewFunctionWithoutPrototype(Handle<String> name, |
| 297 Handle<Code> code); |
| 298 |
| 294 static Handle<DescriptorArray> CopyAppendProxyDescriptor( | 299 static Handle<DescriptorArray> CopyAppendProxyDescriptor( |
| 295 Handle<DescriptorArray> array, | 300 Handle<DescriptorArray> array, |
| 296 Handle<String> key, | 301 Handle<String> key, |
| 297 Handle<Object> value, | 302 Handle<Object> value, |
| 298 PropertyAttributes attributes); | 303 PropertyAttributes attributes); |
| 299 | 304 |
| 300 static Handle<String> NumberToString(Handle<Object> number); | 305 static Handle<String> NumberToString(Handle<Object> number); |
| 301 | 306 |
| 302 enum ApiInstanceType { | 307 enum ApiInstanceType { |
| 303 JavaScriptObject, | 308 JavaScriptObject, |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 369 static void SetRegExpIrregexpData(Handle<JSRegExp> regexp, | 374 static void SetRegExpIrregexpData(Handle<JSRegExp> regexp, |
| 370 JSRegExp::Type type, | 375 JSRegExp::Type type, |
| 371 Handle<String> source, | 376 Handle<String> source, |
| 372 JSRegExp::Flags flags, | 377 JSRegExp::Flags flags, |
| 373 int capture_count); | 378 int capture_count); |
| 374 | 379 |
| 375 private: | 380 private: |
| 376 static Handle<JSFunction> NewFunctionHelper(Handle<String> name, | 381 static Handle<JSFunction> NewFunctionHelper(Handle<String> name, |
| 377 Handle<Object> prototype); | 382 Handle<Object> prototype); |
| 378 | 383 |
| 384 static Handle<JSFunction> NewFunctionWithoutPrototypeHelper( |
| 385 Handle<String> name); |
| 386 |
| 379 static Handle<DescriptorArray> CopyAppendCallbackDescriptors( | 387 static Handle<DescriptorArray> CopyAppendCallbackDescriptors( |
| 380 Handle<DescriptorArray> array, | 388 Handle<DescriptorArray> array, |
| 381 Handle<Object> descriptors); | 389 Handle<Object> descriptors); |
| 382 | 390 |
| 383 // Create a new map cache. | 391 // Create a new map cache. |
| 384 static Handle<MapCache> NewMapCache(int at_least_space_for); | 392 static Handle<MapCache> NewMapCache(int at_least_space_for); |
| 385 | 393 |
| 386 // Update the map cache in the global context with (keys, map) | 394 // Update the map cache in the global context with (keys, map) |
| 387 static Handle<MapCache> AddToMapCache(Handle<Context> context, | 395 static Handle<MapCache> AddToMapCache(Handle<Context> context, |
| 388 Handle<FixedArray> keys, | 396 Handle<FixedArray> keys, |
| 389 Handle<Map> map); | 397 Handle<Map> map); |
| 390 }; | 398 }; |
| 391 | 399 |
| 392 | 400 |
| 393 } } // namespace v8::internal | 401 } } // namespace v8::internal |
| 394 | 402 |
| 395 #endif // V8_FACTORY_H_ | 403 #endif // V8_FACTORY_H_ |
| OLD | NEW |