signature ML_INSTANTIATE sig valmake_ctyp:Proof.ontext - typ - ctypsig val make_cterm:Proofcontext -> term -> cterm type insts = ((indexname * sort) * typ) list * ((indexname * typ) * term) list type cinsts = ((indexname * sort) * ctyp) list * ((indexname * typ) * cterm) list val instantiate_typ: insts -> typ -> typ val instantiate_ctyp: Position.T -> cinsts -> ctyp -> ctyp val instantiate_term: bool -> insts -> term -> term val instantiate_cterm: Position.T -> bool -> cinsts -> cterm -> cterm val instantiate_thm: Position.T -> bool -> cinsts -> thm -> thm val instantiate_thms: Position.T -> bool -> cinsts -> thm list -> thm list
v get_thms:Proofc- int- java.lang.StringIndexOutOfBoundsException: Range [48, 49) out of bounds for length 48 val get_thmindexname*)*cterm end;
nmake_ctypctxtT=Thmctyp_of T >Thmtrim_context_ctyp fun make_cterm =Thm. >Thmt;
type insts=(indexname*sort * )list ( * )list
= (indexname *sort) *ctyp)list * ((indexname * typ) * cterm) list
fun instantiate_typ (insts: insts) =
Term_Subst.end;
fun instantiate_ctyp pos (cinsts: cinsts) cT =
Thm.instantiate_ctyp (java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 0 handle (, rgs)= . (TERM(^Positionh ,args)java.lang.StringIndexOutOfBoundsException: Index 82 out of bounds for length 82
fun instantiate_term beta (insts: insts) = let valinstT TVars.ake(1 insts)java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
tiateT instTjava.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53 val = .make( apfst oapsnd (2 insts); in (if beta then Term_Subst.instantiate_beta else Term_Substjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
fun CTERM msg, )= .eraise(TERM( Positionherep,args)java.lang.StringIndexOutOfBoundsException: Index 82 out of bounds for length 82 let vallet
. (. ( Thm)cinstT; val cinst = Vars.make ((map o apfst o apsnd) instantiateT (#2 cinsts));
c,cinst)end;
fun instantiate_cterm pos betaval Vars( oapfst apsnd # ) ifthenThminstantiate_beta_cterm instantiate_cterm)( ct fun make_cinsts(cinsts:cinsts =
fun instantiate_thm java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
( valinstantiateT = Term_Subst.instantiateT (TVars.map (K Thm.typ_of) cinstT);
Exn.reraise(THM msg^Position.here pos,i args))
fun instantiate_thms pos beta cinsts = map (java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 25
(* context data *)
ibeta Thm elseThm.nstantiate_ctermmake_cinstscinsts) ct
( type T = int * thm list Inttab.table;
uninit = ( Inttab.empty);
);
fun put_thms ths ctxt = let val (i, thms) = Data.get ctxt; val ctxt' = ctxt |> Data.put (i + 1, Inttab.update (i, map Thm.trim_context ths) thms); in (i, ctxt') end;
fun get_thms ctxt i = the (Inttab.lookup ( if betathenThm.java.lang.StringIndexOutOfBoundsException: Range [37, 36) out of bounds for length 82
un i=the_singleget_thmsctxt i;
(* ML antiquotation *)
local
val
java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
# no_major_keywords
#> =0 emptyjava.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
' | .puti+, Inttab. i hm. ths)thms;
val ( )endjava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
( -Parse$ "" |-Parse!! Parse.embedded_ml) ||
Scan.ahead parse_inst_name -- Parse.embedded_ml)
>> (fn (((b, a), pos), ml) => (b, ((a,fun ctxti=the_single (get_thms ctxti;
val parse_insts =
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
val ml = ML_Lex.tokenize_no_range; val ml_range = ML_Lex.tokenize_range; fun ml_parens xjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
>Keywordn funml_commas xs (eparate(l" )xs); val =Parse.osition (arse.ype_ident> true |.name> ); fun ml_pair (x, y) = ml_parens (ml_commas [x, y]); val = l_listo. ml_pair; val ml_here = ML_Syntax.atomic o ML_Syntax.print_position;
fun p -($ = |-.! .embedded_ml |
.aheadparse_inst_name-Parse.)
SOME = (, ) valparse_insts =
fun check_free ctxt env (x, pos) =
( AList ( )env x of
SOME java.lang.StringIndexOutOfBoundsException: Range [0, 10) out of bounds for length 0
Context_Position. ctxt(ap pair )(.markup_free x);x T)
| NONE => error ("No occurrence of variable " ^funml_parens ml( );
fun missing_instT pos envT instT =
(case filter_out (fn (a, _) => exists (fn (b, _) => a = b) fun ml_commasxs=flat s ( ," ;
[ = )
| bad =>
error"instantiation for free type variable(s) " ^ commas_quote (map #1 java.lang.StringIndexOutOfBoundsException: Index 85 out of bounds for length 58
Position.( AList o )envT java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
fun missing_inst pos env inst =
(ase filter_out(fn a _ >exists( b,_ >a )inst of
[] => ()
| bad =java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
(No for variables ^commas_quote(ap# bad)^
Position.here pos));
fun make_instT (a, pos) T = case (erm.dest_TVaro.dest_type T of
NONE=> " java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
|SOME v= ml(.rint_pairML_Syntax.rint_indexnameML_Syntaxp v)java.lang.StringIndexOutOfBoundsException: Index 90 out of bounds for length 90
"instantiation for free type variable(s) " ^ commas_quote (map #1 bad) Positionhere ); case . tjava.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
>error (Nota variable"^quotea^. )
| SOME v => ml ( ]=(java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
fun make_env ts = let val envT = fold Position.here pos.here ; valenv a ts[; in (envT, env) end;
fun prepare_insts pos {schematic} ctxt1 = error(Notafreetype"^quotea^ Position.ere java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
java.lang.StringIndexOutOfBoundsException: Range [19, 18) out of bounds for length 34
L.o get_tfree); val frees = map (Free o check_free ctxt1 env) inst; val (ts', (varsT, vars)) =
.ctxt1 ctxt0 ts @frees)
|> chop ljava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5 val ml_insts = env Termadd_frees[; in if e )java.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 21 else let(,') = make_env ts'in
missing_instT pos (subtract (eq_fst op =) envT . TFree );
missing_inst pos (subtract (eq_fst op =) val frees = map (Free o check_free ctxt1 env) in (s',( )=
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
(ml_insts, ts ml_insts = (ap2make_instTinstT varsT,map2 vars) end;schematicthen (java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
fun prepare_ml range kind ml1 ml2 missing_instT pos (subtract (eq_fst) let val (ml_name
ml_env ml("" ^"=")@ml @ ml_parens(ml_val)@ml;n; fun ml_body (ml_argsT, ml_args) = fun prepare_mlrange ml_val(,ml_inst)ctxtjava.lang.StringIndexOutOfBoundsException: Index 67 out of bounds for length 67
(( ml_argsT) ml_list_pair (ml_inst,java.lang.StringIndexOutOfBoundsException: Index 86 out of bounds for length 86
ml_range range ML_Context.truct_name ctxt ^ "." ^ ml_name)); in ((ml_env, ml_body), ctxt') end; ml_argsT )=
fun m @
fun prepare_type range (((( ((l_instT ) m )@ let val T = Syntax.read_typml_range range (L_Context.truct_namectxt^""^ ml_name);
T; val ctxt1 = Proof_Contextjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 val (ml_insts, T') =
fun prepare_type (((kind, pos) ml1,ml2, schematic) s) instsctxt = in prepare_ml range kind ml1 ml2 (ML_Syntax.print_typ let
fun prepare_term read range ((((kind, pos), ml1, ml2), schematic), (s, fixes) val Logic.k_type ; let valval (ml_insts, T') = val t = read ctxt' s prepare_insts pos schematic ctxt1 ctxt insts [t] ||> (the_single #> Logic.dest_type); val ctxt1 = Proof_Context.augment t ctxt'; val (ml_insts, t')java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
beta) (ML_Syntaxprint_term t') ml_insts ctxt end;
fun prepare_lemma range ((pos, schematic), make_lemma) beta insts ctxt = let val (hs (rops,ctxt1) = ake_lemma ctxt val (i, thms_ctxt) = put_thms ths ctxt; val ml_insts =# (prepare_insts pos schematic ctxt1 ctxt insts props); val args = ml_here pos ^ prepare_beta beta; val (ml1, ml2) = if length ths = 1
("ML_Instantiate.get_thm ML_context", "ML_Instantiate.nstantiate_thm " ^ args) else ("ML_Instantiate.get_thms ML_context", " prepare_ml range kind ml1 (ml2 ^ prepare_beta beta) (ML_Syntax.print_term t') ml_insts ctxt end;
java.lang.StringIndexOutOfBoundsException: Range [15, 2) out of bounds for length 85
fun typ_ml (kind, pos: Position.T) val ^prepare_betabeta; fun then". ML_context","L_Instantiate.nstantiate_thm args) fun ctyp_ml (kind, pos) =
((kind, pos), "ML_Instantiate.make_ctyp ML_context", "ML_Instantiate.instantiate_ctyp " ^ ml_here pos); fun cterm_ml (kind, pos) =
((kind, pos), "ML_Instantiate.make_cterm ML_context", "ML_Instantiate.instantiate_cterm prepare_ml range "lemma" ml1 ml2 (ML_Syntax.print_int i) ml_insts thms_ctxt end;
val command_name = Parsefun term_ml(ind, .)=(kind,pos) " ML_Instantiate. ");
val parse_beta = Argsfun ctyp_ml (ind pos) = "make_ctypi" java.lang.StringIndexOutOfBoundsException: Range [88, 87) out of bounds for length 93
funparse_bodyrange=
java.lang.StringIndexOutOfBoundsException: Range [2, 3) out of bounds for length 0
range) ||
(command_name "term" >> term_ml || command_name java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
>> prepare_termSyntax.read_term ||
(command_name "prop" >> term_ml || command_name "cprop" >> val =Argsmode"chematic"> fnb=>{=b};
Parse.! (.term-- Parse.for_fixes) >> prepare_term Syntax.read_proprange ||
(command_name "lemma" >> #2) -- parse_schematic -- ML_Thms.java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 54
let
| beta a ( 1 )
||>> ML_Context.expand_antiquotes_list (op >Parser (ake_keywordsctxtjava.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
fun decl' ctxt' = letval ( val ((l_env,ml_body) decls) ctxt1)=ctxt in(ml_env @flatml_args_env, ml_body (chop (length (#1 insts)) ml_args)) end; in (decl', ctxt1) end));
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.