move VM-bound data into VMInstance from context

Signed-off-by: seonghyun kim <sh8281.kim@samsung.com>
This commit is contained in:
seonghyun kim 2017-03-23 16:13:06 +09:00
commit 34dad07c79
12 changed files with 352 additions and 299 deletions

View file

@ -17,6 +17,7 @@
#include "Escargot.h"
#include "ArrayObject.h"
#include "Context.h"
#include "VMInstance.h"
namespace Escargot {
@ -29,7 +30,7 @@ ArrayObject::ArrayObject(ExecutionState& state)
m_values[ESCARGOT_OBJECT_BUILTIN_PROPERTY_NUMBER] = Value(0);
setPrototype(state, state.context()->globalObject()->arrayPrototype());
if (UNLIKELY(state.context()->didSomePrototypeObjectDefineIndexedProperty())) {
if (UNLIKELY(state.context()->vmInstance()->didSomePrototypeObjectDefineIndexedProperty())) {
ensureObjectRareData()->m_isFastModeArrayObject = false;
}
}