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

A failure of derive.param1 with template polymorphism in Prop #527

Open
herbelin opened this issue Oct 24, 2023 · 0 comments
Open

A failure of derive.param1 with template polymorphism in Prop #527

herbelin opened this issue Oct 24, 2023 · 0 comments

Comments

@herbelin
Copy link
Contributor

Not sure it is very critical, but there seems to be an issue with template polymorphisms ending in Prop:

Inductive K A := C : A -> K A.
Definition L := K True.
From elpi.apps Require Import derive.std.
Elpi derive.param1 K.
Elpi derive.param1 True.
Fail Elpi derive.param1 L.
(* param1: constant does not have the right type: Unable to unify "K True -> Type" with "L -> Prop"
(universe inconsistency: Cannot enforce is_K.u1 <= Prop). *)

Deriving manually however works, so I suspect the generated is_K not to be declared as template polymorphic:

Inductive K A := C : A -> K A.
Definition L := K True.
From elpi.apps Require Import derive.std.
Unset Uniform Inductive Parameters.
Elpi derive.param1 True.
Inductive is_K (A : Type) (PA : A -> Type) : K A -> Type :=
   is_C : forall a : A, PA a -> is_K A PA (C A a).
Definition is_L : L -> Prop := is_K True is_True.
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

No branches or pull requests

1 participant