OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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/inspector/v8-internal-value-type.h" | 5 #include "src/inspector/v8-internal-value-type.h" |
6 | 6 |
7 #include "src/inspector/protocol-platform.h" | |
8 #include "src/inspector/string-util.h" | 7 #include "src/inspector/string-util.h" |
9 | 8 |
10 namespace v8_inspector { | 9 namespace v8_inspector { |
11 | 10 |
12 namespace { | 11 namespace { |
13 | 12 |
14 v8::Local<v8::Private> internalSubtypePrivate(v8::Isolate* isolate) { | 13 v8::Local<v8::Private> internalSubtypePrivate(v8::Isolate* isolate) { |
15 return v8::Private::ForApi( | 14 return v8::Private::ForApi( |
16 isolate, | 15 isolate, |
17 toV8StringInternalized(isolate, "V8InternalType#internalSubtype")); | 16 toV8StringInternalized(isolate, "V8InternalType#internalSubtype")); |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 if (!object->HasPrivate(context, privateValue).FromMaybe(false)) | 67 if (!object->HasPrivate(context, privateValue).FromMaybe(false)) |
69 return v8::Null(isolate); | 68 return v8::Null(isolate); |
70 v8::Local<v8::Value> subtypeValue; | 69 v8::Local<v8::Value> subtypeValue; |
71 if (!object->GetPrivate(context, privateValue).ToLocal(&subtypeValue) || | 70 if (!object->GetPrivate(context, privateValue).ToLocal(&subtypeValue) || |
72 !subtypeValue->IsString()) | 71 !subtypeValue->IsString()) |
73 return v8::Null(isolate); | 72 return v8::Null(isolate); |
74 return subtypeValue; | 73 return subtypeValue; |
75 } | 74 } |
76 | 75 |
77 } // namespace v8_inspector | 76 } // namespace v8_inspector |
OLD | NEW |