Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ fixed #4560 ] pattern attribute no-eta-equality inductive records
Having both pattern and copattern matching for records without eta-equality breaks subject reduction. If you want to pattern match on the constructor for a no-eta record, you have to declare it 'pattern'. The default is copattern matching. The attribute 'pattern' is ignored for 'coinductive' or 'eta-equality' records. Recursive records might be declared as no-eta by the positivity checker; thus, we need to remember the attribute 'pattern' until the positivity checker has run. It is stored in the new field recPatternMatching :: PatternOrCopattern of the Record alternative of TCM.Defn. Ultimately, the choice of PatternMatching or CopatternMatching is integrated in the field recEtaEquality' :: HasEta This change to Agda affects a dozen test cases and also the standard library at some places.
- Loading branch information
1 parent
9e9f658
commit 37cfa65
Showing
54 changed files
with
510 additions
and
185 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.