X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Flambda-delta%2Fbasic_rg%2FbrgSubstitution.ml;h=e482b66c0bc4ac951171c555e0022f578fd4759b;hb=c2b39b7ef14ab610cb2056fb6b75492c7068288e;hp=5adc12631f26778d4c9fa77a1b9c75a487c3423c;hpb=dcdee4ca839dac671924a95f0ada71faf06a8be4;p=helm.git diff --git a/helm/software/lambda-delta/basic_rg/brgSubstitution.ml b/helm/software/lambda-delta/basic_rg/brgSubstitution.ml index 5adc12631..e482b66c0 100644 --- a/helm/software/lambda-delta/basic_rg/brgSubstitution.ml +++ b/helm/software/lambda-delta/basic_rg/brgSubstitution.ml @@ -13,16 +13,16 @@ module B = Brg let iter map d = let rec iter_bind d = function - | B.Void as b -> b - | B.Abst w -> B.Abst (iter_term d w) - | B.Abbr v -> B.Abbr (iter_term d v) + | B.Void _ as b -> b + | B.Abst (a, w) -> B.Abst (a, iter_term d w) + | B.Abbr (a, v) -> B.Abbr (a, iter_term d v) and iter_term d = function | B.Sort _ as t -> t | B.GRef _ as t -> t | B.LRef (a, i) as t -> if i < d then t else map d a i | B.Cast (a, w, v) -> B.Cast (a, iter_term d w, iter_term d v) | B.Appl (a, w, u) -> B.Appl (a, iter_term d w, iter_term d u) - | B.Bind (a, b, u) -> B.Bind (a, iter_bind d b, iter_term (succ d) u) + | B.Bind (b, u) -> B.Bind (iter_bind d b, iter_term (succ d) u) in iter_term d @@ -33,6 +33,6 @@ let lift g h d t = if h = 0 then g t else g (iter (lift_map h) d t) let lift_bind g h d = function - | B.Void -> g B.Void - | B.Abst w -> let g w = g (B.Abst w) in lift g h d w - | B.Abbr v -> let g v = g (B.Abbr v) in lift g h d v + | B.Void _ as b -> g b + | B.Abst (a, w) -> let g w = g (B.abst a w) in lift g h d w + | B.Abbr (a, v) -> let g v = g (B.abbr a v) in lift g h d v