Repository navigation
Docs: the interpreter file describes a TypeReference member cache that no longer exists - #3440
Merged
lahma merged 1 commit intoAug 27, 2026
Conversation
…t no longer exists `Jint/Runtime/Interpreter/AGENTS.md` told anyone touching a shared interop cache that `TypeReference` keeps a process-wide static member cache "on a *weaker* key -- just `(Type, member name)`, with no requirement or profile -- so it is shared even between engines whose interop configuration differs". That described `TypeReference._memberAccessors`, which sebastienros#3052 removed. Static-member resolution now goes through `TypeResolver.GetStaticAccessor`, whose key is `StaticAccessorCacheKey(Type, member name, InteropResolutionProfile)` and which runs the same `IsShareable` / `IsConverterNeutral` exclusions as the instance lane. The one real opt-out left is an enum reference, which resolves per instance because `EnumConversion` decides whether a constant is a `JsString` or a `JsNumber` and the key cannot express it -- which the code says in a comment and the instruction file did not. Found while auditing every process-wide cache for sebastienros#3426: the paragraph as written makes an agent record a defect that is not there, and miss the enum exception that is. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014W5mbjGhyvgAS4pivXoc4S
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Jint/Runtime/Interpreter/AGENTS.mdtells anyone touching a shared interop cache thatTypeReferencekeeps a process-wide static member cache "on a weaker key — just(Type, member name), with no requirement or profile — so it is shared even between engines whose interop configuration differs".That described
TypeReference._memberAccessors, which #3052 removed. Static-member resolution now goes throughTypeResolver.GetStaticAccessor, whose key isStaticAccessorCacheKey(Type, member name, InteropResolutionProfile)and which runs the sameIsShareable/IsConverterNeutralexclusions as the instance lane.The one real opt-out left is an enum reference, which resolves per instance because the engine's
EnumConversionmode decides whether a constant is aJsStringor aJsNumberand the key cannot express it.TypeReference.CreatePropertyDescriptorsays so in a comment; the instruction file did not.Found while auditing every process-wide cache for #3426. The paragraph as written makes an agent record a defect that is not there, and miss the exception that is — which is exactly what it cost during that audit.
Docs only.
AgentInstructionFileTestsgreen (the file gets shorter).🤖 Generated with Claude Code
https://claude.ai/code/session_014W5mbjGhyvgAS4pivXoc4S