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

Unified Diff: runtime/vm/dart_api_impl.h

Issue 302143004: - Add Dart_EmptyString to return the canonical empty string similar to how (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/include/dart_api.h ('k') | 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/vm/dart_api_impl.h
===================================================================
--- runtime/vm/dart_api_impl.h (revision 36820)
+++ runtime/vm/dart_api_impl.h (working copy)
@@ -194,14 +194,25 @@
static Dart_Handle NewError(const char* format, ...) PRINTF_ATTRIBUTE(1, 2);
// Gets a handle to Null.
- static Dart_Handle Null();
+ static Dart_Handle Null() {
+ return null_handle_;
+ }
// Gets a handle to True.
- static Dart_Handle True();
+ static Dart_Handle True() {
+ return true_handle_;
+ }
- // Gets a handle to False
- static Dart_Handle False();
+ // Gets a handle to False.
+ static Dart_Handle False() {
+ return false_handle_;
+ }
+ // Gets a handle to EmptyString.
+ static Dart_Handle EmptyString() {
+ return empty_string_handle_;
+ }
+
// Retrieves the top ApiLocalScope.
static ApiLocalScope* TopScope(Isolate* isolate);
@@ -265,6 +276,7 @@
static Dart_Handle true_handle_;
static Dart_Handle false_handle_;
static Dart_Handle null_handle_;
+ static Dart_Handle empty_string_handle_;
friend class ApiNativeScope;
};
« no previous file with comments | « runtime/include/dart_api.h ('k') | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698