summaryrefslogtreecommitdiff
path: root/src/sp_tree.h
blob: d29d095008b2ebf2b82fd7479a9fb2481f75090a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef SP_TREE_H
#define SP_TREE_H
#include "php_snuffleupagus.h"

typedef enum {
  UNDEFINED = 0,
  OBJECT,
  ARRAY,
  ARRAY_END,
  INTERPRETED_STRING,
  LITERAL_STRING,
  CLASS,
  VAR,
  CONSTANT
} elem_type;

typedef struct parser_s {
  elem_type type;
  char *value;
  struct parser_s *idx;
  struct parser_s *next;
} sp_tree;

sp_tree *sp_tree_new();
void sp_tree_free(sp_tree *);

#endif