Repository navigation
feat(#1317): add identity-object lint - #1320
Merged
Merged
Conversation
Flags a hand-written identity formation ([x] > (φ ↦ x)) that could be replaced with the `I` glyph. A formation is matched only when it binds exactly one void and decorates that same void via ξ; the glyph's own desugared shape is told apart by its formation, void and φ all sharing the same @line/@pos, since all three come from the single glyph character. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KicXH9j9HV3JxU57JHJr33
The o[2] predicate chain re-scoped o[1] to the phi node's own (nonexistent) children instead of the formation's void, so the lint never matched. Flatten the chained brackets into a single conjunction so every o[1]/o[2] reference stays anchored to the candidate formation. Also spell "handwritten" as one word per the repo's grammar check. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KicXH9j9HV3JxU57JHJr33
The placeholder base "Q.number" isn't a valid fqn under the XMIR schema; use "Φ.number" like the rest of the test packs do. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KicXH9j9HV3JxU57JHJr33
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KicXH9j9HV3JxU57JHJr33
yegor256
marked this pull request as ready for review
August 28, 2026 06:41
Member
Author
|
Thanks for the contribution! Generated by Claude Code |
|
@yegor256 Thanks for the contribution! You've earned +4 points for this: +16 as a basis; -4 for too many hits-of-code (168 >= 100); -8 for the lack of code review. Please, keep them coming. Your running score is +1704; don't forget to check your Zerocracy account too). |
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.
Summary
identity-objectlint that flags a handwritten identity formation ([x] > (φ ↦ x)) that could be replaced with theIglyph.ξ; the glyph's own desugared shape is told apart by its formation, void andφall sharing the same@line/@pos, since all three come from the single glyph character (per the heuristic proposed in the issue).φapplied to something,φreaching a name that isn't its own void), an anonymous-formation case, and a line-0/context case.Closes #1317
Test plan
mvn test -Dtest=LtByXslTest#testsAllLintsByEo— all 427 YAML packs pass, including the newidentity-objectpackmvn test— full test suite passesmvn verify -DskipTests— qulice static analysis passesxcop,yamllint,reuse lint,typos,markdownlint-cli2,vale— all pass on the new files (no errors)Generated by Claude Code