diff options
Diffstat (limited to 'Source/JavaScriptCore/runtime/RegExpObject.cpp')
-rw-r--r-- | Source/JavaScriptCore/runtime/RegExpObject.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/Source/JavaScriptCore/runtime/RegExpObject.cpp b/Source/JavaScriptCore/runtime/RegExpObject.cpp index 00dd1ed74..8b2d03c02 100644 --- a/Source/JavaScriptCore/runtime/RegExpObject.cpp +++ b/Source/JavaScriptCore/runtime/RegExpObject.cpp @@ -30,6 +30,7 @@ #include "JSString.h" #include "Lexer.h" #include "Lookup.h" +#include "Operations.h" #include "RegExpConstructor.h" #include "RegExpMatchesArray.h" #include "RegExpPrototype.h" @@ -63,8 +64,8 @@ const ClassInfo RegExpObject::s_info = { "RegExp", &Base::s_info, 0, ExecState:: */ RegExpObject::RegExpObject(JSGlobalObject* globalObject, Structure* structure, RegExp* regExp) - : JSNonFinalObject(globalObject->globalData(), structure) - , m_regExp(globalObject->globalData(), this, regExp) + : JSNonFinalObject(globalObject->vm(), structure) + , m_regExp(globalObject->vm(), this, regExp) , m_lastIndexIsWritable(true) { m_lastIndex.setWithoutWriteBarrier(jsNumber(0)); @@ -72,7 +73,7 @@ RegExpObject::RegExpObject(JSGlobalObject* globalObject, Structure* structure, R void RegExpObject::finishCreation(JSGlobalObject* globalObject) { - Base::finishCreation(globalObject->globalData()); + Base::finishCreation(globalObject->vm()); ASSERT(inherits(&s_info)); } @@ -314,9 +315,9 @@ MatchResult RegExpObject::match(ExecState* exec, JSString* string) RegExp* regExp = this->regExp(); RegExpConstructor* regExpConstructor = exec->lexicalGlobalObject()->regExpConstructor(); String input = string->value(exec); - JSGlobalData& globalData = exec->globalData(); + VM& vm = exec->vm(); if (!regExp->global()) - return regExpConstructor->performMatch(globalData, regExp, string, input, 0); + return regExpConstructor->performMatch(vm, regExp, string, input, 0); JSValue jsLastIndex = getLastIndex(); unsigned lastIndex; @@ -335,7 +336,7 @@ MatchResult RegExpObject::match(ExecState* exec, JSString* string) lastIndex = static_cast<unsigned>(doubleLastIndex); } - MatchResult result = regExpConstructor->performMatch(globalData, regExp, string, input, lastIndex); + MatchResult result = regExpConstructor->performMatch(vm, regExp, string, input, lastIndex); setLastIndex(exec, result.end); return result; } |