| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium 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 "gin/converter.h" | 5 #include "gin/converter.h" |
| 6 | 6 |
| 7 #include <stdint.h> |
| 8 |
| 7 #include "v8/include/v8.h" | 9 #include "v8/include/v8.h" |
| 8 | 10 |
| 9 using v8::ArrayBuffer; | 11 using v8::ArrayBuffer; |
| 10 using v8::Boolean; | 12 using v8::Boolean; |
| 11 using v8::External; | 13 using v8::External; |
| 12 using v8::Function; | 14 using v8::Function; |
| 13 using v8::Int32; | 15 using v8::Int32; |
| 14 using v8::Integer; | 16 using v8::Integer; |
| 15 using v8::Isolate; | 17 using v8::Isolate; |
| 16 using v8::Local; | 18 using v8::Local; |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 218 std::string V8ToString(v8::Local<v8::Value> value) { | 220 std::string V8ToString(v8::Local<v8::Value> value) { |
| 219 if (value.IsEmpty()) | 221 if (value.IsEmpty()) |
| 220 return std::string(); | 222 return std::string(); |
| 221 std::string result; | 223 std::string result; |
| 222 if (!ConvertFromV8(NULL, value, &result)) | 224 if (!ConvertFromV8(NULL, value, &result)) |
| 223 return std::string(); | 225 return std::string(); |
| 224 return result; | 226 return result; |
| 225 } | 227 } |
| 226 | 228 |
| 227 } // namespace gin | 229 } // namespace gin |
| OLD | NEW |