F-Identity: name the two identity predicates and say which is normative (#59) - #63
Merged
Conversation
…ch is normative (#59) The specification stated two identity tests for captures and never reconciled them. F-Import's is `typeof` object or function; F-Val-Live's recurses and rejects a plain object. A reader implementing from the text could use either for both uses and be wrong in one of two directions. F-Identity resolves it in J3's definitions. The recursive test is normative, because the proposition is about entities the build names and serializes, and two structurally equal plain objects nothing references cannot be told apart in the output. F-Import's broader test is then a deliberate over-approximation whose cost is coverage rather than correctness. Whether to narrow it is left as a question for measurement, since it changes which files fold. F-Capture and F-CallLeak now say which test each uses, values.md's claim that liveness is what F-Capture tests is corrected, and the reference's comments cite F-Identity instead of pointing at CAVEATS.md for an open question. The backward-capture fixture cites F-Identity, since the object it captures is plain and the edge exists only because F-Capture over-approximates. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RfnRhfdYHLFAZJKHwZhBYc
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.
Closes #59.
The specification stated two identity tests for captures and never reconciled them.
F-Import's istypeofobject or function;F-Val-Live's recurses through plain objects and arrays and rejects a plain{ a: 1 }. A reader implementing from the text could use either for both uses and be wrong in one of two directions — the narrow one everywhere loses capture edges, the broad one everywhere makes every parameter helper a taint source.F-Identitylands in J3's definitions and resolves it:F-Val-Live) is normative, because the proposition is about entities the build names and serializes, and two structurally equal plain objects that noAttrRefpoints at cannot be told apart in the outputF-Import) is a deliberate over-approximation: an imported binding is nearly always an entity, and onetypeofis cheaper than a recursive walk of every resolved importF-DirectionF-Importis left as a question for measurement, since it changes which files foldAlso in this change:
F-CaptureandF-CallLeaksay which test each usesvalues.md's claim that liveness is whatF-Capturetests was wrong and is correctedpackages/reference's comments citeF-Identityrather than pointing atCAVEATS.mdfor an open question; that section ofCAVEATS.mdbecomes a pointerF-Succ/backward-along-capturescitesF-Identity, since the value it captures is plain and the edge exists only becauseF-Captureover-approximates🤖 Generated with Claude Code
https://claude.ai/code/session_01RfnRhfdYHLFAZJKHwZhBYc