If this really becomes a performance problem, we can make caching thread-safe. The real problem would be the call to TypeWithDict::byName(...) not being thread safe.