diff options
author | Bernhard Schommer <bernhardschommer@gmail.com> | 2016-07-11 08:30:14 +0200 |
---|---|---|
committer | Bernhard Schommer <bernhardschommer@gmail.com> | 2016-07-11 08:30:14 +0200 |
commit | d5b86a98560c36fbcb3ab8d2698e09147acda512 (patch) | |
tree | f3ab850a1620fa5d3dbbe439998d09de8e0d817d /cparser/validator/Grammar.v | |
parent | ea2d6b70ed06c60dba9ba81cf53883c85fb92068 (diff) | |
parent | 3872ce9f9806d9af334b1fde092145edf664d170 (diff) | |
download | compcert-d5b86a98560c36fbcb3ab8d2698e09147acda512.tar.gz compcert-d5b86a98560c36fbcb3ab8d2698e09147acda512.zip |
Merge branch 'master' into add-file
Diffstat (limited to 'cparser/validator/Grammar.v')
-rw-r--r-- | cparser/validator/Grammar.v | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/cparser/validator/Grammar.v b/cparser/validator/Grammar.v index 0768d647..8e427cd9 100644 --- a/cparser/validator/Grammar.v +++ b/cparser/validator/Grammar.v @@ -17,6 +17,7 @@ Require Import List. Require Import Syntax. Require Import Alphabet. Require Import Orders. +Require Tuples. (** The terminal non-terminal alphabets of the grammar. **) Module Type Alphs. @@ -65,7 +66,7 @@ Module Symbol(Import A:Alphs). End Symbol. Module Type T. - Require Export Tuples. + Export Tuples. Include Alphs <+ Symbol. @@ -154,12 +155,12 @@ Module Defs(Import G:T). Fixpoint pt_size {head_symbol word sem} (tree:parse_tree head_symbol word sem) := match tree with | Terminal_pt _ _ => 1 - | Non_terminal_pt _ _ _ l => S (ptl_size l) + | Non_terminal_pt l => S (ptl_size l) end with ptl_size {head_symbols word sems} (tree:parse_tree_list head_symbols word sems) := match tree with | Nil_ptl => 0 - | Cons_ptl _ _ _ t _ _ _ q => + | Cons_ptl t q => pt_size t + ptl_size q end. End Defs. |