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

Unified Diff: src/runtime.cc

Issue 12440061: Improve SeqString::Truncate for latest allocated strings. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: renamed according to suggestion Created 7 years, 9 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 | « src/objects.cc ('k') | src/spaces.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime.cc
diff --git a/src/runtime.cc b/src/runtime.cc
index b14cdbdfc3e5b2fa5bd5261bc36c4943da089f47..d240f4c785bf289c296e58202f4e3407279f29c4 100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -5137,10 +5137,10 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_NewString) {
RUNTIME_FUNCTION(MaybeObject*, Runtime_TruncateString) {
- NoHandleAllocation ha(isolate);
- CONVERT_ARG_CHECKED(SeqString, string, 0);
+ HandleScope scope(isolate);
+ CONVERT_ARG_HANDLE_CHECKED(SeqString, string, 0);
CONVERT_SMI_ARG_CHECKED(new_length, 1);
- return string->Truncate(new_length);
+ return *SeqString::Truncate(string, new_length);
}
« no previous file with comments | « src/objects.cc ('k') | src/spaces.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698