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

Side by Side Diff: include/v8.h

Issue 910683002: Introduce a compile method that takes context extensions (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 5 years, 10 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 1303 matching lines...) Expand 10 before | Expand all | Expand 10 after
1314 * 1314 *
1315 * This is an experimental feature. 1315 * This is an experimental feature.
1316 * 1316 *
1317 * TODO(adamk): Script is likely the wrong return value for this; 1317 * TODO(adamk): Script is likely the wrong return value for this;
1318 * should return some new Module type. 1318 * should return some new Module type.
1319 */ 1319 */
1320 static Local<Script> CompileModule( 1320 static Local<Script> CompileModule(
1321 Isolate* isolate, Source* source, 1321 Isolate* isolate, Source* source,
1322 CompileOptions options = kNoCompileOptions); 1322 CompileOptions options = kNoCompileOptions);
1323 1323
1324 /**
1325 * Compile a function for a given context. This is equivalent to running
1326 *
1327 * with (obj) {
1328 * return function() { ... }
1329 * }
1330 *
1331 * It is possible to specify multiple context extensions (obj in the above
1332 * example).
1333 */
1334 static Local<Function> CompileFunctionInContext(
1335 Isolate* isolate, Source* source, Local<Context> context,
1336 size_t context_extension_count, Local<Object> context_extensions[]);
1337
1324 private: 1338 private:
1325 static Local<UnboundScript> CompileUnboundInternal(Isolate* isolate, 1339 static Local<UnboundScript> CompileUnboundInternal(Isolate* isolate,
1326 Source* source, 1340 Source* source,
1327 CompileOptions options, 1341 CompileOptions options,
1328 bool is_module); 1342 bool is_module);
1329 }; 1343 };
1330 1344
1331 1345
1332 /** 1346 /**
1333 * An error message. 1347 * An error message.
(...skipping 6186 matching lines...) Expand 10 before | Expand all | Expand 10 after
7520 */ 7534 */
7521 7535
7522 7536
7523 } // namespace v8 7537 } // namespace v8
7524 7538
7525 7539
7526 #undef TYPE_CHECK 7540 #undef TYPE_CHECK
7527 7541
7528 7542
7529 #endif // V8_H_ 7543 #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