Second shipping

The Peano arithmetic passed. New features:

* Pattern matching algorithm (linear)
* Rewriting algorithm
* Type checking of the rewriting system
* AST of the terms and some checking
* New AST for the rewriting system.
* New tests and a lot of bug fixes.