src/HOL/Tools/ctr_sugar.ML
changeset 54617 1183bd511980
parent 54615 62fb5af93fe2
child 54618 e78e7df36690
equal deleted inserted replaced
54616:a21a2223c02b 54617:1183bd511980
   930             Local_Theory.declaration {syntax = false, pervasive = true}
   930             Local_Theory.declaration {syntax = false, pervasive = true}
   931               (fn phi => Case_Translation.register
   931               (fn phi => Case_Translation.register
   932                  (Morphism.term phi casex) (map (Morphism.term phi) ctrs))
   932                  (Morphism.term phi casex) (map (Morphism.term phi) ctrs))
   933          |> Local_Theory.notes (anonymous_notes @ notes) |> snd
   933          |> Local_Theory.notes (anonymous_notes @ notes) |> snd
   934          |> register_ctr_sugar fcT_name ctr_sugar
   934          |> register_ctr_sugar fcT_name ctr_sugar
   935          |> Local_Theory.background_theory
   935          |> null (Thm.hyps_of (hd case_thms))
   936            (add_ctr_code fcT_name As (map dest_Const ctrs) inject_thms distinct_thms case_thms))
   936            ? Local_Theory.background_theory
       
   937              (add_ctr_code fcT_name As (map dest_Const ctrs) inject_thms distinct_thms case_thms))
   937       end;
   938       end;
   938   in
   939   in
   939     (goalss, after_qed, lthy')
   940     (goalss, after_qed, lthy')
   940   end;
   941   end;
   941 
   942