| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 516 FIXED_ARRAY_TYPE, | 516 FIXED_ARRAY_TYPE, |
| 517 SHARED_FUNCTION_INFO_TYPE, | 517 SHARED_FUNCTION_INFO_TYPE, |
| 518 | 518 |
| 519 JS_VALUE_TYPE, // FIRST_JS_OBJECT_TYPE | 519 JS_VALUE_TYPE, // FIRST_JS_OBJECT_TYPE |
| 520 JS_OBJECT_TYPE, | 520 JS_OBJECT_TYPE, |
| 521 JS_CONTEXT_EXTENSION_OBJECT_TYPE, | 521 JS_CONTEXT_EXTENSION_OBJECT_TYPE, |
| 522 JS_GLOBAL_OBJECT_TYPE, | 522 JS_GLOBAL_OBJECT_TYPE, |
| 523 JS_BUILTINS_OBJECT_TYPE, | 523 JS_BUILTINS_OBJECT_TYPE, |
| 524 JS_GLOBAL_PROXY_TYPE, | 524 JS_GLOBAL_PROXY_TYPE, |
| 525 JS_ARRAY_TYPE, | 525 JS_ARRAY_TYPE, |
| 526 JS_REGEXP_TYPE, // LAST_JS_OBJECT_TYPE | 526 |
| 527 JS_REGEXP_TYPE, // LAST_JS_OBJECT_TYPE, FIRST_FUNCTION_CLASS_TYPE |
| 527 | 528 |
| 528 JS_FUNCTION_TYPE, | 529 JS_FUNCTION_TYPE, |
| 529 | 530 |
| 530 // Pseudo-types | 531 // Pseudo-types |
| 531 FIRST_TYPE = 0x0, | 532 FIRST_TYPE = 0x0, |
| 532 LAST_TYPE = JS_FUNCTION_TYPE, | 533 LAST_TYPE = JS_FUNCTION_TYPE, |
| 533 INVALID_TYPE = FIRST_TYPE - 1, | 534 INVALID_TYPE = FIRST_TYPE - 1, |
| 534 FIRST_NONSTRING_TYPE = MAP_TYPE, | 535 FIRST_NONSTRING_TYPE = MAP_TYPE, |
| 535 // Boundaries for testing for an external array. | 536 // Boundaries for testing for an external array. |
| 536 FIRST_EXTERNAL_ARRAY_TYPE = EXTERNAL_BYTE_ARRAY_TYPE, | 537 FIRST_EXTERNAL_ARRAY_TYPE = EXTERNAL_BYTE_ARRAY_TYPE, |
| 537 LAST_EXTERNAL_ARRAY_TYPE = EXTERNAL_FLOAT_ARRAY_TYPE, | 538 LAST_EXTERNAL_ARRAY_TYPE = EXTERNAL_FLOAT_ARRAY_TYPE, |
| 538 // Boundary for promotion to old data space/old pointer space. | 539 // Boundary for promotion to old data space/old pointer space. |
| 539 LAST_DATA_TYPE = FILLER_TYPE, | 540 LAST_DATA_TYPE = FILLER_TYPE, |
| 540 // Boundaries for testing the type is a JavaScript "object". Note that | 541 // Boundaries for testing the type is a JavaScript "object". Note that |
| 541 // function objects are not counted as objects, even though they are | 542 // function objects are not counted as objects, even though they are |
| 542 // implemented as such; only values whose typeof is "object" are included. | 543 // implemented as such; only values whose typeof is "object" are included. |
| 543 FIRST_JS_OBJECT_TYPE = JS_VALUE_TYPE, | 544 FIRST_JS_OBJECT_TYPE = JS_VALUE_TYPE, |
| 544 LAST_JS_OBJECT_TYPE = JS_REGEXP_TYPE | 545 LAST_JS_OBJECT_TYPE = JS_REGEXP_TYPE, |
| 546 // RegExp objects have [[Class]] "function" because they are callable. |
| 547 // All types from this type and above are objects with [[Class]] "function". |
| 548 FIRST_FUNCTION_CLASS_TYPE = JS_REGEXP_TYPE |
| 545 }; | 549 }; |
| 546 | 550 |
| 547 | 551 |
| 548 STATIC_CHECK(JS_OBJECT_TYPE == Internals::kJSObjectType); | 552 STATIC_CHECK(JS_OBJECT_TYPE == Internals::kJSObjectType); |
| 549 STATIC_CHECK(FIRST_NONSTRING_TYPE == Internals::kFirstNonstringType); | 553 STATIC_CHECK(FIRST_NONSTRING_TYPE == Internals::kFirstNonstringType); |
| 550 STATIC_CHECK(PROXY_TYPE == Internals::kProxyType); | 554 STATIC_CHECK(PROXY_TYPE == Internals::kProxyType); |
| 551 | 555 |
| 552 | 556 |
| 553 enum CompareResult { | 557 enum CompareResult { |
| 554 LESS = -1, | 558 LESS = -1, |
| (...skipping 5843 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6398 } else { | 6402 } else { |
| 6399 value &= ~(1 << bit_position); | 6403 value &= ~(1 << bit_position); |
| 6400 } | 6404 } |
| 6401 return value; | 6405 return value; |
| 6402 } | 6406 } |
| 6403 }; | 6407 }; |
| 6404 | 6408 |
| 6405 } } // namespace v8::internal | 6409 } } // namespace v8::internal |
| 6406 | 6410 |
| 6407 #endif // V8_OBJECTS_H_ | 6411 #endif // V8_OBJECTS_H_ |
| OLD | NEW |