Changeset 172961 in webkit for trunk/Source/JavaScriptCore/dfg/DFGLazyJSValue.cpp
- Timestamp:
- Aug 26, 2014, 9:46:10 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGLazyJSValue.cpp
r172940 r172961 114 114 } 115 115 116 uintptr_t LazyJSValue::switchLookupValue(SwitchKind kind) const117 {118 // NB. Not every kind of JSValue will be able to give you a switch lookup119 // value, and this method will assert, or do bad things, if you use it120 // for a kind of value that can't.121 switch (m_kind) {122 case KnownValue:123 switch (kind) {124 case SwitchImm:125 return value()->value().asInt32();126 case SwitchCell:127 return bitwise_cast<uintptr_t>(value()->value().asCell());128 default:129 RELEASE_ASSERT_NOT_REACHED();130 return 0;131 }132 case SingleCharacterString:133 switch (kind) {134 case SwitchChar:135 return character();136 default:137 RELEASE_ASSERT_NOT_REACHED();138 return 0;139 }140 default:141 RELEASE_ASSERT_NOT_REACHED();142 return 0;143 }144 }145 146 116 void LazyJSValue::dumpInContext(PrintStream& out, DumpContext* context) const 147 117 {
Note:
See TracChangeset
for help on using the changeset viewer.