aboutsummaryrefslogtreecommitdiff
path: root/interp
AgeCommit message (Collapse)Author
2019-05-29Merge PR #10248: Move the Discharge module in the kernel and merge it with ↵Maxime Dénès
Cooking Reviewed-by: SkySkimmer Ack-by: herbelin Reviewed-by: maximedenes Ack-by: ppedrot
2019-05-26More precise type for Safe_typing export and inlining of private constants.Pierre-Marie Pédrot
We get rid of the future wrappers, as all callers are immediately forcing the result.
2019-05-26Actually merge Discharge into Cooking.Pierre-Marie Pédrot
This is the intended module for the feature provided by the inductive discharge. This allows for a bit of code sharing and cleanup.
2019-05-26Share API between Discharge and Cooking.Pierre-Marie Pédrot
2019-05-26Move the Discharge module into the kernel.Pierre-Marie Pédrot
2019-05-23do not parse `|` as infix in patterns; parse `|}` as `|` `}`Georges Gonthier
* use mixfix `(p1 | … | pn)` notation for nested disjunctive patterns, rather than infix `|`, making pattern syntax consistent with term syntax. * disable extending `pattern` grammar with notation incompatible with the nested disjunctive pattern syntax `(p1 | … | pn)`, such as the `(p | q)` divisibility notation used by `Numbers`. * emit a (disabled by default) `disj-pattern-notation` warning when such `Notation` is attempted. * update documentation accordingly; document incompatibilities in `changelog`. * comment special treatment of `(num)` in grammar. * update file extensions in `Pcoq` header comment. * correct the keyword declarations to reflect the contents of the grammar files; perhaps there should be an option to disable implicit keyword extension in a `.mlg` file, so that these lists could actually be checked. * parse the `|}` manifest record terminator as `|` followed by `}`, eliminating the `|}` token which conflicts with notations that use `|` as a terminator (such as, absolute value, norm, or cardinal in MathComp). Since `|` is now an `operconstr` _and_ `pattern` terminator, `bar_cbrace` rule checks for contiguous symbols, this change entails no visible behaviour change.
2019-05-23Fixing typos - Part 2JPR
2019-05-22Merge PR #10177: Fix #10176: shadowing vs automatic class based ↵Hugo Herbelin
generalization + cleanups Reviewed-by: herbelin
2019-05-21Merge PR #10174: Further cleanup of the side-effect machineryGaëtan Gilbert
Reviewed-by: SkySkimmer Reviewed-by: gares Reviewed-by: maximedenes
2019-05-20Ensure statically that declarations built by Term_typing are direct.Pierre-Marie Pédrot
This removes a lot of cruft breaking the opaque proof abstraction in Safe_typing and similar.
2019-05-19Merge the definition of constants and private constants in the API.Pierre-Marie Pédrot
2019-05-19Inverting the responsibility to define logically a constant in Declare.Pierre-Marie Pédrot
The code was intricate due to the special handling of side-effects, while it was sufficient to extrude the logical definition to make it clearer. We thus declare a constant in two parts, first purely kernel-related, then purely libobject-related.
2019-05-19Implicit Quantifiers recurse in continuation of let-inJasper Hugunin
2019-05-18Merge PR #10134: Simplify impargsHugo Herbelin
Ack-by: SkySkimmer Reviewed-by: herbelin Ack-by: jashug
2019-05-16Fix #10176: shadowing vs automatic class based generalizationGaëtan Gilbert
2019-05-16binder_kind Generalized: remove 1st arg as it's always ImplicitGaëtan Gilbert
https://coq.inria.fr/distrib/current/refman/language/gallina-extensions.html#implicit-generalization >The generalizing binders `{ } and `( ) work similarly to their >explicit counterparts, only binding the generalized variables >implicitly, as maximally-inserted arguments. I guess this was meant to provide a way to get "(A:_) {B:bla A}" from "`{B:bla A}" (where A is generalizable) but there's no syntax for it so let's drop the ml side until such a syntax exists.
2019-05-16Cleanup Implicit_quantifiers.implicit_applicationGaëtan Gilbert
- fix misleading indentation - simplify "let a, b = e in a, b" -> "e"
2019-05-13Merge PR #10076: [Canonical structures] Annotation to field declarations to ↵Enrico Tassi
prevent them from being “canonical” Ack-by: SkySkimmer Ack-by: Zimmi48 Reviewed-by: gares Ack-by: maximedenes Ack-by: robbertkrebbers Ack-by: vbgl
2019-05-10[Canonical structures] Some projections may not be canonicalVincent Laporte
2019-05-10Remove ref from some implicit_discharge_requestJasper Hugunin
2019-05-10Simplify dispose_implicitsJasper Hugunin
2019-05-10[api] Remove 8.10 deprecations.Emilio Jesus Gallego Arias
Some of them are significant so presumably it will take a bit of effort to fix overlays. I left out the removal of `nf_enter` for now as MTac2 needs some serious porting in order to avoid it.
2019-04-29Revert #8187Vincent Laporte
2019-04-29Revert #9249Vincent Laporte
2019-04-23Merge PR #9889: Fix pretty-printing of primitive integersMaxime Dénès
Ack-by: JasonGross Ack-by: erikmd Reviewed-by: maximedenes Ack-by: proux01
2019-04-16[ast] [constrexpr] Make recursion_order_expr an AST node.Emilio Jesus Gallego Arias
This is a bit more uniform.
2019-04-16Clean the representation of recursive annotation in ConstrexprMaxime Dénès
We make clearer which arguments are optional and which are mandatory. Some of these representations are tricky because of small differences between Program and Function, which share the same infrastructure. As a side-effect of this cleanup, Program Fixpoint can now be used with e.g. {measure (m + n) R}. Previously, parentheses were required around R.
2019-04-11Merge PR #9909: Remove all but one call to `Global` in the pretyperPierre-Marie Pédrot
Ack-by: ejgallego Reviewed-by: gares Ack-by: maximedenes Ack-by: ppedrot
2019-04-10Merge PR #9910: [api] [proofs] Remove dependency of proofs on interp.Gaëtan Gilbert
Reviewed-by: SkySkimmer
2019-04-10Remove calls to global env in InductiveopsMaxime Dénès
2019-04-10Remove calls to Global.env and Libobject from RecordopsMaxime Dénès
2019-04-10Remove calls to Global.env in Glob_opsMaxime Dénès
2019-04-10Functionalize env in type classesMaxime Dénès
I had to reorganize the code a bit. The Context command moved to comAssumption, as it is not so related to type classes. We were able to remove a few hooks on the way.
2019-04-06Fix pretty-printing of primitive integersErik Martin-Dorel
A scope delimiter was missing for primitive integers constants. Add related regression tests.
2019-04-05[api] [proofs] Remove dependency of proofs on interp.Emilio Jesus Gallego Arias
We perform some cleanup and remove dependency of `proofs/` on `interp/`, which seems logical. In fact, `interp` + `parsing` are quite self-contained, so if there is interest we could also make tactics to depend directly on proofs.
2019-04-05Remove cache in HeadsMaxime Dénès
This cache makes the pretyper depend on components that should morally be higher-level (Libobject and co), so I'd like to see how critical this cache is before taking any action.
2019-04-02Allow underscores as comments in numeral constants.Pierre Roux
The numerals lexed are now [0-9][0-9_]* ([.][0-9_]+)? ([eE][+-]?[0-9][0-9_]*)?
2019-04-02Add parsing of decimal constants (e.g., 1.02e+01)Pierre Roux
Rather than integers '[0-9]+', numeral constant can now be parsed according to the regexp '[0-9]+ ([.][0-9]+)? ([eE][+-]?[0-9]+)?'. This can be used in one of the two following ways: - using the function `Notation.register_rawnumeral_interpreter` in an OCaml plugin - using `Numeral Notation` with the type `decimal` added to `Decimal.v` See examples of each use case in the next two commits.
2019-04-02Rename raw_natural_number to raw_numeralPierre Roux
In anticipation of an extension from natural numbers to other numeral constants.
2019-04-01Replace type sign = bool with SPlus | SMinusPierre Roux
2019-04-01Update numeral notation printing docJason Gross
Fixes #9844
2019-04-01[numeral] Add a case for IndRef in constr_of_globJason Gross
Fixes #9840
2019-04-01[interp] [numeral] Use cbv rather than vmJason Gross
It is important to fully normalize the term, *including inductive parameters of constructors*; see https://github.com/coq/coq/issues/9840 for details on what goes wrong if this does not happen, e.g., from using the vm rather than cbv. Supersedes / closes #9655
2019-03-30Error when [foo.(bar)] is used with nonprojection [bar]Gaëtan Gilbert
(warn if bar is a nonprimitive projection)
2019-03-25Merge PR #9586: Use named_context_val for fast lookup in intern named referenceEmilio Jesus Gallego Arias
Reviewed-by: herbelin Reviewed-by: ppedrot
2019-03-18Use named_context_val for fast lookup in intern named referenceGaëtan Gilbert
2019-03-18Fix constr_matching on SPropGaëtan Gilbert
2019-03-14Add relevance marks on binders.Gaëtan Gilbert
Kernel should be mostly correct, higher levels do random stuff at times.
2019-03-14Add a non-cumulative impredicative universe SProp.Gaëtan Gilbert
Note currently it's impossible to define inductives in SProp because indtypes.ml and the pretyper aren't fully plugged.
2019-03-14Make Sorts.t privateGaëtan Gilbert