Skip to content

Commit

Permalink
Use projection opacity for compat. constant opacity in evarconv.ml
Browse files Browse the repository at this point in the history
  • Loading branch information
Jan-Oliver Kaiser committed Dec 8, 2023
1 parent 2f55506 commit 8a8a22c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pretyping/evarconv.ml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,12 @@ let unfold_projection env evd ts p r c =
let eval_flexible_term ts env evd c =
match EConstr.kind evd c with
| Const (c, u) ->
if TransparentState.is_transparent_constant ts c
let transparent =
match Structures.PrimitiveProjections.find_opt c with
| Some pr -> TransparentState.is_transparent_projection ts pr
| None -> TransparentState.is_transparent_constant ts c
in
if transparent
then Option.map EConstr.of_constr (constant_opt_value_in env (c, EInstance.kind evd u))
else None
| Rel n ->
Expand Down

0 comments on commit 8a8a22c

Please sign in to comment.