From a0d1e515158732f0a0a82ccd9a0f2a142c08e81b Mon Sep 17 00:00:00 2001 From: Andrey Efremov Date: Tue, 12 Sep 2023 15:12:04 +0300 Subject: [PATCH] Use PandaVector instead of std::vector in regexp_executor Signed-off-by: Andrey Efremov --- runtime/regexp/regexp_executor.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/regexp/regexp_executor.cpp b/runtime/regexp/regexp_executor.cpp index 5e1d4f28e..87b5f70a9 100644 --- a/runtime/regexp/regexp_executor.cpp +++ b/runtime/regexp/regexp_executor.cpp @@ -25,7 +25,7 @@ RegExpMatchResult> RegExpExecutor::GetResult(const JSThread { ObjectFactory *factory = thread->GetEcmaVM()->GetFactory(); RegExpMatchResult> result; - std::vector>> captures; + PandaVector>> captures; result.is_success = is_success; if (is_success) { for (uint32_t i = 0; i < GetCaptureCount(); i++) { @@ -63,7 +63,7 @@ RegExpMatchResult> RegExpExecutor::GetResult(const JSThread } captures.emplace_back(pair); } - result.captures = captures; + result.captures = std::move(captures); result.end_index = GetCurrentPtr() - GetInputPtr(); if (IsWideChar()) { result.end_index /= WIDE_CHAR_SIZE; -- Gitee