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

Unified Diff: runtime/include/dart_api.h

Issue 905823002: Verify proper API use of acquire/release typed data (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/include/dart_api.h
===================================================================
--- runtime/include/dart_api.h (revision 43108)
+++ runtime/include/dart_api.h (working copy)
@@ -1949,10 +1949,16 @@
* \param data The internal data address is returned here.
* \param len Size of the typed array is returned here.
*
- * Note: When the internal address of the object is acquired any calls to a
- * Dart API function that could potentially allocate an object or run
- * any Dart code will return an error.
+ * Notes:
+ * When the internal address of the object is acquired any calls to a
+ * Dart API function that could potentially allocate an object or run
+ * any Dart code will return an error.
*
+ * Any Dart API functions for accessing the data should not be called
+ * before the corresponding release. In particular, the object should
+ * not be acquired again before its release. This leads to undefined
+ * behavior.
+ *
* \return Success if the internal data address is acquired successfully.
* Otherwise, returns an error handle.
*/
« no previous file with comments | « no previous file | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698