| 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_OBJECTS_H_ | 5 #ifndef V8_OBJECTS_H_ |
| 6 #define V8_OBJECTS_H_ | 6 #define V8_OBJECTS_H_ |
| 7 | 7 |
| 8 #include <iosfwd> | 8 #include <iosfwd> |
| 9 | 9 |
| 10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
| (...skipping 3974 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3985 // Lookup support for serialized scope info. Returns the | 3985 // Lookup support for serialized scope info. Returns the |
| 3986 // context slot index for a given slot name if the slot is present; otherwise | 3986 // context slot index for a given slot name if the slot is present; otherwise |
| 3987 // returns a value < 0. The name must be an internalized string. | 3987 // returns a value < 0. The name must be an internalized string. |
| 3988 // If the slot is present and mode != NULL, sets *mode to the corresponding | 3988 // If the slot is present and mode != NULL, sets *mode to the corresponding |
| 3989 // mode for that variable. | 3989 // mode for that variable. |
| 3990 static int ContextSlotIndex(Handle<ScopeInfo> scope_info, Handle<String> name, | 3990 static int ContextSlotIndex(Handle<ScopeInfo> scope_info, Handle<String> name, |
| 3991 VariableMode* mode, VariableLocation* location, | 3991 VariableMode* mode, VariableLocation* location, |
| 3992 InitializationFlag* init_flag, | 3992 InitializationFlag* init_flag, |
| 3993 MaybeAssignedFlag* maybe_assigned_flag); | 3993 MaybeAssignedFlag* maybe_assigned_flag); |
| 3994 | 3994 |
| 3995 // Lookup the name of a certain context slot by its index. |
| 3996 String* ContextSlotName(int slot_index); |
| 3997 |
| 3995 // Lookup support for serialized scope info. Returns the | 3998 // Lookup support for serialized scope info. Returns the |
| 3996 // parameter index for a given parameter name if the parameter is present; | 3999 // parameter index for a given parameter name if the parameter is present; |
| 3997 // otherwise returns a value < 0. The name must be an internalized string. | 4000 // otherwise returns a value < 0. The name must be an internalized string. |
| 3998 int ParameterIndex(String* name); | 4001 int ParameterIndex(String* name); |
| 3999 | 4002 |
| 4000 // Lookup support for serialized scope info. Returns the function context | 4003 // Lookup support for serialized scope info. Returns the function context |
| 4001 // slot index if the function name is present and context-allocated (named | 4004 // slot index if the function name is present and context-allocated (named |
| 4002 // function expressions, only), otherwise returns a value < 0. The name | 4005 // function expressions, only), otherwise returns a value < 0. The name |
| 4003 // must be an internalized string. | 4006 // must be an internalized string. |
| 4004 int FunctionContextSlotIndex(String* name, VariableMode* mode); | 4007 int FunctionContextSlotIndex(String* name, VariableMode* mode); |
| (...skipping 6842 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 10847 } else { | 10850 } else { |
| 10848 value &= ~(1 << bit_position); | 10851 value &= ~(1 << bit_position); |
| 10849 } | 10852 } |
| 10850 return value; | 10853 return value; |
| 10851 } | 10854 } |
| 10852 }; | 10855 }; |
| 10853 | 10856 |
| 10854 } } // namespace v8::internal | 10857 } } // namespace v8::internal |
| 10855 | 10858 |
| 10856 #endif // V8_OBJECTS_H_ | 10859 #endif // V8_OBJECTS_H_ |
| OLD | NEW |