Skip to content

Fix AST equality for composite literal elements - #1792

Closed
dajiaohuang wants to merge 2 commits into
dominikh:masterfrom
dajiaohuang:fix/astutil-compositelit-equal
Closed

dajiaohuang wants to merge 2 commits into
dominikh:masterfrom
dajiaohuang:fix/astutil-compositelit-equal

Conversation

@dajiaohuang

Copy link
Copy Markdown

astutil.Equal compared each composite literal element from the right-hand side against itself, so literals with differing elements were considered equal. Compare corresponding elements from the left and right literals instead, and add a regression test.

@dajiaohuang

Copy link
Copy Markdown
Author

Closing this duplicate after comparing the current patches. The same defect and fix are already covered by #1800. The additional generic-instantiation change is already tracked separately in #1764. Keeping the existing contribution avoids competing review threads; the contributor branches remain preserved.

@dajiaohuang dajiaohuang closed this Oct 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant