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 #ifndef V8_EXECUTION_H_ | 5 #ifndef V8_EXECUTION_H_ |
6 #define V8_EXECUTION_H_ | 6 #define V8_EXECUTION_H_ |
7 | 7 |
8 #include "src/handles.h" | 8 #include "src/handles.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 28 matching lines...) Expand all Loading... |
39 // a pending exception. | 39 // a pending exception. |
40 // | 40 // |
41 MUST_USE_RESULT static MaybeHandle<Object> New(Handle<JSFunction> func, | 41 MUST_USE_RESULT static MaybeHandle<Object> New(Handle<JSFunction> func, |
42 int argc, | 42 int argc, |
43 Handle<Object> argv[]); | 43 Handle<Object> argv[]); |
44 | 44 |
45 // Call a function, just like Call(), but make sure to silently catch | 45 // Call a function, just like Call(), but make sure to silently catch |
46 // any thrown exceptions. The return value is either the result of | 46 // any thrown exceptions. The return value is either the result of |
47 // calling the function (if caught exception is false) or the exception | 47 // calling the function (if caught exception is false) or the exception |
48 // that occurred (if caught exception is true). | 48 // that occurred (if caught exception is true). |
49 static MaybeHandle<Object> TryCall( | 49 // In the exception case, exception_out holds the caught exceptions, unless |
50 Handle<JSFunction> func, | 50 // it is a termination exception. |
51 Handle<Object> receiver, | 51 static MaybeHandle<Object> TryCall(Handle<JSFunction> func, |
52 int argc, | 52 Handle<Object> receiver, int argc, |
53 Handle<Object> argv[], | 53 Handle<Object> argv[], |
54 Handle<Object>* exception_out = NULL); | 54 MaybeHandle<Object>* exception_out = NULL); |
55 | 55 |
56 // ECMA-262 9.3 | 56 // ECMA-262 9.3 |
57 MUST_USE_RESULT static MaybeHandle<Object> ToNumber( | 57 MUST_USE_RESULT static MaybeHandle<Object> ToNumber( |
58 Isolate* isolate, Handle<Object> obj); | 58 Isolate* isolate, Handle<Object> obj); |
59 | 59 |
60 // ECMA-262 9.4 | 60 // ECMA-262 9.4 |
61 MUST_USE_RESULT static MaybeHandle<Object> ToInteger( | 61 MUST_USE_RESULT static MaybeHandle<Object> ToInteger( |
62 Isolate* isolate, Handle<Object> obj); | 62 Isolate* isolate, Handle<Object> obj); |
63 | 63 |
64 // ECMA-262 9.5 | 64 // ECMA-262 9.5 |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
269 friend class Isolate; | 269 friend class Isolate; |
270 friend class StackLimitCheck; | 270 friend class StackLimitCheck; |
271 friend class PostponeInterruptsScope; | 271 friend class PostponeInterruptsScope; |
272 | 272 |
273 DISALLOW_COPY_AND_ASSIGN(StackGuard); | 273 DISALLOW_COPY_AND_ASSIGN(StackGuard); |
274 }; | 274 }; |
275 | 275 |
276 } } // namespace v8::internal | 276 } } // namespace v8::internal |
277 | 277 |
278 #endif // V8_EXECUTION_H_ | 278 #endif // V8_EXECUTION_H_ |
OLD | NEW |