Changeset 40046 in webkit for trunk/JavaScriptCore/interpreter/Interpreter.cpp
- Timestamp:
- Jan 19, 2009, 4:54:18 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/interpreter/Interpreter.cpp
r39958 r40046 111 111 { 112 112 if (JSValuePtr::areBothInt32Fast(v1, v2)) 113 return v1 ->getInt32Fast() < v2->getInt32Fast();113 return v1.getInt32Fast() < v2.getInt32Fast(); 114 114 115 115 double n1; 116 116 double n2; 117 if (v1 ->getNumber(n1) && v2->getNumber(n2))117 if (v1.getNumber(n1) && v2.getNumber(n2)) 118 118 return n1 < n2; 119 119 … … 124 124 JSValuePtr p1; 125 125 JSValuePtr p2; 126 bool wasNotString1 = v1 ->getPrimitiveNumber(callFrame, n1, p1);127 bool wasNotString2 = v2 ->getPrimitiveNumber(callFrame, n2, p2);126 bool wasNotString1 = v1.getPrimitiveNumber(callFrame, n1, p1); 127 bool wasNotString2 = v2.getPrimitiveNumber(callFrame, n2, p2); 128 128 129 129 if (wasNotString1 | wasNotString2) … … 136 136 { 137 137 if (JSValuePtr::areBothInt32Fast(v1, v2)) 138 return v1 ->getInt32Fast() <= v2->getInt32Fast();138 return v1.getInt32Fast() <= v2.getInt32Fast(); 139 139 140 140 double n1; 141 141 double n2; 142 if (v1 ->getNumber(n1) && v2->getNumber(n2))142 if (v1.getNumber(n1) && v2.getNumber(n2)) 143 143 return n1 <= n2; 144 144 … … 149 149 JSValuePtr p1; 150 150 JSValuePtr p2; 151 bool wasNotString1 = v1 ->getPrimitiveNumber(callFrame, n1, p1);152 bool wasNotString2 = v2 ->getPrimitiveNumber(callFrame, n2, p2);151 bool wasNotString1 = v1.getPrimitiveNumber(callFrame, n1, p1); 152 bool wasNotString2 = v2.getPrimitiveNumber(callFrame, n2, p2); 153 153 154 154 if (wasNotString1 | wasNotString2) … … 161 161 { 162 162 // exception for the Date exception in defaultValue() 163 JSValuePtr p1 = v1 ->toPrimitive(callFrame);164 JSValuePtr p2 = v2 ->toPrimitive(callFrame);165 166 if (p1 ->isString() || p2->isString()) {167 RefPtr<UString::Rep> value = concatenate(p1 ->toString(callFrame).rep(), p2->toString(callFrame).rep());163 JSValuePtr p1 = v1.toPrimitive(callFrame); 164 JSValuePtr p2 = v2.toPrimitive(callFrame); 165 166 if (p1.isString() || p2.isString()) { 167 RefPtr<UString::Rep> value = concatenate(p1.toString(callFrame).rep(), p2.toString(callFrame).rep()); 168 168 if (!value) 169 169 return throwOutOfMemoryError(callFrame); … … 171 171 } 172 172 173 return jsNumber(callFrame, p1 ->toNumber(callFrame) + p2->toNumber(callFrame));173 return jsNumber(callFrame, p1.toNumber(callFrame) + p2.toNumber(callFrame)); 174 174 } 175 175 … … 188 188 double right = 0.0; 189 189 190 bool rightIsNumber = v2 ->getNumber(right);191 if (rightIsNumber && v1 ->getNumber(left))190 bool rightIsNumber = v2.getNumber(right); 191 if (rightIsNumber && v1.getNumber(left)) 192 192 return jsNumber(callFrame, left + right); 193 193 194 bool leftIsString = v1 ->isString();195 if (leftIsString && v2 ->isString()) {194 bool leftIsString = v1.isString(); 195 if (leftIsString && v2.isString()) { 196 196 RefPtr<UString::Rep> value = concatenate(asString(v1)->value().rep(), asString(v2)->value().rep()); 197 197 if (!value) … … 201 201 202 202 if (rightIsNumber & leftIsString) { 203 RefPtr<UString::Rep> value = v2 ->isInt32Fast() ?204 concatenate(asString(v1)->value().rep(), v2 ->getInt32Fast()) :203 RefPtr<UString::Rep> value = v2.isInt32Fast() ? 204 concatenate(asString(v1)->value().rep(), v2.getInt32Fast()) : 205 205 concatenate(asString(v1)->value().rep(), right); 206 206 … … 216 216 static JSValuePtr jsTypeStringForValue(CallFrame* callFrame, JSValuePtr v) 217 217 { 218 if (v ->isUndefined())218 if (v.isUndefined()) 219 219 return jsNontrivialString(callFrame, "undefined"); 220 if (v ->isBoolean())220 if (v.isBoolean()) 221 221 return jsNontrivialString(callFrame, "boolean"); 222 if (v ->isNumber())222 if (v.isNumber()) 223 223 return jsNontrivialString(callFrame, "number"); 224 if (v ->isString())224 if (v.isString()) 225 225 return jsNontrivialString(callFrame, "string"); 226 if (v ->isObject()) {226 if (v.isObject()) { 227 227 // Return "undefined" for objects that should be treated 228 228 // as null when doing comparisons. … … 238 238 static bool jsIsObjectType(JSValuePtr v) 239 239 { 240 if (!v ->isCell())241 return v ->isNull();240 if (!v.isCell()) 241 return v.isNull(); 242 242 243 243 JSType type = asCell(v)->structure()->typeInfo().type(); … … 256 256 static bool jsIsFunctionType(JSValuePtr v) 257 257 { 258 if (v ->isObject()) {258 if (v.isObject()) { 259 259 CallData callData; 260 260 if (asObject(v)->getCallData(callData) != CallTypeNone) … … 515 515 static NEVER_INLINE bool isNotObject(CallFrame* callFrame, bool forInstanceOf, CodeBlock* codeBlock, const Instruction* vPC, JSValuePtr value, JSValuePtr& exceptionData) 516 516 { 517 if (value ->isObject())517 if (value.isObject()) 518 518 return false; 519 519 exceptionData = createInvalidParamError(callFrame, forInstanceOf ? "instanceof" : "in" , value, vPC - codeBlock->instructions().begin(), codeBlock); … … 528 528 JSValuePtr program = argv[1].jsValue(callFrame); 529 529 530 if (!program ->isString())530 if (!program.isString()) 531 531 return program; 532 532 … … 539 539 JSValuePtr result = jsUndefined(); 540 540 if (evalNode) 541 result = callFrame->globalData().interpreter->execute(evalNode.get(), callFrame, callFrame->thisValue() ->toThisObject(callFrame), callFrame->registers() - registerFile->start() + registerOffset, scopeChain, &exceptionValue);541 result = callFrame->globalData().interpreter->execute(evalNode.get(), callFrame, callFrame->thisValue().toThisObject(callFrame), callFrame->registers() - registerFile->start() + registerOffset, scopeChain, &exceptionValue); 542 542 543 543 return result; … … 743 743 744 744 CodeBlock* codeBlock = callFrame->codeBlock(); 745 if (exceptionValue ->isObject()) {745 if (exceptionValue.isObject()) { 746 746 JSObject* exception = asObject(exceptionValue); 747 747 if (exception->isNotAnObjectErrorStub()) { … … 1168 1168 { 1169 1169 JSValuePtr prototype = structure->prototypeForLookup(callFrame); 1170 if (!prototype ->isCell())1170 if (!prototype.isCell()) 1171 1171 return 0; 1172 1172 RefPtr<StructureChain> chain = StructureChain::create(asObject(prototype)->structure()); … … 1181 1181 return; 1182 1182 1183 if (!baseValue ->isCell())1183 if (!baseValue.isCell()) 1184 1184 return; 1185 1185 … … 1263 1263 // must be a proxy for another object. 1264 1264 1265 if (v ->isNull())1265 if (v.isNull()) 1266 1266 return 0; 1267 1267 … … 1290 1290 1291 1291 // FIXME: Cache property access for immediates. 1292 if (!baseValue ->isCell()) {1292 if (!baseValue.isCell()) { 1293 1293 vPC[0] = getOpcode(op_get_by_id_generic); 1294 1294 return; … … 1343 1343 1344 1344 if (slot.slotBase() == structure->prototypeForLookup(callFrame)) { 1345 ASSERT(slot.slotBase() ->isObject());1345 ASSERT(slot.slotBase().isObject()); 1346 1346 1347 1347 JSObject* baseObject = asObject(slot.slotBase()); … … 1554 1554 JSValuePtr src = callFrame[(++vPC)->u.operand].jsValue(callFrame); 1555 1555 1556 if (src ->isUndefinedOrNull()) {1556 if (src.isUndefinedOrNull()) { 1557 1557 callFrame[dst] = jsBoolean(true); 1558 1558 ++vPC; … … 1560 1560 } 1561 1561 1562 callFrame[dst] = jsBoolean(src ->isCell() && src->asCell()->structure()->typeInfo().masqueradesAsUndefined());1562 callFrame[dst] = jsBoolean(src.isCell() && src.asCell()->structure()->typeInfo().masqueradesAsUndefined()); 1563 1563 ++vPC; 1564 1564 NEXT_INSTRUCTION(); … … 1594 1594 JSValuePtr src = callFrame[(++vPC)->u.operand].jsValue(callFrame); 1595 1595 1596 if (src ->isUndefinedOrNull()) {1596 if (src.isUndefinedOrNull()) { 1597 1597 callFrame[dst] = jsBoolean(false); 1598 1598 ++vPC; … … 1600 1600 } 1601 1601 1602 callFrame[dst] = jsBoolean(!src ->isCell() || !asCell(src)->structure()->typeInfo().masqueradesAsUndefined());1602 callFrame[dst] = jsBoolean(!src.isCell() || !asCell(src)->structure()->typeInfo().masqueradesAsUndefined()); 1603 1603 ++vPC; 1604 1604 NEXT_INSTRUCTION(); … … 1679 1679 callFrame[srcDst] = JSValuePtr(JSFastMath::incImmediateNumber(v)); 1680 1680 else { 1681 JSValuePtr result = jsNumber(callFrame, v ->toNumber(callFrame) + 1);1681 JSValuePtr result = jsNumber(callFrame, v.toNumber(callFrame) + 1); 1682 1682 CHECK_FOR_EXCEPTION(); 1683 1683 callFrame[srcDst] = result; … … 1698 1698 callFrame[srcDst] = JSValuePtr(JSFastMath::decImmediateNumber(v)); 1699 1699 else { 1700 JSValuePtr result = jsNumber(callFrame, v ->toNumber(callFrame) - 1);1700 JSValuePtr result = jsNumber(callFrame, v.toNumber(callFrame) - 1); 1701 1701 CHECK_FOR_EXCEPTION(); 1702 1702 callFrame[srcDst] = result; … … 1720 1720 callFrame[srcDst] = JSValuePtr(JSFastMath::incImmediateNumber(v)); 1721 1721 } else { 1722 JSValuePtr number = callFrame[srcDst].jsValue(callFrame) ->toJSNumber(callFrame);1722 JSValuePtr number = callFrame[srcDst].jsValue(callFrame).toJSNumber(callFrame); 1723 1723 CHECK_FOR_EXCEPTION(); 1724 1724 callFrame[dst] = number; 1725 callFrame[srcDst] = JSValuePtr(jsNumber(callFrame, number ->uncheckedGetNumber() + 1));1725 callFrame[srcDst] = JSValuePtr(jsNumber(callFrame, number.uncheckedGetNumber() + 1)); 1726 1726 } 1727 1727 … … 1743 1743 callFrame[srcDst] = JSValuePtr(JSFastMath::decImmediateNumber(v)); 1744 1744 } else { 1745 JSValuePtr number = callFrame[srcDst].jsValue(callFrame) ->toJSNumber(callFrame);1745 JSValuePtr number = callFrame[srcDst].jsValue(callFrame).toJSNumber(callFrame); 1746 1746 CHECK_FOR_EXCEPTION(); 1747 1747 callFrame[dst] = number; 1748 callFrame[srcDst] = JSValuePtr(jsNumber(callFrame, number ->uncheckedGetNumber() - 1));1748 callFrame[srcDst] = JSValuePtr(jsNumber(callFrame, number.uncheckedGetNumber() - 1)); 1749 1749 } 1750 1750 … … 1763 1763 JSValuePtr srcVal = callFrame[src].jsValue(callFrame); 1764 1764 1765 if (LIKELY(srcVal ->isNumber()))1765 if (LIKELY(srcVal.isNumber())) 1766 1766 callFrame[dst] = callFrame[src]; 1767 1767 else { 1768 JSValuePtr result = srcVal ->toJSNumber(callFrame);1768 JSValuePtr result = srcVal.toJSNumber(callFrame); 1769 1769 CHECK_FOR_EXCEPTION(); 1770 1770 callFrame[dst] = result; … … 1784 1784 ++vPC; 1785 1785 double v; 1786 if (src ->getNumber(v))1786 if (src.getNumber(v)) 1787 1787 callFrame[dst] = JSValuePtr(jsNumber(callFrame, -v)); 1788 1788 else { 1789 JSValuePtr result = jsNumber(callFrame, -src ->toNumber(callFrame));1789 JSValuePtr result = jsNumber(callFrame, -src.toNumber(callFrame)); 1790 1790 CHECK_FOR_EXCEPTION(); 1791 1791 callFrame[dst] = result; … … 1826 1826 double right; 1827 1827 if (JSValuePtr::areBothInt32Fast(src1, src2)) { 1828 int32_t left = src1 ->getInt32Fast();1829 int32_t right = src2 ->getInt32Fast();1828 int32_t left = src1.getInt32Fast(); 1829 int32_t right = src2.getInt32Fast(); 1830 1830 if ((left | right) >> 15 == 0) 1831 1831 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left * right)); 1832 1832 else 1833 1833 callFrame[dst] = JSValuePtr(jsNumber(callFrame, static_cast<double>(left) * static_cast<double>(right))); 1834 } else if (src1 ->getNumber(left) && src2->getNumber(right))1834 } else if (src1.getNumber(left) && src2.getNumber(right)) 1835 1835 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left * right)); 1836 1836 else { 1837 JSValuePtr result = jsNumber(callFrame, src1 ->toNumber(callFrame) * src2->toNumber(callFrame));1837 JSValuePtr result = jsNumber(callFrame, src1.toNumber(callFrame) * src2.toNumber(callFrame)); 1838 1838 CHECK_FOR_EXCEPTION(); 1839 1839 callFrame[dst] = result; … … 1855 1855 double left; 1856 1856 double right; 1857 if (dividend ->getNumber(left) && divisor->getNumber(right))1857 if (dividend.getNumber(left) && divisor.getNumber(right)) 1858 1858 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left / right)); 1859 1859 else { 1860 JSValuePtr result = jsNumber(callFrame, dividend ->toNumber(callFrame) / divisor->toNumber(callFrame));1860 JSValuePtr result = jsNumber(callFrame, dividend.toNumber(callFrame) / divisor.toNumber(callFrame)); 1861 1861 CHECK_FOR_EXCEPTION(); 1862 1862 callFrame[dst] = result; … … 1882 1882 // We expect the result of the modulus of a number that was representable as an int32 to also be representable 1883 1883 // as an int32. 1884 JSValuePtr result = JSValuePtr::makeInt32Fast(dividendValue ->getInt32Fast() % divisorValue->getInt32Fast());1884 JSValuePtr result = JSValuePtr::makeInt32Fast(dividendValue.getInt32Fast() % divisorValue.getInt32Fast()); 1885 1885 ASSERT(result); 1886 1886 callFrame[dst] = result; … … 1889 1889 } 1890 1890 1891 double d = dividendValue ->toNumber(callFrame);1892 JSValuePtr result = jsNumber(callFrame, fmod(d, divisorValue ->toNumber(callFrame)));1891 double d = dividendValue.toNumber(callFrame); 1892 JSValuePtr result = jsNumber(callFrame, fmod(d, divisorValue.toNumber(callFrame))); 1893 1893 CHECK_FOR_EXCEPTION(); 1894 1894 callFrame[dst] = result; … … 1910 1910 if (JSFastMath::canDoFastAdditiveOperations(src1, src2)) 1911 1911 callFrame[dst] = JSValuePtr(JSFastMath::subImmediateNumbers(src1, src2)); 1912 else if (src1 ->getNumber(left) && src2->getNumber(right))1912 else if (src1.getNumber(left) && src2.getNumber(right)) 1913 1913 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left - right)); 1914 1914 else { 1915 JSValuePtr result = jsNumber(callFrame, src1 ->toNumber(callFrame) - src2->toNumber(callFrame));1915 JSValuePtr result = jsNumber(callFrame, src1.toNumber(callFrame) - src2.toNumber(callFrame)); 1916 1916 CHECK_FOR_EXCEPTION(); 1917 1917 callFrame[dst] = result; … … 1933 1933 uint32_t right; 1934 1934 if (JSValuePtr::areBothInt32Fast(val, shift)) 1935 callFrame[dst] = JSValuePtr(jsNumber(callFrame, val ->getInt32Fast() << (shift->getInt32Fast() & 0x1f)));1936 else if (val ->numberToInt32(left) && shift->numberToUInt32(right))1935 callFrame[dst] = JSValuePtr(jsNumber(callFrame, val.getInt32Fast() << (shift.getInt32Fast() & 0x1f))); 1936 else if (val.numberToInt32(left) && shift.numberToUInt32(right)) 1937 1937 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left << (right & 0x1f))); 1938 1938 else { 1939 JSValuePtr result = jsNumber(callFrame, (val ->toInt32(callFrame)) << (shift->toUInt32(callFrame) & 0x1f));1939 JSValuePtr result = jsNumber(callFrame, (val.toInt32(callFrame)) << (shift.toUInt32(callFrame) & 0x1f)); 1940 1940 CHECK_FOR_EXCEPTION(); 1941 1941 callFrame[dst] = result; … … 1959 1959 if (JSFastMath::canDoFastRshift(val, shift)) 1960 1960 callFrame[dst] = JSValuePtr(JSFastMath::rightShiftImmediateNumbers(val, shift)); 1961 else if (val ->numberToInt32(left) && shift->numberToUInt32(right))1961 else if (val.numberToInt32(left) && shift.numberToUInt32(right)) 1962 1962 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left >> (right & 0x1f))); 1963 1963 else { 1964 JSValuePtr result = jsNumber(callFrame, (val ->toInt32(callFrame)) >> (shift->toUInt32(callFrame) & 0x1f));1964 JSValuePtr result = jsNumber(callFrame, (val.toInt32(callFrame)) >> (shift.toUInt32(callFrame) & 0x1f)); 1965 1965 CHECK_FOR_EXCEPTION(); 1966 1966 callFrame[dst] = result; … … 1983 1983 callFrame[dst] = JSValuePtr(JSFastMath::rightShiftImmediateNumbers(val, shift)); 1984 1984 else { 1985 JSValuePtr result = jsNumber(callFrame, (val ->toUInt32(callFrame)) >> (shift->toUInt32(callFrame) & 0x1f));1985 JSValuePtr result = jsNumber(callFrame, (val.toUInt32(callFrame)) >> (shift.toUInt32(callFrame) & 0x1f)); 1986 1986 CHECK_FOR_EXCEPTION(); 1987 1987 callFrame[dst] = result; … … 2005 2005 if (JSFastMath::canDoFastBitwiseOperations(src1, src2)) 2006 2006 callFrame[dst] = JSValuePtr(JSFastMath::andImmediateNumbers(src1, src2)); 2007 else if (src1 ->numberToInt32(left) && src2->numberToInt32(right))2007 else if (src1.numberToInt32(left) && src2.numberToInt32(right)) 2008 2008 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left & right)); 2009 2009 else { 2010 JSValuePtr result = jsNumber(callFrame, src1 ->toInt32(callFrame) & src2->toInt32(callFrame));2010 JSValuePtr result = jsNumber(callFrame, src1.toInt32(callFrame) & src2.toInt32(callFrame)); 2011 2011 CHECK_FOR_EXCEPTION(); 2012 2012 callFrame[dst] = result; … … 2030 2030 if (JSFastMath::canDoFastBitwiseOperations(src1, src2)) 2031 2031 callFrame[dst] = JSValuePtr(JSFastMath::xorImmediateNumbers(src1, src2)); 2032 else if (src1 ->numberToInt32(left) && src2->numberToInt32(right))2032 else if (src1.numberToInt32(left) && src2.numberToInt32(right)) 2033 2033 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left ^ right)); 2034 2034 else { 2035 JSValuePtr result = jsNumber(callFrame, src1 ->toInt32(callFrame) ^ src2->toInt32(callFrame));2035 JSValuePtr result = jsNumber(callFrame, src1.toInt32(callFrame) ^ src2.toInt32(callFrame)); 2036 2036 CHECK_FOR_EXCEPTION(); 2037 2037 callFrame[dst] = result; … … 2055 2055 if (JSFastMath::canDoFastBitwiseOperations(src1, src2)) 2056 2056 callFrame[dst] = JSValuePtr(JSFastMath::orImmediateNumbers(src1, src2)); 2057 else if (src1 ->numberToInt32(left) && src2->numberToInt32(right))2057 else if (src1.numberToInt32(left) && src2.numberToInt32(right)) 2058 2058 callFrame[dst] = JSValuePtr(jsNumber(callFrame, left | right)); 2059 2059 else { 2060 JSValuePtr result = jsNumber(callFrame, src1 ->toInt32(callFrame) | src2->toInt32(callFrame));2060 JSValuePtr result = jsNumber(callFrame, src1.toInt32(callFrame) | src2.toInt32(callFrame)); 2061 2061 CHECK_FOR_EXCEPTION(); 2062 2062 callFrame[dst] = result; … … 2075 2075 JSValuePtr src = callFrame[(++vPC)->u.operand].jsValue(callFrame); 2076 2076 int32_t value; 2077 if (src ->numberToInt32(value))2077 if (src.numberToInt32(value)) 2078 2078 callFrame[dst] = JSValuePtr(jsNumber(callFrame, ~value)); 2079 2079 else { 2080 JSValuePtr result = jsNumber(callFrame, ~src ->toInt32(callFrame));2080 JSValuePtr result = jsNumber(callFrame, ~src.toInt32(callFrame)); 2081 2081 CHECK_FOR_EXCEPTION(); 2082 2082 callFrame[dst] = result; … … 2093 2093 int dst = (++vPC)->u.operand; 2094 2094 int src = (++vPC)->u.operand; 2095 JSValuePtr result = jsBoolean(!callFrame[src].jsValue(callFrame) ->toBoolean(callFrame));2095 JSValuePtr result = jsBoolean(!callFrame[src].jsValue(callFrame).toBoolean(callFrame)); 2096 2096 CHECK_FOR_EXCEPTION(); 2097 2097 callFrame[dst] = result; … … 2152 2152 int src = (++vPC)->u.operand; 2153 2153 JSValuePtr v = callFrame[src].jsValue(callFrame); 2154 callFrame[dst] = jsBoolean(v ->isCell() ? v->asCell()->structure()->typeInfo().masqueradesAsUndefined() : v->isUndefined());2154 callFrame[dst] = jsBoolean(v.isCell() ? v.asCell()->structure()->typeInfo().masqueradesAsUndefined() : v.isUndefined()); 2155 2155 2156 2156 ++vPC; … … 2166 2166 int dst = (++vPC)->u.operand; 2167 2167 int src = (++vPC)->u.operand; 2168 callFrame[dst] = jsBoolean(callFrame[src].jsValue(callFrame) ->isBoolean());2168 callFrame[dst] = jsBoolean(callFrame[src].jsValue(callFrame).isBoolean()); 2169 2169 2170 2170 ++vPC; … … 2180 2180 int dst = (++vPC)->u.operand; 2181 2181 int src = (++vPC)->u.operand; 2182 callFrame[dst] = jsBoolean(callFrame[src].jsValue(callFrame) ->isNumber());2182 callFrame[dst] = jsBoolean(callFrame[src].jsValue(callFrame).isNumber()); 2183 2183 2184 2184 ++vPC; … … 2194 2194 int dst = (++vPC)->u.operand; 2195 2195 int src = (++vPC)->u.operand; 2196 callFrame[dst] = jsBoolean(callFrame[src].jsValue(callFrame) ->isString());2196 callFrame[dst] = jsBoolean(callFrame[src].jsValue(callFrame).isString()); 2197 2197 2198 2198 ++vPC; … … 2249 2249 2250 2250 uint32_t i; 2251 if (propName ->getUInt32(i))2251 if (propName.getUInt32(i)) 2252 2252 callFrame[dst] = jsBoolean(baseObj->hasProperty(callFrame, i)); 2253 2253 else { 2254 Identifier property(callFrame, propName ->toString(callFrame));2254 Identifier property(callFrame, propName.toString(callFrame)); 2255 2255 CHECK_FOR_EXCEPTION(); 2256 2256 callFrame[dst] = jsBoolean(baseObj->hasProperty(callFrame, property)); … … 2444 2444 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2445 2445 PropertySlot slot(baseValue); 2446 JSValuePtr result = baseValue ->get(callFrame, ident, slot);2446 JSValuePtr result = baseValue.get(callFrame, ident, slot); 2447 2447 CHECK_FOR_EXCEPTION(); 2448 2448 … … 2463 2463 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2464 2464 2465 if (LIKELY(baseValue ->isCell())) {2465 if (LIKELY(baseValue.isCell())) { 2466 2466 JSCell* baseCell = asCell(baseValue); 2467 2467 Structure* structure = vPC[4].u.structure; … … 2494 2494 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2495 2495 2496 if (LIKELY(baseValue ->isCell())) {2496 if (LIKELY(baseValue.isCell())) { 2497 2497 JSCell* baseCell = asCell(baseValue); 2498 2498 Structure* structure = vPC[4].u.structure; 2499 2499 2500 2500 if (LIKELY(baseCell->structure() == structure)) { 2501 ASSERT(structure->prototypeForLookup(callFrame) ->isObject());2501 ASSERT(structure->prototypeForLookup(callFrame).isObject()); 2502 2502 JSObject* protoObject = asObject(structure->prototypeForLookup(callFrame)); 2503 2503 Structure* prototypeStructure = vPC[5].u.structure; … … 2543 2543 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2544 2544 2545 if (LIKELY(baseValue ->isCell())) {2545 if (LIKELY(baseValue.isCell())) { 2546 2546 JSCell* baseCell = asCell(baseValue); 2547 2547 Structure* structure = vPC[4].u.structure; … … 2588 2588 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2589 2589 PropertySlot slot(baseValue); 2590 JSValuePtr result = baseValue ->get(callFrame, ident, slot);2590 JSValuePtr result = baseValue.get(callFrame, ident, slot); 2591 2591 CHECK_FOR_EXCEPTION(); 2592 2592 … … 2653 2653 Identifier& ident = codeBlock->identifier(property); 2654 2654 PutPropertySlot slot; 2655 baseValue ->put(callFrame, ident, callFrame[value].jsValue(callFrame), slot);2655 baseValue.put(callFrame, ident, callFrame[value].jsValue(callFrame), slot); 2656 2656 CHECK_FOR_EXCEPTION(); 2657 2657 … … 2675 2675 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2676 2676 2677 if (LIKELY(baseValue ->isCell())) {2677 if (LIKELY(baseValue.isCell())) { 2678 2678 JSCell* baseCell = asCell(baseValue); 2679 2679 Structure* oldStructure = vPC[4].u.structure; … … 2687 2687 2688 2688 JSValuePtr proto = baseObject->structure()->prototypeForLookup(callFrame); 2689 while (!proto ->isNull()) {2689 while (!proto.isNull()) { 2690 2690 if (UNLIKELY(asObject(proto)->structure() != (*it).get())) { 2691 2691 uncachePutByID(callFrame->codeBlock(), vPC); … … 2725 2725 JSValuePtr baseValue = callFrame[base].jsValue(callFrame); 2726 2726 2727 if (LIKELY(baseValue ->isCell())) {2727 if (LIKELY(baseValue.isCell())) { 2728 2728 JSCell* baseCell = asCell(baseValue); 2729 2729 Structure* structure = vPC[4].u.structure; … … 2762 2762 Identifier& ident = callFrame->codeBlock()->identifier(property); 2763 2763 PutPropertySlot slot; 2764 baseValue ->put(callFrame, ident, callFrame[value].jsValue(callFrame), slot);2764 baseValue.put(callFrame, ident, callFrame[value].jsValue(callFrame), slot); 2765 2765 CHECK_FOR_EXCEPTION(); 2766 2766 … … 2780 2780 int property = (++vPC)->u.operand; 2781 2781 2782 JSObject* baseObj = callFrame[base].jsValue(callFrame) ->toObject(callFrame);2782 JSObject* baseObj = callFrame[base].jsValue(callFrame).toObject(callFrame); 2783 2783 Identifier& ident = callFrame->codeBlock()->identifier(property); 2784 2784 JSValuePtr result = jsBoolean(baseObj->deleteProperty(callFrame, ident)); … … 2805 2805 JSValuePtr result; 2806 2806 2807 if (LIKELY(subscript ->isUInt32Fast())) {2808 uint32_t i = subscript ->getUInt32Fast();2807 if (LIKELY(subscript.isUInt32Fast())) { 2808 uint32_t i = subscript.getUInt32Fast(); 2809 2809 if (isJSArray(baseValue)) { 2810 2810 JSArray* jsArray = asArray(baseValue); … … 2818 2818 result = asByteArray(baseValue)->getIndex(callFrame, i); 2819 2819 else 2820 result = baseValue ->get(callFrame, i);2820 result = baseValue.get(callFrame, i); 2821 2821 } else { 2822 Identifier property(callFrame, subscript ->toString(callFrame));2823 result = baseValue ->get(callFrame, property);2822 Identifier property(callFrame, subscript.toString(callFrame)); 2823 result = baseValue.get(callFrame, property); 2824 2824 } 2825 2825 … … 2847 2847 JSValuePtr subscript = callFrame[property].jsValue(callFrame); 2848 2848 2849 if (LIKELY(subscript ->isUInt32Fast())) {2850 uint32_t i = subscript ->getUInt32Fast();2849 if (LIKELY(subscript.isUInt32Fast())) { 2850 uint32_t i = subscript.getUInt32Fast(); 2851 2851 if (isJSArray(baseValue)) { 2852 2852 JSArray* jsArray = asArray(baseValue); … … 2859 2859 double dValue = 0; 2860 2860 JSValuePtr jsValue = callFrame[value].jsValue(callFrame); 2861 if (jsValue ->isInt32Fast())2862 jsByteArray->setIndex(i, jsValue ->getInt32Fast());2863 else if (jsValue ->getNumber(dValue))2861 if (jsValue.isInt32Fast()) 2862 jsByteArray->setIndex(i, jsValue.getInt32Fast()); 2863 else if (jsValue.getNumber(dValue)) 2864 2864 jsByteArray->setIndex(i, dValue); 2865 2865 else 2866 baseValue ->put(callFrame, i, jsValue);2866 baseValue.put(callFrame, i, jsValue); 2867 2867 } else 2868 baseValue ->put(callFrame, i, callFrame[value].jsValue(callFrame));2868 baseValue.put(callFrame, i, callFrame[value].jsValue(callFrame)); 2869 2869 } else { 2870 Identifier property(callFrame, subscript ->toString(callFrame));2870 Identifier property(callFrame, subscript.toString(callFrame)); 2871 2871 if (!globalData->exception) { // Don't put to an object if toString threw an exception. 2872 2872 PutPropertySlot slot; 2873 baseValue ->put(callFrame, property, callFrame[value].jsValue(callFrame), slot);2873 baseValue.put(callFrame, property, callFrame[value].jsValue(callFrame), slot); 2874 2874 } 2875 2875 } … … 2891 2891 int property = (++vPC)->u.operand; 2892 2892 2893 JSObject* baseObj = callFrame[base].jsValue(callFrame) ->toObject(callFrame); // may throw2893 JSObject* baseObj = callFrame[base].jsValue(callFrame).toObject(callFrame); // may throw 2894 2894 2895 2895 JSValuePtr subscript = callFrame[property].jsValue(callFrame); 2896 2896 JSValuePtr result; 2897 2897 uint32_t i; 2898 if (subscript ->getUInt32(i))2898 if (subscript.getUInt32(i)) 2899 2899 result = jsBoolean(baseObj->deleteProperty(callFrame, i)); 2900 2900 else { 2901 2901 CHECK_FOR_EXCEPTION(); 2902 Identifier property(callFrame, subscript ->toString(callFrame));2902 Identifier property(callFrame, subscript.toString(callFrame)); 2903 2903 CHECK_FOR_EXCEPTION(); 2904 2904 result = jsBoolean(baseObj->deleteProperty(callFrame, property)); … … 2926 2926 int value = (++vPC)->u.operand; 2927 2927 2928 callFrame[base].jsValue(callFrame) ->put(callFrame, property, callFrame[value].jsValue(callFrame));2928 callFrame[base].jsValue(callFrame).put(callFrame, property, callFrame[value].jsValue(callFrame)); 2929 2929 2930 2930 ++vPC; … … 2973 2973 int cond = (++vPC)->u.operand; 2974 2974 int target = (++vPC)->u.operand; 2975 if (callFrame[cond].jsValue(callFrame) ->toBoolean(callFrame)) {2975 if (callFrame[cond].jsValue(callFrame).toBoolean(callFrame)) { 2976 2976 vPC += target; 2977 2977 CHECK_FOR_TIMEOUT(); … … 2990 2990 int cond = (++vPC)->u.operand; 2991 2991 int target = (++vPC)->u.operand; 2992 if (callFrame[cond].jsValue(callFrame) ->toBoolean(callFrame)) {2992 if (callFrame[cond].jsValue(callFrame).toBoolean(callFrame)) { 2993 2993 vPC += target; 2994 2994 NEXT_INSTRUCTION(); … … 3006 3006 int cond = (++vPC)->u.operand; 3007 3007 int target = (++vPC)->u.operand; 3008 if (!callFrame[cond].jsValue(callFrame) ->toBoolean(callFrame)) {3008 if (!callFrame[cond].jsValue(callFrame).toBoolean(callFrame)) { 3009 3009 vPC += target; 3010 3010 NEXT_INSTRUCTION(); … … 3024 3024 JSValuePtr srcValue = callFrame[src].jsValue(callFrame); 3025 3025 3026 if (srcValue ->isUndefinedOrNull() || (srcValue->isCell() && srcValue->asCell()->structure()->typeInfo().masqueradesAsUndefined())) {3026 if (srcValue.isUndefinedOrNull() || (srcValue.isCell() && srcValue.asCell()->structure()->typeInfo().masqueradesAsUndefined())) { 3027 3027 vPC += target; 3028 3028 NEXT_INSTRUCTION(); … … 3042 3042 JSValuePtr srcValue = callFrame[src].jsValue(callFrame); 3043 3043 3044 if (!srcValue ->isUndefinedOrNull() || (srcValue->isCell() && !srcValue->asCell()->structure()->typeInfo().masqueradesAsUndefined())) {3044 if (!srcValue.isUndefinedOrNull() || (srcValue.isCell() && !srcValue.asCell()->structure()->typeInfo().masqueradesAsUndefined())) { 3045 3045 vPC += target; 3046 3046 NEXT_INSTRUCTION(); … … 3139 3139 int defaultOffset = (++vPC)->u.operand; 3140 3140 JSValuePtr scrutinee = callFrame[(++vPC)->u.operand].jsValue(callFrame); 3141 if (scrutinee ->isInt32Fast())3142 vPC += callFrame->codeBlock()->immediateSwitchJumpTable(tableIndex).offsetForValue(scrutinee ->getInt32Fast(), defaultOffset);3141 if (scrutinee.isInt32Fast()) 3142 vPC += callFrame->codeBlock()->immediateSwitchJumpTable(tableIndex).offsetForValue(scrutinee.getInt32Fast(), defaultOffset); 3143 3143 else 3144 3144 vPC += defaultOffset; … … 3157 3157 int defaultOffset = (++vPC)->u.operand; 3158 3158 JSValuePtr scrutinee = callFrame[(++vPC)->u.operand].jsValue(callFrame); 3159 if (!scrutinee ->isString())3159 if (!scrutinee.isString()) 3160 3160 vPC += defaultOffset; 3161 3161 else { … … 3180 3180 int defaultOffset = (++vPC)->u.operand; 3181 3181 JSValuePtr scrutinee = callFrame[(++vPC)->u.operand].jsValue(callFrame); 3182 if (!scrutinee ->isString())3182 if (!scrutinee.isString()) 3183 3183 vPC += defaultOffset; 3184 3184 else … … 3275 3275 3276 3276 CallData callData; 3277 CallType callType = v ->getCallData(callData);3277 CallType callType = v.getCallData(callData); 3278 3278 3279 3279 if (callType == CallTypeJS) { … … 3468 3468 int thisRegister = (++vPC)->u.operand; 3469 3469 JSValuePtr thisVal = callFrame[thisRegister].getJSValue(); 3470 if (thisVal ->needsThisConversion())3471 callFrame[thisRegister] = JSValuePtr(thisVal ->toThisObject(callFrame));3470 if (thisVal.needsThisConversion()) 3471 callFrame[thisRegister] = JSValuePtr(thisVal.toThisObject(callFrame)); 3472 3472 3473 3473 ++vPC; … … 3517 3517 3518 3518 ConstructData constructData; 3519 ConstructType constructType = v ->getConstructData(constructData);3519 ConstructType constructType = v.getConstructData(constructData); 3520 3520 3521 3521 if (constructType == ConstructTypeJS) { … … 3526 3526 Structure* structure; 3527 3527 JSValuePtr prototype = callFrame[proto].jsValue(callFrame); 3528 if (prototype ->isObject())3528 if (prototype.isObject()) 3529 3529 structure = asObject(prototype)->inheritorID(); 3530 3530 else … … 3585 3585 3586 3586 int dst = vPC[1].u.operand;; 3587 if (LIKELY(callFrame[dst].jsValue(callFrame) ->isObject())) {3587 if (LIKELY(callFrame[dst].jsValue(callFrame).isObject())) { 3588 3588 vPC += 3; 3589 3589 NEXT_INSTRUCTION(); … … 3605 3605 int scope = (++vPC)->u.operand; 3606 3606 JSValuePtr v = callFrame[scope].jsValue(callFrame); 3607 JSObject* o = v ->toObject(callFrame);3607 JSObject* o = v.toObject(callFrame); 3608 3608 CHECK_FOR_EXCEPTION(); 3609 3609 … … 3765 3765 3766 3766 CodeBlock* codeBlock = callFrame->codeBlock(); 3767 callFrame[dst] = JSValuePtr(Error::create(callFrame, (ErrorType)type, codeBlock->unexpectedConstant(message) ->toString(callFrame), codeBlock->lineNumberForBytecodeOffset(callFrame, vPC - codeBlock->instructions().begin()), codeBlock->ownerNode()->sourceID(), codeBlock->ownerNode()->sourceURL()));3767 callFrame[dst] = JSValuePtr(Error::create(callFrame, (ErrorType)type, codeBlock->unexpectedConstant(message).toString(callFrame), codeBlock->lineNumberForBytecodeOffset(callFrame, vPC - codeBlock->instructions().begin()), codeBlock->ownerNode()->sourceID(), codeBlock->ownerNode()->sourceURL())); 3768 3768 3769 3769 ++vPC; … … 3800 3800 int function = (++vPC)->u.operand; 3801 3801 3802 ASSERT(callFrame[base].jsValue(callFrame) ->isObject());3802 ASSERT(callFrame[base].jsValue(callFrame).isObject()); 3803 3803 JSObject* baseObj = asObject(callFrame[base].jsValue(callFrame)); 3804 3804 Identifier& ident = callFrame->codeBlock()->identifier(property); 3805 ASSERT(callFrame[function].jsValue(callFrame) ->isObject());3805 ASSERT(callFrame[function].jsValue(callFrame).isObject()); 3806 3806 baseObj->defineGetter(callFrame, ident, asObject(callFrame[function].jsValue(callFrame))); 3807 3807 … … 3824 3824 int function = (++vPC)->u.operand; 3825 3825 3826 ASSERT(callFrame[base].jsValue(callFrame) ->isObject());3826 ASSERT(callFrame[base].jsValue(callFrame).isObject()); 3827 3827 JSObject* baseObj = asObject(callFrame[base].jsValue(callFrame)); 3828 3828 Identifier& ident = callFrame->codeBlock()->identifier(property); 3829 ASSERT(callFrame[function].jsValue(callFrame) ->isObject());3829 ASSERT(callFrame[function].jsValue(callFrame).isObject()); 3830 3830 baseObj->defineSetter(callFrame, ident, asObject(callFrame[function].jsValue(callFrame))); 3831 3831 … … 4005 4005 // The interpreter checks for recursion here; I do not believe this can occur in CTI. 4006 4006 4007 if (!baseValue ->isCell())4007 if (!baseValue.isCell()) 4008 4008 return; 4009 4009 … … 4064 4064 4065 4065 // FIXME: Cache property access for immediates. 4066 if (!baseValue ->isCell()) {4066 if (!baseValue.isCell()) { 4067 4067 ctiPatchCallByReturnAddress(returnAddress, reinterpret_cast<void*>(cti_op_get_by_id_generic)); 4068 4068 return; … … 4118 4118 4119 4119 if (slot.slotBase() == structure->prototypeForLookup(callFrame)) { 4120 ASSERT(slot.slotBase() ->isObject());4120 ASSERT(slot.slotBase().isObject()); 4121 4121 4122 4122 JSObject* slotBaseObject = asObject(slot.slotBase()); … … 4256 4256 CallFrame* callFrame = ARG_callFrame; 4257 4257 4258 JSObject* result = v1 ->toThisObject(callFrame);4258 JSObject* result = v1.toThisObject(callFrame); 4259 4259 CHECK_FOR_EXCEPTION_AT_END(); 4260 4260 return result; … … 4280 4280 double right = 0.0; 4281 4281 4282 bool rightIsNumber = v2 ->getNumber(right);4283 if (rightIsNumber && v1 ->getNumber(left))4282 bool rightIsNumber = v2.getNumber(right); 4283 if (rightIsNumber && v1.getNumber(left)) 4284 4284 return JSValuePtr::encode(jsNumber(ARG_globalData, left + right)); 4285 4285 4286 4286 CallFrame* callFrame = ARG_callFrame; 4287 4287 4288 bool leftIsString = v1 ->isString();4289 if (leftIsString && v2 ->isString()) {4288 bool leftIsString = v1.isString(); 4289 if (leftIsString && v2.isString()) { 4290 4290 RefPtr<UString::Rep> value = concatenate(asString(v1)->value().rep(), asString(v2)->value().rep()); 4291 4291 if (UNLIKELY(!value)) { … … 4298 4298 4299 4299 if (rightIsNumber & leftIsString) { 4300 RefPtr<UString::Rep> value = v2 ->isInt32Fast() ?4301 concatenate(asString(v1)->value().rep(), v2 ->getInt32Fast()) :4300 RefPtr<UString::Rep> value = v2.isInt32Fast() ? 4301 concatenate(asString(v1)->value().rep(), v2.getInt32Fast()) : 4302 4302 concatenate(asString(v1)->value().rep(), right); 4303 4303 … … 4322 4322 4323 4323 CallFrame* callFrame = ARG_callFrame; 4324 JSValuePtr result = jsNumber(ARG_globalData, v ->toNumber(callFrame) + 1);4324 JSValuePtr result = jsNumber(ARG_globalData, v.toNumber(callFrame) + 1); 4325 4325 CHECK_FOR_EXCEPTION_AT_END(); 4326 4326 return JSValuePtr::encode(result); … … 4392 4392 4393 4393 PutPropertySlot slot; 4394 ARG_src1 ->put(ARG_callFrame, *ARG_id2, ARG_src3, slot);4394 ARG_src1.put(ARG_callFrame, *ARG_id2, ARG_src3, slot); 4395 4395 CHECK_FOR_EXCEPTION_AT_END(); 4396 4396 } … … 4405 4405 JSValuePtr baseValue = ARG_src1; 4406 4406 PropertySlot slot(baseValue); 4407 JSValuePtr result = baseValue ->get(callFrame, ident, slot);4407 JSValuePtr result = baseValue.get(callFrame, ident, slot); 4408 4408 4409 4409 CHECK_FOR_EXCEPTION_AT_END(); … … 4421 4421 4422 4422 PutPropertySlot slot; 4423 ARG_src1 ->put(callFrame, ident, ARG_src3, slot);4423 ARG_src1.put(callFrame, ident, ARG_src3, slot); 4424 4424 4425 4425 ctiPatchCallByReturnAddress(STUB_RETURN_ADDRESS, reinterpret_cast<void*>(cti_op_put_by_id_second)); … … 4433 4433 4434 4434 PutPropertySlot slot; 4435 ARG_src1 ->put(ARG_callFrame, *ARG_id2, ARG_src3, slot);4435 ARG_src1.put(ARG_callFrame, *ARG_id2, ARG_src3, slot); 4436 4436 ARG_globalData->interpreter->tryCTICachePutByID(ARG_callFrame, ARG_callFrame->codeBlock(), STUB_RETURN_ADDRESS, ARG_src1, slot); 4437 4437 CHECK_FOR_EXCEPTION_AT_END(); … … 4446 4446 4447 4447 PutPropertySlot slot; 4448 ARG_src1 ->put(callFrame, ident, ARG_src3, slot);4448 ARG_src1.put(callFrame, ident, ARG_src3, slot); 4449 4449 4450 4450 CHECK_FOR_EXCEPTION_AT_END(); … … 4460 4460 JSValuePtr baseValue = ARG_src1; 4461 4461 PropertySlot slot(baseValue); 4462 JSValuePtr result = baseValue ->get(callFrame, ident, slot);4462 JSValuePtr result = baseValue.get(callFrame, ident, slot); 4463 4463 4464 4464 ctiPatchCallByReturnAddress(STUB_RETURN_ADDRESS, reinterpret_cast<void*>(cti_op_get_by_id_second)); … … 4477 4477 JSValuePtr baseValue = ARG_src1; 4478 4478 PropertySlot slot(baseValue); 4479 JSValuePtr result = baseValue ->get(callFrame, ident, slot);4479 JSValuePtr result = baseValue.get(callFrame, ident, slot); 4480 4480 4481 4481 ARG_globalData->interpreter->tryCTICacheGetByID(callFrame, callFrame->codeBlock(), STUB_RETURN_ADDRESS, baseValue, ident, slot); … … 4494 4494 JSValuePtr baseValue = ARG_src1; 4495 4495 PropertySlot slot(baseValue); 4496 JSValuePtr result = baseValue ->get(callFrame, ident, slot);4496 JSValuePtr result = baseValue.get(callFrame, ident, slot); 4497 4497 4498 4498 CHECK_FOR_EXCEPTION(); 4499 4499 4500 if (baseValue ->isCell()4500 if (baseValue.isCell() 4501 4501 && slot.isCacheable() 4502 4502 && !asCell(baseValue)->structure()->isDictionary() … … 4506 4506 StructureStubInfo* stubInfo = &codeBlock->getStubInfo(STUB_RETURN_ADDRESS); 4507 4507 4508 ASSERT(slot.slotBase() ->isObject());4508 ASSERT(slot.slotBase().isObject()); 4509 4509 4510 4510 PolymorphicAccessStructureList* polymorphicStructureList; … … 4568 4568 JSValuePtr baseValue = ARG_src1; 4569 4569 PropertySlot slot(baseValue); 4570 JSValuePtr result = baseValue ->get(callFrame, *ARG_id2, slot);4570 JSValuePtr result = baseValue.get(callFrame, *ARG_id2, slot); 4571 4571 4572 4572 CHECK_FOR_EXCEPTION(); 4573 4573 4574 if (!baseValue ->isCell() || !slot.isCacheable() || asCell(baseValue)->structure()->isDictionary()) {4574 if (!baseValue.isCell() || !slot.isCacheable() || asCell(baseValue)->structure()->isDictionary()) { 4575 4575 ctiPatchCallByReturnAddress(STUB_RETURN_ADDRESS, reinterpret_cast<void*>(cti_op_get_by_id_proto_fail)); 4576 4576 return JSValuePtr::encode(result); … … 4581 4581 StructureStubInfo* stubInfo = &codeBlock->getStubInfo(STUB_RETURN_ADDRESS); 4582 4582 4583 ASSERT(slot.slotBase() ->isObject());4583 ASSERT(slot.slotBase().isObject()); 4584 4584 JSObject* slotBaseObject = asObject(slot.slotBase()); 4585 4585 … … 4627 4627 JSValuePtr baseValue = ARG_src1; 4628 4628 PropertySlot slot(baseValue); 4629 JSValuePtr result = baseValue ->get(ARG_callFrame, *ARG_id2, slot);4629 JSValuePtr result = baseValue.get(ARG_callFrame, *ARG_id2, slot); 4630 4630 4631 4631 CHECK_FOR_EXCEPTION_AT_END(); … … 4639 4639 JSValuePtr baseValue = ARG_src1; 4640 4640 PropertySlot slot(baseValue); 4641 JSValuePtr result = baseValue ->get(ARG_callFrame, *ARG_id2, slot);4641 JSValuePtr result = baseValue.get(ARG_callFrame, *ARG_id2, slot); 4642 4642 4643 4643 CHECK_FOR_EXCEPTION_AT_END(); … … 4651 4651 JSValuePtr baseValue = ARG_src1; 4652 4652 PropertySlot slot(baseValue); 4653 JSValuePtr result = baseValue ->get(ARG_callFrame, *ARG_id2, slot);4653 JSValuePtr result = baseValue.get(ARG_callFrame, *ARG_id2, slot); 4654 4654 4655 4655 CHECK_FOR_EXCEPTION_AT_END(); … … 4663 4663 JSValuePtr baseValue = ARG_src1; 4664 4664 PropertySlot slot(baseValue); 4665 JSValuePtr result = baseValue ->get(ARG_callFrame, *ARG_id2, slot);4665 JSValuePtr result = baseValue.get(ARG_callFrame, *ARG_id2, slot); 4666 4666 4667 4667 CHECK_FOR_EXCEPTION_AT_END(); … … 4681 4681 4682 4682 // at least one of these checks must have failed to get to the slow case 4683 ASSERT(!value ->isCell() || !baseVal->isCell() || !proto->isCell()4684 || !value ->isObject() || !baseVal->isObject() || !proto->isObject()4683 ASSERT(!value.isCell() || !baseVal.isCell() || !proto.isCell() 4684 || !value.isObject() || !baseVal.isObject() || !proto.isObject() 4685 4685 || (asObject(baseVal)->structure()->typeInfo().flags() & (ImplementsHasInstance | OverridesHasInstance)) != ImplementsHasInstance); 4686 4686 4687 if (!baseVal ->isObject()) {4687 if (!baseVal.isObject()) { 4688 4688 CallFrame* callFrame = ARG_callFrame; 4689 4689 CodeBlock* codeBlock = callFrame->codeBlock(); … … 4696 4696 return JSValuePtr::encode(jsBoolean(false)); 4697 4697 4698 if (!proto ->isObject()) {4698 if (!proto.isObject()) { 4699 4699 throwError(callFrame, TypeError, "instanceof called on an object with an invalid prototype property."); 4700 4700 VM_THROW_EXCEPTION(); 4701 4701 } 4702 4702 4703 if (!value ->isObject())4703 if (!value.isObject()) 4704 4704 return JSValuePtr::encode(jsBoolean(false)); 4705 4705 … … 4716 4716 CallFrame* callFrame = ARG_callFrame; 4717 4717 4718 JSObject* baseObj = ARG_src1 ->toObject(callFrame);4718 JSObject* baseObj = ARG_src1.toObject(callFrame); 4719 4719 4720 4720 JSValuePtr result = jsBoolean(baseObj->deleteProperty(callFrame, *ARG_id2)); … … 4732 4732 double left; 4733 4733 double right; 4734 if (src1 ->getNumber(left) && src2->getNumber(right))4734 if (src1.getNumber(left) && src2.getNumber(right)) 4735 4735 return JSValuePtr::encode(jsNumber(ARG_globalData, left * right)); 4736 4736 4737 4737 CallFrame* callFrame = ARG_callFrame; 4738 JSValuePtr result = jsNumber(ARG_globalData, src1 ->toNumber(callFrame) * src2->toNumber(callFrame));4738 JSValuePtr result = jsNumber(ARG_globalData, src1.toNumber(callFrame) * src2.toNumber(callFrame)); 4739 4739 CHECK_FOR_EXCEPTION_AT_END(); 4740 4740 return JSValuePtr::encode(result); … … 4754 4754 #ifndef NDEBUG 4755 4755 CallData callData; 4756 ASSERT(ARG_src1 ->getCallData(callData) == CallTypeJS);4756 ASSERT(ARG_src1.getCallData(callData) == CallTypeJS); 4757 4757 #endif 4758 4758 … … 4856 4856 4857 4857 CallData callData; 4858 CallType callType = funcVal ->getCallData(callData);4858 CallType callType = funcVal.getCallData(callData); 4859 4859 4860 4860 ASSERT(callType != CallTypeJS); … … 5002 5002 5003 5003 Structure* structure; 5004 if (ARG_src4 ->isObject())5004 if (ARG_src4.isObject()) 5005 5005 structure = asObject(ARG_src4)->inheritorID(); 5006 5006 else … … 5020 5020 5021 5021 ConstructData constructData; 5022 ConstructType constructType = constrVal ->getConstructData(constructData);5022 ConstructType constructType = constrVal.getConstructData(constructData); 5023 5023 5024 5024 if (constructType == ConstructTypeHost) { … … 5055 5055 JSValuePtr result; 5056 5056 5057 if (LIKELY(subscript ->isUInt32Fast())) {5058 uint32_t i = subscript ->getUInt32Fast();5057 if (LIKELY(subscript.isUInt32Fast())) { 5058 uint32_t i = subscript.getUInt32Fast(); 5059 5059 if (interpreter->isJSArray(baseValue)) { 5060 5060 JSArray* jsArray = asArray(baseValue); … … 5070 5070 return JSValuePtr::encode(asByteArray(baseValue)->getIndex(callFrame, i)); 5071 5071 } else 5072 result = baseValue ->get(callFrame, i);5072 result = baseValue.get(callFrame, i); 5073 5073 } else { 5074 Identifier property(callFrame, subscript ->toString(callFrame));5075 result = baseValue ->get(callFrame, property);5074 Identifier property(callFrame, subscript.toString(callFrame)); 5075 result = baseValue.get(callFrame, property); 5076 5076 } 5077 5077 … … 5092 5092 JSValuePtr result; 5093 5093 5094 if (LIKELY(subscript ->isUInt32Fast())) {5095 uint32_t i = subscript ->getUInt32Fast();5094 if (LIKELY(subscript.isUInt32Fast())) { 5095 uint32_t i = subscript.getUInt32Fast(); 5096 5096 if (interpreter->isJSByteArray(baseValue) && asByteArray(baseValue)->canAccessIndex(i)) { 5097 5097 // All fast byte array accesses are safe from exceptions so return immediately to avoid exception checks. … … 5099 5099 } 5100 5100 5101 result = baseValue ->get(callFrame, i);5101 result = baseValue.get(callFrame, i); 5102 5102 if (!interpreter->isJSByteArray(baseValue)) 5103 5103 ctiPatchCallByReturnAddress(STUB_RETURN_ADDRESS, reinterpret_cast<void*>(cti_op_get_by_val)); 5104 5104 } else { 5105 Identifier property(callFrame, subscript ->toString(callFrame));5106 result = baseValue ->get(callFrame, property);5105 Identifier property(callFrame, subscript.toString(callFrame)); 5106 result = baseValue.get(callFrame, property); 5107 5107 } 5108 5108 … … 5162 5162 double left; 5163 5163 double right; 5164 if (src1 ->getNumber(left) && src2->getNumber(right))5164 if (src1.getNumber(left) && src2.getNumber(right)) 5165 5165 return JSValuePtr::encode(jsNumber(ARG_globalData, left - right)); 5166 5166 5167 5167 CallFrame* callFrame = ARG_callFrame; 5168 JSValuePtr result = jsNumber(ARG_globalData, src1 ->toNumber(callFrame) - src2->toNumber(callFrame));5168 JSValuePtr result = jsNumber(ARG_globalData, src1.toNumber(callFrame) - src2.toNumber(callFrame)); 5169 5169 CHECK_FOR_EXCEPTION_AT_END(); 5170 5170 return JSValuePtr::encode(result); … … 5182 5182 JSValuePtr value = ARG_src3; 5183 5183 5184 if (LIKELY(subscript ->isUInt32Fast())) {5185 uint32_t i = subscript ->getUInt32Fast();5184 if (LIKELY(subscript.isUInt32Fast())) { 5185 uint32_t i = subscript.getUInt32Fast(); 5186 5186 if (interpreter->isJSArray(baseValue)) { 5187 5187 JSArray* jsArray = asArray(baseValue); … … 5194 5194 ctiPatchCallByReturnAddress(STUB_RETURN_ADDRESS, reinterpret_cast<void*>(cti_op_put_by_val_byte_array)); 5195 5195 // All fast byte array accesses are safe from exceptions so return immediately to avoid exception checks. 5196 if (value ->isInt32Fast()) {5197 jsByteArray->setIndex(i, value ->getInt32Fast());5196 if (value.isInt32Fast()) { 5197 jsByteArray->setIndex(i, value.getInt32Fast()); 5198 5198 return; 5199 5199 } else { 5200 5200 double dValue = 0; 5201 if (value ->getNumber(dValue)) {5201 if (value.getNumber(dValue)) { 5202 5202 jsByteArray->setIndex(i, dValue); 5203 5203 return; … … 5205 5205 } 5206 5206 5207 baseValue ->put(callFrame, i, value);5207 baseValue.put(callFrame, i, value); 5208 5208 } else 5209 baseValue ->put(callFrame, i, value);5209 baseValue.put(callFrame, i, value); 5210 5210 } else { 5211 Identifier property(callFrame, subscript ->toString(callFrame));5211 Identifier property(callFrame, subscript.toString(callFrame)); 5212 5212 if (!ARG_globalData->exception) { // Don't put to an object if toString threw an exception. 5213 5213 PutPropertySlot slot; 5214 baseValue ->put(callFrame, property, value, slot);5214 baseValue.put(callFrame, property, value, slot); 5215 5215 } 5216 5216 } … … 5236 5236 // This should work since we're re-boxing an immediate unboxed in JIT code. 5237 5237 ASSERT(JSValuePtr::makeInt32Fast(i)); 5238 Identifier property(callFrame, JSValuePtr::makeInt32Fast(i) ->toString(callFrame));5238 Identifier property(callFrame, JSValuePtr::makeInt32Fast(i).toString(callFrame)); 5239 5239 // FIXME: can toString throw an exception here? 5240 5240 if (!ARG_globalData->exception) { // Don't put to an object if toString threw an exception. 5241 5241 PutPropertySlot slot; 5242 baseValue ->put(callFrame, property, value, slot);5242 baseValue.put(callFrame, property, value, slot); 5243 5243 } 5244 5244 } … … 5258 5258 JSValuePtr value = ARG_src3; 5259 5259 5260 if (LIKELY(subscript ->isUInt32Fast())) {5261 uint32_t i = subscript ->getUInt32Fast();5260 if (LIKELY(subscript.isUInt32Fast())) { 5261 uint32_t i = subscript.getUInt32Fast(); 5262 5262 if (interpreter->isJSByteArray(baseValue) && asByteArray(baseValue)->canAccessIndex(i)) { 5263 5263 JSByteArray* jsByteArray = asByteArray(baseValue); 5264 5264 5265 5265 // All fast byte array accesses are safe from exceptions so return immediately to avoid exception checks. 5266 if (value ->isInt32Fast()) {5267 jsByteArray->setIndex(i, value ->getInt32Fast());5266 if (value.isInt32Fast()) { 5267 jsByteArray->setIndex(i, value.getInt32Fast()); 5268 5268 return; 5269 5269 } else { 5270 5270 double dValue = 0; 5271 if (value ->getNumber(dValue)) {5271 if (value.getNumber(dValue)) { 5272 5272 jsByteArray->setIndex(i, dValue); 5273 5273 return; … … 5278 5278 if (!interpreter->isJSByteArray(baseValue)) 5279 5279 ctiPatchCallByReturnAddress(STUB_RETURN_ADDRESS, reinterpret_cast<void*>(cti_op_put_by_val)); 5280 baseValue ->put(callFrame, i, value);5280 baseValue.put(callFrame, i, value); 5281 5281 } else { 5282 Identifier property(callFrame, subscript ->toString(callFrame));5282 Identifier property(callFrame, subscript.toString(callFrame)); 5283 5283 if (!ARG_globalData->exception) { // Don't put to an object if toString threw an exception. 5284 5284 PutPropertySlot slot; 5285 baseValue ->put(callFrame, property, value, slot);5285 baseValue.put(callFrame, property, value, slot); 5286 5286 } 5287 5287 } … … 5308 5308 CallFrame* callFrame = ARG_callFrame; 5309 5309 5310 bool result = src1 ->toBoolean(callFrame);5310 bool result = src1.toBoolean(callFrame); 5311 5311 CHECK_FOR_EXCEPTION_AT_END(); 5312 5312 return result; … … 5320 5320 5321 5321 double v; 5322 if (src ->getNumber(v))5322 if (src.getNumber(v)) 5323 5323 return JSValuePtr::encode(jsNumber(ARG_globalData, -v)); 5324 5324 5325 5325 CallFrame* callFrame = ARG_callFrame; 5326 JSValuePtr result = jsNumber(ARG_globalData, -src ->toNumber(callFrame));5326 JSValuePtr result = jsNumber(ARG_globalData, -src.toNumber(callFrame)); 5327 5327 CHECK_FOR_EXCEPTION_AT_END(); 5328 5328 return JSValuePtr::encode(result); … … 5410 5410 double left; 5411 5411 double right; 5412 if (src1 ->getNumber(left) && src2->getNumber(right))5412 if (src1.getNumber(left) && src2.getNumber(right)) 5413 5413 return JSValuePtr::encode(jsNumber(ARG_globalData, left / right)); 5414 5414 5415 5415 CallFrame* callFrame = ARG_callFrame; 5416 JSValuePtr result = jsNumber(ARG_globalData, src1 ->toNumber(callFrame) / src2->toNumber(callFrame));5416 JSValuePtr result = jsNumber(ARG_globalData, src1.toNumber(callFrame) / src2.toNumber(callFrame)); 5417 5417 CHECK_FOR_EXCEPTION_AT_END(); 5418 5418 return JSValuePtr::encode(result); … … 5426 5426 5427 5427 CallFrame* callFrame = ARG_callFrame; 5428 JSValuePtr result = jsNumber(ARG_globalData, v ->toNumber(callFrame) - 1);5428 JSValuePtr result = jsNumber(ARG_globalData, v.toNumber(callFrame) - 1); 5429 5429 CHECK_FOR_EXCEPTION_AT_END(); 5430 5430 return JSValuePtr::encode(result); … … 5452 5452 CallFrame* callFrame = ARG_callFrame; 5453 5453 5454 JSValuePtr result = jsBoolean(!src ->toBoolean(callFrame));5454 JSValuePtr result = jsBoolean(!src.toBoolean(callFrame)); 5455 5455 CHECK_FOR_EXCEPTION_AT_END(); 5456 5456 return JSValuePtr::encode(result); … … 5465 5465 CallFrame* callFrame = ARG_callFrame; 5466 5466 5467 bool result = src1 ->toBoolean(callFrame);5467 bool result = src1.toBoolean(callFrame); 5468 5468 CHECK_FOR_EXCEPTION_AT_END(); 5469 5469 return result; … … 5478 5478 CallFrame* callFrame = ARG_callFrame; 5479 5479 5480 JSValuePtr number = v ->toJSNumber(callFrame);5480 JSValuePtr number = v.toJSNumber(callFrame); 5481 5481 CHECK_FOR_EXCEPTION_AT_END(); 5482 5482 5483 RETURN_PAIR(JSValuePtr::encode(number), JSValuePtr::encode(jsNumber(ARG_globalData, number ->uncheckedGetNumber() + 1)));5483 RETURN_PAIR(JSValuePtr::encode(number), JSValuePtr::encode(jsNumber(ARG_globalData, number.uncheckedGetNumber() + 1))); 5484 5484 } 5485 5485 … … 5509 5509 uint32_t right; 5510 5510 if (JSValuePtr::areBothInt32Fast(val, shift)) 5511 return JSValuePtr::encode(jsNumber(ARG_globalData, val ->getInt32Fast() << (shift->getInt32Fast() & 0x1f)));5512 if (val ->numberToInt32(left) && shift->numberToUInt32(right))5511 return JSValuePtr::encode(jsNumber(ARG_globalData, val.getInt32Fast() << (shift.getInt32Fast() & 0x1f))); 5512 if (val.numberToInt32(left) && shift.numberToUInt32(right)) 5513 5513 return JSValuePtr::encode(jsNumber(ARG_globalData, left << (right & 0x1f))); 5514 5514 5515 5515 CallFrame* callFrame = ARG_callFrame; 5516 JSValuePtr result = jsNumber(ARG_globalData, (val ->toInt32(callFrame)) << (shift->toUInt32(callFrame) & 0x1f));5516 JSValuePtr result = jsNumber(ARG_globalData, (val.toInt32(callFrame)) << (shift.toUInt32(callFrame) & 0x1f)); 5517 5517 CHECK_FOR_EXCEPTION_AT_END(); 5518 5518 return JSValuePtr::encode(result); … … 5528 5528 int32_t left; 5529 5529 int32_t right; 5530 if (src1 ->numberToInt32(left) && src2->numberToInt32(right))5530 if (src1.numberToInt32(left) && src2.numberToInt32(right)) 5531 5531 return JSValuePtr::encode(jsNumber(ARG_globalData, left & right)); 5532 5532 5533 5533 CallFrame* callFrame = ARG_callFrame; 5534 JSValuePtr result = jsNumber(ARG_globalData, src1 ->toInt32(callFrame) & src2->toInt32(callFrame));5534 JSValuePtr result = jsNumber(ARG_globalData, src1.toInt32(callFrame) & src2.toInt32(callFrame)); 5535 5535 CHECK_FOR_EXCEPTION_AT_END(); 5536 5536 return JSValuePtr::encode(result); … … 5548 5548 if (JSFastMath::canDoFastRshift(val, shift)) 5549 5549 return JSValuePtr::encode(JSFastMath::rightShiftImmediateNumbers(val, shift)); 5550 if (val ->numberToInt32(left) && shift->numberToUInt32(right))5550 if (val.numberToInt32(left) && shift.numberToUInt32(right)) 5551 5551 return JSValuePtr::encode(jsNumber(ARG_globalData, left >> (right & 0x1f))); 5552 5552 5553 5553 CallFrame* callFrame = ARG_callFrame; 5554 JSValuePtr result = jsNumber(ARG_globalData, (val ->toInt32(callFrame)) >> (shift->toUInt32(callFrame) & 0x1f));5554 JSValuePtr result = jsNumber(ARG_globalData, (val.toInt32(callFrame)) >> (shift.toUInt32(callFrame) & 0x1f)); 5555 5555 CHECK_FOR_EXCEPTION_AT_END(); 5556 5556 return JSValuePtr::encode(result); … … 5564 5564 5565 5565 int value; 5566 if (src ->numberToInt32(value))5566 if (src.numberToInt32(value)) 5567 5567 return JSValuePtr::encode(jsNumber(ARG_globalData, ~value)); 5568 5568 5569 5569 CallFrame* callFrame = ARG_callFrame; 5570 JSValuePtr result = jsNumber(ARG_globalData, ~src ->toInt32(callFrame));5570 JSValuePtr result = jsNumber(ARG_globalData, ~src.toInt32(callFrame)); 5571 5571 CHECK_FOR_EXCEPTION_AT_END(); 5572 5572 return JSValuePtr::encode(result); … … 5622 5622 5623 5623 CallFrame* callFrame = ARG_callFrame; 5624 double d = dividendValue ->toNumber(callFrame);5625 JSValuePtr result = jsNumber(ARG_globalData, fmod(d, divisorValue ->toNumber(callFrame)));5624 double d = dividendValue.toNumber(callFrame); 5625 JSValuePtr result = jsNumber(ARG_globalData, fmod(d, divisorValue.toNumber(callFrame))); 5626 5626 CHECK_FOR_EXCEPTION_AT_END(); 5627 5627 return JSValuePtr::encode(result); … … 5661 5661 CallFrame* callFrame = ARG_callFrame; 5662 5662 5663 JSValuePtr number = v ->toJSNumber(callFrame);5663 JSValuePtr number = v.toJSNumber(callFrame); 5664 5664 CHECK_FOR_EXCEPTION_AT_END(); 5665 5665 5666 RETURN_PAIR(JSValuePtr::encode(number), JSValuePtr::encode(jsNumber(ARG_globalData, number ->uncheckedGetNumber() - 1)));5666 RETURN_PAIR(JSValuePtr::encode(number), JSValuePtr::encode(jsNumber(ARG_globalData, number.uncheckedGetNumber() - 1))); 5667 5667 } 5668 5668 … … 5679 5679 return JSValuePtr::encode(JSFastMath::rightShiftImmediateNumbers(val, shift)); 5680 5680 else { 5681 JSValuePtr result = jsNumber(ARG_globalData, (val ->toUInt32(callFrame)) >> (shift->toUInt32(callFrame) & 0x1f));5681 JSValuePtr result = jsNumber(ARG_globalData, (val.toUInt32(callFrame)) >> (shift.toUInt32(callFrame) & 0x1f)); 5682 5682 CHECK_FOR_EXCEPTION_AT_END(); 5683 5683 return JSValuePtr::encode(result); … … 5694 5694 CallFrame* callFrame = ARG_callFrame; 5695 5695 5696 JSValuePtr result = jsNumber(ARG_globalData, src1 ->toInt32(callFrame) ^ src2->toInt32(callFrame));5696 JSValuePtr result = jsNumber(ARG_globalData, src1.toInt32(callFrame) ^ src2.toInt32(callFrame)); 5697 5697 CHECK_FOR_EXCEPTION_AT_END(); 5698 5698 return JSValuePtr::encode(result); … … 5715 5715 CallFrame* callFrame = ARG_callFrame; 5716 5716 5717 JSValuePtr result = jsNumber(ARG_globalData, src1 ->toInt32(callFrame) | src2->toInt32(callFrame));5717 JSValuePtr result = jsNumber(ARG_globalData, src1.toInt32(callFrame) | src2.toInt32(callFrame)); 5718 5718 CHECK_FOR_EXCEPTION_AT_END(); 5719 5719 return JSValuePtr::encode(result); … … 5799 5799 BEGIN_STUB_FUNCTION(); 5800 5800 5801 JSObject* o = ARG_src1 ->toObject(ARG_callFrame);5801 JSObject* o = ARG_src1.toObject(ARG_callFrame); 5802 5802 CHECK_FOR_EXCEPTION(); 5803 5803 ARG_callFrame->setScopeChain(ARG_callFrame->scopeChain()->push(o)); … … 5824 5824 5825 5825 JSValuePtr v = ARG_src1; 5826 return JSValuePtr::encode(jsBoolean(v ->isCell() ? v->asCell()->structure()->typeInfo().masqueradesAsUndefined() : v->isUndefined()));5826 return JSValuePtr::encode(jsBoolean(v.isCell() ? v.asCell()->structure()->typeInfo().masqueradesAsUndefined() : v.isUndefined())); 5827 5827 } 5828 5828 … … 5831 5831 BEGIN_STUB_FUNCTION(); 5832 5832 5833 return JSValuePtr::encode(jsBoolean(ARG_src1 ->isBoolean()));5833 return JSValuePtr::encode(jsBoolean(ARG_src1.isBoolean())); 5834 5834 } 5835 5835 … … 5838 5838 BEGIN_STUB_FUNCTION(); 5839 5839 5840 return JSValuePtr::encode(jsBoolean(ARG_src1 ->isNumber()));5840 return JSValuePtr::encode(jsBoolean(ARG_src1.isNumber())); 5841 5841 } 5842 5842 … … 5889 5889 CallFrame* callFrame = ARG_callFrame; 5890 5890 5891 JSValuePtr result = src ->toJSNumber(callFrame);5891 JSValuePtr result = src.toJSNumber(callFrame); 5892 5892 CHECK_FOR_EXCEPTION_AT_END(); 5893 5893 return JSValuePtr::encode(result); … … 5901 5901 JSValuePtr baseVal = ARG_src2; 5902 5902 5903 if (!baseVal ->isObject()) {5903 if (!baseVal.isObject()) { 5904 5904 CallFrame* callFrame = ARG_callFrame; 5905 5905 CodeBlock* codeBlock = callFrame->codeBlock(); … … 5913 5913 5914 5914 uint32_t i; 5915 if (propName ->getUInt32(i))5915 if (propName.getUInt32(i)) 5916 5916 return JSValuePtr::encode(jsBoolean(baseObj->hasProperty(callFrame, i))); 5917 5917 5918 Identifier property(callFrame, propName ->toString(callFrame));5918 Identifier property(callFrame, propName.toString(callFrame)); 5919 5919 CHECK_FOR_EXCEPTION(); 5920 5920 return JSValuePtr::encode(jsBoolean(baseObj->hasProperty(callFrame, property))); … … 5952 5952 unsigned property = ARG_int2; 5953 5953 5954 ARG_src1 ->put(callFrame, property, ARG_src3);5954 ARG_src1.put(callFrame, property, ARG_src3); 5955 5955 } 5956 5956 … … 5964 5964 CodeBlock* codeBlock = callFrame->codeBlock(); 5965 5965 5966 if (scrutinee ->isInt32Fast())5967 return codeBlock->immediateSwitchJumpTable(tableIndex).ctiForValue(scrutinee ->getInt32Fast());5966 if (scrutinee.isInt32Fast()) 5967 return codeBlock->immediateSwitchJumpTable(tableIndex).ctiForValue(scrutinee.getInt32Fast()); 5968 5968 5969 5969 return codeBlock->immediateSwitchJumpTable(tableIndex).ctiDefault; … … 5981 5981 void* result = codeBlock->characterSwitchJumpTable(tableIndex).ctiDefault; 5982 5982 5983 if (scrutinee ->isString()) {5983 if (scrutinee.isString()) { 5984 5984 UString::Rep* value = asString(scrutinee)->value().rep(); 5985 5985 if (value->size() == 1) … … 6001 6001 void* result = codeBlock->stringSwitchJumpTable(tableIndex).ctiDefault; 6002 6002 6003 if (scrutinee ->isString()) {6003 if (scrutinee.isString()) { 6004 6004 UString::Rep* value = asString(scrutinee)->value().rep(); 6005 6005 result = codeBlock->stringSwitchJumpTable(tableIndex).ctiForValue(value); … … 6016 6016 6017 6017 JSValuePtr baseValue = ARG_src1; 6018 JSObject* baseObj = baseValue ->toObject(callFrame); // may throw6018 JSObject* baseObj = baseValue.toObject(callFrame); // may throw 6019 6019 6020 6020 JSValuePtr subscript = ARG_src2; 6021 6021 JSValuePtr result; 6022 6022 uint32_t i; 6023 if (subscript ->getUInt32(i))6023 if (subscript.getUInt32(i)) 6024 6024 result = jsBoolean(baseObj->deleteProperty(callFrame, i)); 6025 6025 else { 6026 6026 CHECK_FOR_EXCEPTION(); 6027 Identifier property(callFrame, subscript ->toString(callFrame));6027 Identifier property(callFrame, subscript.toString(callFrame)); 6028 6028 CHECK_FOR_EXCEPTION(); 6029 6029 result = jsBoolean(baseObj->deleteProperty(callFrame, property)); … … 6040 6040 CallFrame* callFrame = ARG_callFrame; 6041 6041 6042 ASSERT(ARG_src1 ->isObject());6042 ASSERT(ARG_src1.isObject()); 6043 6043 JSObject* baseObj = asObject(ARG_src1); 6044 ASSERT(ARG_src3 ->isObject());6044 ASSERT(ARG_src3.isObject()); 6045 6045 baseObj->defineGetter(callFrame, *ARG_id2, asObject(ARG_src3)); 6046 6046 } … … 6052 6052 CallFrame* callFrame = ARG_callFrame; 6053 6053 6054 ASSERT(ARG_src1 ->isObject());6054 ASSERT(ARG_src1.isObject()); 6055 6055 JSObject* baseObj = asObject(ARG_src1); 6056 ASSERT(ARG_src3 ->isObject());6056 ASSERT(ARG_src3.isObject()); 6057 6057 baseObj->defineSetter(callFrame, *ARG_id2, asObject(ARG_src3)); 6058 6058 } … … 6069 6069 6070 6070 unsigned lineNumber = codeBlock->lineNumberForBytecodeOffset(callFrame, bytecodeOffset); 6071 return Error::create(callFrame, static_cast<ErrorType>(type), message ->toString(callFrame), lineNumber, codeBlock->ownerNode()->sourceID(), codeBlock->ownerNode()->sourceURL());6071 return Error::create(callFrame, static_cast<ErrorType>(type), message.toString(callFrame), lineNumber, codeBlock->ownerNode()->sourceID(), codeBlock->ownerNode()->sourceURL()); 6072 6072 } 6073 6073
Note:
See TracChangeset
for help on using the changeset viewer.