equal
deleted
inserted
replaced
961 val thy = Proof_Context.theory_of lthy; |
961 val thy = Proof_Context.theory_of lthy; |
962 |
962 |
963 val (bs, mxs) = map_split (apfst fst) fixes; |
963 val (bs, mxs) = map_split (apfst fst) fixes; |
964 val (arg_Ts, res_Ts) = map (strip_type o snd o fst #>> mk_tupleT_balanced) fixes |> split_list; |
964 val (arg_Ts, res_Ts) = map (strip_type o snd o fst #>> mk_tupleT_balanced) fixes |> split_list; |
965 |
965 |
966 val _ = (case filter_out (fn (_, T) => Sign.of_sort thy (T, HOLogic.typeS)) (bs ~~ arg_Ts) of |
966 val _ = (case filter_out (fn (_, T) => Sign.of_sort thy (T, @{sort type})) (bs ~~ arg_Ts) of |
967 [] => () |
967 [] => () |
968 | (b, _) :: _ => primcorec_error ("type of " ^ Binding.print b ^ " contains top sort")); |
968 | (b, _) :: _ => primcorec_error ("type of " ^ Binding.print b ^ " contains top sort")); |
969 |
969 |
970 val actual_nn = length bs; |
970 val actual_nn = length bs; |
971 |
971 |