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

Unified Diff: src/factory.cc

Issue 223593004: Revert "Return MaybeHandle from NewConsString." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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/factory.h ('k') | src/func-name-inferrer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/factory.cc
diff --git a/src/factory.cc b/src/factory.cc
index 20dd19db9a4c17f34f0759f3239056d6bc7e1bb5..9fa1e12abe19253aad57c1e743863fd30ceac259 100644
--- a/src/factory.cc
+++ b/src/factory.cc
@@ -334,8 +334,8 @@ Handle<ConsString> Factory::NewRawConsString(String::Encoding encoding) {
}
-MaybeHandle<String> Factory::NewConsString(Handle<String> left,
- Handle<String> right) {
+Handle<String> Factory::NewConsString(Handle<String> left,
+ Handle<String> right) {
int left_length = left->length();
if (left_length == 0) return right;
int right_length = right->length();
@@ -352,8 +352,8 @@ MaybeHandle<String> Factory::NewConsString(Handle<String> left,
// Make sure that an out of memory exception is thrown if the length
// of the new cons string is too large.
if (length > String::kMaxLength || length < 0) {
- return isolate()->Throw<String>(
- isolate()->factory()->NewInvalidStringLengthError());
+ isolate()->ThrowInvalidStringLength();
+ return Handle<String>::null();
}
bool left_is_one_byte = left->IsOneByteRepresentation();
« no previous file with comments | « src/factory.h ('k') | src/func-name-inferrer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698