LGTM, if this is what you want.
http://codereview.chromium.org/43005/diff/1/2 File src/string.js (right): http://codereview.chromium.org/43005/diff/1/2#newcode65 Line 65: var subject = ToString(this); This changes the behavior on non-string receivers to potentially use the fast case, but at the cost of an extra is-this-a-string check in the case where the receiver is a string. The assumption made was that non-string receivers of String.prototype.charAt are so rare that they can be ignored (even if charAt is intentionally generic). Ofcourse, this depends on the receiver not being a temporary String wrapper object. http://codereview.chromium.org/43005 --~--~---------~--~----~------------~-------~--~----~ v8-dev mailing list v8-dev@googlegroups.com http://groups.google.com/group/v8-dev -~----------~----~----~----~------~----~------~--~---