Add opcode to edge

This commit is contained in:
c9s 2014-05-23 11:47:44 +08:00
parent 7d16413cb3
commit 403b1d9ba2
2 changed files with 2 additions and 0 deletions

View file

@ -56,6 +56,7 @@ struct _node {
struct _edge {
char * pattern;
int pattern_len;
int opcode;
bool has_slug;
node * child;
};

View file

@ -28,6 +28,7 @@ edge * r3_edge_create(char * pattern, int pattern_len, node * child) {
edge * e = (edge*) zmalloc( sizeof(edge) );
e->pattern = pattern;
e->pattern_len = pattern_len;
e->opcode = 0;
e->child = child;
return e;
}