Lines Matching defs:regexp
373 THROW_TYPE_ERROR_AND_RETURN(thread, "is regexp", JSTaggedValue::Exception());
419 THROW_TYPE_ERROR_AND_RETURN(thread, "is regexp", JSTaggedValue::Exception());
610 JSHandle<JSTaggedValue> regexp = BuiltinsString::GetCallArg(argv, 0);
611 if (thisTag->IsString() && regexp->IsECMAObject()) {
612 if (BuiltinsRegExp::IsFastRegExp(thread, regexp, BuiltinsRegExp::RegExpSymbol::MATCH)) {
613 return BuiltinsRegExp::RegExpMatch(thread, regexp, thisTag, true);
619 if (!regexp->IsUndefined() && !regexp->IsNull()) {
620 JSHandle<JSTaggedValue> matcher = JSObject::GetMethod(thread, regexp, matchTag);
625 EcmaInterpreter::NewRuntimeCallInfo(thread, matcher, regexp, undefined, 1);
634 JSHandle<JSTaggedValue> rx(thread, BuiltinsRegExp::RegExpCreate(thread, regexp, undifinedHandle));
652 JSHandle<JSTaggedValue> regexp = BuiltinsString::GetCallArg(argv, 0);
658 // 2. If regexp is neither undefined nor null, then
659 if (!regexp->IsUndefined() && !regexp->IsNull()) {
661 if (regexp->IsECMAObject() &&
662 BuiltinsRegExp::IsFastRegExp(thread, regexp, BuiltinsRegExp::RegExpSymbol::MATCH)) {
663 bool isGlobal = BuiltinsRegExp::GetOriginalFlag(thread, regexp, RegExpParser::FLAG_GLOBAL);
669 } else if (JSObject::IsRegExp(thread, regexp)) {
672 JSHandle<JSTaggedValue> flags = JSObject::GetProperty(thread, regexp, flagsString).GetValue();
690 if (thisTag->IsString() && regexp->IsECMAObject()) {
692 BuiltinsRegExp::IsFastRegExp(thread, regexp, BuiltinsRegExp::RegExpSymbol::MATCHALL)) {
694 return BuiltinsRegExp::RegExpMatchAll(thread, regexp, string, true);
697 // c. Let matcher be ? GetMethod(regexp, @@matchAll).
700 (regexp->IsString() || regexp->IsNumber()));
702 JSHandle<JSTaggedValue> matcher = JSObject::GetMethod(thread, regexp, matchAllTag);
705 // i. Return ? Call(matcher, regexp, « O »).
707 EcmaInterpreter::NewRuntimeCallInfo(thread, matcher, regexp, undefined, 1);
717 // 4. Let rx be ? RegExpCreate(regexp, "g").
719 thread, regexp, JSHandle<JSTaggedValue>(ecmaVm->GetFactory()->NewFromASCII("g"))));
1503 JSHandle<JSTaggedValue> regexp = BuiltinsString::GetCallArg(argv, 0);
1504 if (thisTag->IsString() && regexp->IsECMAObject()) {
1505 if (BuiltinsRegExp::IsFastRegExp(thread, regexp, BuiltinsRegExp::RegExpSymbol::SEARCH)) {
1506 return BuiltinsRegExp::RegExpSearchFast(thread, regexp, thisTag);
1511 if (!regexp->IsUndefined() && !regexp->IsNull()) {
1512 JSHandle<JSTaggedValue> searcher = JSObject::GetMethod(thread, regexp, searchTag);
1517 EcmaInterpreter::NewRuntimeCallInfo(thread, searcher, regexp, undefined, 1);
1525 JSHandle<JSTaggedValue> rx(thread, BuiltinsRegExp::RegExpCreate(thread, regexp, undefined));
1593 // this condition need change, all regexp should use RegExpSplit
1813 THROW_TYPE_ERROR_AND_RETURN(thread, "is regexp", JSTaggedValue::Exception());