equal
deleted
inserted
replaced
407 fun short_thm_name ctxt th = |
407 fun short_thm_name ctxt th = |
408 let |
408 let |
409 val long = Thm.get_name_hint th |
409 val long = Thm.get_name_hint th |
410 val short = Long_Name.base_name long |
410 val short = Long_Name.base_name long |
411 in |
411 in |
412 if Thm.eq_thm_prop (th, singleton (Attrib.eval_thms ctxt) (Facts.named short, [])) then short |
412 (case try (singleton (Attrib.eval_thms ctxt)) (Facts.named short, []) of |
413 else long |
413 SOME th' => if Thm.eq_thm_prop (th, th') then short else long |
|
414 | _ => long) |
414 end |
415 end |
415 |
416 |
416 val map_prod = Ctr_Sugar_Util.map_prod |
417 val map_prod = Ctr_Sugar_Util.map_prod |
417 |
418 |
418 (* Compare the length of a list with an integer n while traversing at most n elements of the list. |
419 (* Compare the length of a list with an integer n while traversing at most n elements of the list. |