comparison c/regexParser/regexParser.h @ 111:1d30f70702df pairPro

add determinize.cc and transition.cc
author masa
date Sat, 21 Nov 2015 18:04:25 +0900
parents a3adc5c24e19
children ca30f8334741
comparison
equal deleted inserted replaced
110:a3adc5c24e19 111:1d30f70702df
1 typedef struct charClass { 1 typedef struct charClass {
2 unsigned char table[256]; 2 unsigned char type;
3 struct utf8Range { 3 union condition {
4 unsigned char *begin; 4 struct utf8Range {
5 unsigned char *end; 5 unsigned char *begin;
6 struct utf8Range *next; 6 unsigned char *end;
7 } *rangeList; 7 struct utf8Range *next;
8 } rangeList;
9 unsigned char character;
10 WordPtr w;
11 } *conditionList;
12 struct charClass *next;
8 } CharClass, *CharClassPtr; 13 } CharClass, *CharClassPtr;
9 14
10 typedef struct word { 15 typedef struct word {
11 unsigned char *word; 16 unsigned char *word;
12 long length; 17 long length;
13 } Word, *WordPtr; 18 } Word, *WordPtr;
14 19
15 typedef struct node { 20 typedef struct node {
16 unsigned char tokenType; 21 unsigned char tokenType;
17 int nodeNumber; 22 unsigned long nodeNumber;
18 union value { 23 CharClassPtr cc;
19 CharClassPtr cc;
20 unsigned char character;
21 WordPtr w;
22 } Value, *ValuePtr;
23 struct node *left; 24 struct node *left;
24 struct node *right; 25 struct node *right;
25 } Node, *NodePtr; 26 } Node, *NodePtr;