src/HOL/Tools/Mirabelle/mirabelle.ML
changeset 73848 77306bf4e1ee
parent 73847 58f6b41efe88
parent 73824 6e9a47d3850c
child 73849 4eac16052a94
--- a/src/HOL/Tools/Mirabelle/mirabelle.ML	Thu Jun 10 11:21:57 2021 +0200
+++ b/src/HOL/Tools/Mirabelle/mirabelle.ML	Thu Jun 10 11:54:14 2021 +0200
@@ -177,7 +177,8 @@
                   val name = Toplevel.name_of tr;
                   val pos = Toplevel.pos_of tr;
                 in
-                  if can (Proof.assert_backward o Toplevel.proof_of) st andalso
+                  if Context.proper_subthy (\<^theory>, thy) andalso
+                    can (Proof.assert_backward o Toplevel.proof_of) st andalso
                     member (op =) whitelist name andalso check_thy pos
                   then SOME {theory_index = thy_index, name = name, pos = pos,
                     pre = Toplevel.proof_of st, post = st'}