Correct chasing of type variable instantiations during type unification.
The following theory should not raise exception TERM:
constdefs
somepredicate :: "(('b => 'b) => ('a => 'a))
=> 'a => 'b => bool"
"somepredicate upd v x == True"
lemma somepredicate_idI:
"somepredicate id (f v) v"
by (simp add: somepredicate_def)
lemma somepredicate_triv:
"somepredicate upd v x ==> somepredicate upd v x"
by assumption
lemmas somepredicate_triv [OF somepredicate_idI]
lemmas st' = somepredicate_triv[where v="h :: nat => bool"]
lemmas st2 = st'[OF somepredicate_idI]