Index: src/regexp/regexp-utils.cc |
diff --git a/src/regexp/regexp-utils.cc b/src/regexp/regexp-utils.cc |
index d40431866a391388b4e8ebfbbbe75e529e6bb2c5..f6ef076f2c38b781f58d4589e94801ce64130562 100644 |
--- a/src/regexp/regexp-utils.cc |
+++ b/src/regexp/regexp-utils.cc |
@@ -174,7 +174,8 @@ |
ASSIGN_RETURN_ON_EXCEPTION(isolate, last_index_obj, |
Object::ToLength(isolate, last_index_obj), Object); |
- const int last_index = PositiveNumberToUint32(*last_index_obj); |
+ |
+ const int last_index = Handle<Smi>::cast(last_index_obj)->value(); |
const int new_last_index = |
AdvanceStringIndex(isolate, string, last_index, unicode); |