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

Unified Diff: runtime/include/dart_api.h

Issue 8446009: Add Dart_Null, Dart_True, and Dart_False. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years, 1 month 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.h » ('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 1035)
+++ runtime/include/dart_api.h (working copy)
@@ -139,8 +139,6 @@
* Requires there to be a current isolate.
*/
DART_EXPORT Dart_Handle Dart_NewPersistentHandle(Dart_Handle object);
-// TODO(turnidge): This function currently only works when passes a
-// local handle. Make it work for both local and persistent handles.
/**
* Deallocates a persistent handle.
@@ -440,6 +438,15 @@
// --- Objects ----
/**
+ * Returns the null object.
+ *
+ * Requires there to be a current isolate.
+ *
+ * \return A handle to the null object.
+ */
+DART_EXPORT Dart_Handle Dart_Null();
+
+/**
* Is this object null?
*/
DART_EXPORT bool Dart_IsNull(Dart_Handle object);
@@ -567,6 +574,24 @@
// --- Booleans ----
/**
+ * Returns the True object.
+ *
+ * Requires there to be a current isolate.
+ *
+ * \return A handle to the True object.
+ */
+DART_EXPORT Dart_Handle Dart_True();
+
+/**
+ * Returns the False object.
+ *
+ * Requires there to be a current isolate.
+ *
+ * \return A handle to the False object.
+ */
+DART_EXPORT Dart_Handle Dart_False();
+
+/**
* Is this object a Boolean?
*/
DART_EXPORT bool Dart_IsBoolean(Dart_Handle object);
« no previous file with comments | « no previous file | runtime/vm/dart_api_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698