blob: 5dfd2a86c420561b20c956a409e6de67b83e561d (
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
/* Web IDL AST interface
*
* This file is part of nsgenjsbind.
* Licensed under the MIT License,
* http://www.opensource.org/licenses/mit-license.php
* Copyright 2012 Vincent Sanders <vince@netsurf-browser.org>
*/
#ifndef genjsbind_webidl_ast_h
#define genjsbind_webidl_ast_h
enum webidl_node_type {
WEBIDL_NODE_TYPE_ROOT,
WEBIDL_NODE_TYPE_INTERFACE,
};
struct webidl_ifmember {
char *name;
};
struct webidl_if {
char *name;
struct webidl_ifmember* members;
};
struct webidl_node {
enum webidl_node_type type;
union {
struct webidl_node *nodes;
struct webidl_if interface;
} data;
};
extern struct webidl_node *webidl_root;
/** parse web idl file */
int webidl_parsefile(char *filename);
struct webidl_node *webidl_new_node(enum webidl_node_type type);
#endif
|