view c/regexParser/regexParser.h @ 91:912d7bd51f38

remove static variable in createRegexTree.cc
author Masataka Kohagura <kohagura@cr.ie.u-ryukyu.ac.jp>
date Fri, 23 Oct 2015 18:53:46 +0900
parents 50a146c05192
children a3adc5c24e19
line wrap: on
line source

typedef struct charClass {
    unsigned char table[256];
    struct utf8Range {
        unsigned char *begin;
        unsigned char *end;
        struct utf8Range *next;
    } *rangeList;
} CharClass, *CharClassPtr;

typedef struct word {
    unsigned char *word;
    long length;
} Word, *WordPtr;

typedef struct node {
    unsigned char tokenType;
    int nodeNumber;
    union value {
        CharClassPtr cc;
        unsigned char character;
        WordPtr w;
    } Value, *ValuePtr;
    struct node *self;
    struct node *parent;
    struct node *left;
    struct node *right;
} Node, *NodePtr;

typedef struct regexInfo {
    unsigned char *ptr;
    unsigned char tokenType;
    int tokenValue;
    int nodeNumber;
} RegexInfo, *RegexInfoPtr;