Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

checker: fix being too strict with generics in assignment type mismatch checking #20346

Merged
merged 2 commits into from
Jan 2, 2024

Conversation

shove70
Copy link
Contributor

@shove70 shove70 commented Jan 2, 2024

Close #20335

This PR is a patch to PR #20327, temporarily relaxing the mismatch check on generic types. :)

  1. The test case of the original PR 20327 continues to be valid
  2. discord.v on the submitted 94d5563 can already be compiled properly.

At present, the type mismatch check on assignment is too lenient for generics, and there will be some missed cases. I have written it down in a memo and arranged time for detailed handling

Copy link
Member

@spytheman spytheman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent work. Thank you very much.

@spytheman spytheman merged commit 7a56ebf into vlang:master Jan 2, 2024
54 checks passed
@shove70 shove70 deleted the patch-1 branch January 2, 2024 21:53
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.

Compiler incorrectly errors on generic method
2 participants