src/HOL/BNF/Tools/bnf_gfp_rec_sugar.ML
changeset 54975 451786451d04
parent 54974 d1c76303244e
child 54976 b502f04c0442
equal deleted inserted replaced
54974:d1c76303244e 54975:451786451d04
   710       ([dissect_coeqn_sel fun_names basic_ctr_specss eqn_pos NONE NONE eqn0 of_spec_opt concl],
   710       ([dissect_coeqn_sel fun_names basic_ctr_specss eqn_pos NONE NONE eqn0 of_spec_opt concl],
   711        matchedsss)
   711        matchedsss)
   712     else if is_Free head andalso member (op =) fun_names (fst (dest_Free head)) then
   712     else if is_Free head andalso member (op =) fun_names (fst (dest_Free head)) then
   713       if member (op =) ctrs (head_of (unfold_let (the rhs_opt))) then
   713       if member (op =) ctrs (head_of (unfold_let (the rhs_opt))) then
   714         dissect_coeqn_ctr fun_names sequentials basic_ctr_specss eqn_pos eqn0
   714         dissect_coeqn_ctr fun_names sequentials basic_ctr_specss eqn_pos eqn0
   715           (if null prems then SOME eqn0 else NONE) prems concl matchedsss
   715           (if null prems then SOME (snd (HOLogic.dest_eq (HOLogic.dest_Trueprop eqn))) else NONE)
       
   716           prems concl matchedsss
   716       else if null prems then
   717       else if null prems then
   717         dissect_coeqn_code lthy has_call fun_names basic_ctr_specss eqn_pos eqn0 concl matchedsss
   718         dissect_coeqn_code lthy has_call fun_names basic_ctr_specss eqn_pos eqn0 concl matchedsss
   718         |>> flat
   719         |>> flat
   719       else
   720       else
   720         primcorec_error_eqn "cannot mix constructor and code views (see manual for details)" eqn
   721         primcorec_error_eqn "cannot mix constructor and code views (see manual for details)" eqn