Don't use OfType to check for a function on the stack in JSAstVisitor.
Make the traversal record cache an ordinary dictionary, but thread local, to avoid the overhead of locking/thread-safety.