Line data Source code
1 : // Copyright 2018 the V8 project authors. All rights reserved.
2 : // Use of this source code is governed by a BSD-style license that can be
3 : // found in the LICENSE file.
4 :
5 : #ifndef V8_OBJECTS_JS_PROXY_INL_H_
6 : #define V8_OBJECTS_JS_PROXY_INL_H_
7 :
8 : #include "src/objects/js-proxy.h"
9 :
10 : #include "src/objects-inl.h" // Needed for write barriers
11 :
12 : // Has to be the last include (doesn't have include guards):
13 : #include "src/objects/object-macros.h"
14 :
15 : namespace v8 {
16 : namespace internal {
17 :
18 12359292 : OBJECT_CONSTRUCTORS_IMPL(JSProxy, JSReceiver)
19 :
20 6179646 : CAST_ACCESSOR(JSProxy)
21 :
22 6173560 : ACCESSORS(JSProxy, target, Object, kTargetOffset)
23 23771835 : ACCESSORS(JSProxy, handler, Object, kHandlerOffset)
24 :
25 12347326 : bool JSProxy::IsRevoked() const { return !handler()->IsJSReceiver(); }
26 :
27 : } // namespace internal
28 : } // namespace v8
29 :
30 : #include "src/objects/object-macros-undef.h"
31 :
32 : #endif // V8_OBJECTS_JS_PROXY_INL_H_
|