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

Unified Diff: runtime/vm/dart_api_impl.cc

Issue 11368138: Add some support for the code-point code-unit distinction. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Implemented feedback from patch set 3 Created 8 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
Index: runtime/vm/dart_api_impl.cc
diff --git a/runtime/vm/dart_api_impl.cc b/runtime/vm/dart_api_impl.cc
index 88d0389e57560cb003aac5c0a69429c8cb73481e..8d251d0891334772ea8055b8ecfd0bdb50ee7783 100644
--- a/runtime/vm/dart_api_impl.cc
+++ b/runtime/vm/dart_api_impl.cc
@@ -1579,7 +1579,9 @@ DART_EXPORT Dart_Handle Dart_NewStringFromUTF32(const uint32_t* utf32_array,
RETURN_NULL_ERROR(utf32_array);
}
CHECK_LENGTH(length, String::kMaxElements);
- return Api::NewHandle(isolate, String::New(utf32_array, length));
+ return Api::NewHandle(
+ isolate,
+ String::New(reinterpret_cast<const int32_t*>(utf32_array), length));
}

Powered by Google App Engine
This is Rietveld 408576698