2 * Copyright 2011 Jacek Caban for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
55 typedef struct _expression_t {
56 expression_type_t type;
57 struct _expression_t *next;
73 } double_expression_t;
78 } string_expression_t;
82 expression_t *subexpr;
89 } binary_expression_t;
93 expression_t *obj_expr;
94 const WCHAR *identifier;
96 } member_expression_t;
119 typedef struct _statement_t {
120 statement_type_t type;
121 struct _statement_t *next;
126 member_expression_t *expr;
131 member_expression_t *member_expr;
132 expression_t *value_expr;
133 } assign_statement_t;
135 typedef struct _dim_decl_t {
137 struct _dim_decl_t *next;
140 typedef struct _dim_statement_t {
142 dim_decl_t *dim_decls;
145 typedef struct _arg_decl_t {
148 struct _arg_decl_t *next;
151 typedef struct _function_decl_t {
153 function_type_t type;
157 struct _function_decl_t *next;
158 struct _function_decl_t *next_prop_func;
163 function_decl_t *func_decl;
164 } function_statement_t;
166 typedef struct _class_prop_decl_t {
169 struct _class_prop_decl_t *next;
172 typedef struct _class_decl_t {
174 function_decl_t *funcs;
175 class_prop_decl_t *props;
176 struct _class_decl_t *next;
179 typedef struct _elseif_decl_t {
182 struct _elseif_decl_t *next;
188 statement_t *if_stat;
189 elseif_decl_t *elseifs;
190 statement_t *else_stat;
202 } onerror_statement_t;
204 typedef struct _const_decl_t {
206 expression_t *value_expr;
207 struct _const_decl_t *next;
220 BOOL option_explicit;
228 statement_t *stats_tail;
229 class_decl_t *class_decls;
234 HRESULT parse_script(parser_ctx_t*,const WCHAR*) DECLSPEC_HIDDEN;
235 void parser_release(parser_ctx_t*) DECLSPEC_HIDDEN;
236 int parser_lex(void*,parser_ctx_t*) DECLSPEC_HIDDEN;
237 void *parser_alloc(parser_ctx_t*,size_t) DECLSPEC_HIDDEN;