Changeset 172961 in webkit for trunk/Source/JavaScriptCore/dfg/DFGLazyJSValue.h
- Timestamp:
- Aug 26, 2014, 9:46:10 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGLazyJSValue.h
r172940 r172961 29 29 #if ENABLE(DFG_JIT) 30 30 31 #include "DFGCommon.h"32 31 #include "DFGFrozenValue.h" 33 32 #include <wtf/text/StringImpl.h> … … 97 96 TriState strictEqual(const LazyJSValue& other) const; 98 97 99 uintptr_t switchLookupValue(SwitchKind) const; 98 unsigned switchLookupValue() const 99 { 100 // NB. Not every kind of JSValue will be able to give you a switch lookup 101 // value, and this method will assert, or do bad things, if you use it 102 // for a kind of value that can't. 103 switch (m_kind) { 104 case KnownValue: 105 return value()->value().asInt32(); 106 case SingleCharacterString: 107 return character(); 108 default: 109 RELEASE_ASSERT_NOT_REACHED(); 110 return 0; 111 } 112 } 100 113 101 114 void dump(PrintStream&) const;
Note:
See TracChangeset
for help on using the changeset viewer.