aboutsummaryrefslogtreecommitdiff
path: root/stm
AgeCommit message (Collapse)Author
2017-01-30Fix a typo in STM universe communications.Maxime Dénès
2017-01-17STM: fix run-time classification of VernacInstance (fix #5313)Enrico Tassi
2016-11-29STM: cur_id must be invalid if an error occurs (fix #5191)Enrico Tassi
Line erroneously removed in 17f3346c
2016-11-18Revert "Merge remote-tracking branch 'github/pr/360' into v8.6"Maxime Dénès
This reverts commit b00e039b957b8428c21faec5c76f3a3484cde2cf, reversing changes made to ca9e00ff9b2a8ee17430398a5e0bef2345c39341. It turns out that calling from fake_ide the STM commands that were removed by this PR requires an extension of the XML protocol. So postponing the integration.
2016-11-17[stm] Remove STM-related vernacularsEmilio Jesus Gallego Arias
I think these commands never make a lot of sense on scripts other than debugging and we have better methods now. The last remaining command, used for the tty emulation has been renamed to VtBack, but it should go away at some point too once the legacy interfaces are removed.
2016-10-26STM: make ~valid state id non optional from APIsEnrico Tassi
It used to be Stateid.initial by default. That is indeed a valid state id but very likely not the very best one (that would be the tip of the document).
2016-10-18[stm] Fix record field name clash.Emilio Jesus Gallego Arias
PR#173 introduced a record field name clash in `stm.mli`, with duplicate fields `start/stop` for the types `focus` and `static_block_declaration`. We fix by renaming the younger ones (as to minimize code incompatibilities), but other options are possible/could be preferred, however they would be quite more invasive so I think they should be postponed for the day the Stm API is cleaned up.
2016-10-01Add command 'Set foo Append "bar"' for appending to an option (bug #5109).Guillaume Melquiond
For now, the only meaningful user is "Set Warnings". Example: Section Bar. Local Set Warnings Append "-foo". (* warning foo is now disabled *) End Bar. (* foo is now reenabled, assuming it was before entering the section *)
2016-09-29STM: compute the correct state for edited Qed (#5086)Enrico Tassi
When a proof is 're-opened', the Qed node does not change. Still the STM has to install the old state (where only the future proof has to be updated). This bit was missing. Why was it working: the bug happens only if you reopen the very last proof, i.e. there is no sentence that stays valid after the Qed. If there is such a sentence, its state was computed correctly before, and is not changed. If it is the very last, then the next state is based on the wrong one...
2016-09-29Cleanup API, making inference_hook optionalMatthieu Sozeau
2016-09-28Fix bug #4723 and FIXME in API for solve_by_tacMatthieu Sozeau
This avoids leakage of universes. Also makes Program Lemma/Fact work again, it tries to solve the remaining evars using the obligation tactic.
2016-09-13AsyncTaskQueue: annotate debug feedback messages with worker idEnrico Tassi
2016-09-13stm: feedback forwarding has to be atomicEnrico Tassi
I think that a better place for the mutex would be the printing routine, but I still hope we will get rid of threads in favor of coroutines. So I keep all mutexes in Stm.
2016-09-07Merge branch 'v8.5' into v8.6Pierre-Marie Pédrot
2016-09-07STM: if_verbose on "Checking task ..." (fix #4058)Enrico Tassi
2016-09-06STM: queries give back a dummy safe_id in case of error (#5041)Enrico Tassi
2016-09-06STM: sideff: report safe_id correctly (fix #4968)Enrico Tassi
2016-09-06STM: nested Abort is like nested Qed (fix #4756)Enrico Tassi
There was an "optimization", since Abort is an empty side effect. But that optimization had an impact on the DAG shape. Now a nested proof, no matter if it is kept or dropped, is handled the same.
2016-09-05Fix #5065: Anomaly: Not a proof by inductionMaxime Dénès
Using abstract can create beta-redexes or let-ins in the head of the proof terms. The code projecting out mutual lemmas was not robust enough.
2016-09-05feedback: support multiple feedback listenersEnrico Tassi
So that a module can add his own and look at the traffic
2016-09-02Merge branch 'v8.5' into v8.6Pierre-Marie Pédrot
2016-08-31Fix bug #5043: [Admitted] lemmas pick up section variables.Pierre-Marie Pédrot
We add a flag Keep Admitted Variables that allows to recover the legacy v8.4 behaviour of admitted lemmas. The statement of such lemmas did not depend on the current context variables.
2016-08-30Fix #4871 - interrupting par:abstract kills coqtopMaxime Dénès
Fix done with Enrico.
2016-07-03errors.ml renamed into cErrors.ml (avoid clash with an OCaml compiler-lib ↵Pierre Letouzey
module) For the moment, there is an Error module in compilers-lib/ocamlbytecomp.cm(x)a
2016-07-01Separate flags for fix/cofix/match reduction and clean reduction function names.Maxime Dénès
This is a reimplementation of Hugo's PR#117. We are trying to address the problem that the name of some reduction functions was not saying what they were doing (e.g. whd_betadeltaiota was doing let-in reduction). Like PR#117, we are careful that no function changed semantics without changing the names. Porting existing ML code should be a matter of renamings a few function calls. Also, we introduce more precise reduction flags fMATCH, fFIX, fCOFIX collectively denominated iota. We renamed the following functions: Closure.betadeltaiota -> Closure.all Closure.betadeltaiotanolet -> Closure.allnolet Reductionops.beta -> Closure.beta Reductionops.zeta -> Closure.zeta Reductionops.betaiota -> Closure.betaiota Reductionops.betaiotazeta -> Closure.betaiotazeta Reductionops.delta -> Closure.delta Reductionops.betalet -> Closure.betazeta Reductionops.betadelta -> Closure.betadeltazeta Reductionops.betadeltaiota -> Closure.all Reductionops.betadeltaiotanolet -> Closure.allnolet Closure.no_red -> Closure.nored Reductionops.nored -> Closure.nored Reductionops.nf_betadeltaiota -> Reductionops.nf_all Reductionops.whd_betadelta -> Reductionops.whd_betadeltazeta Reductionops.whd_betadeltaiota -> Reductionops.whd_all Reductionops.whd_betadeltaiota_nolet -> Reductionops.whd_allnolet Reductionops.whd_betadelta_stack -> Reductionops.whd_betadeltazeta_stack Reductionops.whd_betadeltaiota_stack -> Reductionops.whd_all_stack Reductionops.whd_betadeltaiota_nolet_stack -> Reductionops.whd_allnolet_stack Reductionops.whd_betadelta_state -> Reductionops.whd_betadeltazeta_state Reductionops.whd_betadeltaiota_state -> Reductionops.whd_all_state Reductionops.whd_betadeltaiota_nolet_state -> Reductionops.whd_allnolet_state Reductionops.whd_eta -> Reductionops.shrink_eta Tacmach.pf_whd_betadeltaiota -> Tacmach.pf_whd_all Tacmach.New.pf_whd_betadeltaiota -> Tacmach.New.pf_whd_all And removed the following ones: Reductionops.whd_betaetalet Reductionops.whd_betaetalet_stack Reductionops.whd_betaetalet_state Reductionops.whd_betadeltaeta_stack Reductionops.whd_betadeltaeta_state Reductionops.whd_betadeltaeta Reductionops.whd_betadeltaiotaeta_stack Reductionops.whd_betadeltaiotaeta_state Reductionops.whd_betadeltaiotaeta They were unused and having some reduction functions perform eta is confusing as whd_all and nf_all don't do it.
2016-06-29Univs: earlier errors for strict univ decls #4527Matthieu Sozeau
When declaring the universes of a lemma explicitely, throw an error if after minimization the type of a lemma still refers to unbound universes. This is a fix and an incompatibility, but scripts will be backwards compatible themselves. Fix another minor bug in treating universe binders for (Co)Fixpoint.
2016-06-29A new infrastructure for warnings.Maxime Dénès
On the user side, coqtop and coqc take a list of warning names or categories after -w. No prefix means activate the warning, a "-" prefix means deactivate it, and "+" means turn the warning into an error. Special categories include "all", and "default" which contains the warnings enabled by default. We also provide a vernacular Set Warnings which takes the same flags as argument. Note that coqc now prints warnings. The name and category of a warning are printed with the warning itself. On the developer side, Feedback.msg_warning is still accessible, but the recommended way to print a warning is in two steps: 1) create it by: let warn_my_warning = CWarnings.create ~name:"my-warning" ~category:"my-category" (fun args -> Pp.strbrk ...) 2) print it by: warn_my_warning args
2016-06-27Merge branch 'v8.5'Pierre-Marie Pédrot
2016-06-25[feedback] Remove `ErrorMsg` in favor of `Message Error`.Emilio Jesus Gallego Arias
The ErrorMsg datatype was introduced to allow locations in messages, however, it was redundant with error and used only in one place. We remove it in favor of a more uniform treatment of messages with location. This patch also removes the use of `Loc.ghost` in one place. Lightly tested.
2016-06-18Moving the typing_flags to the environment.Pierre-Marie Pédrot
2016-06-17par: like all: but in parallelEnrico Tassi
This commit documents par:, fixes its semantics so that is behaves like all:, supports (toplevel) abstract and optimizes toplevel solve. `par: solve [tac]` is equivalent to `Ltac tac1 := solve[tac]...par: tac1` but is optimized for failures: if one goal fails all are aborted immediately. `par: abstract tac` runs abstract on the generated proof terms. Nested abstract calls are not supported.
2016-06-16Factorizing the uses of Declareops.safe_flags.Pierre-Marie Pédrot
This allows a smooth addition of various unsafe flags without wreaking havoc in the ML codebase.
2016-06-16Merge PR #79: Let the kernel assume that a (co-)inductive type is positive.Pierre-Marie Pédrot
2016-06-15Remove the syntax changes introduced by this branch.Pierre-Marie Pédrot
We decided to only export the API, so that an external plugin can provide this feature without having to merge it in current Coq trunk. This postpones the attribute implementation in vernacular commands after 8.6.
2016-06-15Allow `Pretyping.search_guard` to not check guardArnaud Spiwack
This is a minimal modification to the pretyping interface which allows for toplevel fixed points to be accepted by the pretyper. Toplevel co-fixed points are accepted without this. However (co-)fixed point _nested_ inside a `Definition` or a `Fixpoint` are always checked for guardedness by the pretyper.
2016-06-14Merge remote-tracking branch 'origin/pr/166' into trunkEnrico Tassi
Add -o option to coqc
2016-06-14Merge remote-tracking branch 'origin/pr/205' into trunkEnrico Tassi
2016-06-14Merge remote-tracking branch 'origin/pr/182' into trunkEnrico Tassi
2016-06-14Admitted: fix #4818 return initial stmt and univsMatthieu Sozeau
2016-06-13STM classification: VernacTimeout may contain an "internal command".Maxime Dénès
2016-06-13Print Assumptions and co. can "pierce opacity".Maxime Dénès
2016-06-07DocumentationEnrico Tassi
2016-06-06Renaming: ErrorBlock -> ProofBlockEnrico Tassi
Since this is really what they are. Squashing this renaming back to the root of the feature branch is hard.
2016-06-06STM: each proof block can be enabled separatelyEnrico Tassi
By default we enable only {} and par: that are detectable in a complete way.
2016-06-06Error box detection run only on errorEnrico Tassi
Advantage: 0 cost if no error occurs Disadvantage: a box *must* end with the error absorbing command
2016-06-06STM: proof block detection for indentationEnrico Tassi
2016-06-06rebase on trunkEnrico Tassi
2016-06-06STM: fix error reporting of par:Enrico Tassi
2016-06-06STM: proof block detection made optional + simple testEnrico Tassi
2016-06-06STM: proof block detection for par:Enrico Tassi
"par: tac" is a terminator, if it fails we can admit all focused goals and continue.