fix: do not apply eta for structures in Prop
The eta-expansion contains invalid projections, and the eta-rule is subsumed by proof irrelevance anyhow.
This commit is contained in:
parent
3746005f5f
commit
a7c9d2735f
1 changed files with 2 additions and 0 deletions
|
|
@ -67,6 +67,8 @@ inline expr to_cnstr_when_structure(environment const & env, name const & induct
|
|||
expr e_type = whnf(infer_type(e));
|
||||
if (!is_constant(get_app_fn(e_type), induct_name))
|
||||
return e;
|
||||
if (whnf(infer_type(e_type)) == mk_Prop())
|
||||
return e;
|
||||
return expand_eta_struct(env, e_type, e);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue