aboutsummaryrefslogtreecommitdiff
path: root/gcc/cpplib.h
diff options
context:
space:
mode:
authorZack Weinberg <zack@gcc.gnu.org>2000-07-18 00:59:49 +0000
committerZack Weinberg <zack@gcc.gnu.org>2000-07-18 00:59:49 +0000
commit711b88243b220e3cd737696da51de70f32bb7d5c (patch)
treea8929adb35764d62c4016b482a4cb4b619be00cb /gcc/cpplib.h
parent5d8fcdcb2ddbd52a35621a7880cf268c50a54027 (diff)
downloadgcc-711b88243b220e3cd737696da51de70f32bb7d5c.zip
gcc-711b88243b220e3cd737696da51de70f32bb7d5c.tar.gz
gcc-711b88243b220e3cd737696da51de70f32bb7d5c.tar.bz2
[multiple changes]
2000-02-17 Zack Weinberg <zack@wolery.cumb.org> * cpphash.c: Don't include hashtab.h. Most macro-handling code moved to cppmacro.c. (hash_HASHNODE, eq_HASHNODE, _cpp_dump_macro_hash, dump_hash_helper): Delete. (expand_hash, higher_prime_number, _cpp_lookup_with_hash, cpp_forall_identifiers): New. Implement specialized version of Vlad's expandable hash table. (cpp_lookup): Use new functions. (_cpp_init_macros, _cpp_cleanup_macros): Adjust for new implementation. * cppmacro.c: New file. * cppinit.c (dump_macros_helper): New. (cpp_finish): Iterate over the identifier table directly. * cpplex.c (parse_name): Calculate the hash of the identifier while we scan it. Use _cpp_lookup_with_hash when we can. * cpphash.h: Update prototypes. (xcnewvec, HASHSTEP): New helper macros. * cpplib.h: Update prototypes. * Makefile.in (LIBCPP_OBJS): Add cppmacro.o. (cppmacro.o): New rule. (cpphash.o): Update deps. * cppmain.c: Do not set pfile->printer if no_output is on. 2000-02-15 Neil Booth <neilb@earthling.net> * cpplib.c: Change all directive-handler functions to return void, not int. * cpphash.h: Update typedefs. From-SVN: r35113
Diffstat (limited to 'gcc/cpplib.h')
-rw-r--r--gcc/cpplib.h24
1 files changed, 14 insertions, 10 deletions
diff --git a/gcc/cpplib.h b/gcc/cpplib.h
index 500b5e2..80671cf 100644
--- a/gcc/cpplib.h
+++ b/gcc/cpplib.h
@@ -653,6 +653,10 @@ extern void cpp_undef PARAMS ((cpp_reader *, const char *));
extern void cpp_unassert PARAMS ((cpp_reader *, const char *));
extern void cpp_free_token_list PARAMS ((cpp_toklist *));
+extern cpp_buffer *cpp_push_buffer PARAMS ((cpp_reader *,
+ const unsigned char *, long));
+extern cpp_buffer *cpp_pop_buffer PARAMS ((cpp_reader *));
+extern int cpp_defined PARAMS ((cpp_reader *, const unsigned char *, int));
/* N.B. The error-message-printer prototypes have not been nicely
formatted because exgettext needs to see 'msgid' on the same line
@@ -680,8 +684,8 @@ extern void cpp_pedwarn_with_line PARAMS ((cpp_reader *, int, int, const char *m
ATTRIBUTE_PRINTF_4;
extern void cpp_pedwarn_with_file_and_line PARAMS ((cpp_reader *, const char *, int, int, const char *msgid, ...))
ATTRIBUTE_PRINTF_5;
-extern void cpp_error_from_errno PARAMS ((cpp_reader *, const char *));
-extern void cpp_notice_from_errno PARAMS ((cpp_reader *, const char *));
+extern void cpp_error_from_errno PARAMS ((cpp_reader *, const char *));
+extern void cpp_notice_from_errno PARAMS ((cpp_reader *, const char *));
/* In cpplex.c */
extern cpp_buffer *cpp_push_buffer PARAMS ((cpp_reader *,
@@ -694,16 +698,16 @@ extern int cpp_ideq PARAMS ((const cpp_token *,
const char *));
/* In cpphash.c */
-extern int cpp_defined PARAMS ((cpp_reader *,
- const unsigned char *, int));
-extern cpp_hashnode *cpp_lookup PARAMS ((cpp_reader *,
- const unsigned char *, int));
+extern cpp_hashnode *cpp_lookup PARAMS ((cpp_reader *,
+ const unsigned char *, size_t));
+extern void cpp_forall_identifiers PARAMS ((cpp_reader *,
+ int (*) PARAMS ((cpp_reader *,
+ cpp_hashnode *))));
/* In cppfiles.c */
-extern int cpp_included PARAMS ((cpp_reader *, const char *));
-extern int cpp_read_file PARAMS ((cpp_reader *, const char *));
-extern void cpp_make_system_header PARAMS ((cpp_reader *,
- cpp_buffer *, int));
+extern int cpp_included PARAMS ((cpp_reader *, const char *));
+extern int cpp_read_file PARAMS ((cpp_reader *, const char *));
+extern void cpp_make_system_header PARAMS ((cpp_reader *, cpp_buffer *, int));
#ifdef __cplusplus
}