Ferruccio Guidi [Wed, 3 Jun 2009 20:20:11 +0000 (20:20 +0000)]
- boxPp: added missing spaces
- core_notation: bug fix in the input notation for congruent: we added term 90 after \sub
- library/nat/permutation.ma: added input notation for transpose and fixed term precedence in its output notation
- library/Makefile: compilation of single files re-enabled.
The syntax for compiling file.ma is is "make file.mo" and "make file.mo.opt"
now nat/congruence.ma and nat/permutation.ma are fully reconstructed :)
1) CicNotationPres.render: type changed to make it more general (no
dependency on the Hashtbl) and URI/REFERENCE agnostic.
A compatibility function CicNotationPres.lookup_uri is provided to
easily map the (old) Hashtbl to the (new) lookup function.
2) user interface partially changed to render NG objects in the CicBrowser
and to follow NG hyperlinks
3) New CicNotationPt entries NRef (similar to Uri) and NRefPattern
(similar to UriPattern) to avoid hijacking the old Uris (actually,
uris + xpointers) to also hold new references.
This allows to properly implement notation (for NG) and to properly
handle hyperlinks.
4) all remaining Warnings for unused variables fixed (in some way or
another, hopefully the correct one)
5) GrafiteEngine, NQed: the height of an object is now recomputed just
before putting it in the environment. This fixes all the bugs related
to reduction.
6) GrafiteParser/LexiconEngine: both old URIs and new references are now
allowed in NG terms and in notations
7) ng_cic_content: rendering functions now return an "id |-> reference" table
to correctly implement MathML hrefs
8) NReference: new compare function
9) NCicUntrusted: new height_of_obj_kind function (to be used in GrafiteEngine)
10) OCic2NCic: new reference_of_oxuri function to map old uris + xpointers
into new references
11) bug fixed: after the commit by Enrico that starts using the extensible
PTS, the old-to-new objects translations used to map Type into "Type" which
was not declared. Type is now mapped into Type[0] and Type (as a "notation")
is now a synonim of Type[0] (only during parsing for now)
12) bug fixed: after the commit by Enrico that cleans up terms for
alpha-conversion and dummy products, the test in NCicTypeChecker that
verifies the consistency of left parameters in constructor --- that used
to do that NOT up to alpha-conversion --- used to fail when dummy products
were found. The test is now relaxed to include alpha-conversion.
13) bug fixed: NCicTypeChecker did not verify that a .dec reference pointed to
an axiom and that a .def reference did not point to an axiom. Fixed.
Ferruccio Guidi [Fri, 29 May 2009 14:26:50 +0000 (14:26 +0000)]
- cicNotationParser: added extra space to TeX control sequences accordind to previous commit of cicNotationLexer
- core_notation: bugfix in the notation for exp
- library/nat/congruence.ma: notation for "congruent" moved to core_notation
Ferruccio Guidi [Thu, 28 May 2009 17:17:29 +0000 (17:17 +0000)]
- cicInspect: relevant nodes count updated: letin nodes are not relevant
- Procedural: reflexivity is now supported
- grafiteAst: boolean flag for include to tag inclusion of a source file. This command is relevant for .ma generation only. [ the source file of a .mma is not included in the generated .ma ]
- cicNotationLexer: unexpanded TeX macro symbols are now encoded with an extra space at the end. This is consistent with the concept of TeX sequence and fixes a bug in the renering of these symbols. The space is needed for reparsing!
Ferruccio Guidi [Wed, 27 May 2009 17:16:31 +0000 (17:16 +0000)]
- Procedural: we specify more unifiers for apply to help higher-order unification
- cicNotationPp: bugfix in the notation for Meta and ImplicitPattern
- transcript: grafite lexer/parser updated
Basic support for interpretations for NG:
1) only interpretations for old objects are used
(i.e. no way yet to declare a new interpretation on a new object)
2) only interpretations for constants (no inductive definitions/constructors)
since we have no faithful embedding of new references into old URIs
3) no support for backtracking (I think)
Ferruccio Guidi [Thu, 21 May 2009 19:04:29 +0000 (19:04 +0000)]
Procedural: we use the expected type rather than the inferred type when we perform a cut to keep the goal in sync with the expected type.
we try to beta-reduce the elimination pattern when it does not match the goal/expected type
now nat/compare.ma and Z/z.ma are fully reconstructed :)
Ferruccio Guidi [Wed, 20 May 2009 20:44:49 +0000 (20:44 +0000)]
we catch the refiner errors in the critical step and fall back to the non-criticall version (this is just for debugging)
bug-fix in elimination recognition euristics
now nat/orders.ma and nat/times.ma are fully reconstructed :)
1) GrafiteAst.NEval => GrafiteAst.NReduce
2) new tactic "nnormalize" implemented
3) "ngeneralize" now uses "wanted" when no term is selected
(so that it is possible to use ngeneralize to move an
hypothesis down)
4) new syntax for non punctuational tinycals was missing
1) new tactic normalize (low-level function implemented in
nCicTacReduction)
2) the select tactic used to generate fresh metavariables by unifying the
"wanted" part of the pattern in a root where "wanted" did not occur.
Those metavariables are now removed in that case
1) order of processing of case branches reverted (to generate metas in
left-to-right order)
2) metas generated by eat_prods are now re-ordered so that they occur
in left-to-right order
Patch to add a debugging string to HExtlib.split_nth reverted
(we cannot add a string to every function that raises an exception).
To know where the problem is, it is sufficient to look at the backtrace.
However:
1) it works for matitac -debug
2) ocaml is so dumb that it says "compile with -g" when it cannot find
the executable in the current working directory. Since Matita chdir
to the directory where the .ma file is, you need to put a copy of
matitac (or make a symbolic link) where the .ma file is.
Ferruccio Guidi [Thu, 14 May 2009 13:43:55 +0000 (13:43 +0000)]
- libraryObjects: new default "natural numbers" with the uri of nat.
alias num "natural number" uses this one instead of the hardcoded uri (removed)
also destroy_nat (moved to termAcicContent) looks at this default
Ferruccio Guidi [Wed, 13 May 2009 18:44:42 +0000 (18:44 +0000)]
- matitaEngine: some commands like "coercion" must not be executed when mma's are dumped. This hack will be removed when mma's will be executed while dumped
- primitiveTactics: bugxix in the generation of the predicate for elim: we leave to the refiner the task of instantiating the types of the pattern variables.
Note: the head beta-reductions after the elimination must be performed following the instantiated predicate because (\lambda x:?.t v) does not beta-reduce (bug or feature?)
Andrea Asperti [Wed, 13 May 2009 09:27:34 +0000 (09:27 +0000)]
Signature is computed on the initial goal, once and for all.
Ripristined the filtering on candidates also for non-smart applications
(was too slow on some examples, e.g. in Fsub *
Ferruccio Guidi [Tue, 12 May 2009 19:04:32 +0000 (19:04 +0000)]
- Procedural: we now reconstruct "let H := v in t" with "intros (1) H" when the goal starts with an abbreviation. Clearbody before change in reactivated (to change the inferred type of the abbreviations of sort Prop)
- RELATIONAL: notation fixup
- character: autobatch fixup
- ng_tactics: dependences were not committed correctly
- critical bug fixed in NCicSubstitution.lift:
(0,Irl 0) was lifted to (1,Irl 0)
but later on NCicTypechecker.check_metasenv_consistency assumes the
invariant that the currenct context has length (m+n) if the metavariable
is (m,Irl n). But this invariant is false in the case (m, Irl 0) when m > 0.
- in NCicRefiner there was one line to normalize (m,Irl 0) and (m,Ctx []) to
(0,...). Is it still required after the first patch to the kernel? I suspect
no, thus I put an assert false to check.
Bug fixed: left parameters of constructors were unified before refining them.
Fixed, but the new code typechecks the constructors twice (in order to
re-compute) the sort without the inductive types. Is a more efficient
implementation worth the effort?
1) better implementation of NObj that now calls recursively NQed
to avoid code duplication
2) NQed now calls the kernel to check the object, since add_obj is too
low level for that (this makes a huge difference with the previous
architecture, but will probably break when dealing with undo)
Ferruccio Guidi [Wed, 6 May 2009 18:26:56 +0000 (18:26 +0000)]
- cicUtil: is_sober now detects folded applications
- Procedural: bugfix in pattern generation for elim/rewrite, better debug output, applications are flattened before alpha-conversion to hide a bug of the double type inference :( (it generates folded applications)
- applyTransformation: coercions are shown when rendering a tactic because Procedural is not aware of coercions :(
Ferruccio Guidi [Tue, 5 May 2009 17:23:49 +0000 (17:23 +0000)]
- hExtlib: new function "list_assoc_all"
- procedural: new flag "nodefaults" to turn off "default" based tactics. The `Variant flavour is now activated
- grafiteAst: now inline accepts a list of flags that can be easily extended
current flags are: procedural, nodefaults, depth=n, prefix="string" (untested),
theorem, definition, etc.
- transcript: support for explicitly provided inline flags