equal
deleted
inserted
replaced
115 fun prep_term thy (Const c) = Const (CodegenNames.const thy (CodegenConsts.norm_of_typ thy c), dummyT) |
115 fun prep_term thy (Const c) = Const (CodegenNames.const thy (CodegenConsts.norm_of_typ thy c), dummyT) |
116 | prep_term thy (Free v_ty) = Free v_ty |
116 | prep_term thy (Free v_ty) = Free v_ty |
117 | prep_term thy (s $ t) = prep_term thy s $ prep_term thy t |
117 | prep_term thy (s $ t) = prep_term thy s $ prep_term thy t |
118 | prep_term thy (Abs (raw_v, ty, raw_t)) = |
118 | prep_term thy (Abs (raw_v, ty, raw_t)) = |
119 let |
119 let |
120 val (v, t) = Syntax.variant_abs (CodegenNames.purify_var raw_v, ty, raw_t); |
120 val (v, t) = Syntax.variant_abs (raw_v, ty, raw_t); |
121 in Abs (v, ty, prep_term thy t) end; |
121 in Abs (v, ty, prep_term thy t) end; |
122 |
122 |
123 |
123 |
124 (* generation of fresh names *) |
124 (* generation of fresh names *) |
125 |
125 |