]> git.ipfire.org Git - thirdparty/gcc.git/blame - libcpp/ChangeLog
re PR fortran/18990 (ICE in gfc_get_derived_type, at fortran/trans-types.c)
[thirdparty/gcc.git] / libcpp / ChangeLog
CommitLineData
ad6ed77e
JG
12005-12-07 Jon Grimm <jgrimm2@us.ibm.com>
2 Ben Elliston <bje@au.ibm.com>
3
4 * include/cpplib.h (CPP_N_DFLOAT): New.
5 * expr.c (interpret_float_suffix): Identify df, dd, and dl
6 suffixes as decimal floating point constants.
7 (cpp_classify_number): Disallow hexadecimal DFP constants.
8
ba096620
GP
92005-11-14 Gerald Pfeifer <gerald@pfeifer.com>
10 Ian Lance Taylor <ian@airs.com>
11
12 * include/cpplib.h (struct cpp_callbacks): Annotate error with
13 ATTRIBUTE_FPTR_PRINTF(3,0) instead of ATTRIBUTE_PRINTF(3,0).
14
456b8ce5
UB
152005-11-09 Per Bothner <per@bothner.com>
16 Uros Bizjak <uros@kss-loka.si>
17
18 PR c/24101
19 * init.c (read_original_filename): Temporarily set
20 state.in_directive before calling _cpp_lex_direct for
21 CPP_HASH tokens.
22
5571f74f
JW
232005-11-03 James E Wilson <wilson@specifix.com>
24
25 PR preprocessor/24202
26 * files.c (_cpp_pop_file_buffer): Set buffer_valid to false.
27
a63607ed
JM
282005-11-04 Joseph S. Myers <joseph@codesourcery.com>
29
30 * include/cpplib.h (struct cpp_callbacks): Make error take
31 va_list* parameter.
32 * errors.c (cpp_error): Update call to callback.
33
651ed942
AP
342005-11-03 Andrew Pinski <pinskia@physics.uc.edu>
35
36 PR preprocessor/22042
37 * macro.c (_cpp_builtin_macro_text): Lower the needed max
38 buffer size.
39 (cpp_quote_string): Don't octalify non printable
40 charactors.
41
178b58b5
JM
422005-11-03 Joseph S. Myers <joseph@codesourcery.com>
43
44 PR c++/17964
45 * include/cpplib.h (struct cpp_options): Add client_diagnostic.
46 (struct cpp_callbacks): Add error.
47 * errors.c (cpp_error): If client_diagnostic, use error callback.
48 * charset.c (convert_escape): Don't use %03o in diagnostic.
49
3ee5ed11 502005-10-21 James E Wilson <wilson@specifix.com>
6568f34b
JW
51
52 PR preprocessor/15220
53 * files.c (_cpp_find_file): New parameter angle_brackets. Fix all
54 callers. Pass to open_file_failed.
55 (open_file_failed): New parameter angle_brackets. Fix all callers.
56 Use in print_dep assignment.
57 * init.c (cpp_read_main_file): Pass additional arg to _cpp_find_file.
58 * internal.h (_cpp_find_file): Add new parm to declaration.
59
077fc835
KH
602005-10-08 Kazu Hirata <kazu@codesourcery.com>
61
62 * configure.ac: Require 64-bit int for arm*-*-*eabi*.
63 * configure: Regenerate.
64
cbc43ae0
ILT
652005-10-04 Ian Lance Taylor <ian@airs.com>
66
67 PR preprocessor/13726
68 * directives.c (check_eol_return_comments): New static function.
69 (parse_include): Add buf parameter. Change all callers.
70 (do_include_common): If not discard comments, turn on
71 save_comments. Pass collected comments to include callback.
72 * include/cpplib.h (struct cpp_callbacks): Add new parameter to
73 include callback: cpp_token list.
74
af15a2fe
JM
752005-09-20 Joseph S. Myers <joseph@codesourcery.com>
76
77 * include/cpplib.h (struct cpp_options): Add extended_identifiers.
78 * init.c (struct lang_flags, lang_defaults): Add
79 extended_identifiers.
80 (cpp_set_lang): Use it.
81 * lex.c (forms_identifier_p): Check extended_identifiers.
82
f5eab47e
JJ
832005-08-30 Jakub Jelinek <jakub@redhat.com>
84
85 PR preprocessor/20348
86 PR preprocessor/20356
87 * files.c (_cpp_find_file, search_cache): Revert 2004-06-26 and
88 2004-06-05 changes.
89
467129e6
KG
902005-07-23 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
91
92 * configure.ac (ACX_PROG_CC_WARNING_OPTS): add
93 -Wmissing-format-attribute.
94
95 * configure: Regenerate.
96
200031d1
KC
972005-06-29 Kelley Cook <kcook@gcc.gnu.org>
98
99 * all files: Update FSF address in copyright headers.
100 * makeucnid.c (write_copyright): Update outputted FSF address.
101
f610dd5f
ZW
1022005-06-13 Zack Weinberg <zack@codesourcery.com>
103
104 * configure.ac: Invoke ZW_CREATE_DEPDIR and
105 ZW_PROG_COMPILER_DEPENDENCIES.
106 * aclocal.m4, configure: Regenerate.
107 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.base, COMPILE):
108 New variables.
109 (distclean): Clean up $(DEPDIR) and its contents.
110 (.c.o): Use $(COMPILE).
111 Include $(DEPDIR)/*.Po for most object->header dependencies.
112
c3f829c1
GDR
1132005-05-28 Gabriel Dos Reis <gdr@integrable-solutions.net>
114
115 * configure.ac: Check declarations for asprintf and vasprintf.
116 * config.in: Regenerate.
117 * configure: Likewise.
118
119 * charset.c (conversion_loop): Use XRESIZEVEC.
120 (convert_no_conversion): Likewise.
121 (convert_using_iconv): Likewise.
122 (init_iconv_desc): Cast return value of alloca.
123 (cpp_host_to_exec_charset): Use XNEWVEC.
124 (emit_numeric_escape): Use XRESIZEVEC.
125 (cpp_interpret_string): Use XNEWVEC.
126 (cpp_interpret_string): Use XRESIZEVEC.
127 (_cpp_interpret_identifier): Cast return value of alloca.
128 (_cpp_convert_input): Use XNEWVEC and XRESIZEVEC.
129 * directives.c (glue_header_name): Use XNEWVEC and XRESIZEVEC.
130 (parse_include): Use XNEWVEC.
131 (insert_pragma_entry): Rename local variable "new" to
f610dd5f 132 "new_entry".
c3f829c1
GDR
133 (save_registered_pragmas): Cast return value of xmemdup.
134 (destringize_and_run): Same for alloca.
135 (parse_assertion): Likewise.
136 (do_assert): Cast allocated storage to proper type.
137 (cpp_define): Likewise.
138 (_cpp_define_builtin): Likewise.
139 (cpp_undef): Likewise.
140 (handle_assertion): Likewise.
141 (cpp_push_buffer): Rename local variable "new" to "new_buffer".
142 * expr.c (CPP_UPLUS): Cast value to type cpp_ttype.
143 (CPP_UMINUS): Likewise.
144 (struct cpp_operator): Rename from struct operator.
145 (_cpp_expand_op_stack): Use XRESIZEVEC.
146 * files.c (pch_open_file): Use XNEWVEC.
147 (pch_open_file): Use XRESIZEVEC.
148 (read_file_guts): Use XNEWVEC and XRESIZEVEC.
149 (dir_name_of_file): Use XNEWVEC.
150 (make_cpp_file): Use XCNEW.
151 (make_cpp_dir): Likewise.
152 (allocate_file_hash_entries): USE XNEWVEC.
153 (cpp_included): Cast return value of htab_find_with_hash.
154 (append_file_to_dir): Use XNEWVEC.
155 (read_filename_string): Likewise. Use XRESIZEVEC too.
156 (read_name_map): Cast return value of alloca. Use XRESIZEVEC.
157 (remap_filename): Use XNEWVEC.
158 (struct pchf_entry): Move definition out of struct pchf_data.
159 (_cpp_save_file_entries): Use XCNEWVAR.
160 (_cpp_read_file_entries): Use XNEWVAR.
161 * identifiers.c (alloc_node): Use XOBNEW.
162 * init.c (cpp_create_reader): Use XCNEW.
163 (cpp_init_builtins): Cast of b->value to enum builtin_type.
164 (read_original_directory): Cast return value of alloca.
165 * lex.c (add_line_note): Use XRESIZEVEC.
166 (warn_about_normalization): Use XNEWVEC.
167 (_cpp_lex_direct): Cast node->directive_index to (enum cpp_ttype).
168 (new_buff): Use XNEWVEC.
169 * line-map.c (linemap_add): Use XRESIZEVEC.
170 * macro.c (builtin_macro): Cast return value of alloca.
171 (paste_tokens): Likewise.
172 (expand_arg): Use XNEWVEC and XRESIZEVEC.
173 (_cpp_save_parameter): Use XRESIZEVEC.
174 (create_iso_definition): Cast allocated storage to proper type.
175 (_cpp_create_definition): Likewise.
176 (cpp_macro_definition): Use XRESIZEVEC.
177 * makedepend.c (add_clm): Use XNEW.
178 (add_dir): Likewise.
179 * mkdeps.c (munge): Use XNEWVEC.
180 (deps_init): Use XCNEW.
181 (deps_add_target): Use XRESIZEVEC.
182 (deps_add_default_target): Cast return value of alloca.
183 (deps_add_dep): Use XRESIZEVEC.
184 (deps_add_vpath): Likewise. Use XNEWVEC too.
185 (deps_restore): Likewise.
186 * pch.c (save_idents): Use XNEW and XNEWVEC.
187 (cpp_save_state): Use XNEW.
188 (count_defs): Cast return value of htab_find.
189 (write_defs): Likewise.
190 (cpp_write_pch_deps): Use XNEWVEC.
191 (collect_ht_nodes): Use XRESIZEVEC.
192 (cpp_valid_state): Use XNEWVEC.
193 (save_macros): Use XRESIZEVEC. Cast return value of xmemdup.
194 * symtab.c (ht_create): Use XCNEW.
195 (ht_lookup_with_hash): Cast return value of obstack_copy0.
196 (ht_expand): Use XCNEWVEC.
197 * system.h (HAVE_DESIGNATED_INITIALIZERS): False if __cplusplus.
198 (bool): Do not define if __cplusplus.
199
1ed17cd5
ZW
2002005-05-12 Zack Weinberg <zack@codesourcery.com>
201
202 * directives.c (#sccs table entry): Mark IN_I, consistent with #ident.
203 (do_sccs): Delete function definition, #define to do_ident.
204 (do_ident): Don't hardwire directive name.
205
5a8c20ce
RK
2062005-05-12 Ryota Kunisawa <kunisawa@access.co.jp>
207
208 PR bootstrap/21230
209 * configure: Regenerate.
210
473c5bc9
AP
2112005-04-27 Andris Pavenis <pavenis@latnet.lv>
212
213 * files.c: Include io.h for DJGPP to get prototype of setmode.
214
c1fc5047
PB
2152005-04-19 Per Bothner <per@bothner.com>
216
217 PR preprocessor/20907
218 * line-map.c (linemap_line_start): Fix bug when we need to increse
219 column_bits but can re-use the current line_map.
220
042630ad
KG
2212005-04-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
222
223 * system.h (fopen, fdopen, freopen): Define these to the unlocked
224 libiberty functions.
225
0d667716
KG
2262005-04-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
227
228 * configure.ac (libcpp_UNLOCKED_FUNCS): New.
229 (AC_CHECK_FUNCS, AC_CHECK_DECLS): Check for libcpp_UNLOCKED_FUNCS.
230 * system.h (putchar, getc, getchar, clearerr, feof, fileno,
231 fflush, fgetc, fgets, ferror, fread): Redefine to the associated
232 _unlocked function.
233 (fwrite_unlocked): Fix prototype.
1ed17cd5 234
0d667716
KG
235 * configure, config.in: Regenerate.
236
cae064e7
JJ
2372005-04-05 Jakub Jelinek <jakub@redhat.com>
238
239 PR preprocessor/19475
240 * macro.c (create_iso_definition): For < ISO C99, don't
241 pedwarn if there is no whitespace between macro name and its
242 replacement, but the replacement starts with a basic character
243 set character.
244
cbada204
AJ
2452005-03-28 Andreas Jaeger <aj@suse.de>
246
247 * lex.c (warn_about_normalization): Cast field width to int to
248 avoid warning.
249
f42eccdb
JM
2502005-03-19 Joseph S. Myers <joseph@codesourcery.com>
251
252 * configure.ac: Consistently use solaris2.1[0-9]* instead of
253 solaris2.1[0-9].
254 * configure: Regenerate.
255
c79e602b
GK
2562005-03-15 Geoffrey Keating <geoffk@apple.com>
257
258 * charset.c (_cpp_valid_ucn): In identifiers, reject a partial
259 UCN rather than printing an error.
260
50668cf6
GK
2612005-03-14 Geoffrey Keating <geoffk@apple.com>
262
6baba9bb
GK
263 * lex.c (forms_identifier_p): Disable UCNs in C89 mode.
264
2652005-03-14 Geoffrey Keating <geoffk@apple.com>
1ed17cd5 266
50668cf6
GK
267 * init.c (cpp_create_reader): Default warn_normalize to normalized_C.
268 * charset.c: Update for new format of ucnid.h.
269 (ucn_valid_in_identifier): Update for new format of ucnid.h.
270 Add NST parameter, and update it; update callers.
271 (cpp_valid_ucn): Add NST parameter, update callers. Replace abort
272 with cpp_error.
273 (convert_ucn): Pass normalize_state to cpp_valid_ucn.
274 * internal.h (struct normalize_state): New.
275 (INITIAL_NORMALIZE_STATE): New.
276 (NORMALIZE_STATE_RESULT): New.
277 (NORMALIZE_STATE_UPDATE_IDNUM): New.
278 (_cpp_valid_ucn): New.
279 * lex.c (warn_about_normalization): New.
280 (forms_identifier_p): Add normalize_state parameter, update callers.
281 (lex_identifier): Add normalize_state parameter, update callers. Keep
282 the state current.
283 (lex_number): Likewise.
284 (_cpp_lex_direct): Pass normalize_state to subroutines. Check
285 it with warn_about_normalization.
286 * makeucnid.c: New.
287 * ucnid.h: Replace.
288 * ucnid.pl: Remove.
289 * ucnid.tab: Make appropriate for input to makeucnid.c. Remove
290 comments about obsolete version of C++.
291 * include/cpplib.h (enum cpp_normalize_level): New.
292 (struct cpp_options): Add warn_normalize field.
293
47e20491
GK
2942005-03-11 Geoffrey Keating <geoffk@apple.com>
295
296 * directives.c (glue_header_name): Update call to cpp_spell_token.
297 * internal.h (_cpp_interpret_identifier): New.
298 * charset.c (_cpp_interpret_identifier): New.
299 (_cpp_valid_ucn): Allow UCN version of '$'.
300 * lex.c (lex_identifier): Add extra parameter to indicate if initial
301 character was '$' or '\'. Support identifiers with UCNs.
302 (forms_identifier_p): Allow UCNs.
303 (_cpp_lex_direct): Pass extra parameter to lex_identifier.
304 (utf8_to_ucn): New.
305 (cpp_spell_token): Add FORSTRING parameter. Use it.
306 (cpp_token_as_text): Update call to cpp_spell_token.
307 (cpp_output_token): Write UCNs back out.
308 (stringify_arg): Update call to cpp_spell_token.
309 (paste_tokens): Likewise.
310 (cpp_macro_definition): Likewise.
311 * macro.c (stringify_arg): Likewise.
312 (paste_tokens): Likewise.
313 (cpp_macro_definition): Likewise.
314 * include/cpplib.h: Add parameter to cpp_spell_token.
315
73096711
JJ
3162005-03-04 Jakub Jelinek <jakub@redhat.com>
317
318 PR bootstrap/20282
319 PR bootstrap/20305
320 * macro.c (replace_args, cpp_get_token): Copy whole
321 cpp_token_u instead of just cpp_string field from it.
322
2203a881
DP
3232005-02-28 Devang Patel <dpatel@apple.com>
324
325 * directives.c (do_line): Save sysp early before line table is
326 realloc'ed.
1ed17cd5 327
c5ff069d
ZW
3282005-02-20 Zack Weinberg <zack@codesourcery.com>
329
330 PR 18785
331 * charset.c (LAST_POSSIBLY_BASIC_SOURCE_CHAR): New helper macro.
332 (cpp_host_to_exec_charset): New function.
333 * include/cpplib.h: Declare cpp_host_to_exec_charset.
334
04c90eea
DP
3352005-02-19 Devang Patel <dpatel@apple.com>
336
337 * charset.c (_cpp_convert_input): Check '\r' before inserting
338 '\n' at the end.
c5ff069d 339
6da55c00
EC
3402005-02-15 Eric Christopher <echristo@redhat.com>
341
342 PR preprocessor/19077
343 * macro.c (cpp_macro_definition): Move handling of whitespace
344 to PREV_WHITE conditional. Remove overloading of len
345 variable.
346
31c3e631
KH
3472005-02-14 Kazu Hirata <kazu@cs.umass.edu>
348
349 * directives.c, files.c, init.c, internal.h, macro.c, pch.c,
350 traditional.c: Update copyright.
351
be0f1e54
PB
3522005-02-14 Paolo Bonzini <bonzini@gnu.org>
353
354 PR bootstrap/19818
355 * configure.ac: Check for declaration of basename and getopt.
356 * config.in: Regenerate.
357 * configure: Regenerate.
358 * internal.h (ustrcspn): New.
359 * macro.c (create_iso_definition): Fix allocation of memory.
360 (padding_token): Add cast to remove const-ness.
361 * pch.c (cpp_read_state): Use ustrcspn.
362
ecddfb39
MS
3632005-02-08 Mike Stump <mrs@apple.com>
364
365 * files.c (pchf_adder): Remove.
366 (struct pchf_adder_info): Likewise.
367 (_cpp_save_file_entries): Write out all files so that #import works.
368
9fcdd891
JM
3692005-01-23 Joseph S. Myers <joseph@codesourcery.com>
370
371 * configure: Regenerate.
372
ecfd72e7
TS
3732005-01-11 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
374
375 * include/cpplib.h (c_lang): Fix comment to say cpp_create_reader.
376
6c25a4f7 377 * include/cpplib.h: Also update copyright years.
c5ff069d 378
942926ad
GK
3792005-01-03 Geoffrey Keating <geoffk@apple.com>
380
381 * files.c (_cpp_find_file): Add files found by search_path_exhausted
382 to the list of all files.
383
a2566ae9
GDR
3842005-01-01 Gabriel Dos Reis <gdr@integrable-solutions.net>
385
386 * internal.h: Update references to Cpp lib filenames.
387 * directives.c: Likewise.
388 * init.c: Likewise.
389 * macro.c: Likewise.
390 * traditional.c: Likewise.
391
1b449375
EB
3922004-12-15 Eric Botcazou <ebotcazou@libertysurf.fr>
393
394 PR preprocessor/15167
395 * files.c (destroy_cpp_file): New function.
396 (should_stack_file): Make a new file if the
397 compared file is still stacked.
398
28303828
NN
3992004-11-28 Nathanael Nerode <neroden@gcc.gnu.org>
400
c5ff069d 401 PR preprocessor/17610
28303828
NN
402 * directives.c (do_include_common): Error out if an empty filename
403 is given for #include (or #include_next or #import).
404
c812785a
RS
4052004-11-27 Roger Sayle <roger@eyesopen.com>
406 Zack Weinberg <zack@codesourcery.com>
407
408 * internal.h: Replace all uses of uchar with unsigned char.
409 * include/cpp-id-data.h: Likewise. Guard typedef of uchar
410 with !IN_GCC, so uchar is only defined whilst building libcpp.
411
f91eaa01
KC
4122004-11-24 Kelley Cook <kcook@gcc.gnu.org>
413
414 * aclocal.m4: Regenerate.
415
f78ce0c2
RS
4162004-11-24 Roger Sayle <roger@eyesopen.com>
417
418 PR preprocessor/15824
419 * configure.ac: Correct HAVE_UCHAR test to #include <sys/types.h>
420 directly, instead of the non-existant "system.h" and "ansidecl.h".
421 * configure: Regenerate.
422
b5b3e36a 4232004-11-23 Daniel Jacobowitz <dan@codesourcery.com>
c5ff069d 424 Joseph Myers <joseph@codesourcery.com>
b5b3e36a
DJ
425
426 * internal.h (struct lexer_state): Add in_deferred_pragma.
427 * directives.c (struct pragma_entry): Add allow_expansion.
428 (insert_pragma_entry): Take allow_expansion flag.
429 (register_pragma): Likewise.
430 (cpp_register_pragma): Likewise.
431 (_cpp_init_internal_pragmas): Update calls to cpp_register_pragma.
432 (do_pragma): Honor allow_expansion.
433 (cpp_handle_deferred_pragma): Set in_deferred_pragma.
434 * include/cpplib.h (cpp_register_pragma): Update prototype.
435
a8e68029 4362004-11-18 Daniel Jacobowitz <dan@codesourcery.com>
c5ff069d 437 Mark Mitchell <mark@codesourcery.com>
a8e68029
DJ
438
439 * configure.ac (i[34567]86-*-solaris2.1[0-9]*): Set
440 need_64bit_hwint=yes.
441 * configure: Regenerate.
442
50f47ee0
JM
4432004-11-09 Joseph S. Myers <joseph@codesourcery.com>
444
445 * Makefile.in ($(PACKAGE).pot): New rule. Depend on
446 po/$(PACKAGE).pot.
447 (po/$(PACKAGE).pot): Use ":" instead of "," in --keyword
448 arguments. Add keywords _, N_, SYNTAX_ERROR and SYNTAX_ERROR2.
449 Remove local srcdir path from generated file.
450
968e08d6 4512004-11-04 Zack Weinberg <zack@codesourcery.com>
c5ff069d 452 Gerald Pfeifer <gerald@pfeifer.com>
968e08d6
ZW
453
454 * internal.h (HAVE_ICONV): Undefine if we do not have HAVE_ICONV_H
455 as well.
456
3da3d587
ZW
4572004-10-27 Zack Weinberg <zack@codesourcery.com>
458
459 PR 18075
460 * directives.c (do_pragma): Do not defer pragmas which are unknown.
461 (cpp_handle_deferred_pragma): Add cast to silence warning.
462
ac24fc25
JM
4632004-10-14 Joseph S. Myers <jsm@polyomino.org.uk>
464
465 * errors.c (_cpp_begin_message): Print "error: " for errors.
466
7731405b
AJ
4672004-10-10 Andreas Jaeger <aj@suse.de>
468
469 * makedepend.c: Include mkdeps.h for prototype of deps_add_vpath.
470 * Makefile.in (makedepend.o): Add dependency on mkdeps.h.
471
646544e3
AP
4722004-10-08 Andrew Pinski <pinskia@physics.uc.edu>
473
474 * pch.c (cpp_write_pch_state): Remove variable z as it is not
475 used.
476 (cpp_read_state): Remove unused variables, m, d and mac_count.
477
67a74146
PB
4782004-09-29 Per Bothner <per@bothner.com>
479
480 * directives.c (cpp_handle_deferred_pragma): Save, clear and restore
481 cb.line_change. Otherwise do_pragma will call the line_change
482 call-back with a meaningless line number.
483
018a4785
ZW
4842004-09-24 Zack Weinberg <zack@codesourcery.com>
485
486 * configure.ac: Move AC_PROG_MAKE_SET, AC_PROG_INSTALL to
487 programs cluster. Use ACX_PROG_CC_WARNING_OPTS,
488 ACX_PROG_CC_WARNING_ALMOST_PEDANTIC, ACX_PROG_CC_WARNINGS_ARE_ERRORS.
489 * aclocal.m4, configure: Regenerate.
490 * init.c: Include localedir.h.
491 * Makefile.in (WARN_CFLAGS, ALL_CFLAGS): New variables.
492 (DEFS): Delete.
493 (.c.o): Use $(ALL_CFLAGS).
494 (localedir.h, localedir.hs): New rules.
495 (clean): Use rm -rf to remove directories.
496 (distclean): Also delete localedir.h and localedir.hs.
497 (init.o): Update dependencies.
498
88fa57d7
KC
4992004-09-22 Kelley Cook <kcook@gcc.gnu.org>
500
501 * Makefile.in (aclocal.m4): Update dependencies.
502 * configure.ac (AC_CONFIG_MACRO_DIR): New.
503 * aclocal.m4, configure: Regenerate.
504
8f8e9aa5
ZW
5052004-09-17 Zack Weinberg <zack@codesourcery.com>
506
a29f62d9
ZW
507 * charset.c (_cpp_destroy_iconv, emit_numeric_escape)
508 (_cpp_convert_input, _cpp_default_encoding): Add comments.
509 Some other comments in this file also tweaked.
510
8f8e9aa5
ZW
511 * directives.c (do_pragma): Save current buffer position
512 before lexing the pragma keywords; don't call
513 _cpp_backup_tokens in the defer_pragmas case.
514
a2981930
PB
5152004-09-15 Per Bothner <per@bothner.com>
516
517 * include/line-map.h (line_map_start): Add parameter names so
518 preceding comment makes sense.
519 (linemap_add): Remove from comment mention of non-existing parameter.
520
21b11495
ZW
5212004-09-09 Matt Austern <austern@apple.com>
522 Zack Weinberg <zack@codesourcery.com>
523
524 * include/cpplib.h (TTYPE_TABLE): Remove CPP_ and SPELL_
525 prefixes throughout. Add entry for PRAGMA. Remove
526 unnecessary "= 0" from EQ.
527 (enum cpp_ttype): Adjust OP and TK definitions to restore
528 prefixes, via token-paste.
529 (CPP_LAST_EQ, CPP_FIRST_DIGRAPH, CPP_LAST_PUNCTUATOR, CPP_LAST_CPP_OP):
530 Change from #defines to additional cpp_ttype enumerators.
531 (struct cpp_options): Add defer_pragmas.
532 (cpp_handle_deferred_pragma): Prototype new interface.
533
534 * internal.h (struct cpp_reader): Add directive_result.
535 * directives.c (struct pragma_entry): Add is_internal field;
536 give boolean fields type bool.
537 (start_directive): Initialize pfile->directive_result.type.
538 (_cpp_do__Pragma): Likewise.
539 (run_directive): Do not crash if pfile->buffer->prev is NULL.
540 (insert_pragma_entry): Add 'internal' argument; set new->is_internal
541 from it.
542 (register_pragma): New static function, bulk of former
543 cpp_register_pragma here; add 'internal' argument, pass along
544 to insert_pragma_entry.
545 (cpp_register_pragma): Now a wrapper around register_pragma which
546 always passes false for 'internal' argument.
547 (_cpp_init_internal_pragmas): Call register_pragma directly, passing
548 true for 'internal'.
549 (do_pragma): If CPP_OPTION (pfile, defer_pragmas) and this isn't
550 an internal pragma, save text till the end of the line as a CPP_PRAGMA
551 token instead of executing the pragma.
552 (cpp_handle_deferred_pragma): New interface.
553 * lex.c (token_spellings): Adjust OP and TK definitions to
554 match changes to cpplib.h.
555 (_cpp_lex_token): Check for a directive-result token and
556 return it if present.
557 (cpp_token_val_index): Handle CPP_PRAGMA.
558 * macro.c (cpp_builtin_macro_text): Correct comment.
559 (builtin_macro): Handle directive-result tokens from _cpp_do__Pragma.
560
0fd9e8dd
SB
5612004-09-06 Serge Belyshev <belyshev@lubercy.com>
562
563 PR preprocessor/14699
564 * symtab.c (ht_dump_statistics): Change type of sum_of_squares
565 from size_t to double.
566
39b8ce7f
AS
5672004-08-28 Andreas Schwab <schwab@suse.de>
568 Andreas Jaeger <aj@suse.de>
569
570 * configure.ac: Set PACKAGE correctly.
571 * configure: Regenerated.
572
5d1f4b27
PB
5732004-08-25 Paolo Bonzini <bonzini@gnu.org>
574
575 * Makefile.in: Add back top_builddir.
576
078e3ffe
PB
5772004-08-25 Paolo Bonzini <bonzini@gnu.org>
578
579 * configure.ac: Replace Automake macro invocations
580 with manual Autoconf checks and substitutions.
581 * configure: Regenerate.
582 * aclocal.m4: Regenerate.
583 * config.in: Regenerate.
584 * Makefile.am: Removed.
585 * Makefile.in: Heavy simplification and reorganization.
586
b3f8d95d
MM
5872004-08-09 Mark Mitchell <mark@codesourcery.com>
588
589 * configure.ac (arm*-*-eabi*): New target.
590 (arm*-*-symbianelf*): Likewise.
591 * configure: Regenerated.
592
72bb2c39
BI
5932004-07-24 Bernardo Innocenti <bernie@develer.com>
594
595 * internal.h (xnew, xcnew, xnewvec, xcnewvec, xobnew): Remove.
596 * directives.c: Use XNEW-family macros from libiberty.
597 * lex.c: Likewise.
598 * macro.c: Likewise.
599 * cpplib.h (cpp_deps_style): Export enum with name.
600
21b11495 6012004-07-23 Matthias Klose <doko@debian.org>
72bb2c39 602
21b11495 603 * init.c (init_library): Use PACKAGE for the text domain.
85eac2a0 604
a23ee064
AP
6052004-07-16 Andris Pavenis <pavenis@latnet.lv>
606
607 PR preprocessor/16366
608 * internal.h (struct cpp_reader): New field dir_hash.
609 * files.c (make_cpp_dir): Use dir_hash, not file_hash.
610 (_cpp_init_files, _cpp_cleanup_files): Update for new field.
611
a09d4744
NB
6122004-07-04 Neil Booth <neil@duron.akihabara.co.uk>
613
614 PR preprocessor/16192
615 PR preprocessor/15913
616 PR preprocessor/15572
617 * expr.c (_cpp_parse_expr): Handle remaining cases where an
618 expression is missing.
619 * init.c (post_options): Traditional cpp doesn't do // comments.
620
f58f7def
PB
6212004-06-30 Per Bothner <per@bothner.com>
622
623 * include/line-map.h (fileline): Remove old typedef.
624 * internal.h (struct cpp_reader): Use source_location typedef instead.
625
e83d8d43
ZW
6262004-06-26 Zack Weinberg <zack@codesourcery.com>
627
628 Partially revert patch of 2004-06-05.
629 * files.c (search_cache): Remove pfile argument. Don't check
630 for file that would be found by "" or <> search here...
631 (_cpp_find_file): ...do it here, before calling find_file_in_dir.
632 Do not apply directory-of-current-file correction to files
633 found by this check. Rearrange code slightly.
634
c0d578e6
GK
6352004-06-21 Geoffrey Keating <geoffk@apple.com>
636
637 * files.c (should_stack_file): Correct swapped parameters to call
638 to cb.read_pch.
639 * pch.c (cpp_valid_state): Handle -fpreprocessed.
640
159d5224
PB
6412004-06-15 Paolo Bonzini <bonzini@gnu.org>
642
643 * Makefile.in: Regenerate with automake 1.8.5.
644 * aclocal.m4: Likewise.
645 * configure: Regenerate.
646
2fac9c01
ZW
6472004-06-11 Zack Weinberg <zack@codesourcery.com>
648
649 * configure.ac: Don't invoke ACX_HEADER_STDBOOL.
650 * configure, config.in: Regenerate.
651 * system.h: Unconditionally define bool as unsigned char,
652 BOOL_BITFIELD as unsigned int.
653 * .cvsignore: New file.
654
d8044160
GK
6552004-06-09 Geoffrey Keating <geoffk@apple.com>
656
657 * traditional.c (push_replacement_text): Set macro->traditional.
658 (save_replacement_text): Likewise.
659 * pch.c (cpp_write_pch_state): Don't write list of defined macros.
660 (struct save_macro_item): Delete.
661 (struct save_macro_data): Use a character array not the previous
662 structured format.
663 (save_macros): Save macro as text not as internal structures.
664 (cpp_prepare_state): Update for changes to save_macro_data.
665 (cpp_read_state): Don't read macros defined in PCH. Restore
2cf22451 666 -D macros as text.
d8044160
GK
667 * macro.c (create_iso_definition): Honour alloc_subobject.
668 Clear traditional flag.
669 (_cpp_create_definition): Honour alloc_subobject.
670 * lex.c (cpp_token_val_index): New.
671 * internal.h: Include cpp-id-data.h.
672 (uchar): Move definition to cpp-id-data.h.
673 (U): Likewise.
674 (cpp_macro): Likewise.
675 * directives.c (struct answer): Move to cpp-id-data.h.
676 (do_assert): Honour alloc_subobject.
2cf22451
ZW
677
678 * include/symtab.h (struct ht): Add field 'alloc_subobject'.
679 * include/cpplib.h (struct cpp_string): Add GTY marker.
680 (enum cpp_token_fld_kind): New.
681 (struct cpp_token): Add GTY markers.
682 (cpp_token_val_index): Prototype.
683 (CPP_HASHNODE_VALUE_IDX): New.
684 (struct cpp_hashnode): Don't skip fields of 'value' when marking.
685 * include/cpp-id-data.h: New file.
d8044160 686
0ca8e815
PB
6872004-06-09 Paolo Bonzini <bonzini@gnu.org>
688
689 * Makefile.am (all-local): New.
690 * Makefile.in: Regenerate.
691
b51fa00f
RS
6922004-06-06 Roger Sayle <roger@eyesopen.com>
693
694 * Makefile.am (LIBICONV): Declare.
695 (makedepend_LDADD): Use LIBICONV.
696 * Makefile.in: Regenerate.
697
5e2f3f39
AP
6982004-06-05 Andrew Pinski <pinskia@physics.uc.edu>
699
700 * Makefile.am (LIBINTL): Declare
701 (makedepend_LDADD): Use LIBINTL.
702 * Makefile.in: Regenerate.
703
c6e83800
ZW
7042004-06-05 Zack Weinberg <zack@codesourcery.com>
705
706 * Makefile.am: Add makedepend.
707 * Makefile.in, aclocal.m4: Regenerate.
708 * charset.c: Insert a space to avoid a warning.
709 * directives.c: Include mkdeps.h.
710 (_cpp_handle_directive): Reenable macro expander if appropriate.
711 (undefine_macros): Inline body of _cpp_free_definition for speed.
712 Do not call undef callback or _cpp_warn_if_unused_macro.
713 (cpp_get_deps): New interface.
714 * files.c (search_cache): Add pfile argument. Check for file
715 that would be found by "" or <> search here...
716 (_cpp_find_file): ...not here. Correct recorded start_dir of
717 files found by directory-of-current-file search that would be
718 found by "" or <> search.
719 * init.c (cpp_add_dependency_target): Delete.
720 * internal.h (struct lexer_state): Add discarding_output flag.
721 * lex.c (lex_identifier): Compute hash function while scanning.
722 * macro.c (cpp_scan_nooutput): Disable macro expansion outside
723 directives.
724 * makedepend.c: New file.
725 * mkdeps.c (struct deps): Add vpath vector.
726 (apply_vpath, deps_add_vpath): New function.
727 (deps_free): Free vpath vector.
728 (deps_add_dep, deps_add_target): Use apply_vpath.
729 * symtab.c (calc_hash): Use HT_HASHSTEP and HT_FINISH.
730 (ht_lookup_with_hash): New function.
731 * cpplib.h, mkdeps.h: Update prototypes.
732 * symtab.h: Update prototypes.
733 (HT_HASHSTEP, HT_FINISH): New macros.
734
b453c95f
GK
7352004-05-29 Geoffrey Keating <geoffk@apple.com>
736
737 * symtab.c (ht_create): Set entries_owned.
738 (ht_destroy): Honour entries_owned.
739 (ht_expand): Likewise.
740 (ht_load): New.
2cf22451
ZW
741 * include/symtab.h (struct ht): New field 'entries_owned'
742 (ht_load): New prototype.
b453c95f 743
963e23c5
PB
7442004-05-26 Paolo Bonzini <bonzini@gnu.org>
745
746 PR bootstrap/15651
747 * configure.ac: Fix m4 quoting when picking
748 the size of HOST_WIDE_INT.
749 * configure: Regenerate.
750
0429bc77
PB
7512004-05-25 Paolo Bonzini <bonzini@gnu.org>
752
753 * Makefile.am: the correct directory for
754 gettext include files is given by @INCINTL@.
755 * Makefile.in: Regenerate.
756
c86dd7db
PB
7572004-05-24 Paolo Bonzini <bonzini@gnu.org>
758
759 * system.h [!ENABLE_NLS]: dgettext takes two
760 parameters.
761
4f4e53dd
PB
7622004-05-23 Paolo Bonzini <bonzini@gnu.org>
763
764 Moved libcpp from the gcc subdirectory to the toplevel.
765 * Makefile.am: New file.
766 * Makefile.in: Regenerate.
767 * configure.ac: New file.
768 * configure: Regenerate.
769 * config.in: Regenerate.
770 * charset.c: Moved from gcc/cppcharset.c. Add note about
771 brokenness of input charset detection. Adjust for change
772 in name of cppucnid.h.
773 * errors.c: Moved from gcc/cpperror.c. Do not include intl.h.
774 * expr.c: Moved from gcc/cppexp.c.
775 * files.c: Moved from gcc/cppfiles.c. Do not include intl.h.
776 Remove #define of O_BINARY, it is in system.h.
777 * identifiers.c: Moved from gcc/cpphash.c.
778 * internal.h: Moved from gcc/cpphash.h. Change header
779 guard name. All other files adjusted to match name change.
780 * init.c: Moved from gcc/cppinit.c.
781 (init_library) [ENABLE_NLS]: Call bindtextdomain.
782 * lex.c: Moved from gcc/cpplex.c.
783 * directives.c: Moved from gcc/cpplib.c.
784 * macro.c: Moved from gcc/cppmacro.c.
785 * pch.c: Moved from gcc/cpppch.c. Do not include intl.h.
786 * traditional.c: Moved from gcc/cpptrad.c.
787 * ucnid.h: Moved from gcc/cppucnid.h. Change header
788 guard name.
789 * ucnid.pl: Moved from gcc/cppucnid.pl.
790 * ucnid.tab: Moved from gcc/cppucnid.tab. Change header
791 guard name.
792 * symtab.c: Moved from gcc/hashtable.c.
793 * line-map.c: Moved from gcc. Do not include intl.h.
794 * mkdeps.c: Moved from gcc.
795 * system.h: New file.
2cf22451
ZW
796 * include/cpplib.h: Moved from gcc. Change header guard name.
797 * include/line-map.h: Moved from gcc. Change header guard name.
798 * include/mkdeps.h: Moved from gcc. Change header guard name.
799 * include/symtab.h: Moved from gcc/hashtable.h. Change header
800 guard name.