24 Jun
2009
24 Jun
'09
6:18 a.m.
Traditionally, if we find a dictionary in the prototype chain when we're trying to cache, we do a fromDictionary transition, so the cache can succeed. For example, in tryCacheGetById: // Since we're accessing a prototype in a loop, it's a good bet that it // should not be treated as a dictionary. if (slotBaseObject->structure()->isDictionary()) slotBaseObject-
setStructure(Structure::fromDictionaryTransition(slotBaseObject- structure()));
Is there a good reason not to do that in this case? Geoff