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 #include "src/v8.h" | 5 #include "src/handles.h" |
6 | 6 |
7 #include "src/handles.h" | 7 #include "src/base/logging.h" |
| 8 #include "src/objects-inl.h" |
8 | 9 |
9 namespace v8 { | 10 namespace v8 { |
10 namespace internal { | 11 namespace internal { |
11 | 12 |
12 #ifdef DEBUG | 13 #ifdef DEBUG |
13 bool HandleBase::IsDereferenceAllowed(DereferenceCheckMode mode) const { | 14 bool HandleBase::IsDereferenceAllowed(DereferenceCheckMode mode) const { |
14 DCHECK_NOT_NULL(location_); | 15 DCHECK_NOT_NULL(location_); |
15 Object* object = *location_; | 16 Object* object = *location_; |
16 if (object->IsSmi()) return true; | 17 if (object->IsSmi()) return true; |
17 HeapObject* heap_object = HeapObject::cast(object); | 18 HeapObject* heap_object = HeapObject::cast(object); |
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 data->next = prev_next_; | 150 data->next = prev_next_; |
150 data->limit = prev_limit_; | 151 data->limit = prev_limit_; |
151 #ifdef DEBUG | 152 #ifdef DEBUG |
152 handles_detached_ = true; | 153 handles_detached_ = true; |
153 #endif | 154 #endif |
154 return deferred; | 155 return deferred; |
155 } | 156 } |
156 | 157 |
157 } // namespace internal | 158 } // namespace internal |
158 } // namespace v8 | 159 } // namespace v8 |
OLD | NEW |