tatoo.git
11 years agoRemove spurious debugging messages.
Kim Nguyễn [Wed, 13 Mar 2013 13:58:57 +0000 (14:58 +0100)]
Remove spurious debugging messages.

11 years agoAdd .. and . to the path syntax.
Kim Nguyễn [Wed, 13 Mar 2013 13:44:53 +0000 (14:44 +0100)]
Add .. and . to the path syntax.

11 years agoRemove git bug related files.
Kim Nguyễn [Wed, 13 Mar 2013 13:07:41 +0000 (14:07 +0100)]
Remove git bug related files.

11 years agoFix a bug in the handling of processing-instruction() test.
Kim Nguyễn [Wed, 13 Mar 2013 11:41:46 +0000 (12:41 +0100)]
Fix a bug in the handling of processing-instruction() test.

11 years agoAdd support for following and preceding using the usual encoding:
Kim Nguyễn [Wed, 13 Mar 2013 11:35:04 +0000 (12:35 +0100)]
Add support for following and preceding using the usual encoding:
axis = ancestor-or-self::node()/axis-sibling::node()/descendant-or-self

11 years agoAdd a kind element to the node tree. Improve support for XPath by
Kim Nguyễn [Wed, 13 Mar 2013 10:21:41 +0000 (11:21 +0100)]
Add a kind element to the node tree. Improve support for XPath by
allowing processing-instruction and comment tests.
Fix the handling of attribute nodes.

11 years agoRework the java test program to print out attribute nodes too.
Kim Nguyễn [Wed, 13 Mar 2013 10:21:24 +0000 (11:21 +0100)]
Rework the java test program to print out attribute nodes too.

11 years agoPut the node_kind type into a NodeKind module in the Common module.
Kim Nguyễn [Wed, 13 Mar 2013 10:19:02 +0000 (11:19 +0100)]
Put the node_kind type into a NodeKind module in the Common module.

11 years agoRemove old test files.
Kim Nguyễn [Wed, 13 Mar 2013 10:16:57 +0000 (11:16 +0100)]
Remove old test files.

11 years agoAdd a new test case for comments nodes.
Kim Nguyễn [Wed, 13 Mar 2013 10:15:57 +0000 (11:15 +0100)]
Add a new test case for comments nodes.

11 years agoAllow the @id syntax in XPath expressions.
Kim Nguyễn [Sun, 10 Mar 2013 18:10:46 +0000 (19:10 +0100)]
Allow the @id syntax in XPath expressions.

11 years agoFix a nasty bug in PtSet module (intersect function was the one
Kim Nguyễn [Sun, 10 Mar 2013 18:05:36 +0000 (19:05 +0100)]
Fix a nasty bug in PtSet module (intersect function was the one
for little-endian patricia trees and therefore buggy)

11 years agoBUG added: [68ad3227c315] following/preceding axes
Kim Nguyễn [Sun, 10 Mar 2013 11:45:58 +0000 (12:45 +0100)]
BUG added: [68ad3227c315] following/preceding axes

11 years agoInitialized bug tracker
Kim Nguyễn [Sun, 10 Mar 2013 11:38:46 +0000 (12:38 +0100)]
Initialized bug tracker

11 years agoMake the test script less verbose
Kim Nguyễn [Sun, 10 Mar 2013 11:36:02 +0000 (12:36 +0100)]
Make the test script less verbose

11 years agoFix descendant-or-self (which wrongly looked for elements in the
Kim Nguyễn [Sun, 10 Mar 2013 11:33:36 +0000 (12:33 +0100)]
Fix descendant-or-self (which wrongly looked for elements in the
right sibling of self)

11 years agoChange the path to the root directory before attempting to open
Kim Nguyễn [Sun, 10 Mar 2013 11:33:07 +0000 (12:33 +0100)]
Change the path to the root directory before attempting to open
any file in the build script

11 years agoMain program output incorrect xml tags
Kim Nguyễn [Sun, 10 Mar 2013 11:08:04 +0000 (12:08 +0100)]
Main program output incorrect xml tags
Adapt test scripts so that they can be called from the project root

11 years agoWorkaround lame ocamlbuild issues (symlinks are not created for
Kim Nguyễn [Sun, 10 Mar 2013 10:55:12 +0000 (11:55 +0100)]
Workaround lame ocamlbuild issues (symlinks are not created for
some reason)

11 years agoAdd .class files to .gitignore
Kim Nguyễn [Sun, 10 Mar 2013 09:53:36 +0000 (10:53 +0100)]
Add .class files to .gitignore

11 years agoSilence an 'unused variable' warning.
Kim Nguyễn [Sun, 10 Mar 2013 09:52:57 +0000 (10:52 +0100)]
Silence an 'unused variable' warning.

11 years agoHandle compiling the java test program from ocamlbuild too
Kim Nguyễn [Sun, 10 Mar 2013 09:52:24 +0000 (10:52 +0100)]
Handle compiling the java test program from ocamlbuild too

11 years agoAdd a missing ';' and remove some dead code and outdated comments.
Kim Nguyễn [Sun, 10 Mar 2013 09:51:48 +0000 (10:51 +0100)]
Add a missing ';' and remove some dead code and outdated comments.

11 years agoMerge branch 'feature/test-suite'
Kim Nguyễn [Sun, 10 Mar 2013 09:27:43 +0000 (10:27 +0100)]
Merge branch 'feature/test-suite'

* feature/test-suite:
  Fix the xml_diff program to also check trailing events (after </root>)
  Adds a set of testing script

11 years agoMerge branch 'feature/attributes'
Kim Nguyễn [Sun, 10 Mar 2013 09:23:36 +0000 (10:23 +0100)]
Merge branch 'feature/attributes'

* feature/attributes:
  - Add a new test case.
  - Fix the handling of attributes.
  - Fix the pretty printing of the attribute test.
  - Add a test case for attribute handling.

11 years agoFix the xml_diff program to also check trailing events (after </root>)
Kim Nguyễn [Sun, 10 Mar 2013 09:17:49 +0000 (10:17 +0100)]
Fix the xml_diff program to also check trailing events (after </root>)
Reformat output of XML query in test program
Fix testing scripts.

11 years agoAdds a set of testing script:
Kim Nguyễn [Sun, 10 Mar 2013 08:37:19 +0000 (09:37 +0100)]
Adds a set of testing script:
     - xml_diff: program to compare two XML files
     - XPathEval.java: reference implementation of XPath 1.0 in Java JAXP
     - gen_test.sh: create reference query results

11 years agoRename the main testing program.
Kim Nguyễn [Sat, 9 Mar 2013 21:40:19 +0000 (22:40 +0100)]
Rename the main testing program.

11 years agoAdd a new test case.
Kim Nguyễn [Sat, 9 Mar 2013 21:38:10 +0000 (22:38 +0100)]
Add a new test case.

11 years agoFix the handling of attributes:
Kim Nguyễn [Sat, 9 Mar 2013 21:36:02 +0000 (22:36 +0100)]
Fix the handling of attributes:
  - make use of the Is_attribute predicate in formulæ
  - Change the encoding of attributes in the tree structure
    (attributes are now proper children with a particular marker
     in the tag name).

11 years agoFix the pretty printing of the attribute test.
Kim Nguyễn [Sat, 9 Mar 2013 17:27:47 +0000 (18:27 +0100)]
Fix the pretty printing of the attribute test.

11 years agoAdd a test case for attribute handling.
Kim Nguyễn [Tue, 5 Mar 2013 18:26:19 +0000 (19:26 +0100)]
Add a test case for attribute handling.

11 years agoFix a bug in the parser where a leading '//' would be parsed incorectly.
Kim Nguyễn [Sat, 9 Mar 2013 16:19:23 +0000 (17:19 +0100)]
Fix a bug in the parser where a leading '//' would be parsed incorectly.

11 years agoAdd a function to remove unreachable states in the automaton
Kim Nguyễn [Sat, 9 Mar 2013 10:38:54 +0000 (11:38 +0100)]
Add a function to remove unreachable states in the automaton

11 years agoExtend the interface with a fold function (over the structure
Kim Nguyễn [Sat, 9 Mar 2013 10:19:21 +0000 (11:19 +0100)]
Extend the interface with a fold function (over the structure
of the formula).

11 years agoRework the formula predicates:
Kim Nguyễn [Sat, 9 Mar 2013 10:14:37 +0000 (11:14 +0100)]
Rework the formula predicates:
       - adds testing for first child, next sibling etc and their converse
       - make the predicate complete w.r.t negation
       - move the evaluation of formula to the Eval module (where the type of
       context is known)

11 years agoAdd the inverse string (superscript -1) to the module.
Kim Nguyễn [Sat, 9 Mar 2013 10:07:25 +0000 (11:07 +0100)]
Add the inverse string (superscript -1) to the module.

11 years agoAdd another test case.
Kim Nguyễn [Fri, 8 Mar 2013 17:46:42 +0000 (18:46 +0100)]
Add another test case.

11 years agoActually fix the problems with negation.
Kim Nguyễn [Fri, 8 Mar 2013 17:45:21 +0000 (18:45 +0100)]
Actually fix the problems with negation.

11 years agoWorking for element only document (with arbitrary paths & negation).
Kim Nguyễn [Tue, 5 Mar 2013 18:22:09 +0000 (19:22 +0100)]
Working for element only document (with arbitrary paths & negation).
- Need to fix attributes handling
- Need to add preceding/following

11 years agoAdd a first runtime function. Positive fragment seems to work.
Kim Nguyễn [Tue, 5 Mar 2013 15:36:26 +0000 (16:36 +0100)]
Add a first runtime function. Positive fragment seems to work.
Negation of backward axes is buggy.

11 years agoAdd an abstract generic interface for trees (of which Naive is an
Kim Nguyễn [Tue, 5 Mar 2013 15:35:12 +0000 (16:35 +0100)]
Add an abstract generic interface for trees (of which Naive is an
implementation).

11 years agoSplit the sig.ml module in *_sig.ml (one for each module)
Kim Nguyễn [Mon, 4 Mar 2013 22:34:44 +0000 (23:34 +0100)]
Split the sig.ml module in *_sig.ml (one for each module)

11 years agoSilence several warnings (missing _ in records, unused variables).
Kim Nguyễn [Tue, 5 Mar 2013 00:35:44 +0000 (01:35 +0100)]
Silence several warnings (missing _ in records, unused variables).

11 years agoForce compilation with -w @A-4 (all warnings but warning number 4
Kim Nguyễn [Tue, 5 Mar 2013 00:34:11 +0000 (01:34 +0100)]
Force compilation with -w @A-4 (all warnings but warning number 4
turned into errors. Warning 4 is 'Fragile pattern-matching').

11 years agoFix the printing of attributes.
Kim Nguyễn [Mon, 4 Mar 2013 21:03:25 +0000 (22:03 +0100)]
Fix the printing of attributes.

11 years agoRemove dead code.
Kim Nguyễn [Mon, 4 Mar 2013 20:50:22 +0000 (21:50 +0100)]
Remove dead code.

11 years agoAllow one to pass several targets to the build script.
Kim Nguyễn [Mon, 4 Mar 2013 20:49:55 +0000 (21:49 +0100)]
Allow one to pass several targets to the build script.

11 years agoUpdate hacking instructions.
Kim Nguyễn [Thu, 14 Feb 2013 16:34:54 +0000 (17:34 +0100)]
Update hacking instructions.

11 years agoSimply use String.make for Pretty.padding and Pretty.line, since it's
Kim Nguyễn [Mon, 4 Mar 2013 17:53:38 +0000 (18:53 +0100)]
Simply use String.make for Pretty.padding and Pretty.line, since it's
only used in places where performance is not critical.

11 years agoReplace internal use of str_formatter with local buffered formatter in
Kim Nguyễn [Mon, 4 Mar 2013 17:52:37 +0000 (18:52 +0100)]
Replace internal use of str_formatter with local buffered formatter in
Atom.print and Formula.print. Use of str_formatter in both was not re-entrant
and caused printing error when displaying a formula containing an Atom.

11 years agoOnly print ∑ instead of ∑-{} when the set is universal.
Kim Nguyễn [Mon, 4 Mar 2013 15:56:09 +0000 (16:56 +0100)]
Only print ∑ instead of ∑-{} when the set is universal.

11 years agoFirst implementation of compilation from XPath to automata using
Kim Nguyễn [Mon, 4 Mar 2013 15:49:36 +0000 (16:49 +0100)]
First implementation of compilation from XPath to automata using
the reverse axes technique.

11 years agoAdd the compilation from existential XPath to automata.
Kim Nguyễn [Tue, 12 Feb 2013 20:52:54 +0000 (21:52 +0100)]
Add the compilation from existential XPath to automata.
This patches misses the book-keeping stuff to keep to build the automaton
object and the compilation of the top-level part of the query.

11 years agoAdd a specific prefix for QNames that represent attributes.
Kim Nguyễn [Thu, 14 Feb 2013 16:23:35 +0000 (17:23 +0100)]
Add a specific prefix for QNames that represent attributes.
Use that prefix in the naive tree implementation for attribute nodes.

11 years agoSynchronise build script with master.
Kim Nguyễn [Tue, 12 Feb 2013 16:37:06 +0000 (17:37 +0100)]
Synchronise build script with master.

11 years agoCompilation of the axis part of an XPath expression.
Kim Nguyễn [Mon, 11 Feb 2013 17:54:28 +0000 (18:54 +0100)]
Compilation of the axis part of an XPath expression.

11 years agoMake the build script compatible with emacs compile mode.
Kim Nguyễn [Tue, 12 Feb 2013 16:31:02 +0000 (17:31 +0100)]
Make the build script compatible with emacs compile mode.

11 years agoAdd functions to normalize an automaton:
Kim Nguyễn [Fri, 8 Feb 2013 17:44:11 +0000 (18:44 +0100)]
Add functions to normalize an automaton:
 (1) Ensures that adding transitions leaves them pairwise disjoint
 (2) Add a function to complete an automaton with dummy states
 (3) Add a normalization function that replaces negative atoms with
     a positive state recognizing the complement

11 years agoBuild script can be called from a subdirectory of the project root.
Kim Nguyễn [Fri, 8 Feb 2013 17:43:27 +0000 (18:43 +0100)]
Build script can be called from a subdirectory of the project root.

11 years agoClean-up the build system.
Kim Nguyễn [Thu, 7 Feb 2013 22:12:04 +0000 (23:12 +0100)]
Clean-up the build system.
- Add a portable build script (only requires ocaml)
- Regroup all build option in the _tags file
- Write a generic myocamlbuild.ml file

11 years agoUse ocamlbuild's built-in support for ocamlfind (requires ocaml 3.12.1)
Kim Nguyễn [Thu, 7 Feb 2013 18:02:12 +0000 (19:02 +0100)]
Use ocamlbuild's built-in support for ocamlfind (requires ocaml 3.12.1)

11 years agoSilences the Makefile.
Kim Nguyễn [Thu, 7 Feb 2013 17:13:09 +0000 (18:13 +0100)]
Silences the Makefile.

11 years agoRefactor module organisation and build process.
Kim Nguyễn [Thu, 7 Feb 2013 09:36:30 +0000 (10:36 +0100)]
Refactor module organisation and build process.

11 years agoImplement formulae parametrized by atomic predicates.
Kim Nguyễn [Wed, 6 Feb 2013 13:30:45 +0000 (14:30 +0100)]
Implement formulae parametrized by atomic predicates.

11 years agoRefactor xpath parser and ast in a submodule.
Kim Nguyễn [Tue, 5 Feb 2013 14:03:32 +0000 (15:03 +0100)]
Refactor xpath parser and ast in a submodule.

11 years agoAvoid one string concatenation in debug printing function.
Kim Nguyễn [Tue, 5 Feb 2013 13:11:09 +0000 (14:11 +0100)]
Avoid one string concatenation in debug printing function.

11 years agoFinish renaming Move constructor to Atom.
Kim Nguyễn [Mon, 4 Feb 2013 15:04:55 +0000 (16:04 +0100)]
Finish renaming Move constructor to Atom.

11 years agoSanitize header files and add a timestamp mark in each source file.
Kim Nguyễn [Wed, 30 Jan 2013 18:10:34 +0000 (19:10 +0100)]
Sanitize header files and add a timestamp mark in each source file.

11 years agoRewrite parser using ocamlyacc to remove further dependencies
Kim Nguyễn [Mon, 28 Jan 2013 23:22:13 +0000 (00:22 +0100)]
Rewrite parser using ocamlyacc to remove further dependencies
on camlp4.

11 years agoRewrite the AST to conform to the W3C grammar
Kim Nguyễn [Mon, 28 Jan 2013 17:44:40 +0000 (18:44 +0100)]
Rewrite the AST to conform to the W3C grammar

11 years agoAdd automata data structure.
Kim Nguyễn [Fri, 21 Dec 2012 13:17:02 +0000 (14:17 +0100)]
Add automata data structure.

11 years agoRemove AbsoluteDOS from the XPath AST.
Kim Nguyễn [Fri, 21 Dec 2012 13:16:39 +0000 (14:16 +0100)]
Remove AbsoluteDOS from the XPath AST.

11 years agoUse ocamlfind to invoke pa_macro appropriately.
Kim Nguyễn [Fri, 21 Dec 2012 10:31:06 +0000 (11:31 +0100)]
Use ocamlfind to invoke pa_macro appropriately.

11 years agoCompile again.
Kim Nguyễn [Wed, 19 Dec 2012 15:33:58 +0000 (16:33 +0100)]
Compile again.

11 years agoModify the run_test script.
Kim Nguyễn [Wed, 12 Dec 2012 20:43:38 +0000 (21:43 +0100)]
Modify the run_test script.

11 years agoMerge branch 'master' of ssh://git.nguyen.vg/tatoo
Kim Nguyễn [Fri, 26 Oct 2012 15:44:25 +0000 (17:44 +0200)]
Merge branch 'master' of ssh://git.nguyen.vg/tatoo

11 years agoCosmetic changes in the Patricia Tree code.
Kim Nguyễn [Fri, 26 Oct 2012 15:38:57 +0000 (17:38 +0200)]
Cosmetic changes in the Patricia Tree code.

11 years agoRefactor the code to have a unique place for signature definition.
Kim Nguyễn [Mon, 24 Sep 2012 16:25:40 +0000 (18:25 +0200)]
Refactor the code to have a unique place for signature definition.
Re-architecture the code to have all signatures in the sigs.ml module.
Any signature which occurs at least twice in the code (e.g. in a.ml
and corresponding a.mli) is put in a module A in Sigs. The signature
can the be included in a.ml and its 'module type of' can be included
in a.mli.

private signatures can stay in the .ml files where they appear.

11 years agoWith -f, we can read the XPath query in a file.
Lucca Hirschi [Fri, 29 Jun 2012 08:28:27 +0000 (10:28 +0200)]
With -f, we can read the XPath query in a file.

11 years agoQueries and script for testing.
Lucca Hirschi [Fri, 29 Jun 2012 08:27:58 +0000 (10:27 +0200)]
Queries and script for testing.

11 years agoRemove spurious debugging statement.
Kim Nguyễn [Thu, 28 Jun 2012 16:58:36 +0000 (18:58 +0200)]
Remove spurious debugging statement.

11 years agoAdd attributes to the test document.
Kim Nguyễn [Thu, 28 Jun 2012 16:47:21 +0000 (18:47 +0200)]
Add attributes to the test document.

11 years agoAdd support for attribute nodes. Correctly escape special charaters
Kim Nguyễn [Thu, 28 Jun 2012 16:46:53 +0000 (18:46 +0200)]
Add support for attribute nodes. Correctly escape special charaters
during printing.

11 years agoAdd support for text elements in the XML document.
Kim Nguyễn [Thu, 28 Jun 2012 16:15:46 +0000 (18:15 +0200)]
Add support for text elements in the XML document.

11 years agoMerge branch 'master' of ssh://git.nguyen.vg/tatoo
Kim Nguyễn [Thu, 28 Jun 2012 15:29:27 +0000 (17:29 +0200)]
Merge branch 'master' of ssh://git.nguyen.vg/tatoo

Conflicts:
.gitignore

11 years agoAdd .gitignore and ignore result of compilation.
Kim Nguyễn [Thu, 28 Jun 2012 15:28:28 +0000 (17:28 +0200)]
Add .gitignore and ignore result of compilation.

11 years ago.gitignore for test.native and _build
Lucca Hirschi [Thu, 28 Jun 2012 14:44:50 +0000 (16:44 +0200)]
.gitignore for test.native and _build

11 years agoUsable version:
Kim Nguyễn [Thu, 28 Jun 2012 12:46:11 +0000 (14:46 +0200)]
Usable version:
       - use ocamlbuild
       - cherry pick Pretty, State, StateSet and Formula from SXSI
       - Parsing of XML documents

11 years agoAdd autoconf infrastructure, license, and macro files.
Kim Nguyễn [Tue, 12 Jun 2012 16:37:20 +0000 (18:37 +0200)]
Add autoconf infrastructure, license, and macro files.