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

Adapt to coq/coq#19233 (template_universes don't duplicate level data) #126

Merged
merged 1 commit into from
Jun 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/parametricity.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1064,17 +1064,17 @@ let get_arity t =

(* Workaround to ensure that template universe levels are linear *)
let fix_template_params order evdr env temp b params =
let templ = List.rev temp.template_param_levels in
let templ = List.rev temp.template_param_arguments in
(* For all template levels generate fresh levels for all translated parameters *)
let rec freshen umap templ params = match templ with
| [] ->
let () = assert (List.is_empty params) in
umap, []
| None :: templ ->
| false :: templ ->
let decls, params = List.chop (order + 1) params in
let umap, params = freshen umap templ params in
umap, decls @ params
| Some _ :: templ ->
| true :: templ ->
let decls, params = List.chop (order + 1) params in
let umap, params = freshen umap templ params in
let rel, pdecls = match decls with
Expand Down
Loading