-
Notifications
You must be signed in to change notification settings - Fork 407
Explicit polarity annotation #570
Copy link
Copy link
Closed
Labels
polaritypositivityPositivity checking for data-type definitionsPositivity checking for data-type definitionssized typesSized types, termination checking with sized types, size inferenceSized types, termination checking with sized types, size inferencetype: enhancementIssues and pull requests about possible improvementsIssues and pull requests about possible improvements
Milestone
Description
This code does not work since polarity of Nat (monotone in i) is only inferred when the constructors are given. But it is already needed for checking sub.
data Nat : {i : Size} -> Set
sub : {i : Size} -> Nat {i} → Nat {↑ i}
sub x = x
data Nat where
zero : {i : Size} -> Nat {↑ i}
suc : {i : Size} -> Nat {i} -> Nat {↑ i}Original issue reported on code.google.com by andreas....@gmail.com on 19 Feb 2012 at 10:21
Attachments:
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
polaritypositivityPositivity checking for data-type definitionsPositivity checking for data-type definitionssized typesSized types, termination checking with sized types, size inferenceSized types, termination checking with sized types, size inferencetype: enhancementIssues and pull requests about possible improvementsIssues and pull requests about possible improvements