equal
deleted
inserted
replaced
1587 |
1587 |
1588 val args = map Logic.mk_type extraTs @ map Free xs; |
1588 val args = map Logic.mk_type extraTs @ map Free xs; |
1589 val head = Term.list_comb (Const (name, predT), args); |
1589 val head = Term.list_comb (Const (name, predT), args); |
1590 val statement = ObjectLogic.ensure_propT thy head; |
1590 val statement = ObjectLogic.ensure_propT thy head; |
1591 |
1591 |
1592 val (defs_thy, [pred_def]) = |
1592 val ([pred_def], defs_thy) = |
1593 thy |
1593 thy |
1594 |> (if bodyT <> propT then I else |
1594 |> (if bodyT <> propT then I else |
1595 Theory.add_trfuns ([], [], map (aprop_tr' (length args)) (NameSpace.accesses' name), [])) |
1595 Theory.add_trfuns ([], [], map (aprop_tr' (length args)) (NameSpace.accesses' name), [])) |
1596 |> Theory.add_consts_i [(bname, predT, Syntax.NoSyn)] |
1596 |> Theory.add_consts_i [(bname, predT, Syntax.NoSyn)] |
1597 |> PureThy.add_defs_i false [((Thm.def_name bname, Logic.mk_equals (head, body)), [])]; |
1597 |> PureThy.add_defs_i false [((Thm.def_name bname, Logic.mk_equals (head, body)), [])]; |