]> matita.cs.unibo.it Git - helm.git/blob - helm/software/components/ng_kernel/test.ma
splat_args is now better understood and debugged: we need TWO splat_args, one when
[helm.git] / helm / software / components / ng_kernel / test.ma
1 (**************************************************************************)
2 (*       ___                                                              *)
3 (*      ||M||                                                             *)
4 (*      ||A||       A project by Andrea Asperti                           *)
5 (*      ||T||                                                             *)
6 (*      ||I||       Developers:                                           *)
7 (*      ||T||         The HELM team.                                      *)
8 (*      ||A||         http://helm.cs.unibo.it                             *)
9 (*      \   /                                                             *)
10 (*       \ /        This file is distributed under the terms of the       *)
11 (*        v         GNU General Public License Version 2                  *)
12 (*                                                                        *)
13 (**************************************************************************)
14
15 include "nat/plus.ma".
16
17 let rec f n := 
18   match n with
19   [ O => O
20   | S m => let rec g x := 
21              match x with
22              [ O => f m
23              | S q => 
24                   let rec h y := 
25                     match y with 
26                     [ O => f m + g q
27                     | S w => h w]
28                   in
29                     h q] 
30            in 
31              g m].