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

Side by Side Diff: runtime/include/dart_api.h

Issue 35393003: Retain script path of parent isolate when spawnFunction is called so that (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 2 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 2 * Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
3 * for details. All rights reserved. Use of this source code is governed by a 3 * for details. All rights reserved. Use of this source code is governed by a
4 * BSD-style license that can be found in the LICENSE file. 4 * BSD-style license that can be found in the LICENSE file.
5 */ 5 */
6 6
7 #ifndef INCLUDE_DART_API_H_ 7 #ifndef INCLUDE_DART_API_H_
8 #define INCLUDE_DART_API_H_ 8 #define INCLUDE_DART_API_H_
9 9
10 /** \mainpage Dart Embedding API Reference 10 /** \mainpage Dart Embedding API Reference
(...skipping 595 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 * required (for example, if the isolate was created successfully by 606 * required (for example, if the isolate was created successfully by
607 * Dart_CreateIsolate() but the root library fails to load 607 * Dart_CreateIsolate() but the root library fails to load
608 * successfully, then the function should call Dart_ShutdownIsolate 608 * successfully, then the function should call Dart_ShutdownIsolate
609 * before returning). 609 * before returning).
610 * 610 *
611 * When the function returns false, the function should set *error to 611 * When the function returns false, the function should set *error to
612 * a malloc-allocated buffer containing a useful error message. The 612 * a malloc-allocated buffer containing a useful error message. The
613 * caller of this function (the vm) will make sure that the buffer is 613 * caller of this function (the vm) will make sure that the buffer is
614 * freed. 614 * freed.
615 * 615 *
616 * \param script_uri The uri of the script to load. This uri has been 616 * \param script_uri The uri of the script to load.
617 * canonicalized by the library tag handler from the parent isolate. 617 * This uri is non NULL if the isolate is being created using the
618 * spawnUri isolate API. This uri has been canonicalized by the
619 * library tag handler from the parent isolate.
618 * The callback is responsible for loading this script by a call to 620 * The callback is responsible for loading this script by a call to
619 * Dart_LoadScript or Dart_LoadScriptFromSnapshot. 621 * Dart_LoadScript or Dart_LoadScriptFromSnapshot.
622 * This uri will be NULL if the isolate is being created using the
623 * spawnFunction isolate API.
624 * The callback is responsible for loading the script used in the
625 * parent isolate by a call to Dart_LoadScript or
626 * Dart_LoadScriptFromSnapshot.
620 * \param main The name of the main entry point this isolate will 627 * \param main The name of the main entry point this isolate will
621 * eventually run. This is provided for advisory purposes only to 628 * eventually run. This is provided for advisory purposes only to
622 * improve debugging messages. The main function is not invoked by 629 * improve debugging messages. The main function is not invoked by
623 * this function. 630 * this function.
624 * \param unhandled_exc The name of the function to this isolate will
625 * call when an unhandled exception is encountered.
626 * \param callback_data The callback data which was passed to the 631 * \param callback_data The callback data which was passed to the
627 * parent isolate when it was created by calling Dart_CreateIsolate(). 632 * parent isolate when it was created by calling Dart_CreateIsolate().
628 * \param error A structure into which the embedder can place a 633 * \param error A structure into which the embedder can place a
629 * C string containing an error message in the case of failures. 634 * C string containing an error message in the case of failures.
630 * 635 *
631 * \return The embedder returns NULL if the creation and 636 * \return The embedder returns NULL if the creation and
632 * initialization was not successful and the isolate if successful. 637 * initialization was not successful and the isolate if successful.
633 */ 638 */
634 typedef Dart_Isolate (*Dart_IsolateCreateCallback)(const char* script_uri, 639 typedef Dart_Isolate (*Dart_IsolateCreateCallback)(const char* script_uri,
635 const char* main, 640 const char* main,
(...skipping 1671 matching lines...) Expand 10 before | Expand all | Expand 10 after
2307 * 2312 *
2308 * \param object An object. 2313 * \param object An object.
2309 * \param peer A value to store in the peer field. 2314 * \param peer A value to store in the peer field.
2310 * 2315 *
2311 * \return Returns an error if 'object' is a subtype of Null, num, or 2316 * \return Returns an error if 'object' is a subtype of Null, num, or
2312 * bool. 2317 * bool.
2313 */ 2318 */
2314 DART_EXPORT Dart_Handle Dart_SetPeer(Dart_Handle object, void* peer); 2319 DART_EXPORT Dart_Handle Dart_SetPeer(Dart_Handle object, void* peer);
2315 2320
2316 #endif /* INCLUDE_DART_API_H_ */ /* NOLINT */ 2321 #endif /* INCLUDE_DART_API_H_ */ /* NOLINT */
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698