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/api.h" | 5 #include "src/api.h" |
6 | 6 |
7 #include <string.h> // For memcpy, strlen. | 7 #include <string.h> // For memcpy, strlen. |
8 #ifdef V8_USE_ADDRESS_SANITIZER | 8 #ifdef V8_USE_ADDRESS_SANITIZER |
9 #include <sanitizer/asan_interface.h> | 9 #include <sanitizer/asan_interface.h> |
10 #endif // V8_USE_ADDRESS_SANITIZER | 10 #endif // V8_USE_ADDRESS_SANITIZER |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
219 reinterpret_cast<v8::Isolate*>(script->GetIsolate()); | 219 reinterpret_cast<v8::Isolate*>(script->GetIsolate()); |
220 ScriptOriginOptions options(script->origin_options()); | 220 ScriptOriginOptions options(script->origin_options()); |
221 v8::ScriptOrigin origin( | 221 v8::ScriptOrigin origin( |
222 Utils::ToLocal(scriptName), | 222 Utils::ToLocal(scriptName), |
223 v8::Integer::New(v8_isolate, script->line_offset()), | 223 v8::Integer::New(v8_isolate, script->line_offset()), |
224 v8::Integer::New(v8_isolate, script->column_offset()), | 224 v8::Integer::New(v8_isolate, script->column_offset()), |
225 v8::Boolean::New(v8_isolate, options.IsSharedCrossOrigin()), | 225 v8::Boolean::New(v8_isolate, options.IsSharedCrossOrigin()), |
226 v8::Integer::New(v8_isolate, script->id()), | 226 v8::Integer::New(v8_isolate, script->id()), |
227 v8::Boolean::New(v8_isolate, options.IsEmbedderDebugScript()), | 227 v8::Boolean::New(v8_isolate, options.IsEmbedderDebugScript()), |
228 Utils::ToLocal(source_map_url), | 228 Utils::ToLocal(source_map_url), |
229 v8::Boolean::New(v8_isolate, options.IsOpaque()), | 229 v8::Boolean::New(v8_isolate, options.IsOpaque())); |
230 v8::Boolean::New(v8_isolate, options.AllowHtmlComments())); | |
231 return origin; | 230 return origin; |
232 } | 231 } |
233 | 232 |
234 | 233 |
235 // --- E x c e p t i o n B e h a v i o r --- | 234 // --- E x c e p t i o n B e h a v i o r --- |
236 | 235 |
237 | 236 |
238 void i::FatalProcessOutOfMemory(const char* location) { | 237 void i::FatalProcessOutOfMemory(const char* location) { |
239 i::V8::FatalProcessOutOfMemory(location, false); | 238 i::V8::FatalProcessOutOfMemory(location, false); |
240 } | 239 } |
(...skipping 8512 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8753 Address callback_address = | 8752 Address callback_address = |
8754 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); | 8753 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); |
8755 VMState<EXTERNAL> state(isolate); | 8754 VMState<EXTERNAL> state(isolate); |
8756 ExternalCallbackScope call_scope(isolate, callback_address); | 8755 ExternalCallbackScope call_scope(isolate, callback_address); |
8757 callback(info); | 8756 callback(info); |
8758 } | 8757 } |
8759 | 8758 |
8760 | 8759 |
8761 } // namespace internal | 8760 } // namespace internal |
8762 } // namespace v8 | 8761 } // namespace v8 |
OLD | NEW |