Commit b939cb83 authored by Andrei Paskevich's avatar Andrei Paskevich

Pmodule: fix a silly mistake in type cloning

name shadowing kills kittens
parent def34e58
......@@ -32,8 +32,6 @@ library/gallery migration
- no warning on lemma functions
cf examples/tests/lemma_functions.mlw
- cloning a recursive data type (e.g. clone list.List)
- "old" and "at" in program code gives a syntax error
(bench/programs/bad-to-keep/old3.mlw), we can do better
......
......@@ -639,8 +639,8 @@ let clone_type_decl inst cl tdl =
if Sits.mem s alg then begin
if not (Mts.mem s.its_ts cl.ts_table) then
let id = id_clone s.its_ts.ts_name in
let s = create_rec_itysymbol id s.its_ts.ts_args in
cl.ts_table <- Mts.add s.its_ts s cl.ts_table
let s' = create_rec_itysymbol id s.its_ts.ts_args in
cl.ts_table <- Mts.add s.its_ts s' cl.ts_table
end else Opt.iter (visit alg s) (Mits.find_opt s def);
List.iter down tl
| Ityvar _ -> () in
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment