diff options
| author | Gaƫtan Gilbert | 2019-05-21 23:06:40 +0200 |
|---|---|---|
| committer | Enrico Tassi | 2019-06-04 13:58:43 +0200 |
| commit | 3b7509b96273f4e412b747e0c55dd193f38fd418 (patch) | |
| tree | a77d952a62174ded2042cb15ee40abf44c328ca2 /vernac/vernacextend.ml | |
| parent | 96231a23a9b76b17541572defb6089e23e80c474 (diff) | |
VernacExtend produces vernac_interp_phase ADT (old name functional_vernac)
+ hide interp_functional_vernac in vernacentries
Diffstat (limited to 'vernac/vernacextend.ml')
| -rw-r--r-- | vernac/vernacextend.ml | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/vernac/vernacextend.ml b/vernac/vernacextend.ml index 644413cbb9..cf704206af 100644 --- a/vernac/vernacextend.ml +++ b/vernac/vernacextend.ml @@ -53,7 +53,16 @@ type vernac_when = | VtLater type vernac_classification = vernac_type * vernac_when -type vernac_command = atts:Attributes.vernac_flags -> pstate:Proof_global.stack option -> Proof_global.stack option +type vernac_interp_phase = + | VtDefault of (unit -> unit) + | VtCloseProof of (pstate:Proof_global.t -> unit) + | VtMaybeOpenProof of (unit -> Proof_global.t option) + | VtOpenProof of (unit -> Proof_global.t) + | VtModifyProof of (pstate:Proof_global.t -> Proof_global.t) + | VtReadProofOpt of (pstate:Proof_global.t option -> unit) + | VtReadProof of (pstate:Proof_global.t -> unit) + +type vernac_command = atts:Attributes.vernac_flags -> vernac_interp_phase type plugin_args = Genarg.raw_generic_argument list @@ -83,7 +92,7 @@ let warn_deprecated_command = (* Interpretation of a vernac command *) -let call opn converted_args ~atts ~pstate = +let call opn converted_args ~atts = let phase = ref "Looking up command" in try let depr, callback = vinterp_map opn in @@ -99,7 +108,7 @@ let call opn converted_args ~atts ~pstate = phase := "Checking arguments"; let hunk = callback converted_args in phase := "Executing command"; - hunk ~atts ~pstate + hunk ~atts with | reraise -> let reraise = CErrors.push reraise in |
