-
Notifications
You must be signed in to change notification settings - Fork 380
Fix #7669: positivity checker: compute function arity up to def. eq. #7674
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
Conversation
The change here improves polarity inference, which seems to make solutions of unification problems less unique.
|
Here's a minimized example for the difference in unification behavior: data Unit : Set where
tt : Unit
postulate
A B : Set
FUN : Set₁
FUN = Set → Set
ConstA : Unit → FUN
ConstA tt _ = A
postulate
x : Unit
f : (Z : Set) → ConstA x Z
a : ConstA x B
a = f _ With the old behavior, the code above typechecks even though the hole in |
That sounds like a bug to me. |
Yes it is a bug, the new behavior is the correct one. With the old behavior, the positivity checker fails to infer that the second argument of |
Agda PR #7674 requires some implicit arguments explicitly in some record expression given since variance info got refined (invariant to non-variant) and hence solutions are no longer unique.
3d2e01f
to
2d36d06
Compare
Updating std-lib in |
Agda PR #7674 requires some implicit arguments explicitly in some record expression given since variance info got refined (invariant to non-variant) and hence solutions are no longer unique.
Agda PR #7674 requires some implicit arguments explicitly in some record expression given since variance info got refined (invariant to non-variant) and hence solutions are no longer unique.
Agda PR #7674 requires some implicit arguments explicitly in some record expression given since variance info got refined (invariant to non-variant) and hence solutions are no longer unique.
* agda/agda#7674 eta-expand fields in record expression Agda PR #7674 requires some implicit arguments explicitly in some record expression given since variance info got refined (invariant to non-variant) and hence solutions are no longer unique. * Workaround for Agda 2.7.0 (and lower, I suppose) * Correct option --warn to --warning for agda/agda#7966 The official name of the option is `--warning` and the prefix `--warn` is only accepted because we have no options like `--warner` or `--warner-brothers-owns-us`, but we might have so in the future. * Update README and CI for v2.8.0-rc3 --------- Co-authored-by: Andreas Abel <[email protected]>
Closes #7669.