let order_new_goals metasenv subst open_goals ppterm =
let prop,rest = split_goals_in_prop metasenv subst open_goals in
let closed_prop, open_prop = split_goals_with_metas metasenv subst prop in
+ let closed_type, open_type = split_goals_with_metas metasenv subst rest in
let open_goals =
- (List.map (fun x -> x,P) (closed_prop @ open_prop))
+ (List.map (fun x -> x,P) (open_prop @ closed_prop))
@
- (List.map (fun x -> x,T) rest)
+ (List.map (fun x -> x,T) (open_type @ closed_type))
in
let tys =
List.map