# HG changeset patch # User desharna # Date 1627385958 -7200 # Node ID ffbd1b7e54397f551fc71143347758aaef9a552a # Parent 62e4ec8cff387dd40d67568a60e887996610e328 tuned Mirabelle's theory selection diff -r 62e4ec8cff38 -r ffbd1b7e5439 src/HOL/Tools/Mirabelle/mirabelle.ML --- a/src/HOL/Tools/Mirabelle/mirabelle.ML Mon Jul 26 13:12:22 2021 +0200 +++ b/src/HOL/Tools/Mirabelle/mirabelle.ML Tue Jul 27 13:39:18 2021 +0200 @@ -134,7 +134,10 @@ fun check_theories strs = let - val theories = map read_theory_range strs; + fun theory_import_name s = + #theory_name (Resources.import_name (Session.get_name ()) Path.current s); + val theories = map read_theory_range strs + |> map (apfst theory_import_name); fun get_theory name = if null theories then SOME NONE else get_first (fn (a, b) => if a = name then SOME b else NONE) theories; @@ -173,8 +176,7 @@ fun make_commands (thy_index, (thy, segments)) = let val thy_long_name = Context.theory_long_name thy; - val thy_name = Context.theory_name thy; - val check_thy = check_theory thy_name; + val check_thy = check_theory thy_long_name; fun make_command {command = tr, prev_state = st, state = st', ...} = let val name = Toplevel.name_of tr;