src/Pure/ML/ml_thms.ML
changeset 41376 08240feb69c7
parent 37216 3165bc303f66
child 41486 82c1e348bc18
equal deleted inserted replaced
41375:7a89b4b94817 41376:08240feb69c7
    37   (fn _ => scan >> (fn ths => fn background =>
    37   (fn _ => scan >> (fn ths => fn background =>
    38     let
    38     let
    39       val i = serial ();
    39       val i = serial ();
    40       val (a, background') = background
    40       val (a, background') = background
    41         |> ML_Antiquote.variant kind ||> put_thms (i, ths);
    41         |> ML_Antiquote.variant kind ||> put_thms (i, ths);
    42       val ml = (thm_bind kind a i, "Isabelle." ^ a);
    42       val ml = (thm_bind kind a i, " Isabelle." ^ a ^ " ");
    43     in (K ml, background') end));
    43     in (K ml, background') end));
    44 
    44 
    45 val _ = thm_antiq "thm" (Attrib.thm >> single);
    45 val _ = thm_antiq "thm" (Attrib.thm >> single);
    46 val _ = thm_antiq "thms" Attrib.thms;
    46 val _ = thm_antiq "thms" Attrib.thms;
    47 
    47 
    67           |> Proof.theorem NONE after_qed propss
    67           |> Proof.theorem NONE after_qed propss
    68           |> Proof.global_terminal_proof methods;
    68           |> Proof.global_terminal_proof methods;
    69         val (a, background') = background
    69         val (a, background') = background
    70           |> ML_Antiquote.variant "lemma" ||> put_thms (i, the_thms ctxt' i);
    70           |> ML_Antiquote.variant "lemma" ||> put_thms (i, the_thms ctxt' i);
    71         val ml =
    71         val ml =
    72           (thm_bind (if length (flat propss) = 1 then "thm" else "thms") a i, "Isabelle." ^ a);
    72           (thm_bind (if length (flat propss) = 1 then "thm" else "thms") a i,
       
    73             " Isabelle." ^ a ^ " ");
    73       in (K ml, background') end));
    74       in (K ml, background') end));
    74 
    75 
    75 end;
    76 end;
    76 
    77