equal
deleted
inserted
replaced
354 fun match_name c = |
354 fun match_name c = |
355 case Symtab.lookup matcher_tab c of SOME m => m |
355 case Symtab.lookup matcher_tab c of SOME m => m |
356 | NONE => fixrec_err ("unknown pattern constructor: " ^ c) |
356 | NONE => fixrec_err ("unknown pattern constructor: " ^ c) |
357 |
357 |
358 val matches = map (compile_eqs match_name) (map (map (snd o fst)) blocks) |
358 val matches = map (compile_eqs match_name) (map (map (snd o fst)) blocks) |
359 val spec' = map (pair Attrib.empty_binding) matches |
359 val spec' = map (pair Binding.empty_atts) matches |
360 val (lthy, _, _, unfold_thms) = |
360 val (lthy, _, _, unfold_thms) = |
361 add_fixdefs fixes spec' lthy |
361 add_fixdefs fixes spec' lthy |
362 |
362 |
363 val blocks' = map (map fst o filter_out snd) blocks |
363 val blocks' = map (map fst o filter_out snd) blocks |
364 val simps : (Attrib.binding * thm) list list = |
364 val simps : (Attrib.binding * thm) list list = |
386 (*************************************************************************) |
386 (*************************************************************************) |
387 (******************************** Parsers ********************************) |
387 (******************************** Parsers ********************************) |
388 (*************************************************************************) |
388 (*************************************************************************) |
389 |
389 |
390 val opt_thm_name' : (bool * Attrib.binding) parser = |
390 val opt_thm_name' : (bool * Attrib.binding) parser = |
391 @{keyword "("} -- @{keyword "unchecked"} -- @{keyword ")"} >> K (true, Attrib.empty_binding) |
391 @{keyword "("} -- @{keyword "unchecked"} -- @{keyword ")"} >> K (true, Binding.empty_atts) |
392 || Parse_Spec.opt_thm_name ":" >> pair false |
392 || Parse_Spec.opt_thm_name ":" >> pair false |
393 |
393 |
394 val spec' : (bool * (Attrib.binding * string)) parser = |
394 val spec' : (bool * (Attrib.binding * string)) parser = |
395 opt_thm_name' -- Parse.prop >> (fn ((a, b), c) => (a, (b, c))) |
395 opt_thm_name' -- Parse.prop >> (fn ((a, b), c) => (a, (b, c))) |
396 |
396 |