| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| (...skipping 4376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4387 // Lookup support for serialized scope info. Returns the receiver context | 4387 // Lookup support for serialized scope info. Returns the receiver context |
| 4388 // slot index if scope has a "this" binding, and the binding is | 4388 // slot index if scope has a "this" binding, and the binding is |
| 4389 // context-allocated. Otherwise returns a value < 0. | 4389 // context-allocated. Otherwise returns a value < 0. |
| 4390 int ReceiverContextSlotIndex(); | 4390 int ReceiverContextSlotIndex(); |
| 4391 | 4391 |
| 4392 FunctionKind function_kind(); | 4392 FunctionKind function_kind(); |
| 4393 | 4393 |
| 4394 // Returns true if this ScopeInfo is linked to a outer ScopeInfo. | 4394 // Returns true if this ScopeInfo is linked to a outer ScopeInfo. |
| 4395 bool HasOuterScopeInfo(); | 4395 bool HasOuterScopeInfo(); |
| 4396 | 4396 |
| 4397 // Returns true if this ScopeInfo was created for a debug-evaluate scope. |
| 4398 bool IsDebugEvaluateScope(); |
| 4399 |
| 4400 // Can be used to mark a ScopeInfo that looks like a with-scope as actually |
| 4401 // being a debug-evaluate scope. |
| 4402 void SetIsDebugEvaluateScope(); |
| 4403 |
| 4397 // Return the outer ScopeInfo if present. | 4404 // Return the outer ScopeInfo if present. |
| 4398 ScopeInfo* OuterScopeInfo(); | 4405 ScopeInfo* OuterScopeInfo(); |
| 4399 | 4406 |
| 4400 #ifdef DEBUG | 4407 #ifdef DEBUG |
| 4401 bool Equals(ScopeInfo* other) const; | 4408 bool Equals(ScopeInfo* other) const; |
| 4402 #endif | 4409 #endif |
| 4403 | 4410 |
| 4404 static Handle<ScopeInfo> Create(Isolate* isolate, Zone* zone, Scope* scope, | 4411 static Handle<ScopeInfo> Create(Isolate* isolate, Zone* zone, Scope* scope, |
| 4405 MaybeHandle<ScopeInfo> outer_scope); | 4412 MaybeHandle<ScopeInfo> outer_scope); |
| 4406 static Handle<ScopeInfo> CreateForWithScope( | 4413 static Handle<ScopeInfo> CreateForWithScope( |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4518 : public BitField<VariableAllocationInfo, HasNewTargetField::kNext, 2> {}; | 4525 : public BitField<VariableAllocationInfo, HasNewTargetField::kNext, 2> {}; |
| 4519 class AsmModuleField | 4526 class AsmModuleField |
| 4520 : public BitField<bool, FunctionVariableField::kNext, 1> {}; | 4527 : public BitField<bool, FunctionVariableField::kNext, 1> {}; |
| 4521 class AsmFunctionField : public BitField<bool, AsmModuleField::kNext, 1> {}; | 4528 class AsmFunctionField : public BitField<bool, AsmModuleField::kNext, 1> {}; |
| 4522 class HasSimpleParametersField | 4529 class HasSimpleParametersField |
| 4523 : public BitField<bool, AsmFunctionField::kNext, 1> {}; | 4530 : public BitField<bool, AsmFunctionField::kNext, 1> {}; |
| 4524 class FunctionKindField | 4531 class FunctionKindField |
| 4525 : public BitField<FunctionKind, HasSimpleParametersField::kNext, 9> {}; | 4532 : public BitField<FunctionKind, HasSimpleParametersField::kNext, 9> {}; |
| 4526 class HasOuterScopeInfoField | 4533 class HasOuterScopeInfoField |
| 4527 : public BitField<bool, FunctionKindField::kNext, 1> {}; | 4534 : public BitField<bool, FunctionKindField::kNext, 1> {}; |
| 4535 class IsDebugEvaluateScopeField |
| 4536 : public BitField<bool, HasOuterScopeInfoField::kNext, 1> {}; |
| 4528 | 4537 |
| 4529 // Properties of variables. | 4538 // Properties of variables. |
| 4530 class VariableModeField : public BitField<VariableMode, 0, 3> {}; | 4539 class VariableModeField : public BitField<VariableMode, 0, 3> {}; |
| 4531 class InitFlagField : public BitField<InitializationFlag, 3, 1> {}; | 4540 class InitFlagField : public BitField<InitializationFlag, 3, 1> {}; |
| 4532 class MaybeAssignedFlagField : public BitField<MaybeAssignedFlag, 4, 1> {}; | 4541 class MaybeAssignedFlagField : public BitField<MaybeAssignedFlag, 4, 1> {}; |
| 4533 | 4542 |
| 4534 friend class ScopeIterator; | 4543 friend class ScopeIterator; |
| 4535 }; | 4544 }; |
| 4536 | 4545 |
| 4537 class ModuleInfoEntry : public FixedArray { | 4546 class ModuleInfoEntry : public FixedArray { |
| (...skipping 6735 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11273 } | 11282 } |
| 11274 return value; | 11283 return value; |
| 11275 } | 11284 } |
| 11276 }; | 11285 }; |
| 11277 | 11286 |
| 11278 | 11287 |
| 11279 } // NOLINT, false-positive due to second-order macros. | 11288 } // NOLINT, false-positive due to second-order macros. |
| 11280 } // NOLINT, false-positive due to second-order macros. | 11289 } // NOLINT, false-positive due to second-order macros. |
| 11281 | 11290 |
| 11282 #endif // V8_OBJECTS_H_ | 11291 #endif // V8_OBJECTS_H_ |
| OLD | NEW |