annotate macro.h @ 19:f9792a9ec704

macro expansion.
author David A. Holland
date Mon, 20 Dec 2010 03:55:19 -0500
parents c08a947d8f30
children 76c114899f63
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
17
76da41da923f added macro table
David A. Holland
parents: 15
diff changeset
1 #include <stdbool.h>
76da41da923f added macro table
David A. Holland
parents: 15
diff changeset
2 #include <stddef.h>
76da41da923f added macro table
David A. Holland
parents: 15
diff changeset
3
4
ee9a66b87c70 Initial version of toplevel and options handling.
David A. Holland
parents:
diff changeset
4 struct place;
ee9a66b87c70 Initial version of toplevel and options handling.
David A. Holland
parents:
diff changeset
5
17
76da41da923f added macro table
David A. Holland
parents: 15
diff changeset
6 void macros_init(void);
76da41da923f added macro table
David A. Holland
parents: 15
diff changeset
7 void macros_cleanup(void);
76da41da923f added macro table
David A. Holland
parents: 15
diff changeset
8
18
c08a947d8f30 deal with macro parameters
David A. Holland
parents: 17
diff changeset
9 void macro_define_plain(struct place *, const char *macro,
c08a947d8f30 deal with macro parameters
David A. Holland
parents: 17
diff changeset
10 struct place *, const char *expansion);
c08a947d8f30 deal with macro parameters
David A. Holland
parents: 17
diff changeset
11 void macro_define_params(struct place *, const char *macro,
c08a947d8f30 deal with macro parameters
David A. Holland
parents: 17
diff changeset
12 struct place *, const char *params,
c08a947d8f30 deal with macro parameters
David A. Holland
parents: 17
diff changeset
13 struct place *, const char *expansion);
4
ee9a66b87c70 Initial version of toplevel and options handling.
David A. Holland
parents:
diff changeset
14 void macro_undef(const char *macro);
15
f6177d3ed5c2 handle directives
David A. Holland
parents: 4
diff changeset
15 bool macro_isdefined(const char *macro);
f6177d3ed5c2 handle directives
David A. Holland
parents: 4
diff changeset
16
f6177d3ed5c2 handle directives
David A. Holland
parents: 4
diff changeset
17 char *macroexpand(struct place *, char *buf, size_t len, bool honordefined);
f6177d3ed5c2 handle directives
David A. Holland
parents: 4
diff changeset
18
f6177d3ed5c2 handle directives
David A. Holland
parents: 4
diff changeset
19 void macro_sendline(struct place *, char *buf, size_t len);
f6177d3ed5c2 handle directives
David A. Holland
parents: 4
diff changeset
20 void macro_sendeof(struct place *);