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

Correctly split non-varpats in tactics #1427

Merged
merged 1 commit into from
Feb 23, 2021

Conversation

isovector
Copy link
Collaborator

This PR fixes #1426. The old logic accidentally would only replace top-level VarPats. This one instead does an SYB traversal over the bound patterns and replaces a VarPat with its case-matches. The implementation here is a bit stupid --- it does one traversal for each body, but this is user-written code, so all inputs involved are small constants.

@isovector isovector changed the title Successfully split non-varpats Correctly split non-varpats in tactics Feb 23, 2021
@isovector
Copy link
Collaborator Author

@Ailrun I'd love to get this in before the 1.0 release if possible.

Copy link
Member

@Ailrun Ailrun left a comment

Choose a reason for hiding this comment

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

OK, I think including this into the release makes sense as this bug is kinda critical for the usage of the split tactic.

@isovector isovector added merge me Label to trigger pull request merge and removed merge me Label to trigger pull request merge labels Feb 23, 2021
@mergify mergify bot merged commit 7817a10 into haskell:master Feb 23, 2021
@isovector isovector deleted the fix-bug-split branch March 1, 2021 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge me Label to trigger pull request merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tactics' agda-split can destroy matches
2 participants