Index: src/runtime.cc |
diff --git a/src/runtime.cc b/src/runtime.cc |
index d8aaf718097616ae83cc35fa1e9d56121774ea48..ff0503718b5c93262a33eda9f7ab8d24a6d379a4 100644 |
--- a/src/runtime.cc |
+++ b/src/runtime.cc |
@@ -2713,7 +2713,7 @@ MUST_USE_RESULT static MaybeObject* StringReplaceRegExpWithEmptyString( |
end = RegExpImpl::GetCapture(match_info_array, 1); |
} |
- int length = subject->length(); |
+ int length = subject_handle->length(); |
int new_length = length - (end - start); |
if (new_length == 0) { |
return isolate->heap()->empty_string(); |