G.NReduce (loc, kind, p)
| IDENT "nrewrite"; dir = direction; what = tactic_term ; where = pattern_spec ->
G.NRewrite (loc, dir, what, where)
- | IDENT "ntry"; LPAREN ; tac = SELF ; RPAREN -> G.NTry (loc,tac)
+ | IDENT "ntry"; tac = SELF -> G.NTry (loc,tac)
+ | IDENT "nrepeat"; tac = SELF -> G.NRepeat (loc,tac)
+ | LPAREN; l = LIST1 SELF; RPAREN -> G.NBlock (loc,l)
| IDENT "nassumption" -> G.NAssumption loc
| SYMBOL "#"; n=IDENT -> G.NIntro (loc,n)
| SYMBOL "#"; SYMBOL "_" -> G.NIntro (loc,"_")
G.NUnivConstraint (loc, strict,u1,u2)
| IDENT "unification"; IDENT "hint"; n = int; t = tactic_term ->
G.UnificationHint (loc, t, n)
+ | IDENT "ncoercion"; name = IDENT; SYMBOL ":"; ty = term;
+ SYMBOL <:unicode<def>>; t = term; "on";
+ id = [ IDENT | PIDENT ]; SYMBOL ":"; source = term;
+ "to"; target = term ->
+ G.NCoercion(loc,name,t,ty,(id,source),target)
| IDENT "nrecord" ; (params,name,ty,fields) = record_spec ->
G.NObj (loc, N.Record (params,name,ty,fields))
]];
status, LSome stm
| (iloc,fname,normal,mode) = include_command ; SYMBOL "." ->
fun ?(never_include=false) ~include_paths status ->
+ let _root, buri, fullpath, _rrelpath =
+ Librarian.baseuri_of_script ~include_paths fname in
+ if never_include then raise (NoInclusionPerformed fullpath)
+ else
+ begin
let stm =
- G.Executable (loc, G.Command (loc, G.Include (iloc, normal, fname)))
- in
+ G.Executable
+ (loc, G.Command (loc, G.Include (iloc,normal,`OldAndNew,fname))) in
!grafite_callback stm;
- let _root, buri, fullpath, _rrelpath =
- Librarian.baseuri_of_script ~include_paths fname
- in
let status =
- if never_include then raise (NoInclusionPerformed fullpath)
- else LE.eval_command status (L.Include (iloc,buri,mode,fullpath))
- in
+ LE.eval_command status (L.Include (iloc,buri,mode,fullpath)) in
let stm =
- G.Executable (loc, G.Command (loc, G.Include (iloc, normal, buri)))
+ G.Executable
+ (loc,G.Command (loc,G.Include (iloc,normal,`OldAndNew,buri)))
in
- status, LSome stm
+ status, LSome stm
+ end
| scom = lexicon_command ; SYMBOL "." ->
fun ?(never_include=false) ~include_paths status ->
!lexicon_callback scom;