equal
deleted
inserted
replaced
349 val unchecks = these_unchecks thy [class]; |
349 val unchecks = these_unchecks thy [class]; |
350 val b = Morphism.binding morph c; |
350 val b = Morphism.binding morph c; |
351 val c' = Sign.full_name thy b; |
351 val c' = Sign.full_name thy b; |
352 val rhs' = Pattern.rewrite_term thy unchecks [] rhs; |
352 val rhs' = Pattern.rewrite_term thy unchecks [] rhs; |
353 val ty' = Term.fastype_of rhs'; |
353 val ty' = Term.fastype_of rhs'; |
354 val rhs'' = map_types ((*Type.strip_sorts o *)Logic.varifyT) rhs'; |
354 val rhs'' = map_types Logic.varifyT rhs'; |
355 in |
355 in |
356 thy |
356 thy |
357 |> Sign.add_abbrev (#1 prmode) pos (b, rhs'') |
357 |> Sign.add_abbrev (#1 prmode) pos (b, rhs'') |
358 |> snd |
358 |> snd |
359 |> Sign.add_const_constraint (c', SOME ty') |
359 |> Sign.add_const_constraint (c', SOME ty') |