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

Issue 11275008: - Represent strings internally in UTF-16 format, this makes it (Closed)

Created:
8 years, 2 months ago by siva
Modified:
8 years, 1 month ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org, Tom Ball
Visibility:
Public.

Description

- Represent strings internally in UTF-16 format, this makes it compatible with webkit and will allow for easy externalization of strings (The language specification was changed recently to reflect this as follows "A string is a sequence of UTF-16 code units"). - Remove four byte string class and all references to it. - Rename some of the string functions in Dart API to make them consistent and better describe the underlying functionality Dart_NewString => Dart_NewStringFromCString Dart_NewString8 => Dart_NewStringFromUTF8 Dart_NewString16 => Dart_NewStringFromUTF16 Dart_NewString32 => Dart_NewStringFromUTF32 Dart_NewExternalString8 => Dart_NewExternalUTF8String Dart_NewExternalString16 => Dart_NewExternalUTF16String Dart_NewExternalString32 => Dart_NewExternalUTF32String Dart_StringGet8 => Dart_StringToUTF8 Dart_StringGet16 => Dart_StringToUTF16 Dart_StringToCString => Dart_StringToCString Dart_IsString8 => Removed Dart_IsString16 -> Removed Dart_StringToBytes -> Removed Dart_StringGet32 -> Removed

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Patch Set 4 : #

Patch Set 5 : #

Patch Set 6 : #

Total comments: 36

Patch Set 7 : #

Patch Set 8 : #

Total comments: 9
Unified diffs Side-by-side diffs Delta from patch set Stats (+1221 lines, -1998 lines) Patch
M bin/builtin.cc View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M bin/builtin_natives.cc View 1 2 3 4 5 6 2 chunks +7 lines, -4 lines 0 comments Download
M bin/builtin_nolib.cc View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M bin/common.cc View 1 2 3 4 5 6 1 chunk +7 lines, -7 lines 0 comments Download
M bin/crypto.cc View 1 2 3 4 5 6 3 chunks +3 lines, -3 lines 0 comments Download
M bin/dartutils.h View 1 2 3 4 5 6 1 chunk +7 lines, -0 lines 0 comments Download
M bin/dartutils.cc View 1 2 3 4 5 6 13 chunks +34 lines, -33 lines 2 comments Download
M bin/dbg_message.cc View 1 2 3 4 5 6 3 chunks +5 lines, -5 lines 0 comments Download
M bin/directory.cc View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M bin/file.cc View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M bin/gen_snapshot.cc View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M bin/main.cc View 1 2 3 4 5 6 10 chunks +17 lines, -14 lines 0 comments Download
M bin/platform.cc View 1 2 3 4 5 6 3 chunks +5 lines, -4 lines 0 comments Download
M bin/socket.cc View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M bin/test_extension.cc View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M include/dart_api.h View 1 2 3 4 5 6 3 chunks +53 lines, -111 lines 3 comments Download
M lib/mirrors.cc View 1 2 3 4 5 6 7 25 chunks +34 lines, -29 lines 0 comments Download
M lib/string.cc View 1 2 3 4 5 6 2 chunks +14 lines, -15 lines 0 comments Download
M vm/benchmark_test.h View 1 2 3 4 5 6 1 chunk +5 lines, -0 lines 0 comments Download
M vm/benchmark_test.cc View 1 2 3 4 5 6 3 chunks +10 lines, -20 lines 0 comments Download
M vm/class_finalizer.cc View 1 2 3 4 5 6 2 chunks +0 lines, -6 lines 0 comments Download
M vm/custom_isolate_test.cc View 1 2 3 4 5 6 2 chunks +3 lines, -3 lines 0 comments Download
M vm/dart_api_impl.cc View 1 2 3 4 5 6 5 chunks +59 lines, -140 lines 0 comments Download
M vm/dart_api_impl_test.cc View 1 2 3 4 5 6 175 chunks +396 lines, -428 lines 0 comments Download
M vm/dart_api_message.cc View 1 2 3 4 5 6 1 chunk +0 lines, -3 lines 0 comments Download
M vm/debugger_api_impl_test.cc View 1 2 3 4 5 6 8 chunks +11 lines, -11 lines 0 comments Download
M vm/exceptions_test.cc View 1 2 3 4 5 6 3 chunks +5 lines, -5 lines 0 comments Download
M vm/flow_graph_compiler.cc View 1 2 3 4 5 6 1 chunk +0 lines, -2 lines 0 comments Download
M vm/heap_profiler.cc View 1 2 3 4 5 6 3 chunks +3 lines, -16 lines 0 comments Download
M vm/heap_test.cc View 1 2 3 4 5 6 2 chunks +2 lines, -6 lines 0 comments Download
M vm/isolate_test.cc View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download
M vm/object.h View 1 2 3 4 5 6 6 chunks +32 lines, -130 lines 0 comments Download
M vm/object.cc View 1 2 3 4 5 6 24 chunks +122 lines, -360 lines 4 comments Download
M vm/object_store.h View 1 2 3 4 5 6 3 chunks +0 lines, -14 lines 0 comments Download
M vm/object_store.cc View 1 2 3 4 5 6 1 chunk +0 lines, -2 lines 0 comments Download
M vm/object_test.cc View 1 2 3 4 5 6 29 chunks +84 lines, -296 lines 0 comments Download
M vm/raw_object.h View 1 2 3 4 5 6 9 chunks +23 lines, -42 lines 0 comments Download
M vm/raw_object.cc View 1 2 3 4 5 6 3 chunks +0 lines, -24 lines 0 comments Download
M vm/raw_object_snapshot.cc View 1 2 3 4 5 6 4 chunks +0 lines, -70 lines 0 comments Download
M vm/snapshot.h View 1 2 3 4 5 6 2 chunks +0 lines, -2 lines 0 comments Download
M vm/snapshot.cc View 1 2 3 4 5 6 1 chunk +0 lines, -7 lines 0 comments Download
M vm/snapshot_test.cc View 1 2 3 4 5 6 8 chunks +16 lines, -16 lines 0 comments Download
M vm/stack_frame_test.cc View 1 2 3 4 5 6 2 chunks +4 lines, -4 lines 0 comments Download
M vm/symbols.h View 1 2 3 4 5 6 1 chunk +0 lines, -2 lines 0 comments Download
M vm/symbols.cc View 1 2 3 4 5 6 1 chunk +11 lines, -11 lines 0 comments Download
M vm/unicode.h View 1 2 3 4 5 6 2 chunks +39 lines, -6 lines 0 comments Download
M vm/unicode.cc View 1 2 3 4 5 6 7 6 chunks +102 lines, -45 lines 0 comments Download
M vm/unicode_test.cc View 1 2 3 4 5 6 85 chunks +86 lines, -85 lines 0 comments Download
M vm/unit_test.h View 1 2 3 4 5 6 1 chunk +5 lines, -0 lines 0 comments Download
M vm/unit_test.cc View 1 2 3 4 5 6 3 chunks +4 lines, -4 lines 0 comments Download

Messages

Total messages: 9 (0 generated)
siva
8 years, 2 months ago (2012-10-24 23:01:38 UTC) #1
cshapiro
lgtm with comments I noticed you changed StringTo to StringAs which is something I was ...
8 years, 2 months ago (2012-10-24 23:52:29 UTC) #2
Anton Muhin
https://chromiumcodereview.appspot.com/11275008/diff/3011/include/dart_api.h File include/dart_api.h (left): https://chromiumcodereview.appspot.com/11275008/diff/3011/include/dart_api.h#oldcode1329 include/dart_api.h:1329: DART_EXPORT bool Dart_IsString8(Dart_Handle object); Internally, are all the strings ...
8 years, 1 month ago (2012-10-25 13:35:47 UTC) #3
Tom Ball
lgtm
8 years, 1 month ago (2012-10-25 21:29:43 UTC) #4
siva
- Addressed review comments. - retained names Dart_StringToCString, DartStringToUTF8 and Dart_StringToUTF16 This change triggers some ...
8 years, 1 month ago (2012-10-26 21:38:29 UTC) #5
Anton Muhin
https://chromiumcodereview.appspot.com/11275008/diff/29006/bin/dartutils.cc File bin/dartutils.cc (right): https://chromiumcodereview.appspot.com/11275008/diff/29006/bin/dartutils.cc#newcode216 bin/dartutils.cc:216: delete file; shouldn't you deallocate text_buffer here too? https://chromiumcodereview.appspot.com/11275008/diff/29006/include/dart_api.h ...
8 years, 1 month ago (2012-10-29 16:05:45 UTC) #6
siva
https://chromiumcodereview.appspot.com/11275008/diff/29006/bin/dartutils.cc File bin/dartutils.cc (right): https://chromiumcodereview.appspot.com/11275008/diff/29006/bin/dartutils.cc#newcode216 bin/dartutils.cc:216: delete file; On 2012/10/29 16:05:46, Anton Muhin wrote: > ...
8 years, 1 month ago (2012-10-30 00:33:34 UTC) #7
Anton Muhin
lgtm https://chromiumcodereview.appspot.com/11275008/diff/29006/include/dart_api.h File include/dart_api.h (right): https://chromiumcodereview.appspot.com/11275008/diff/29006/include/dart_api.h#newcode1475 include/dart_api.h:1475: DART_EXPORT Dart_Handle Dart_StringToUTF16(Dart_Handle str, Dart_IsAscii is all I ...
8 years, 1 month ago (2012-10-30 08:40:44 UTC) #8
Anton Muhin
8 years, 1 month ago (2012-11-12 13:28:13 UTC) #9
Is it obsolete now?

Powered by Google App Engine
This is Rietveld 408576698