OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/V8DebuggerScript.h" | 5 #include "src/inspector/v8-debugger-script.h" |
6 | 6 |
7 #include "src/inspector/ProtocolPlatform.h" | 7 #include "src/inspector/protocol-platform.h" |
8 #include "src/inspector/StringUtil.h" | 8 #include "src/inspector/string-util.h" |
9 | 9 |
10 namespace v8_inspector { | 10 namespace v8_inspector { |
11 | 11 |
12 static const char hexDigits[17] = "0123456789ABCDEF"; | 12 static const char hexDigits[17] = "0123456789ABCDEF"; |
13 | 13 |
14 static void appendUnsignedAsHex(unsigned number, String16Builder* destination) { | 14 static void appendUnsignedAsHex(unsigned number, String16Builder* destination) { |
15 for (size_t i = 0; i < 8; ++i) { | 15 for (size_t i = 0; i < 8; ++i) { |
16 UChar c = hexDigits[number & 0xF]; | 16 UChar c = hexDigits[number & 0xF]; |
17 destination->append(c); | 17 destination->append(c); |
18 number >>= 4; | 18 number >>= 4; |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 m_sourceMappingURL = sourceMappingURL; | 131 m_sourceMappingURL = sourceMappingURL; |
132 } | 132 } |
133 | 133 |
134 void V8DebuggerScript::setSource(v8::Isolate* isolate, | 134 void V8DebuggerScript::setSource(v8::Isolate* isolate, |
135 v8::Local<v8::String> source) { | 135 v8::Local<v8::String> source) { |
136 m_source.Reset(isolate, source); | 136 m_source.Reset(isolate, source); |
137 m_hash = calculateHash(toProtocolString(source)); | 137 m_hash = calculateHash(toProtocolString(source)); |
138 } | 138 } |
139 | 139 |
140 } // namespace v8_inspector | 140 } // namespace v8_inspector |
OLD | NEW |