| OLD | NEW |
| 1 // Copyright 2006-2009 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2009 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 2725 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2736 // SharedFunctionInfo describes the JSFunction information that can be | 2736 // SharedFunctionInfo describes the JSFunction information that can be |
| 2737 // shared by multiple instances of the function. | 2737 // shared by multiple instances of the function. |
| 2738 class SharedFunctionInfo: public HeapObject { | 2738 class SharedFunctionInfo: public HeapObject { |
| 2739 public: | 2739 public: |
| 2740 // [name]: Function name. | 2740 // [name]: Function name. |
| 2741 DECL_ACCESSORS(name, Object) | 2741 DECL_ACCESSORS(name, Object) |
| 2742 | 2742 |
| 2743 // [code]: Function code. | 2743 // [code]: Function code. |
| 2744 DECL_ACCESSORS(code, Code) | 2744 DECL_ACCESSORS(code, Code) |
| 2745 | 2745 |
| 2746 // [construct stub]: Code stub for constructing instances of this function. |
| 2747 DECL_ACCESSORS(construct_stub, Code) |
| 2748 |
| 2746 // Returns if this function has been compiled to native code yet. | 2749 // Returns if this function has been compiled to native code yet. |
| 2747 inline bool is_compiled(); | 2750 inline bool is_compiled(); |
| 2748 | 2751 |
| 2749 // [length]: The function length - usually the number of declared parameters. | 2752 // [length]: The function length - usually the number of declared parameters. |
| 2750 // Use up to 2^30 parameters. | 2753 // Use up to 2^30 parameters. |
| 2751 inline int length(); | 2754 inline int length(); |
| 2752 inline void set_length(int value); | 2755 inline void set_length(int value); |
| 2753 | 2756 |
| 2754 // [formal parameter count]: The declared number of parameters. | 2757 // [formal parameter count]: The declared number of parameters. |
| 2755 inline int formal_parameter_count(); | 2758 inline int formal_parameter_count(); |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2831 // Casting. | 2834 // Casting. |
| 2832 static inline SharedFunctionInfo* cast(Object* obj); | 2835 static inline SharedFunctionInfo* cast(Object* obj); |
| 2833 | 2836 |
| 2834 // Constants. | 2837 // Constants. |
| 2835 static const int kDontAdaptArgumentsSentinel = -1; | 2838 static const int kDontAdaptArgumentsSentinel = -1; |
| 2836 | 2839 |
| 2837 // Layout description. | 2840 // Layout description. |
| 2838 // (An even number of integers has a size that is a multiple of a pointer.) | 2841 // (An even number of integers has a size that is a multiple of a pointer.) |
| 2839 static const int kNameOffset = HeapObject::kHeaderSize; | 2842 static const int kNameOffset = HeapObject::kHeaderSize; |
| 2840 static const int kCodeOffset = kNameOffset + kPointerSize; | 2843 static const int kCodeOffset = kNameOffset + kPointerSize; |
| 2841 static const int kLengthOffset = kCodeOffset + kPointerSize; | 2844 static const int kConstructStubOffset = kCodeOffset + kPointerSize; |
| 2845 static const int kLengthOffset = kConstructStubOffset + kPointerSize; |
| 2842 static const int kFormalParameterCountOffset = kLengthOffset + kIntSize; | 2846 static const int kFormalParameterCountOffset = kLengthOffset + kIntSize; |
| 2843 static const int kExpectedNofPropertiesOffset = | 2847 static const int kExpectedNofPropertiesOffset = |
| 2844 kFormalParameterCountOffset + kIntSize; | 2848 kFormalParameterCountOffset + kIntSize; |
| 2845 static const int kStartPositionAndTypeOffset = | 2849 static const int kStartPositionAndTypeOffset = |
| 2846 kExpectedNofPropertiesOffset + kIntSize; | 2850 kExpectedNofPropertiesOffset + kIntSize; |
| 2847 static const int kEndPositionOffset = kStartPositionAndTypeOffset + kIntSize; | 2851 static const int kEndPositionOffset = kStartPositionAndTypeOffset + kIntSize; |
| 2848 static const int kFunctionTokenPositionOffset = kEndPositionOffset + kIntSize; | 2852 static const int kFunctionTokenPositionOffset = kEndPositionOffset + kIntSize; |
| 2849 static const int kInstanceClassNameOffset = | 2853 static const int kInstanceClassNameOffset = |
| 2850 kFunctionTokenPositionOffset + kIntSize; | 2854 kFunctionTokenPositionOffset + kIntSize; |
| 2851 static const int kExternalReferenceDataOffset = | 2855 static const int kExternalReferenceDataOffset = |
| (...skipping 1596 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4448 } else { | 4452 } else { |
| 4449 value &= ~(1 << bit_position); | 4453 value &= ~(1 << bit_position); |
| 4450 } | 4454 } |
| 4451 return value; | 4455 return value; |
| 4452 } | 4456 } |
| 4453 }; | 4457 }; |
| 4454 | 4458 |
| 4455 } } // namespace v8::internal | 4459 } } // namespace v8::internal |
| 4456 | 4460 |
| 4457 #endif // V8_OBJECTS_H_ | 4461 #endif // V8_OBJECTS_H_ |
| OLD | NEW |