Pass const primitive values by value rather than reference (#115)

Signed-off-by: Daniella Barsony bella@inf.u-szeged.hu
This commit is contained in:
Daniella Barsony 2019-03-18 07:00:31 +01:00 committed by yichoi
commit 4afdf61b2b
21 changed files with 131 additions and 131 deletions

View file

@ -264,7 +264,7 @@ void ArrayObject::convertIntoNonFastMode(ExecutionState& state)
m_fastModeData.clear();
}
bool ArrayObject::setArrayLength(ExecutionState& state, const uint64_t& newLength)
bool ArrayObject::setArrayLength(ExecutionState& state, const uint64_t newLength)
{
if (UNLIKELY(isFastModeArray() && (newLength > ESCARGOT_ARRAY_NON_FASTMODE_MIN_SIZE))) {
uint32_t orgLength = getArrayLength(state);