Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(79)

Side by Side Diff: include/v8.h

Issue 1156693003: Introduce a maybe-version of Function::New (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 /** \mainpage V8 API Reference Guide 5 /** \mainpage V8 API Reference Guide
6 * 6 *
7 * V8 is Google's open source JavaScript engine. 7 * V8 is Google's open source JavaScript engine.
8 * 8 *
9 * This set of documents provides reference material generated from the 9 * This set of documents provides reference material generated from the
10 * V8 header file, include/v8.h. 10 * V8 header file, include/v8.h.
(...skipping 3038 matching lines...) Expand 10 before | Expand all | Expand 10 after
3049 3049
3050 /** 3050 /**
3051 * A JavaScript function object (ECMA-262, 15.3). 3051 * A JavaScript function object (ECMA-262, 15.3).
3052 */ 3052 */
3053 class V8_EXPORT Function : public Object { 3053 class V8_EXPORT Function : public Object {
3054 public: 3054 public:
3055 /** 3055 /**
3056 * Create a function in the current execution context 3056 * Create a function in the current execution context
3057 * for a given FunctionCallback. 3057 * for a given FunctionCallback.
3058 */ 3058 */
3059 static Local<Function> New(Isolate* isolate, 3059 static MaybeLocal<Function> New(Local<Context> context,
3060 FunctionCallback callback, 3060 FunctionCallback callback,
3061 Local<Value> data = Local<Value>(), 3061 Local<Value> data = Local<Value>(),
3062 int length = 0); 3062 int length = 0);
3063 static V8_DEPRECATE_SOON(
vogelheim 2015/05/22 15:19:51 Why is the 'static' outside of the macro?
jochen (gone - plz use gerrit) 2015/05/22 18:10:02 consistency with existing uses, however, the __dec
3064 "Use maybe version",
3065 Local<Function> New(Isolate* isolate, FunctionCallback callback,
3066 Local<Value> data = Local<Value>(), int length = 0));
3063 3067
3064 V8_DEPRECATE_SOON("Use maybe version", 3068 V8_DEPRECATE_SOON("Use maybe version",
3065 Local<Object> NewInstance(int argc, Handle<Value> argv[]) 3069 Local<Object> NewInstance(int argc, Handle<Value> argv[])
3066 const); 3070 const);
3067 V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance( 3071 V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance(
3068 Local<Context> context, int argc, Handle<Value> argv[]) const; 3072 Local<Context> context, int argc, Handle<Value> argv[]) const;
3069 3073
3070 V8_DEPRECATE_SOON("Use maybe version", Local<Object> NewInstance() const); 3074 V8_DEPRECATE_SOON("Use maybe version", Local<Object> NewInstance() const);
3071 V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance( 3075 V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance(
3072 Local<Context> context) const { 3076 Local<Context> context) const {
(...skipping 5000 matching lines...) Expand 10 before | Expand all | Expand 10 after
8073 */ 8077 */
8074 8078
8075 8079
8076 } // namespace v8 8080 } // namespace v8
8077 8081
8078 8082
8079 #undef TYPE_CHECK 8083 #undef TYPE_CHECK
8080 8084
8081 8085
8082 #endif // V8_H_ 8086 #endif // V8_H_
OLDNEW
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698