]> gcc.gnu.org Git - gcc.git/blame - gcc/cp/ChangeLog
* config/i386/i386.md: Correct check-in of incorrect version.
[gcc.git] / gcc / cp / ChangeLog
CommitLineData
75b6f3fd
KG
12003-07-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2
3 * decl.c (print_binding_level, print_other_binding_stack,
4 print_binding_stack): Merge uses of HOST_PTR_PRINTF with adjacent
5 stdio calls.
6 * ptree.c (cxx_print_decl, cxx_print_binding): Likewise.
7
5671bf27
AJ
82003-07-07 Andreas Jaeger <aj@suse.de>
9
10 * friend.c: Convert to ISO C90 prototypes.
11
12 * Make-lang.in ($(srcdir)/cp/cfns.h): Use ANSI-C as output
13 language.
14 * cfns.h: Regenerate.
15
16 * typeck.c: Convert remaining prototypes to ISO C90.
17 * search.c: Likewise.
18
19 * decl2.c (build_expr_from_tree): Convert prototype to ISO C90.
20 * semantics.c (expand_or_defer_fn): Likewise
21 * mangle.c (discriminator_for_string_literal): Likewise.
22 * g++spec.c (lang_specific_driver): Likewise.
23
24 * search.c (lookup_base_r): Remove unused variable.
25
0cea056b
NS
262003-07-07 Nathan Sidwell <nathan@codesourcery.com>
27
28 * semantics.c: (genrtl_try_block) Adjust emit_line_note
29 calls.
30
5fc521ac
AJ
312003-07-07 Andreas Jaeger <aj@suse.de>
32
33 * search.c (lookup_base_r): Remove unused variable.
34
267a0752
MC
352003-07-06 Michael Chastain <mec@shout.net>
36
37 PR debug/10055
38 * lex.c (cxx_init): Call push_srcloc and pop_srcloc rather than
39 assigning to input_filename directly.
40
9bcb9aae
KH
412003-07-06 Kazu Hirata <kazu@cs.umass.edu>
42
43 * call.c: Fix comment formatting.
44 * class.c: Likewise.
45 * cp-tree.h: Likewise.
46 * decl.c: Likewise.
47 * decl2.c: Likewise.
48 * error.c: Likewise.
49 * method.c: Likewise.
50 * name-lookup.c: Likewise.
51 * parser.c: Likewise.
52 * pt.c: Likewise.
53 * rtti.c: Likewise.
54 * search.c: Likewise.
55 * typeck.c: Likewise.
56
127b8136
MM
572003-07-06 Mark Mitchell <mark@codesourcery.com>
58
59 PR c++/11345
60 * search.c (lookup_base_r): Remove is_non_public and
61 within_current_scope parameters. Remove other dead code.
62 (lookup_base): Adjust call to lookup_base_r.
63 (adjust_result_of_qualified_name_lookup): Improve comment.
64 * semantics.c (finish_call_expr): Use maybe_dummy_object.
65
cb66e385
NB
662003-07-06 Neil Booth <neil@daikokuya.co.uk>
67
68 * cp-lang.c (LANG_HOOKS_HANDLE_FILENAME,
69 LANG_HOOKS_MISSING_ARGUMENT): Override.
70
0a72704b
MM
712003-07-05 Mark Mitchell <mark@codesourcery.com>
72
73 PR c++/11431
74 * typeck.c (build_static_cast): Check for reference conversions
75 earlier.
76
772003-07-04 Mark Mitchell <mark@codesourcery.com>
78
79 * cp-tree.h (perform_integral_promotions): Declare.
80 * call.c (build_addr_func): Use decay_conversion.
81 (convert_arg_to_ellipsis): Likewise. Remove misleading comment.
82 (convert_for_arg_passing): Use perform_integral_promotions.
83 * cvt.c (build_expr_type_conversion): Use decay_conversion.
84 (type_promotes_to): Do not return a cv-qualified type.
85 * decl.c (grok_reference_init): Fix formatting.
86 (get_atexit_node): Use decay_conversion.
87 (build_enumerator): Use perform_integral_promotions.
88 * init.c (build_vec_init): Use decay_conversion.
89 * semantics.c (finish_expr_stmt): Likewise.
90 (finish_switch_cond): Use perform_integral_promotions.
91 * typeck.c (default_conversion): Likewise.
92 (perform_integral_promotions): New function.
93 (build_indirect_ref): Use decay_conversion.
94 (build_array_ref): Use perform_integral_promotions.
95 (convert_arguments): Use decay_conversion.
96 (build_unary_op): Use perform_integral_promotions.
97 (build_c_cast): Use decay_conversion.
98 (build_modify_expr): Likewise.
99 (convert_for_initialization): Likewise.
100 * typeck2.c (build_x_arrow): Likewise.
101
34cd5ae7
KH
1022003-07-04 Kazu Hirata <kazu@cs.umass.edu>
103
104 * call.c: Fix comment typos.
105 * class.c: Likewise.
106 * cp-tree.h: Likewise.
107 * cvt.c: Likewise.
108 * decl2.c: Likewise.
109 * decl.c: Likewise.
110 * init.c: Likewise.
111 * mangle.c: Likewise.
112 * parser.c: Likewise.
113 * pt.c: Likewise.
114 * search.c: Likewise.
115 * semantics.c: Likewise.
116 * tree.c: Likewise.
117 * typeck.c: Likewise.
118
e6cc3a24
ZW
1192003-07-04 Zack Weinberg <zack@codesourcery.com>
120
121 * parser.c (cp_lexer_read_token): No need to handle string
122 constant concatenation.
123
5f1989e6
KG
1242003-07-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
125
126 * cp-tree.h (GCC_DIAG_STYLE, ATTRIBUTE_GCC_CXXDIAG): Define.
127 (cp_error_at, cp_warning_at, cp_pedwarn_at): Mark with
128 ATTRIBUTE_GCC_CXXDIAG.
129
8d245821
MM
1302003-07-03 Mark Mitchell <mark@codesourcery.com>
131
d6b4ea85
MM
132 * call.c (build_addr_func): Handle bound pointers-to-members.
133 (build_method_call): Do not call resolve_offset_ref.
134 (implicit_conversion): Likewise.
135 (resolve_scoped_fn_name): Use finish_non_static_data_member, not
136 resolve_offset_ref.
137 (resolve_args): Do not call resolve_offset_ref.
138 (build_conditional_expr): Likewise.
139 (build_new_method_call): Likewise.
140 * cp-tree.def (OFFSET_REF): Update documentation.
141 (cp_convert_to_pointer): Update handling of conversions from
142 pointers to members to pointers.
143 (ocp_convert): Do not call resolve_offset_ref.
144 (convert_to_void): Likewise.
145 (build_expr_type_conversion): Likewise.
146 (delete_sanity): Likewise.
147 (resolve_offset_ref): Simplify greatly.
148 (build_vec_delete): Do not call resolve_offset_ref.
149 * parser.c (cp_parser_postfix_expression): Call resolve_offset_ref
150 if appropriate.
151 (cp_parser_unary_expression): Use
152 cp_parser_simple_cast_expression.
153 (cp_parser_delete_expression): Likewise.
154 (cp_parser_cast_expression): Likewise.
155 (cp_parser_pm_expression): Use cp_parser_binary_op.
156 (cp_parser_simple_cast_expression): New function.
157 * rtti.c (build_dynamic_cast_1): Do not call resolve_offset_ref.
158 * semantics.c (finish_increment_expr): Likewise.
159 (finish_typeof): Likewise.
160 * tree.c (lvalue_p_1): Do not handle OFFSET_REF.
161 * typeck.c (require_complete_type): Do not handle OFFSET_REFs.
162 (decay_conversion): Do not call resolve_offset_ref.
163 (finish_class_member_access_expr): Likewise.
164 (convert_arguments): Likewise.
165 (build_x_binary_op): Handle DOTSTAR_EXPR.
166 (condition_conversion): Do not call resolve_offset_ref.
167 (unary_complex_lvalue): Likewise.
168 (build_static_cast): Likewise.
169 (build_reinterpret_cast): Likewise.
170 (build_const_cast): Likewise.
171 (build_c_cast): Likewise.
172 (build_modify_expr): Likewise.
173 (convert_for_assignment): Likewise.
174 (convert_for_initialization): Likewise.
175 * typeck2.c (build_x_arrow): Likewise.
176 (build_m_component_ref): Simplify.
e6cc3a24 177
8d245821
MM
178 * call.c (build_scoped_method_call): Use convert_to_void.
179 (build_method_call): Likewise.
180 * class.c (check_field_decls): Remove dead code.
181 * cvt.c (convert_from_reference): Remove OFFSET_TYPE handling.
182 * decl2.c (grok_array_decl): Remove dead code.
183 (arg_assoc_type): Avoid relying on POINTER_TYPE over OFFSET_TYPE
184 as pointer-to-member representation.
185 * init.c (build_offset_ref): Tidy.
186 (build_vec_delete_1): Use convert_to_void.
187 * mangle.c (write_type): Avoid relying on POINTER_TYPE over OFFSET_TYPE
188 as pointer-to-member representation.
e6cc3a24 189
8db1028e
NS
1902003-07-03 Nathan Sidwell <nathan@codesourcery.com>
191
192 PR c++/9162
193 * decl.c (grokdeclarator): Return friend decls, not
194 void_type_node.
195 * decl2.c (grokfield): Alter friend decl check.
196 * parser.c (struct cp_parser): Document default_arg chain on
197 unparsed_functions_queue.
198 (cp_parser_save_default_args): New.
199 (cp_parser_init_declarator, cp_parser_function_definition,
200 cp_parser_member_declaration): Call it.
201 (cp_parser_class_specifier): Remove unused variable. Alter
202 processing of unparsed_functions_queue.
203
04d6ccbd
KG
2042003-07-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
205
206 * class.c (add_method, check_field_decl): Fix format specifier.
207 * decl.c (duplicate_decls, pushdecl, check_goto,
208 fixup_anonymous_aggr, maybe_commonize_var, grokdeclarator,
209 start_enum): Likewise.
210 * decl2.c (ambiguous_decl): Likewise.
211 * pt.c (redeclare_class_template): Likewise.
212
0c83a0fc
NS
2132003-07-02 Nathan Sidwell <nathan@codesourcery.com>
214
08476342
NS
215 PR c++/10219
216 * pt.c (type_unification_real): Don't unify exprs of error type.
217 * tree.c (error_type): Don't die on error_type.
218
0c83a0fc
NS
219 PR c++/9779
220 * decl2.c (arg_assoc_class): Don't die on NULL type.
221 * typeck.c (type_unknown_p): Don't die on untyped expressions.
222
ddb45080
MM
2232003-07-01 Mark Mitchell <mark@codesourcery.com>
224
225 PR c++/6949
226 * decl2.c (grokfield): Create TEMPLATE_DECLs for methods in local
227 classes.
228
b01b2484
KG
2292003-07-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
230
231 * error.c (locate_error): %P takes an `int', not a `tree'.
232
8cd2462c
JH
233Wed Jul 2 00:36:48 CEST 2003 Jan Hubicka <jh@suse.cz>
234
235 * decl2.c (defer_fn): Set DECL_DEFER_OUTPUT.
236 (finish-file): Do not process function with DECL_DEFER_OUTPUT clear;
237 clear DECL_DEFER_OUTPUT once function is processed; avoid flags
238 massaging.
239
240 * cp-tree.h (DECL_NEEDED_P): Support unit-at-a-time
241 (expand_or_defer_fn): Declare.
242 (lower_function): Declare.
243 * decl.c (start_cleanup_fn): Use expand_or_defer_fn.
244 * decl2.c: Include cgraph.h and varpool.h
245 (maybe_emit_vtables): Make explicit instantations as needed.
246 (mark_member_pointers, lower_function): New functions.
247 (finish_file): Do unit-at-a-time.
248 * method.c (synthesize_method): Use expand_or_defer_fn.
249 * optimize.c (maybe_clone_body): Use expand_or_defer_fn.
250 * parser.c (cp_parser_function_definition_after_decl): Use
251 expand_or_defer_fn.
252 * pt.c (instantiate_decl): Likewise.
253 * semantics.c: Include cgraph.h
254 (expand_or_defer_fn): Break out from ...
255 (expand_body): ... here; deal with unit-at-a-time.
256 * cp-lang.c (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION,
257 LANG_HOOKS_CALLGRAPH_LOWER_FUNCTION): Define.
258
28570f7e
MM
2592003-07-01 Mark Mitchell <mark@codesourcery.com>
260
261 * call.c (resolve_scoped_fn_name): Return error_mark_node for
262 erroneous cases.
263
62bfce90
MM
2642003-07-01 Mark Mitchell <mark@codesourcery.com>
265
266 PR c++/11149
267 * call.c (resolve_scoped_fn_name): Check that the qualifying scope
268 is a class type.
269
814ae570 2702003-07-01 Giovanni Bajo <giovannibajo@libero.it>
e6cc3a24
ZW
271
272 PR c++/8046
273 * error.c (dump_decl): Handle BIT_NOT_EXPR as
274 pseudo destructor calls.
814ae570 275
5b030314
NS
2762003-07-01 Nathan Sidwell <nathan@codesourcery.com>
277
278 * cp-tree.h (define_label): Replace filename and lineno
279 arguments with a location_t.
280 * decl.c (pop_label): Adjust define_label call.
281 (define_label): Replace filename and lineno arguments with a
282 location_t.
283 * semantics.c (finish_label): Adjust define_label call.
284
c9bdad35
MM
2852003-07-01 Mark Mitchell <mark@codesourcery.com>
286
287 PR c++/9559
288 * decl2.c (grokfield): Do not build NOP_EXPRs around the
289 error_mark_node.
290
37fa72e9
NB
2912003-06-30 Neil Booth <neil@daikokuya.co.uk>
292
293 * Make-lang.in: Update.
294 * cp-lang.c (c_language): Define.
295 (LANG_HOOKS_INIT_OPTIONS): Use common hook.
296 * cp-tree.h (cxx_init_options): Remove.
297 * lex.c: Don't include diagnostic.h.
298 (cxx_init_options): Remove.
299
44978276
GB
3002003-06-30 Giovanni Bajo <giovannibajo@libero.it>
301
e6cc3a24
ZW
302 PR c++/4933
303 * error.c (dump_expr): Support correctly the COMPOUND_EXPR
304 tree generated within a template. Use dump_expr to dump an
305 expression sizeof.
44978276 306
f8bee204
GB
3072003-06-30 Giovanni Bajo <giovannibajo@libero.it>
308
e6cc3a24
ZW
309 * mangle.c (write_expression): Exit gracefully when trying to
310 mangle a CALL_EXPR.
f8bee204 311
9b61cc1b
GB
3122003-06-30 Giovanni Bajo <giovannibajo@libero.it>
313
e6cc3a24
ZW
314 PR c++/10750
315 * parser.c (cp_parser_primary_expression): A VAR_DECL with a
316 (value- or type-) dependent expression as DECL_INITIAL is a
317 valid constant-expression (at parser time).
9b61cc1b 318
37198bc8
GB
3192003-06-30 Giovanni Bajo <giovannibajo@libero.it>
320
e6cc3a24
ZW
321 PR c++/11106
322 * error.c (dump_decl): Call dump_decl to dump the DECL_NAME for a
323 USING_DECL, instead of print_tree_identifier.
37198bc8 324
4e3f84b7
GDR
3252003-06-29 Gabriel Dos Reis <gdr@integrable-solutions.net>
326
327 * cp-tree.h (language_to_string): Adjust declaration.
328 * dump.c (cp_dump_tree): Adjust usage.
329 * error.c (dump_char): Use output_formatted_scalar. Tidy.
330 (parm_to_string): Lose unused parameter. Tidy.
331 (expr_to_string): Likewise.
332 (code_to_string): Likewise.
333 (language_to_string): Likewise.
334 (op_to_string): Likewise.
335 (assop_to_string): Likewise.
336 (digit_buffer): Remove.
337 (dump_type): Format builtin vector type as __vector__.
338
748f6cb5
GDR
3392003-06-29 Gabriel Dos Reis <gdr@integrable-solutions.net>
340
341 * error.c (print_integer): Remove.
342 (dump_type_suffix): Adjust.
343 (dump_expr): Likewise.
344
9a472a42
NS
3452003-06-28 Nathan Sidwell <nathan@codesourcery.com>
346
35773471
NS
347 * error.c (print_instantiation_partial_context): Take a
348 location_t.
349 (print_instantiation_full_context): Adjust.
350 (print_instantiation_context): Adjust.
351
9a472a42
NS
352 * cp-tree.h (cp_line_of, cp_file_of): Remove.
353 * error.c (cp_line_of, cp_file_of): Merge into ...
354 (location_of): ... here. Make static, return a location_t.
355 (cp_error_at, cp_warning_at, cp_pedwarn_at): Adjust.
356
2e2d4075
NS
3572003-06-28 Nathan Sidwell <nathan@codesourcery.com>
358
359 PR c++/10784
360 * call.c (joust): Move warn_conversion check outwards.
361
8ce33230
ZW
3622003-06-27 Zack Weinberg <zack@codesourcery.com>
363
364 * decl.c (build_typename_type)
365 * mangle.c (write_template_template_arg)
366 * parser.c (cp_parser_scope_through_which_access_occurs)
367 * pt.c (push_access_scope_real, push_access_scope, pop_access_scope)
368 * repo.c (get_base_filename)
369 * semantics.c (maybe_convert_cond):
370 Mark the definition static, matching the forward declaration.
371
dce50630
MM
3722003-06-27 Mark Mitchell <mark@codesourcery.com>
373
374 PR c++/10468
375 * pt.c (tsubst): Handle qualified TYPEOF_TYPEs correctly.
376
e455bc27
MM
3772003-06-27 Mark Mitchell <mark@codesourcery.com>
378
379 PR c++/10796
380 * decl.c (finish_enum): Implement DR377.
381
382 * decl.c (cp_finish_decl): Don't make variables with reference
383 type readonly while they are being initialized.
384
3a73bcc6
MM
3852003-06-26 Mark Mitchell <mark@codesourcery.com>
386
387 PR c++/11332
388 * typeck.c (build_static_cast): Avoid returning expressions with
389 reference type.
390
8d4ce389
NS
3912003-06-26 Nathan Sidwell <nathan@codesourcery.com>
392
393 * call.c (build_op_delete_call): Use strip_array_call. Correct
394 error message to say 'delete' or 'delete[]'.
395
2f54a1db
GB
3962003-06-26 Giovanni Bajo <giovannibajo@libero.it>
397
8ce33230
ZW
398 PR c++/8266
399 * pt.c (check_explicit_specialization): When looking up a
400 template function from an identifier outside class-scope, bind
401 it to CP_DECL_CONTEXT.
2f54a1db 402
3fe18f1d
MM
4032003-06-25 Mark Mitchell <mark@codesourcery.com>
404
e80706c4
MM
405 PR c++/10990
406 * search.c (lookup_base_r): Rely on accessible_p, rather than
407 trying to emulate that logic here.
408
3fe18f1d
MM
409 PR c++/10931
410 * call.c (convert_like): Pass issue_conversion_warnings.
411 (convert_like_with_context): Likewise.
412 (convert_like_real): Add issue_conversion_warnings parameter.
413 (perform_direct_initialization_if_possible): New function.
414 * cp-tree.h (perform_direct_initialization_if_possible): Declare it.
415 * typeck.c (check_for_casting_away_constness): New function.
416 (build_static_cast): Rewrite.
8ce33230 417
6df5158a
NS
4182003-06-24 Nathan Sidwell <nathan@codesourcery.com>
419
420 * call.c (enforce_access): Assert we get a binfo.
421 (build_op_delete_call): Pass a binfo to
422 perform_or_defer_access_check.
423 * class.c (alter_access): Likewise.
424 * decl.c (make_typename_type): Likewise.
425 (make_unbound_class_template): Likewise.
426 * lex.c (do_identifier): Likewise.
427 * method.c (hack_identifier): Likewise.
428 * parser.c (cp_parser_lookup_name): Likewise.
429 * search.c (lookup_member): Likewise. Move IDENTIFIER_CLASS_VALUE
430 test.
431 * semantics.c (finish_non_static_data_member): Likewise.
432 (perform_or_defer_access_check): Expect a binfo.
433 * typeck.c (comptypes): Expect types.
434
435 * mangle.c (find_substitution): Don't pass a non-type to same_type_p
436 * friend.c (make_friend_class): Likewise.
437 * pt.c (check_default_tmpl_args): Likewise.
438 (lookup_template_class): Likewise.
439
cebebe72
JH
440Tue Jun 24 15:30:05 CEST 2003 Jan Hubicka <jh@suse.cz>
441
442 * method.c (thunk_labelno): Move outside ifdef block to make garbage
443 collector happy.
444
d35543c0
JH
445Tue Jun 24 13:52:34 CEST 2003 Jan Hubicka <jh@suse.cz>
446
447 * class.c (build_vtable): Make vtables.
448 * cp-tree.h (DECL_VTABLE_OR_VTT_P): New macro.
449 * decl2.c (output_vtable_inherit): Rename to ...
450 (prepare_assemble_variable): ... this one; change interface.
451 (maybe_emit_vtables): Do not call output_vtable_inherit.
452 * cp-lang.c (LANG_HOOKS_PREPARE_ASSEMBLE_VARIABLE): Define.
453 * cp-tree.h (prepare_assemble_variable): New.
454
d46c570d
AP
4552003-06-23 Andrew Pinski <pinskia@physics.uc.edu>
456
457 * method.c: add prototype for make_alias_for_thunk.
458 (thunk_labelno, make_alias_for_thunk): only define
459 if ASM_OUTPUT_DEF is defined.
460
89ce1c8f
JJ
4612003-06-23 Jakub Jelinek <jakub@redhat.com>
462
463 * method.c (thunk_labelno): New variable.
464 (make_alias_for_thunk): New function.
465 (use_thunk): Use it if defined ASM_OUTPUT_DEF. Put the thunk
466 into the same section as the function it is calling.
467 Include gt-cp-method.h.
468 * Make-lang.in (gt-cp-method.h): Depend on s-gtype.
469 (cp/method.o): Depend on gt-cp-method.h.
470 * config-lang.in (gtfiles): Add $(srcdir)/cp/method.c.
471
bb4f6e6b
JH
472Mon Jun 23 19:41:27 CEST 2003 Jan Hubicka <jh@suse.cz>
473
474 * decl.c (register_dtor_fn): Mark cleanup as used.
475 * decl2.c (mark_vtable_entries): Skip nops.
476 * rtti.c (get_tinfo_ptr): Mark tinfo as used.
477 (build_dynamic_cast_1): Likewise.
478 (tinfo_base_init): Likewise.
479 (emit_tinfo_decl): Likewise.
480
98decfaf
JJ
4812003-06-23 Jakub Jelinek <jakub@redhat.com>
482
6df5158a 483 * mangle.c (hash_type): Val is the TREE_LIST itself, not a pointer
98decfaf
JJ
484 to it.
485
25abc0a5
GDR
4862003-06-21 Gabriel Dos Reis <gdr@integrable-solutions.net>
487
488 PR c++/10784
489 * call.c (joust): Warn about choosing conversion sequence only if
490 -Wconversion.
491
84cc377e
GDR
4922003-06-21 Gabriel Dos Reis <gdr@integrable-solutions.net>
493
25abc0a5 494 PR c++/10864
84cc377e
GDR
495 * call.c (op_error): Tidy.
496 * error.c (dump_expr): Properly format 'T()' when T is an
497 aggregate type.
498
dfbeb061
GDR
4992003-06-21 Gabriel Dos Reis <gdr@integrable-solutions.net>
500
501 PR c++/10915
502 * decl.c (grok_op_properties): Warn possible confusing conversion
503 only if -Wconversion.
504
68361a03
MM
5052003-06-20 Mark Mitchell <mark@codesourcery.com>
506
66d418e6
MM
507 PR c++/10749
508 * parser.c (cp_parser_class_head): See through dependent names
509 when parsing a class-head.
510
68361a03
MM
511 PR c++/10845
512 * pt.c (try_class_unification): Correct handling of member class
513 templates.
514
1f9cc6db
NS
5152003-06-20 Nathan Sidwell <nathan@codesourcery.com>
516
517 * semantics.c (genrtl_finish_function): Adjust
518 expand_function_end call.
519
170b020f
MM
5202003-06-19 Mark Mitchell <mark@codesourcery.com>
521
00cf3e31
MM
522 PR c++/10939
523 * pt.c (tsubst_decl): Do not try to substitute into non-dependent
524 functions.
525 (value_dependent_expression_p): Correct logic for FUNCTION_DECLs.
526
f139561c
MM
527 PR c++/9649
528 * cp-tree.h (pushdecl_class_level): Change prototype.
529 (push_class_level_binding): Likewise.
530 * decl.c (add_binding): Reject duplicate static data members.
531 (pushdecl_class_level): Return a value indicating whether or not
532 the binding was valid.
533 (push_class_level_binding): Likewise.
534 * semantics.c (finish_member_declaration): Don't keep invalid
535 declarations.
536
170b020f
MM
537 PR c++/11041
538 * call.c (initialize_reference): Do not use cp_finish_decl to emit
539 temporary variables.
540 * cp-tree.h (static_aggregates): Declare.
541 (pushdecl_top_level_and_finish): Likewise.
542 * decl.c (pushdecl_top_level_1): New function.
543 (pushdecl_top_level): Use it.
544 (pushdecl_top_level_and_finish): New function.
545 (initialize_local_var): Remove redundant code.
546 (cp_finish_decl): Remove support for RESULT_DECLs. Don't check
547 building_stmt_tree.
548 * decl.h (static_aggregates): Remove.
549 * decl2.c (get_guard): Use pushdecl_top_level_and_finish.
550 * rtti.c (get_tinfo_decl): Use pushdecl_top_level_and_finish.
551 (tinfo_base_init): Likewise.
8ce33230 552
7a1d37e9
MA
5532003-06-19 Matt Austern <austern@apple.com>
554
555 PR c++/11228
556 * init.c (build_zero_init): Assert that number of array elements
557 is an integer constant.
558 (build_default_init) Don't use build_zero_init for arrays with
559 variable number of elements.
8ce33230 560
e295f317
AJ
5612003-06-19 Andreas Jaeger <aj@suse.de>
562
563 * cp-tree.h: Remove duplicated declarations.
564
3a978d72
NN
5652003-06-18 Nathanael Nerode <neroden@gcc.gnu.org>
566
567 * pt.c: Convert to ISO C.
568 * semantics.c: Convert to ISO C.
569
acd8e2d0
NS
5702003-06-18 Nathan Sidwell <nathan@codesourcery.com>
571
572 * cp-tree.h (comp_except_specs, compparms, cp_has_mutable_p,
573 at_least_as_qualified_p, more_qualified_p): Return bool.
574 * typeck.c: ANSIFY function definitions.
575 (comp_array_types): Take redeclaration bool parameter.
576 (comptypes): Rearrange STRICT handling.
577 (at_least_as_qualified_p, more_qualified_p,
578 comp_cv_qualification): Cache cv quals.
579 (compparms): Rearrange loop.
e295f317 580
c8a209ca
NS
5812003-06-18 Nathan Sidwell <nathan@codesourcery.com>
582
583 * cp-tree.h (COMPARE_RELAXED): Rename to ...
584 (COMPARE_DERIVED): ... here. Adjust comment.
585 (resolve_typename_type_in_current_instantiation): Remove.
586 (cp_tree_equal, comptypes): Return a bool.
587 * cvt.c (convert_to_reference): Adjust comptypes call.
588 * pt.c (template_args_equal, unify,): Adjust cp_tree_equal call.
589 (resolve_typename_type_in_current_instantiation): Remove.
590 * tree.c (cp_tree_equal): Return bool. Cope with TEMPLATE_DECLs and
591 IDENTIFIER_NODEs. Abort if undeciderable. Adjust recursive
592 calls. Refactor code.
593 * typeck.c (comp_array_types): Return bool. Lose callback.
594 parameter. Adjust cp_tree_equal calls.
595 (comptypes): Return bool. Adjust strict handling. Remove relaxed
596 enumeration and java type handling. Deal with typename types here.
597 Adjust recursive and cp_tree_equals calls. Adjust base and derived
598 checking.
599 (comp_target_types): Remove unreachable code. Adjust
600 same_or_base_type_p calls.
601 (ptr_reasonably_similar): Adjust base and derived check.
e295f317 602
c8a209ca
NS
603 * typeck.c (maybe_warn_about_returning_address_of_local): Remove
604 unused calculation.
605 (check_return_expr): Adjust error messages.
606 * cp-tree.def (SCOPE_REF): Correct comment.
607
a26574f5
MM
6082003-06-17 Mark Mitchell <mark@codesourcery.com>
609
610 * mangle.c (mangle_conv_op_name_for_type): Correct sprintf format
611 string again.
612
f3f735eb
RA
6132003-06-17 Robert Abeles <rabeles@archaelogic.com>
614
615 * optimize.c (dump_function): Form complete flag name by
616 prefixing 'fdump-' to string returned by dump_flag_name().
617
f2d90304
MM
6182003-06-17 Mark Mitchell <mark@codesourcery.com>
619
620 * mangle.c (mangle_conv_op_name_for_type): Correct sprintf format
621 string.
622
9da32fe1
JM
6232003-06-17 Jason Merrill <jason@redhat.com>
624
625 PR c++/10929
626 * decl.c (grokfndecl): Don't mark a function inline for
627 -finline-functions if it isn't defined.
628
ca90f3e1
MM
6292003-06-17 Mark Mitchell <mark@codesourcery.com>
630
019bb98e 631 PR c++/10712
3cedc9d8
MM
632 * class.c (handle_using_decl): Robustify.
633
ca90f3e1
MM
634 PR c++/11105
635 * cp-tree.h (DECL_CONV_FN_TYPE): New method.
636 * mangle.c (struct globals): Remove internal_mangling_p.
637 (write_unqualified_name): Use DECL_CONV_FN_TYPE.
638 (write_template_parm): Don't write out the level number.
639 (conv_type_names): New variable.
640 (hash_type): New function.
641 (compare_type): Likewise.
642 (mangle_conv_op_name_for_type): Don't try to mangle conversion
643 operator names.
644 * search.c (lookup_conversion_operator): New function.
645 (lookup_fnfields_1): Use it.
646
4c168c6e
AJ
6472003-06-17 Andreas Jaeger <aj@suse.de>
648
649 * except.c: Remove duplicate declaration of push_eh_cleanup.
650
651 * call.c: Remove extra declaration of inhibit_warnings.
652
89aec4b1
NN
6532003-06-16 Nathanael Nerode <neroden@gcc.gnu.org>
654
655 2003-06-16 Jens-Michael Hoffmann <jensmh@gmx.de>
656 * mangle.c: Convert to ISO C.
657
fad205ff
KG
6582003-06-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
659
660 * cp/decl.c, cp/pt.c, cp/search.c, cp/tree.c: Don't use the PTR
661 macro.
662
b57b79f7
NN
6632003-06-16 Nathanael Nerode <neroden@gcc.gnu.org>
664
665 * tree.c: Convert to ISO C.
666
4de8668e
KH
6672003-06-16 Kazu Hirata <kazu@cs.umass.edu>
668
669 * cp-tree.h: Follow spelling conventions.
670 * mangle.c: Likewise.
671 * method.c: Likewise.
672 * parser.c: Likewise.
673
ee6b0296
NS
6742003-06-14 Nathan Sidwell <nathan@codesourcery.com>
675
676 * decl.c (start_function): Adjust init_function_start call.
677 * method.c (use_thunk): Likewise.
678 * semantics.c (genrtl_start_function): Likewise.
679
d7b42618
NB
6802003-06-14 Neil Booth <neil@daikokuya.co.uk>
681
682 * Make-lang.in: Remove c-options.o.
683
0a8cb79e
NN
6842003-06-13 Nathanael Nerode <neroden@gcc.gnu.org>
685
9e7d1164
NN
686 * lex.c: Convert to ISO C.
687
362efdc1
NN
688 2003-05-19 Jens-Michael Hoffmann <jensmh@gmx.de>
689 * init.c: removes use of PARAMS macro. Use ISO style function
690 declarations. (Not copyright-significant change.)
691
cec57f72
NN
692 * rtti.c: Remove PARAMS.
693
0a8cb79e
NN
694 * typeck2.c: Convert to ISO C.
695
79b59cc3
MM
6962003-06-12 Mark Mitchell <mark@codesourcery.com>
697
698 PR c++/10635
699 * typeck.c (build_c_cast): Check that the destination type is
700 complete.
701
df7f7b9c
MM
7022003-06-11 Mark Mitchell <mark@codesourcery.com>
703
704 PR c++/10432
705 * cp-tree.h (finish_declarator): Remove.
706 * decl.c (cp_finish_decl): Make sure to pop_nested_class even for
707 erroneous declarations.
708 * semantics.c (finish_declarator): Remove.
709
35b4a576
RS
7102003-06-11 Roger Sayle <roger@eyesopen.com>
711
e295f317 712 * decl2.c (generate_ctor_or_dtor_function): Avoid expanding a
35b4a576
RS
713 global static constructor/destructor if it will be empty, i.e.
714 either doesn't call any ctors/dtors or only calls pure or const
715 ctors/dtors.
716
a5512a2f
MM
7172003-06-11 Mark Mitchell <mark@codesourcery.com>
718
24386c5e
MM
719 * mangle.c (tm_p.h): Include it.
720 * Make-lang.in (cp/mangle.o): Depend on $(TM_P_H).
721
a5512a2f
MM
722 PR c++/11131
723 * tree.c (cp_cannot_inline_fn): Check for "inline" before
724 instantiation.
725
0c16e8d6
JM
7262003-06-10 Jason Merrill <jason@redhat.com>
727
728 PR c++/10968
e9bbabab 729 * pt.c (mark_decl_instantiated): Clear DECL_COMDAT.
0c16e8d6 730
d192828a
GK
7312003-06-10 Andrew Pinski <pinskia@physics.uc.edu>
732
733 * decl.c (start_cleanup_fn): Move static 'counter' out, mark with GTY.
734 (start_cleanup_cnt): New.
735
d58b7c2d
MM
7362003-06-10 Mark Mitchell <mark@codesourcery.com>
737
738 PR c++/11131
739 * cp-tree.h (template_for_substitution): Declare.
740 * decl2.c (mark_used): Use it when figuring out whether or not a
741 function is inline.
742 * pt.c (template_for_substitution): Give it external linkage.
743 * tree.c (cp_cannot_inline_tree_fn): Instantiate as early as
744 possible.
745
94d3ea58
ZW
7462003-06-09 Zack Weinberg <zack@codesourcery.com>
747
748 PR 8861
749 * mangle.c (write_real_cst): New function. Implement
750 ABI-compliant mangling of floating-point literals when
751 -fabi-version>=2; provide backward compatibility with 3.3 when
752 -fabi-version=1 (with warning). Clarify commentary.
753 (write_template_arg_literal): Use write_real_cst.
754
55c6e1a6
AJ
7552003-06-07 Andreas Jaeger <aj@suse.de>
756
757 * cp/decl.c (xref_tag): Remove undefined macro NONNESTED_CLASSES.
758
2772ef3e
NB
7592003-06-07 Neil Booth <neil@daikokuya.co.uk>
760
761 * cp-lang.c (LANG_HOOKS_DECODE_OPTON): Drop.
762 (LANG_HOOKS_HANDLE_OPTION): Override.
763 * cp-tree.h (cxx_init_options): Update.
764 * lex.c (cxx_init_options): Update.
765
8f231b5d
JH
766Thu Jun 5 18:33:40 CEST 2003 Jan Hubicka <jh@suse.cz>
767
768 * Make-lang.in: Add support for stageprofile and stagefeedback
769
88d5a16e
R
7702003-06-04 J"orn Rennecke <joern.rennecke@superh.com>
771
772 * decl.c (grokdeclarator): Error_mark_node in, error_mark_node out.
773
81c0e50a
AJ
7742003-06-04 Andreas Jaeger <aj@suse.de>
775
776 * g++spec.c (lang_specific_driver): Remove ALT_LIBM usage.
777
dbe85b80
JM
7782003-06-03 Jason Merrill <jason@redhat.com>
779
94d3ea58 780 * cp/cp-tree.h (CP_AGGREGATE_TYPE_P): Accept vectors.
dbe85b80 781
94d3ea58 782 * cp/decl.c (reshape_init): Handle vectors.
dbe85b80 783
94d3ea58 784 * testsuite/g++.dg/init/array10.C: New.
dbe85b80 785
6c07f448
KL
7862003-06-03 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
787
788 PR c++/10940
789 * pt.c (check_explicit_specialization): Check for 'static'
790 earlier.
791
522801e7
DN
7922003-05-31 Diego Novillo <dnovillo@redhat.com>
793
794 * class.c (dump_array): Call CONSTRUCTOR_ELTS to access
795 the operand of a CONSTRUCTOR node.
796
82a2669e
GDR
7972003-05-31 Gabriel Dos Reis <gdr@integrable-solutions.net>
798
799 * decl.c (cp_binding_level::this_entity): Rename from this_class.
800 (cxx_scope_descriptor): New function.
801 (cxx_scope_debug): Likewise.
802 (push_binding_level): Use it.
803 (pop_binding_level): Likewise.
804 (suspend_binding_level): Likewise.
805 (resume_binding_level): Likewise.
806 (pushlevel_class): Adjust use of this_class.
807 (pushtag): Likewise.
808 (lookup_name_real): Likewise.
809 (global_scope_name): New variable.
810 (initialize_predefined_identifiers): Initialize it.
811 (push_namespace): Use it.
812 (make_cxx_scope): New function.
813 (pushlevel): Use it.
814 (pushlevel_class): Likewise.
815 (push_binding_level): Simplify. Loose the last two arguments.
816 (make_binding_level): Remove.
817 (initial_push__namespace_scope): New function.
818 (push_namespace): Use it. Simplify.
55c6e1a6 819 (cxx_init_decl_processing): Likewise.
82a2669e
GDR
820 (declare_namespace_level): Remove.
821
76d3baad
KL
8222003-05-31 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
823
824 PR c++/10956
825 * pt.c (instantiate_decl): Don't use full template arguments if
826 we are dealing with specializations.
827
f37e2274
GDR
8282003-05-29 Gabriel Dos Reis <gdr@integrable-solutions.net>
829
830 * decl.c (ENABLE_SCOPE_CHECKING): Rename from DEBUG_BINDING_LEVELS.
831 (binding_depth): Unconditionally define.
832 (is_class_level): Likewise.
833 (indent): Likewise. Take an indenting parameter.
55c6e1a6 834 (push_binding_level): Remove conditional definittion.
f37e2274
GDR
835 (pop_binding_level): Likewise.
836 (suspend_binding_level): Likewise.
837 (resume_binding_level): Likewise.
838 (pushlevel): Likewise.
839 (pushlevel_class): Likewise.
840 (poplevel_class): Likewise.
841 (pop_everything): Likewise.
842
5f52c0e0
GDR
8432003-05-27 Gabriel Dos Reis <gdr@integrable-solutions.net>
844
845 * name-lookup.h (global_scope_p): New macro.
846 * decl.c (pop_binding_level): Use it. Don't refer directly to
55c6e1a6 847 global_binding_level.
5f52c0e0
GDR
848 (suspend_binding_level): Likewise.
849 (global_bindings_p): Likewise.
850 (print_other_binding_stack): Likewise.
851 (print_binding_stack): Likewise.
852 (maybe_push_to_top_level): Likewise.
853 (pushdecl_namespace_level): Likewise.
854 (cxx_init_decl_processing): Likewise.
855 (start_decl): Likewise.
856 (cp_finish_decl): Likewise.
857 (start_function): Likewise.
858 (global_binding_level): Remove.
859
b7fc8b57
KL
8602003-05-25 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
861
862 * parser.c (cp_parser_explicit_instantiation): Restore old
863 access before template instantiation.
864
0de12fcc
GK
8652003-05-23 Geoffrey Keating <geoffk@apple.com>
866
867 * lang-specs.h: Use -o to specify preprocessor's output file.
868 Make -no-integrated-cpp work when building PCH files.
869
43b26a01
KL
8702003-05-23 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
871
872 PR c++/10682
873 * pt.c (instantiate_class_template): Use DECL_ARTIFICIAL to
874 check for implicitly created typedef to an enum.
875
49b7aacb
JM
8762003-05-21 Jason Merrill <jason@redhat.com>
877
878 * init.c (build_vec_delete): Copy the address into a temporary
879 variable before calling build_vec_delete_1.
880 * decl2.c (delete_sanity): Don't call stabilize_reference.
881
b190f239
NS
8822003-05-21 Nathan Sidwell <nathan@codesourcery.com>
883
884 * pt.c (register_specialization): Update the decl's location,
885 if necessary.
886 (check_explicit_specialization): Likewise.
887
58228df6
KG
8882003-05-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
889
890 * error.c (dump_expr): Use HOST_WIDE_INT_PRINT_DOUBLE_HEX.
891
16e31964
DS
8922003-05-21 Danny Smith <dannysmith@users.sourceforge.net>
893
894 PR c++/9738
895 * decl.c (duplicate_decls): Re-invoke make_decl_rtl
896 if the old decl had instantiated DECL_RTL.
897 (Base on Richard Henderson 2003-05-13 patch to c-decl.c).
898
a01fff59
MA
8992003-05-19 Matt Austern <austern@apple.com>
900
901 * lang-options.h: Document -Wno-invalid-offsetof
902 * typeck.c (build_class_member_access_expr): Don't complain about
903 (Foo *)p->x for non-POD Foo if warn_invalid_offset is zero.
55c6e1a6 904
7e8f3096
AP
9052003-05-18 Andrew Pinski <pinskia@physics.uc.edu>
906
907 * name-lookup.c (free_binding_entry): fix where the GTY markers are.
908 (binding_entry_make): Make entry->chain NULL after getting an entry.
909 fix the spelling of chain in a comment.
910 (binding_table_free): speed up by having temporary variable.
911 (binding_table_new): set table->chain to be NULL after allocating
55c6e1a6 912 a table.
7e8f3096
AP
913 (cxx_binding_make): use gcc_alloc instead of ggc_alloc_cleared and set
914 binding->previous to NULL after getting an binding for speed.
55c6e1a6 915
5e0c54e5
GDR
9162003-05-18 Gabriel Dos Reis <gdr@integrable-solutions.net>
917
918 * cp-tree.h (struct lang_type_class): Replace data member tags
919 with hash-table nested_udts.
920 (CLASSTYPE_NESTED_UTDS): Rename from CLASSTYPE_TAGS.
921 * class.c (unreverse_member_declarations): Don't touch
55c6e1a6 922 CLASSTYPE_TAGS.
5e0c54e5
GDR
923 (pushclass): Use cxx_remember_type_decls.
924 * decl.c (struct cp_binding_level): Replace data member tags with
925 hash-table type_decls.
926 (pop_binding_level): Handle level->type_decls.
927 (kept_level_p): Adjust.
928 (poplevel): Remove unused local variable.
929 (bt_print_entry): New function.
930 (print_binding_level): Use it.
931 (push_namespace): Build current_binding_level->type_decls.
932 (maybe_process_template_type_declaration): Adjust.
933 (pushtag): Likewise.
934 (clear_anon_tags): Use binding_table_remove_anonymous_types.
935 (gettags): Remove.
936 (cxx_remember_type_decls): Rename from storetags. Adjust.
937 (lookup_tag): Use binding_table_find_anon_type. Tidy.
938 (lookup_tag_reverse): Use binding_table_reverse_maybe_remap.
939 (cxx_init_decl_processing): Build global_binding_level->type_decls.
940 (store_parm_decls): Remove pointless code.
941 * name-lookup.c (free_binding_entry): New variable.
942 (ENTRY_INDEX): New macro.
943 (struct binding_table_s): New datatype.
944 (binding_entry_make): New function.
945 (binding_entry_free): Likewise.
946 (binding_table_construct): Likewise.
947 (binding_table_free): Likewise.
948 (binding_table_new): Likewise.
949 (binding_table_expand): Likewise.
950 (binding_table_insert): Likewise.
951 (binding_table_find): Likewise.
952 (binding_table_find_anon_type): Likewise.
953 (binding_table_reverse_maybe_remap): Likewise.
954 (binding_table_remove_anonymous_types): Likewise.
955 (binding_table_foreach): Likewise.
956 * name-lookup.h (binding_table): New type.
957 (binding_entry): Likewise.
958 (bt_foreach_proc): Likewise.
959 (struct binding_entry_s): New datatype.
960 (SCOPE_DEFAULT_HT_SIZE): New macro.
961 (CLASS_SCOPE_HT_SIZE): Likewise.
962 (NAMESPACE_ORDINARY_HT_SIZE): Likewise.
963 (NAMESPACE_STD_HT_SIZE): Likewise.
964 (GLOBAL_SCOPE_HT_SIZE): Likewise.
965 (binding_table_new): Declare.
966 (binding_table_free): Likewise.
967 (binding_table_insert): Likewise.
968 (binding_table_find_anon_type): Likewise.
969 (binding_table_reverse_maybe_remap): Likewise.
970 (binding_table_remove_anonymous_types): Likewise.
971 (binding_table_foreach): Likewise.
972 (binding_table_find): Likewise.
973 (cxx_remember_type_decls): Likewise.
974 * pt.c (bt_instantiate_type_proc): New function.
975 (do_type_instantiation): Use it.
976 * search.c (lookup_field_r): Use binding_table_find.
977
25903d03
KL
9782003-05-18 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
979
980 * semantics.c (perform_deferred_access_checks): Don't discard
981 checked access.
982
e34d07f2
KG
9832003-05-17 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
984
985 * error.c (cp_error_at, cp_warning_at, cp_pedwarn_at): Eliminate
986 libiberty VA_ macros, always use stdarg.
987 * rtti.c (create_pseudo_type_info): Likewise.
988 * tree.c (build_min_nt, build_min): Likewise.
989
90ff44cf
KG
9902003-05-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
991
992 * ptree.c (cxx_print_type, cxx_print_xnode): Use string
993 concatentation on HOST_WIDE_INT_PRINT_* format specifier to
994 collapse multiple function calls into one.
55c6e1a6 995 * tree.c (debug_binfo): Likewise.
90ff44cf 996
9cefd2ca
JM
9972003-05-15 Jason Merrill <jason@redhat.com>
998
999 PR c++/5388
1000 * call.c (conditional_conversion): Don't consider implicit
55c6e1a6 1001 conversions if T2 is a base of T1.
9cefd2ca
JM
1002 * cp-tree.h (DERIVED_FROM_P, UNIQUELY_DERIVED_FROM_P): Make boolean.
1003 (ACCESSIBLY_UNIQUELY_DERIVED_P, PUBLICLY_UNIQUELY_DERIVED_P): Likewise.
1004
1005 * parser.c (cp_parser_primary_expression): Convert a static data
1006 member from reference.
1007
dffbbe80
MM
10082003-05-15 Mark Mitchell <mark@codesourcery.com>
1009
8f4b394d
MM
1010 * call.c (build_op_delete_call): Avoid creating unnecessary types.
1011 * class.c (instantiate_type): Remove tests for tf_no_attributes.
1012 * cp-tree.h (tsubst_flags_t): Remove tf_no_attributes.
1013 (COMPARE_NO_ATTRIBUTES): Remove.
1014 * typeck.c (comptypes): Do not check COMPARE_NO_ATTRIBUTES.
1015
dffbbe80
MM
1016 PR c++/8385
1017 * semantics.c (finish_typeof): Refine type-dependency check.
1018
a65cddcf
JM
10192003-05-13 Jason Merrill <jason@redhat.com>
1020
1021 * typeck.c (build_modify_expr): Don't always stabilize the lhs and
1022 rhs. Do stabilize the lhs of a MODIFY_EXPR used on the lhs.
1023
afb19ffb
KL
10242003-05-11 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1025
1026 * method.c (synthesize_method): Call push/pop_deferring_access_checks.
1027
9f01ded6
KL
10282003-05-11 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1029
1030 PR c++/10230, c++/10481
1031 * semantics.c (finish_non_static_data_member): Handle when the
1032 non-static member is not from a base of the current class type.
1033
fcea7401
KL
10342003-05-11 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1035
1036 PR c++/10552
1037 * pt.c (tsubst_copy): Handle TEMPLATE_DECL that is a member class
1038 template and has dependent context.
1039
7d021397
KL
10402003-05-10 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1041
1042 * pt.c (instantiate_decl): Call push/pop_deferring_access_checks.
1043
78757caa
KL
10442003-05-10 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1045
1046 PR c++/9252
1047 * cp-tree.h (saved_scope): Remove check_access field.
1048 (tsubst_flags_t): Remove tf_parsing.
1049 * decl.c (maybe_push_to_top_level): Don't initialize
1050 scope_chain->check_access.
1051 (make_typename_type, make_unbound_class_template): Don't use
1052 tf_parsing.
1053 (register_dtor_fn): Use push/pop_deferring_access_checks
1054 instead of scope_chain->check_access.
1055 * method.c (use_thunk): Likewise.
1056 * parser.c (cp_parser_explicit_instantiation
1057 (cp_parser_constructor_declarator_p): Don't call
1058 push/pop_deferring_access_checks here.
1059 (cp_parser_template_argument, cp_parser_class_name): Don't use
1060 tf_parsing.
1061 (yyparse): Check flag_access_control.
1062 * pt.c (instantiate_class_template): Call
1063 push/pop_deferring_access_checks.
1064 * semantics.c (push_deferring_access_checks): Propagate
1065 dk_no_check.
1066 (perform_or_defer_access_check): Make sure basetype_path is
1067 a type before comparison.
1068 * call.c (build_op_delete_call, build_over_call): Use
1069 perform_or_defer_access_check.
1070 * class.c (alter_access): Likewise.
1071 * init.c (build_offset_ref): Likewise.
1072 * lex.c (do_identifier): Likewise.
1073 * method.c (hack_identifier): Likewise.
1074 * search.c (lookup_member): Likewise.
1075 * semantics.c (finish_non_static_data_member): Likewise.
1076 (simplify_aggr_init_exprs_r): Use push/pop_deferring_access_checks
1077 instead of flag_access_control.
1078
8d241e0b
KL
10792003-05-10 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1080
1081 PR c++/9554
1082 * parser.c (cp_parser_class_name): Remove check_access parameter.
1083 All caller adjusted. Update declaration.
1084 (cp_parser_lookup_name): Likewise.
1085 * semantics.c (push_deferring_access_checks): Change parameter type
1086 to enum deferring_kind. All caller adjusted.
1087 (resume_deferring_access_checks): Adjust to use new enum.
1088 (stop_deferring_access_checks): Likewise.
1089 (perform_or_defer_access_check): Likewise.
1090 * cp-tree.h (deferring_kind): New enum.
1091 (deferred_access): Adjust field type.
1092 (push_deferring_access_checks): Update declaration.
1093
88e98cfe
KL
10942003-05-09 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1095
1096 PR c++/10555, c++/10576
1097 * pt.c (lookup_template_class): Handle class template with
1098 multiple levels of parameters when one of the levels contain
1099 errors.
1100
8b5e2ce4
JM
11012003-05-08 Jason Merrill <jason@redhat.com>
1102
1103 * init.c (build_new_1): Don't reuse a TARGET_EXPR in an
1104 expression. Undo some of the recent reorg.
1105
a944ceb9
RH
11062003-05-07 Richard Henderson <rth@redhat.com>
1107
9cefd2ca
JM
1108 PR c++/10570
1109 * cfns.gperf: Comment out POSIX thread cancellation points,
1110 plus abort and raise.
1111 * cfns.h: Regenerate.
a944ceb9 1112
a65fd2d7
JM
11132003-05-07 Jason Merrill <jason@redhat.com>
1114
1115 * call.c (build_conditional_expr): Don't assume that the folded
1116 expression has result_type.
1117
d219f3ff
KL
11182003-05-06 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1119
1120 * typeck.c (build_unary_op): Deal with const qualifier in
1121 invalid pointer-to-member earlier.
1122
5f7262e6
JM
11232003-05-05 Jason Merrill <jason@redhat.com>
1124
1125 PR c++/9537
1126 * call.c (conditional_conversion): Build an RVALUE_CONV if
1127 we're just changing the cv-quals.
1128 (build_conditional_expr): Don't call convert to change
1129 cv-quals.
1130
16692dd5
KL
11312003-05-05 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1132
1133 PR c++/10496
1134 * typeck.c (build_unary_op): Don't output const qualifier when
1135 output invalid pointer-to-member diagnostics.
1136
7df87825
KL
11372003-05-05 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1138
1139 * decl.c: Fix typos.
1140
4b41d9eb
KL
11412003-05-05 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1142
1143 PR c++/4494
1144 * decl.c (start_function): Use same_type_p to check return type
1145 of main.
1146
87f85ea0
ZW
11472003-05-03 Zack Weinberg <zack@codesourcery.com>
1148
1149 PR c/10604
1150 * cp/typeck.c (build_x_compound_expr): No need to check
1151 extra_warnings as well as warn_unused_value.
1152
5dc5d13c
KL
11532003-05-03 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1154
1155 PR c++/9364, c++/10553, c++/10586
1156 * decl.c (make_typename_type): Don't crash on illegal code.
1157
82a98427
NS
11582003-05-03 Nathan Sidwell <nathan@codesourcery.com>
1159
1160 * class.c (finish_struct): Use location_t and input_location
1161 directly.
1162 * decl.c (make_label_decl): Likewise.
1163 (use_label): Likewise.
1164 * decl2.c (warn_if_unknown_interface): Likewise.
1165 (start_static_initialization_or_destruction): Likewise.
1166 (generate_ctor_or_dtor_function): Likewise.
1167 (finish_file): Likewise.
1168 * error.c (print_instantiation_full_context): Likewise.
1169 * init.c (create_temporary_var): Likewise.
1170 * method.c (synthesize_method): Likewise.
1171 * parser.c (cp_token): Likewise.
1172 (cp_lexer_set_source_position_from_token): Likewise.
1173 (cp_lexer_get_preprocessor_token): Likewise.
1174 (cp_parser_statement): Likewise.
1175 * pt.c (tsubst_friend_function): Likewise.
1176 (instantiate_class_template): Likewise.
1177 (tsubst_decl): Likewise.
1178 (tsubst): Likewise.
1179 (instantiate_decl): Likewise.
1180 * semantics.c (begin_class_definition): Likewise.
1181 (expand_body): Likewise.
1182
3489e061
NS
11832003-05-01 Nathan Sidwell <nathan@codesourcery.com>
1184
1185 * class.c (finish_struct): Rename lineno to input_line.
1186 * decl.c (push_binding_level, pop_binding_level,
1187 suspend_binding_level, resume_binding_level, make_label_decl,
1188 use_label, start_function): Likewise.
1189 * decl2.c (warn_if_unknown_interface,
1190 start_static_initialization_or_destruction,
1191 generate_ctor_or_dtor_function, finish_file): Likewise.
1192 * error.c (cp_line_of, print_instantiation_full_context,
1193 print_instantiation_context): Likewise.
1194 * except.c (check_handlers_1, check_handlers): Likewise.
1195 * init.c (create_temporary_var): Likewise.
1196 * method.c (use_thunk, synthesize_method): Likewise.
1197 * parser.c (cp_lexer_set_source_position_from_token,
1198 cp_lexer_get_preprocessor_token): Likewise.
1199 * pt.c (push_tinst_level, pop_tinst_level,
1200 tsubst_friend_function, instantiate_class_template, tsubst_decl,
1201 tsubst, tsubst_expr, instantiate_decl): Likewise.
1202 * semantics.c (genrtl_try_block, finish_label_stmt,
1203 begin_class_definition, expand_body,
87f85ea0 1204 genrtl_finish_function): Likewise.
3489e061
NS
1205 * tree.c (build_min_nt, build_min): Likewise.
1206
49bf4577
MM
12072003-05-01 Mark Mitchell <mark@codesourcery.com>
1208
1209 * decl2.c (comdat_linkage): Don't externalize explicit
1210 instantiations.
1211
d0af00af
KL
12122003-05-01 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1213
1214 PR c++/10554
1215 * decl2.c (do_class_using_decl): Check if operand 0 of SCOPE_REF
1216 is not NULL.
1217
85209a3c
SB
12182003-05-01 Steven Bosscher <steven@gcc.gnu.org>
1219
1220 * cp-tree.h (struct lang_id2): Remove. Move fields from here...
1221 (struct lang_identifier): ... to here.
1222 (LANG_ID_FIELD): Remove.
1223 (SET_LANG_ID): Remove.
1224 (IDENTIFIER_LABEL_VALUE): Adjust for new lang_identifier.
1225 (SET_IDENTIFIER_LABEL_VALUE): Likewise.
1226 (IDENTIFIER_IMPLICIT_DECL): Likewise.
1227 (SET_IDENTIFIERL_IMPLICIT_DECL): Likewise.
1228 (IDENTIFIER_ERROR_LOCUS): Likewise.
1229 (SET_IDENTIFIER_ERROR_LOCUS): Likewise.
1230
d12a7283
KL
12312003-05-01 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1232
1233 PR c++/8772
1234 * pt.c (convert_template_argument): Correct diagnostic.
1235
d7ed5e55
KL
12362003-04-30 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1237
1238 PR c++/9432, c++/9528
1239 * decl2.c (validate_nonmember_using_decl): Handle SCOPE_REF.
1240
152c16a9
GDR
12412003-04-30 Garbiel Dos Reis <gcc@integrable-solutions.net>
1242
1243 * decl.c (check_previous_goto_1): Adjust prototype.
1244 (check_previous_goto): Adjust use.
1245 (check_switch_goto): Likewise.
1246 (use_label): Adjust.
1247 (check_previous_goto_1): Don't use pedwarn_with_file_and_line.
1248 (struct named_label_use_list): Use location_t datatype.
1249
1f6f0cb6
MM
12502003-04-29 Mark Mitchell <mark@codesourcery.com>
1251
1252 PR c++/10551
1253 * pt.c (mark_decl_instantiated): Defer all explicit instantiations
1254 that have not yet been written out.
1255
60cde936
MM
12562003-04-29 Mark Mitchell <mark@codesourcery.com>
1257
555456b1
MM
1258 PR c++/10549
1259 * class.c (layout_class_type): Mark overlong bitfields as having
1260 the maximum size permitted by their type, after layout.
1261
60cde936
MM
1262 PR c++/10527
1263 * error.c (dump_expr): Correctly handling of NEW_EXPR.4
1264
8e854b76
KL
12652003-04-29 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1266
1267 * call.c (build_operator_new_call): Fix typo.
1268 * lang-options.h: Likewise.
1269
0dbc5cd3
MM
12702003-04-29 Mark Mitchell <mark@codesourcery.com>
1271
75135253
MM
1272 PR c++/10515
1273 * cp-tree.h (lookup_field_1): Declare it.
1274 * search.c (lookup_field_1): Make it public.
1275 * decl.c (reshape_init): Handle designated initializers.
1276
0dbc5cd3
MM
1277 * decl.c (maybe_commonize_var): Further tweak support for systems
1278 without weak symbols.
1279
9e6aaf5e
MM
12802003-04-27 Mark Mitchell <mark@codesourcery.com>
1281
1282 * decl.c (maybe_commonize_var): Fix thinko in last patch.
1283
0b50d7f1
MM
12842003-04-27 Mark Mitchell <mark@codesourcery.com>
1285
772f8889
MM
1286 PR c++/10506
1287 * method.c (use_thunk): Decrement immediate_size_expand.
1288
1289 PR c++/10503
1290 * cp-tree.h (DECL_VAR_MARKED_P): New macro.
1291 (DECL_MAYBE_TEMPLATE): Remove.
1292 * class.c (fixed_type_or_null): Avoid infinite recursion.
1293
0b50d7f1
MM
1294 * decl.c (maybe_commonize_var): Make the code match the comments.
1295 * pt.c (instantiate_decl): Move call to import_export_decl.
1296
e2b69423
MM
12972003-04-26 Mark Mitchell <mark@codesourcery.com>
1298
1299 * decl2.c (finish_file): Fix merge botch.
1300
ea56c40c
MM
13012003-04-25 Mark Mitchell <mark@codesourcery.com>
1302
1303 * decl2.c (finish_file): Don't call import_export_decl for
1304 functions that are not defined.
1305 (handle_class_head): Robustify.
1306 * pt.c (instantiate_decl): Do not call cp_finish_decl for
1307 variables that are not defined.
1308
9804b5b8
SP
13092003-04-24 Sylvain Pion <Sylvain.Pion@mpi-sb.mpg.de>
1310
87f85ea0 1311 * call.c (print_z_candidates): Fix off by one error.
9804b5b8 1312
f8986275
NS
13132003-04-24 Nathan Sidwell <nathan@codesourcery.com>
1314
1315 PR c++/10337
1316 * call.c (joust): Don't warn about conversion ops that are exact
1317 or cv-conversions. Rearrange to avoid multiple type comparisons.
1318
374ca7f7
MM
13192003-04-23 Mark Mitchell <mark@codesourcery.com>
1320
1321 PR c++/10471
1322 * call.c (build_cxx_call): Robustify.
1323
6338b358
NB
13242003-04-23 Neil Booth <neil@daikokuya.co.uk>
1325
1326 * Make-lang.in (lex.o): Remove mbchar.h.
1327 * lex.c (MULTIBYTE_CHARS): Lose.
1328 * parser.c (cp_lexer_get_preprocessor_token): CPP_OTHER handled
1329 in c-lex.c.
1330
4223f82f
MM
13312003-04-23 Mark Mitchell <mark@codesourcery.com>
1332
1333 PR c++/9847
1334 * cp-tree.h (duplicate_tag_error): Remove.
1335 * class.c (duplicate_tag_error): Remove.
1336 * semantics.c (begin_class_definition): Return immediately for a
1337 duplicate class definition.
1338
1339 PR c++/10451
1340 * decl.c (grokdeclarator): Correct logic for "mutable" errors.
1341
6adb9463
MM
13422003-04-22 Mark Mitchell <mark@codesourcery.com>
1343
ae2196c2
MM
1344 PR c++/10446
1345 * search.c (lookup_fnfields_1): Handle empty slots in the method
1346 vector.
87f85ea0 1347
befcd99b
MM
1348 PR c++/10428
1349 * decl.c (check_elaborated_type_specifier): New function, split
1350 out from ...
1351 (xref_tag): ... here. Use the new function in more places.
1352
6adb9463
MM
1353 * rtti.c (throw_bad_typeid): Use build_cxx_call.
1354
b2dd096b
MM
13552003-04-21 Mark Mitchell <mark@codesourcery.com>
1356
1357 * call.c (build_over_call): Use build_cxx_call.
1358 (build_cxx_call): New method, split out of build_over_call.
1359 * cp-tree.h (language_function): Add can_throw.
1360 (build_cxx_call): Declare it.
1361 * decl.c (finish_function): If a function does not contain any
1362 calls to functions that can throw an exception, indicate that
1363 fact.
1364 * decl2.c (mark_used): Do not defer the instantiation of
1365 functions, if the current function does not throw.
1366 * optimize.c (maybe_clone_body): Copy TREE_NOTHROW to the clones.
1367 * pt.c (instantiate_decl): Make sure import_export_decl is called
1368 before emitting things.
1369 * rtti.c (throw_bad_cast): Use build_cxx_call.
1370 (build_dynamic_cast_1): Likewise.
1371 * typeck.c (build_function_call): Likewise.
1372
8de9bb0e
NS
13732003-04-21 Nathan Sidwell <nathan@codesourcery.com>
1374
1375 PR c++/9881
1376 * typeck.c (build_unary_op): Fold all COMPONENT_REF addr
1377 expressions. Reverts my 2002-08-08 patch.
87f85ea0 1378
8de9bb0e
NS
1379 * typeck.c (comp_ptr_ttypes_real): Swap final && operands for
1380 cheaper early exit.
1381
299f79b5
NS
13822003-04-20 Nathan Sidwell <nathan@codesourcery.com>
1383
1384 * cp/decl2.c (start_static_storage_duration_function): Take count
1385 arg, don't check if it wraps round.
1386 (generate_ctor_or_dtor_function): Add locus arg, use it.
1387 (generate_ctor_and_dtor_functions_for_priority): Data arg is a
1388 locus.
1389 (finish_file): Set line numbers to past EOF for synthesized
1390 functions.
1391
13922003-04-20 Nathan Sidwell <nathan@codesourcery.com>
de0c0e69
NS
1393
1394 PR c++/10405
1395 * search.c (lookup_field_1): Final scan goes backwards for
1396 types, forwards for non-types.
1397
220a35cc
RS
13982003-04-17 Roger Sayle <roger@eyesopen.com>
1399
1400 PR c/10375
1401 * decl.c (duplicate_decls): Preserve "const", "noreturn" and
1402 "nothrow" function attributes.
1403
09d2f85f
KL
14042003-04-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1405
1406 PR c++/10347
1407 * pt.c (type_dependent_expression_p): Handle array new.
1408
5eb10628
MM
14092003-04-15 Mark Mitchell <mark@codesourcery.com>
1410
1411 PR c++/10381
1412 * parser.c (cp_parser_primary_expression): Reorganize logic for
1413 dealing with name lookup failures.
1414
ac5f3b67
JM
14152003-04-15 Jason Merrill <jason@redhat.com>
1416
1417 * decl2.c (mark_used): Don't instantiate anything if
1418 skip_evaluation.
1419
e6237031
ZL
14202003-04-14 Ziemowit Laski <zlaski@apple.com>
1421
1422 * tree.c (build_cplus_array_type_1): Do not call
1423 uses_template_parms() on a NULL index_type.
1424
1331d16f
RS
14252003-04-13 Roger Sayle <roger@eyesopen.com>
1426
1427 * decl.c (duplicate_decls): Preserve pure and malloc attributes.
1428
f4f4610e
MM
14292003-04-12 Mark Mitchell <mark@codesourcery.com>
1430
1431 PR c++/10300
1432 * init.c (build_new_1): Reorganize.
1433
dcf92453
ZW
14342003-04-12 Zack Weinberg <zack@codesourcery.com>
1435
1436 * class.c (initialize_array)
1437 * decl.c (reshape_init)
1438 * decl2.c (build_expr_from_tree)
1439 * init.c (build_zero_init)
1440 * pt.c (tsubst_copy, tsubst_copy_and_build)
1441 * rtti.c (tinfo_base_init, generic_initializer, ptr_initializer)
1442 (ptm_initializer, class_initializer, get_pseudo_ti_init)
1443 * semantics.c (finish_compound_literal)
1444 * typeck.c (build_ptrmemfunc1)
1445 * typeck2.c (store_init_value, process_init_constructor)
1446 (build_functional_cast): Use build_constructor.
1447
2bd02043
ZW
14482003-04-12 Zack Weinberg <zack@codesourcery.com>
1449
1450 * call.c (print_z_candidates): Use gcc_gettext_width, not
1451 strlen, to determine how much padding to use.
1452
339a28b9
ZW
14532003-04-10 Zack Weinberg <zack@codesourcery.com>
1454
1455 * decl.c: Update all calls to shadow_warning.
1456
1e099144
MM
14572003-04-10 Mark Mitchell <mark@codesourcery.com>
1458
1459 * class.c (layout_class_type): Correct handling for overlong
1460 bit-fields whose width is the same as an integer type.
1461
d78e771d
ZW
14622003-04-06 Zack Weinberg <zack@codesourcery.com>
1463
1464 * cp-tree.def: Make fourth element for all 'c' and 'x' nodes zero.
1465 * cp-lang.c (cp_tree_size): New function.
1466 (LANG_HOOKS_TREE_SIZE): Override.
1467
1468 * cp-tree.h (SOURCE_LOCUS, SRCLOC_FILE, SRCLOC_LINE, struct
1469 tree_srcloc, TS_CP_COMMON, TS_CP_SRCLOC): Kill.
1470 (union lang_tree_node): Remove common and srcloc members.
1471 (build_srcloc_here): Don't prototype.
1472 * decl.c (cp_tree_node_structure): Kill SRCLOC case.
1473 * pt.c (pending_templates): Correct comment.
1474 * tree.c (build_srcloc, build_srcloc_here): Kill.
1475
d2a6f3c0
ZW
14762003-04-06 Zack Weinberg <zack@codesourcery.com>
1477
1478 * call.c: Include intl.h.
1479 (print_z_candidate): Always use inform; get rid of errfn
1480 argument. Reorganize so that all the strings get picked up
1481 by xgettext. Note obligation of caller to pass first argument
1482 through gettext.
1483 (print_z_candidates): Update to match. Indent second and
1484 successive candidates by strlen() of translated message.
1485 (joust): Restructure ambiguous-conversion pedwarn so that
1486 translators see a complete sentence. Update calls to
1487 print_z_candidate.
1488
1489 * Make-lang.in (cp/call.o): Update dependencies.
1490
ff955512
KG
14912003-04-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1492
1493 * decl.c (set_current_binding_level): Delete, revert last change.
1494 (current_binding_level): Modify to allow it as as lvalue.
1495
da247ccc
KG
14962003-04-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1497
1498 * name-lookup.c (find_binding): Pass appropriate pointer type to
1499 POP_TIMEVAR_AND_RETURN.
1500
d893ff33
KG
15012003-04-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1502
1503 * Make-lang.in (cp-warn): Add $(STRICT_WARN).
1504 * cp-tree.h: Don't insist on having GNUC.
1505
78d55cc8
JM
15062003-04-03 Jason Merrill <jason@redhat.com>
1507
55a2af0c
JM
1508 * cvt.c (ocp_convert): Only abort if we try to convert an object
1509 of TREE_ADDRESSABLE type.
1510
78d55cc8
JM
1511 * class.c (build_vtable): Set DECL_ALIGN here.
1512 (get_vtable_decl): Not here.
1513 (layout_vtable_decl): Or here.
1514 (create_vtable_ptr): Or here.
1515 (layout_class_type): Or here.
1516 (check_bitfield_decl): Don't mess with field alignment.
1517
de94b46c
KG
15182003-04-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1519
1520 * operators.def (DEF_SIMPLE_OPERATOR, DEF_ASSN_OPERATOR,
1521 DEF_ASSN_OPERATOR): Delete spurious semi-colon.
1522 * rtti.c (dfs_class_hint_mark): Likewise.
1523
1524 * decl.c (push_local_name, push_class_level_binding,
1525 maybe_inject_for_scope_var): Don't use POP_TIMEVAR_AND_RETURN in
1526 functions returning void.
1527 * decl2.c (add_using_namespace): Likewise.
1528
1529 * decl.c (print_binding_level, print_other_binding_stack,
1530 print_binding_stack): Cast argument of %p specifier to void*.
1531 * ptree.c (cxx_print_decl): Likewise.
1532
1533 * cp-tree.h (VAR_OR_FUNCTION_DECL_CHECK,
1534 VAR_FUNCTION_OR_PARM_DECL_CHECK,
1535 VAR_TEMPL_TYPE_OR_FUNCTION_DECL_CHECK, RECORD_OR_UNION_TYPE_CHECK,
1536 BOUND_TEMPLATE_TEMPLATE_PARM_TYPE_CHECK, LANG_TYPE_CLASS_CHECK,
1537 LANG_TYPE_PTRMEM_CHECK, LANG_DECL_U2_CHECK): Add __extension__.
1538
1539 * decl.c (set_current_binding_level): New macro. Use throughout
1540 when setting the current binding level.
1541
1542 * cp-tree.h (cp_lvalue_kind, base_access): Delete trailing comma
1543 in enum.
1544 * method.c (mangling_flags): Likewise.
1545
1546 * cp-tree.h (lang_type_header): Add __extension__ and use
1547 CHAR_BITFIELD for members.
1548
0de298af
GK
15492003-04-02 Geoffrey Keating <geoffk@apple.com>
1550
1551 PR other/9274
1552 * mangle.c: Include gt-cp-mangle.h.
1553 (subst_identifiers): Mark with GTY.
1554 * config-lang.in (gtfiles): Add cp/mangle.c.
1555 * Make-lang.in: (gt-cp-mangle.h): New rule.
1556 (cp/mangle.o): Depends on gt-cp-mangle.h.
1557
28ea4c88
AP
15582003-04-01 Andrew Pinski <pinskia@physics.uc.edu>
1559
0de298af 1560 * config-lang.in (gtfiles): Add \$(srcdir)/cp/name-lookup.c
28ea4c88
AP
1561 after \$(srcdir)/cp/name-lookup.h.
1562 * name-lookup.c: (cxx_binding_make): Use ggc_alloc_clearedinstead
1563 of ggc_alloc. Include gt-cp-name-lookup.h at the end of the file.
0de298af
GK
1564 * Make-lang.in: (gt-cp-name-lookup.h): Is generated by gengtype.
1565 (cp/name-lookup.o): Depends on gt-cp-name-lookup.h.
d2a6f3c0 1566
adff28c3
JM
15672003-03-31 Jason Merrill <jason@redhat.com>
1568
1569 PR java/10145
1570 * class.c (check_field_decl): Don't set DECL_ALIGN.
1571
c717c5af
MM
15722003-03-30 Mark Mitchell <mark@codesourcery.com>
1573
1574 PR c++/7647
1575 * decl.c (grokdeclarator): Tidy, slightly.
1576 * search.c (lookup_field_1): Add want_type parameter.
1577 (lookup_field_r): Adjust call to lookup_field_1.
1578
7c71dc2b
GDR
15792003-03-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
1580
1581 * Make-lang.in (cp/name-lookup.o): Add more dependencies.
1582
ed3cf953
GDR
15832003-03-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
1584
1585 * cp-tree.h (binding_for_name: Move to name-lookup.h Adjust
d2a6f3c0 1586 prototype.
ed3cf953
GDR
1587 (cxx_scope_find_binding_for_name): Likewise.
1588 * decl.c (find_binding: Move to name-lookup.c.
1589 (binding_for_name): Likewise.
1590 (cxx_scope_find_binding_for_name): Likewise.
1591 (BINDING_LEVEL): Remove.
1592 (push_binding): Tidy.
1593 (push_class_binding): Likewise.
1594 (pop_binding): Likewise.
1595 (poplevel): Likewise.
1596 (poplevel_class): Likewise.
1597 (set_identifier_type_value_with_scope): Likewise.
1598 (push_overloaded_decl): Likewise.
1599 (lookup_tag): Likewise.
1600 (unqualified_namespace_lookup): Likewise.
1601 (lookup_name_current_level): Likewise.
1602 (maybe_inject_for_scope_var): Likewise.
1603 (namespace_binding): Move to name-lookup.c.
1604 (set_namespace_binding): Likewise.
1605 * decl2.c (lookup_using_namespace): Tidy.
1606 (qualified_lookup_using_namespace): Likewise.
1607 (do_toplevel_using_decl): Likewise.
1608 * name-lookup.c: Include "timevar.h"
1609 * name-lookup.h (cxx_scope): Declare.
1610 (struct cxx_binding): Lose member "has_level". Adjust "scope"
1611 member declaration.
1612 (BINDING_SCOPE): Adjust definition.
1613 (BINDING_HAS_LEVEL_P): Remove.
1614
aed81407
GDR
16152003-03-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
1616
1617 * name-lookup.c: New file.
1618 * name-lookup.h: Likewise..
1619 * decl.c (push_binding): Adjust use cxx_binding_make.
1620 (free_bindings): Move to name-lookup.c
1621 (pop_binding): Use cxx_binding_free.
1622 (binding_for_name): Tidy.
1623 * cp-tree.h: Include "name-lookup.h"
1624 (cxx_binding_make): Move to name-lookup.h
1625 (cxx_binding_clear): Likewise.
1626 (struct cxx_binding): Likewise.
1627 (LOCAL_BINDING_P): Likewise.
1628 (INHERITED_VALUE_BINDING_P): Likewise.
1629 (BINDING_SCOPE): Likewise.
1630 (BINDING_HAS_LEVEL_P): Likewise.
1631 (BINDING_VALUE): Likewise.
1632 (BINDING_TYPE): Likewise.
1633 * config-lang.in (gtfiles): Add cp/name-lookup.h
1634 * Make-lang.in (cp/name-lookup.o): New rule.
1635 (CXX_OBJS): Add cp/name-lookup.o
1636 (CXX_TREE_H): Add cp/name-lookup.h
1637
f7b9026e
JM
16382003-03-28 Jason Merrill <jason@redhat.com>
1639
1640 PR c++/10245
1641 * cvt.c (force_rvalue): New fn.
1642 * call.c (build_conditional_expr): Use it.
1643 * cp-tree.h: Declare it.
1644
2d30fe53
MS
16452003-03-28 Mike Stump <mrs@apple.com>
1646
1647 * error.c (dump_expr): Add 0x to printed hex numbers to make
1648 output match source code better.
1649
400fbc08
MM
16502003-03-28 Mark Mitchell <mark@codesourcery.com>
1651
316a2456
MM
1652 PR c++/10218
1653 * decl.c (grokfndecl): Return NULL_TREE for bogus out-of-class
1654 definitions.
1655
400fbc08
MM
1656 * decl2.c (generate_ctor_or_dtor_function): Tolerate a
1657 non-existant ssdf_decls array.
1658 (finish_file): Call generator_ctor_or_dtor_function when there are
1659 static constructors or destructors and no other static
1660 initializations.
1661
433cd9c9
NS
16622003-03-28 Nathan Sidwell <nathan@codesourcery.com>
1663
1664 PR c++/10047
1665 * decl2.c (finish_file): Don't warn about explicitly instantiated
1666 inline decls.
1667
544aef8c
NS
16682003-03-27 Nathan Sidwell <nathan@codesourcery.com>
1669
1670 PR c++/10224
1671 * pt.c (lookup_template_class): Only check instantiated args if
1672 they do not contain template parameters.
1673
649fc72d
NS
16742003-03-27 Nathan Sidwell <nathan@codesourcery.com>
1675
1676 PR c++/10158
1677 * parser.c (cp_parser_function_definition): Set
1678 DECL_INITIALIZED_IN_CLASS for members.
1679 * pt.c (instantiate_decl): Only reduce the template args for
1680 friends that are not defined in class.
1681
d8c8524d
JM
16822003-03-25 Jason Merrill <jason@redhat.com>
1683
1684 * call.c (print_z_candidate): Change name of first arg to msgid.
1685 (joust): Add comment for translators.
1686
1c82cc90 16872003-03-24 Nathan Sidwell <nathan@codesourcery.com>
d2a6f3c0 1688
1c82cc90 1689 PR c++/9898, PR c++/383, DR 322
649fc72d 1690 * pt.c (maybe_adjust_types_for_deduction) <DEDUCE_CONV>: Look
1c82cc90
NS
1691 through reference types on both PARM and ARG.
1692
a5fcc895
NS
16932003-03-24 Nathan Sidwell <nathan@codesourcery.com>
1694
1695 PR c++/10119
649fc72d 1696 * error.c (dump_expr) <BASELINK>: Use dump_expr.
a5fcc895 1697 * pt.c (maybe_fold_nontype_args): New function.
649fc72d
NS
1698 (tsubst_copy) <SCOPE_REF>: Subst any template_id args.
1699 <TEMPLATE_ID_EXPR>: Break out folding code, call it.
1700 (tsubst_copy_and_build) <TEMPLATE_ID_EXPR>: Call
a5fcc895
NS
1701 maybe_fold_nontype_args.
1702
2ef6c975
NS
17032003-03-24 Nathan Sidwell <nathan@codesourcery.com>
1704
1705 PR c++/10026
649fc72d 1706 * decl2.c (arg_assoc_type) <ERROR_MARK>: Don't die.
2ef6c975 1707
f29a2bd1
MM
17082003-03-23 Mark Mitchell <mark@codesourcery.com>
1709
1710 PR c++/7086
2ef6c975
NS
1711 * typeck.c (cxx_mark_addressable): Adjust call to
1712 gen_mem_addressof or put_var_into_stack.
f29a2bd1 1713
3e4a3562
NS
17142003-03-22 Nathan Sidwell <nathan@codesourcery.com>
1715
1716 PR c++/9978, c++/9708
1717 * cp-tree.h (instantiate_template): Add tsubst_flags parameter.
1718 * call.c (add_template_candidate_real): Adjust
1719 instantiate_template call.
1720 * class.c (resolve_address_of_overloaded_function): Likewise.
1721 * decl.c (build_enumerator): Set TREE_CONSTANT.
1722 * pt.c (check_instantiated_args): New.
1723 (push_inline_template_parms_recursive): Set TREE_CONSTANT,
1724 TREE_READONLY.
1725 (build_template_parm_index): Copy TREE_CONSTANT, TREE_READONLY.
1726 (reduce_template_parm_level): Likewise.
1727 (process_template_parm): Likewise.
1728 (check_explicit_specialization): Adjust instantiate_template call.
1729 (convert_template_argument): Don't check non-type argument here.
1730 (lookup_template_class): Check them here.
1731 (tsubst_friend_function): Adjust instantiate_template call.
1732 (instantiate_template): Add tsubst_flags parameter, use it. Check
1733 instantiated args.
1734
d9b2742a
ZW
17352003-03-21 Zack Weinberg <zack@codesourcery.com>
1736
1737 * decl.c: Update calls to shadow_warning.
1738
f3146d75
NS
17392003-03-21 Nathan Sidwell <nathan@codesourcery.com>
1740
1741 PR c++/9898
1742 * error.c (dump_decl) [CONST_DECL]: Print '<enumerator>'.
1743 (dump_expr) [CONSTRUCTOR]: Print default ctor as a function call.
1744
963142fc
MM
17452003-03-20 Mark Mitchell <mark@codesourcery.com>
1746
1747 * cp/decl2.c (arg_assoc_class): Correct check for namespace-scope
1748 friends.
1749 * cp/pt.c (instantiate_class_template): Fix formatting.
1750
a260bce6
MA
17512003-03-14 Matt Austern <austern@apple.com>
1752
1753 * cp-tree.h (unemitted_tinfo_decls): Declaration of a new varray.
1754 (unemitted_tinfo_decl_p): Remove.
1755 (emit_tinfo_decl): Change declaration to remove unused parameter.
1756 * decl2.c (finish_file): Change tinfo emission to loop through
1757 unemitted_tinfo_decls array instead of looping through all decls.
1758 * rtti.c (unemitted_tinfo_decl_p): Declare as static, remove
1759 unused second parameter.
1760 (init_rtti_processing): initialize unemitted_tinfo_decls varray.
1761 (get_tinfo_decls): push new tinfo decl on unemitted_tinfo_decls.
1762 (emit_tinfo_decl): remove unused second parameter, add assertion
d9b2742a
ZW
1763 that decl hasn't already been emitted.
1764
2bd3ecad
NN
17652003-03-19 Nathanael Nerode <neroden@gcc.gnu.org>
1766
1767 * dump.c (cp_dump_tree), cp-tree.h (cp_dump_tree): Change return
1768 type from 'int' to 'bool'. Replace 0 and 1 with true and false in
1769 return statements.
1770
b9747e59
JM
17712003-03-19 Jason Merrill <jason@redhat.com>
1772
1773 PR c++/8316, c++/9315, c++/10136
1774 * call.c (print_z_candidate): Split out from...
1775 (print_z_candidiates): ...here.
1776 (joust): Use it.
1777
10326855
RS
17782003-03-17 Roger Sayle <roger@eyesopen.com>
1779
b9747e59 1780 PR c++/10031
10326855
RS
1781 * decl.c (duplicate_decls): Use the new type when prototyping
1782 anticipated decls, even when the types match. This defines the
1783 exception list for the built-in function.
1784
bdaa131b
JM
17852003-03-17 Jason Merrill <jason@redhat.com>
1786
1787 PR c++/10091
d9b2742a 1788 * typeck.c (build_class_member_access_expr): Compare
bdaa131b
JM
1789 TYPE_MAIN_VARIANTs.
1790
ec20aa6c
MM
17912003-03-17 Mark Mitchell <mark@codesourcery.com>
1792
1793 PR c++/9639
1794 * parser.c (cp_parser_declarator_id): Clear parser->scope.
1795
35e939ae
JM
17962003-03-16 Jason Merrill <jason@redhat.com>
1797
1798 PR c++/9993
1799 * decl.c (finish_function): Only allow the NRVO to use variables
1800 declared at function scope.
1801
40a4184c
AJ
18022003-03-17 Andreas Jaeger <aj@suse.de>
1803
1804 * Make-lang.in (cp/TAGS): Remove.
1805
1f5a253a
NS
18062003-03-16 Nathan Sidwell <nathan@codesourcery.com>
1807
1808 PR c++/9629
1809 * cp-tree.h (struct language_function): Add in_base_initializer.
1810 (in_base_initializer): define it.
1811 (expand_member_init): Remove INIT param.
1812 * init.c (expand_member_init): Remove INIT param, return the member.
1813 (emit_mem_initializers): Set in_base_initializer.
1814 * class.c (build_base_path): Check in_base_initializer.
1815 * parser.c (cp_parser_mem_initializer): Set in_base_initializer.
1816 * pt.c (tsubst_initializer_list): Likewise.
1817
4f907b59
GDR
18182003-03-16 Gabriel Dos Reis <gdr@integrable-solutions.net>
1819
1820 * decl.c (binding_for_name): Fix initialization thinko.
1821
ac2768ff 18222003-03-15 Gabriel Dos Reis <gdr@integrable-solutions.net>
40a4184c 1823
af6fd53f
GDR
1824 Compile-time improvement: 2/n.
1825 * cp-tree.h (struct cxx_binding): New datatype;
1826 (struct lang_identifier): Use it.
1827 (LOCAL_BINDING_P): Adjust definition.
1828 (INHERITED_VALUE_BINDING_P): Likewise.
1829 (BINDING_SCOPE): Likewise.
1830 (BINDING_HAS_LEVEL_P): Likewise.
1831 (BINDING_VALUE): Likewise.
1832 (BINDING_TYPE): Likewise.
1833 (IDENTIFIER_VALUE): Likewise.
1834 (struct tree_binding): Remove.
1835 (TS_CP_BINDING): Likewise.
1836 ((union lang_tree_node): Remove field "binding".
1837 (cxx_binding_clear): New macro.
1838 (binding_for_name): Adjust return type.
1839 (qualified_lookup_using_namespace): Adjust prototype.
1840 (lookup_using_namespace): Adjust prototype.
1841 (cxx_scope_find_binding_for_name): Declare.
1842 * cp-tree.def: Remove CPLUS_BINDING definition.
1843 * decl.c (push_binding): Adjust local variable type.
1844 (add_binding): Likewise.
1845 (push_class_binding): Likewise.
1846 (pop_binding): Likewise.
1847 (poplevel): Likewise.
1848 (poplevel_class): Likewise.
1849 (free_bindings): Adjust type.
1850 (find_binding): Adjust return type, add a third parameter. Remove
40a4184c 1851 non-useful assertion now that we use static typing.
af6fd53f 1852 (cxx_scope_find_binding_for_name): New function.
40a4184c 1853 (binding_for_name): Use it. Adjust local variable type. Simplify.
af6fd53f
GDR
1854 (namespace_binding): Simplify.
1855 (set_namespace_binding): Likewise.
1856 (set_identifier_type_value_with_scope): Adjust local variable type.
1857 (lookup_tag): Don't type-abuse of local variable 'old'.
1858 (lookup_namespace_name): Likewise. Allocate binding on stack.
1859 (select_decl): Adjust prototype.
1860 (unqualified_namespace_lookup): Allocate binding on stack.
1861 Don't type-abuse of local variable 'val'.
1862 (lookup_name_real): Likewise.
1863 (maybe_inject_for_scope_var): Adjust local variable type.
1864 (cp_tree_node_structure): Remove CPLUS_BINDING case label.
1865 (namespace_binding): Adjust logic, simplify.
1866 (BINDING_LEVEL): Adjust definition.
1867 (push_class_level_binding): Adjust local variable type.
1868 (struct cxx_saved_binding): Adjust field 'binding' type.
1869 * decl2.c (ambiguous_decl): Adjust prototype.
1870 (lookup_using_namespace): Adjust local variable type.
1871 (qualified_lookup_using_namespace): Catch type error and correct
1872 ensueing logic error.
1873 (do_nonmember_using_decl): Adjust local variable type. Allocate
1874 temporary cxx_binding on stack.
1875 (do_toplevel_using_decl): Adjust local variable type.
1876 * ptree.c (cxx_print_cxx_binding): New function.
1877 (cxx_print_identifier): Use it.
1878 (cxx_print_xnode): Delete CPLUS_BINDING case label.
1879
6a87d634
RS
18802003-03-15 Roger Sayle <roger@eyesopen.com>
1881
1882 * tree.c (count_functions): Fix whitespace.
1883
c1bad961
NB
18842003-03-15 Neil Booth <neil@daikokuya.co.uk>
1885
1886 * Make-lang.in: Update.
1887
6e049fcd
KL
18882003-03-15 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
1889
1890 PR c++/6440
1891 * pt.c (maybe_process_partial_specialization): Handle
1892 member class template when enclosing class template is
1893 explicit specialized.
1894 (most_general_template): Stop looking when DECL is already
1895 specialized.
1896
0171b21c
JM
18972003-03-13 Jason Merrill <jason@redhat.com>
1898
1899 PR c++/9420
1900 * search.c (lookup_conversions): Call complete_type here.
1901 * call.c (implicit_conversion): Not here.
1902
26f86471
MM
19032003-03-13 Mark Mitchell <mark@codesourcery.com>
1904
45707d31
MM
1905 * decl2.c (do_nonmember_using_decl): Correct handling of
1906 simultaneous type/non-type bindings.
1907
26f86471
MM
1908 * call.c (initialize_reference): Remove bogus assertion.
1909 * decl.c (build_ptrmemfunc_type): Revert change of 2003-03-09.
1910
847311f4
AL
19112003-03-12 Andrew Lewycky <andrew@mxc.ca>
1912
1913 PR c++/7050
1914 * expr.c (cxx_expand_expr): Return const0_rtx for throw
1915 expressions.
1916
2601a4ee
MM
19172003-03-11 Mark Mitchell <mark@codesourcery.com>
1918
e1145e7f 1919 PR c++/9474
2601a4ee
MM
1920 * decl2.c (do_nonmember_using_decl): Do not call duplicate decls
1921 to merge old and new declarations.
1922
2bfe542b
AO
19232003-03-12 Alexandre Oliva <aoliva@redhat.com>
1924
1925 * g++.1: Remove.
1926 * Make-lang.in (c++.generated-manpages): Build cp/g++.1.
1927 (cp/g++.1): Build it from scratch in the build tree.
1928 (c++.install-man): Depend on it. Install it from the build tree.
1929 (c++.mostlyclean): Clean it.
1930
0c33daff
MM
19312003-03-11 Mark Mitchell <mark@codesourcery.com>
1932
3033f0ed 1933 PR c++/9474
2601a4ee
MM
1934 * decl2.c (do_nonmember_using_decl): Do not call duplicate decls
1935 to merge old and new declarations.
1936
0c33daff
MM
1937 PR c++/9924
1938 * decl2.c (do_nonmember_using_decl): Ignore anticipated builtins.
1939
cf237c19
JM
19402003-03-11 Jason Merrill <jason@redhat.com>
1941
1942 PR c++/9820
40a4184c 1943 * search.c (lookup_member): Fix handling of functions in a class
cf237c19
JM
1944 being defined.
1945
436f8a4c
MM
19462003-03-11 Mark Mitchell <mark@codesourcery.com>
1947
1948 PR c++/8700
1949 * call.c (convert_class_to_reference): Adjust usage of
1950 splice_viable.
1951 (any_viable): Remove.
1952 (splice_viable): Combine with any_viable.
1953 (print_z_candidates): Avoid printing duplicates.
1954 (build_user_type_conversion_1): Adjust usage of splice_viable.
1955 (build_new_function_call): Likewise.
1956 (build_operator_new_call): Likewise.
1957 (build_object_call): Likewise.
1958 (build_conditional_expr): Likewise.
1959 (build_new_op): Likewise.
1960 (build_new_method_call): Likewise.
1961 (joust): Remove spurious comment.
1962 * cp-tree.h (DECL_FRIENDLIST): Correct documentation.
1963 * decl2.c (arg_assoc_class): Simplify.
1964 * friend.c (add_friend): Likewise.
1965
5b8e011c
JM
19662003-03-11 Jason Merrill <jason@redhat.com>
1967
1968 PR c++/8660
40a4184c 1969 * decl2.c (check_classfn): A member template only matches a
5b8e011c
JM
1970 member template.
1971
cb60f38d
NB
19722003-03-11 Neil Booth <neil@daikokuya.co.uk>
1973
1974 * Make-lang.in (CXX_C_OBJS): Update.
1975 * lang-specs.h: Don't define __GNUG__ here.
1976
125e6594
MM
19772003-03-10 Mark Mitchell <mark@codesourcery.com>
1978
1979 * call.c (perform_overload_resolution): New function.
1980 (build_new_function_call): Use it.
1981 (build_operator_new_call): Likewise.
1982 (add_candidates): Add explicit_targs and template_only parameters.
1983 (build_new_op): Adjust accordingly.
1984 * cp-tree.h (build_operator_new_call): New function.
1985 (build_function_call_real): Remove.
1986 (build_function_call_maybe): Likewise.
1987 * init.c (build_new_1): Use build_operator_new_call.
1988 * typeck.c (build_function_call_real): Rename to ...
1989 (build_function_call): ... this.
1990
87d7d780 19912003-03-10 Devang Patel <dpatel@apple.com>
40a4184c 1992
87d7d780
DP
1993 PR c++/9394
1994 * g++spec.c (lang_specific_driver): Use DEFAULT_WORD_SWTCH_TAKES_ARG.
125e6594 1995
6e9554e1
JM
19962003-03-10 Jason Merrill <jason@redhat.com>
1997
70f0e288
JM
1998 PR c++/9798
1999 * decl.c (push_using_directive): Push before recursing.
2000
2001 PR c++/9868, c++/9524
6e9554e1
JM
2002 * call.c (resolve_scoped_fn_name): Handle the case of a function
2003 pointer member.
2004
2005 * decl2.c (build_offset_ref_call_from_tree): Only mess with 'this'
2006 argument in the pointer-to-member case.
2007
f6d19bfe
MM
20082003-03-09 Mark Mitchell <mark@codesourcery.com>
2009
1d719415
MM
2010 PR c++/9373
2011 * cp-lang.c (cxx_get_alias_set): Use alias set zero for
2012 pointers to member functions.
2013
f6d19bfe
MM
2014 PR c++/8534
2015 * decl.c (build_ptrmemfunc_type): Do not allow default arugments
2016 in pointer-to-member-function types.
2017
d9b4e85e
GDR
20182003-03-10 Gabriel Dos Reis <gdr@integrable-solutions.net>
2019
2020 * expr.c (cplus_expand_constant): Use C90 prototype style.
2021 (cxx_expand_expr): Likewise.
2022
ca9e1382
KL
20232003-03-09 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2024
2025 PR c++/9970
2026 * decl.c (duplicate_decls): Only copy DECL_THUNKS for virtual
2027 functions.
2028
00a221f0
GK
20292003-03-08 Geoffrey Keating <geoffk@apple.com>
2030
2031 * lang-specs.h (c++-header): Change .pch to .gch.
2032
4bfec483
NB
20332003-03-08 Neil Booth <neil@daikokuya.co.uk>
2034
2035 * cp-tree.h (cxx_init): Update prototype.
2036 * lex.c (cxx_init): Similarly.
2037
089d6ea7
MM
20382003-03-08 Mark Mitchell <mark@codesourcery.com>
2039
0e136342
MM
2040 PR c++/9823
2041 * cp-tree.h (begin_mem_initializers): Remove.
2042 * parser.c (cp_parser_mem_initializer_list): Inline it here.
2043 Do not call finish_mem_initializers if not in a constructor.
2044 (cp_parser_class_head): Fix typo in error message.
2045 * semantics.c (begin_mem_initializers): Remove.
2046 * testsuite/g++.dg/parser/constructor1.C: New test.
2047
089d6ea7
MM
2048 PR c++/9809
2049 * call.c (add_function_candidate): Skip builtin fuctions that have
2050 not yet been declared.
2051
2052 PR c++/9982
2053 * init.c (build_new_1): Correct logic for determining whether or
2054 not to use an array cookie.
2055
2056 PR c++/9524
2057 * parser.c (cp_parser_postfix_expression): Call
2058 finish_non_static_data_member, even when processing_template_decl.
2059
2060 PR c++/9912
2061 * cp-tree.h (is_ancestor): New function.
2062 (handle_class_head): Change prototype.
2063 * decl2.c (is_namespace_ancestor): Rename to ...
2064 (namespace_anecestor): ... this.
2065 (set_decl_namespace): Adjust accordingly.
2066 (handle_class_head): Remove unncessary parameters.
2067 * parser.c (cp_parser_class_head): Check that
2068 nested-name-specifiers are used appropriately.
40a4184c 2069
aa6e8ed3
MM
20702003-03-07 Mark Mitchell <mark@codesourcery.com>
2071
2072 * call.c (reference_binding): Remove REF_IS_VAR parameter.
2073 (implicit_conversion): Adjust call to reference_binding.
2074 (make_temporary_var_for_ref_to_type): Add TYPE parameter.
2075 (initialize_reference): Adjust handling for references bound to
2076 rvalues.
2077 * cp-tree.h (make_temporary_var_for_ref_to_temp): Change
2078 prototype.
2079 (real_non_cast_lvalue_p): New method.
2080 * cvt.c (build_up_reference): Adjust use of
2081 make_temporary_var_for_ref_to_temp.
89d11511 2082 * tree.c (real_non_cast_lvalue_p): New method.
40a4184c 2083
5cc3d3b8
GDR
20842003-03-07 Gabriel Dos Reis <gdr@integrable-solutions.net>
2085
2086 * except.c (init_exception_processing): Use C90 prototype style.
2087 (cp_protect_cleanup_actions): Likewise.
2088 (prepare_eh_type): Likewise.
2089 (build_eh_type_type): Likewise.
2090 (build_exc_ptr): Likewise.
2091 (do_begin_catch): Likewise.
2092 (dtor_nothrow): Likewise.
2093 (do_end_catch): Likewise.
2094 (push_eh_cleanup): Likewise.
2095 (decl_is_java_type): Likewise.
2096 (choose_personality_routine): Likewise.
2097 (initialize_handler_parm): Likewise.
2098 (expand_start_catch_block): Likewise.
2099 (expand_end_catch_block): Likewise.
2100 (begin_eh_spec_block): Likewise.
2101 (finish_eh_spec_block): Likewise.
2102 (do_allocate_exception): Likewise.
2103 (do_free_exception): Likewise.
2104 (wrap_cleanups_r): Likewise.
2105 (stabilize_throw_expr): Likewise.
2106 (build_throw): Likewise.
2107 (complete_ptr_ref_or_void_ptr_p): Likewise.
2108 (is_admissible_throw_operand): Likewise.
2109 (nothrow_libfn_p): Likewise.
2110 (can_convert_eh): Likewise.
2111 (check_handlers_1): Likewise.
2112 (check_handlers): Likewise.
40a4184c 2113
3d938426
MM
21142003-03-06 Mark Mitchell <mark@codesourcery.com>
2115
2116 * call.c (merge_conversion_sequences): New function.
2117 (build_conv): Set ICS_USER_FLAG for USER_CONVs.
2118 (convert_class_to_reference): Correct handling of second
2119 standard conversion sequence in a user-defined conversion
2120 sequence.
2121 (build_user_type_conversion_1): Use merge_conversion_sequences.
2122 * cp-tree.def: Add comments for CONV nodes.
9534f4bc 2123 * rtti.c (get_tinfo_decl): Use build_address/build_nop.
40a4184c 2124
3f8548e7
GDR
21252003-03-07 Gabriel Dos Reis <gdr@integrable-solutions.net>
2126
2127 * error.c (init_error): Use C90 prototype style.
2128 (dump_scope): Likewise.
2129 (dump_qualifiers): Likewise.
2130 (dump_template_argument): Likewise.
2131 (dump_template_argument_list): Likewise.
2132 (dump_template_parameter): Likewise.
2133 (dump_template_bindings): Likewise.
2134 (dump_type): Likewise.
2135 (dump_typename): Likewise.
2136 (class_key_or_enum): Likewise.
2137 (dump_aggr_type): Likewise.
2138 (dump_type_prefix): Likewise.
2139 (dump_type_suffix): Likewise.
2140 (dump_global_iord): Likewise.
2141 (dump_simple_decl): Likewise.
2142 (dump_decl): Likewise.
2143 (dump_template_decl): Likewise.
2144 (dump_function_decl): Likewise.
2145 (dump_parameters): Likewise.
2146 (dump_exception_spec): Likewise.
2147 (dump_function_name): Likewise.
2148 (dump_template_parms): Likewise.
2149 (dump_char): Likewise.
2150 (dump_expr_list): Likewise.
2151 (dump_expr): Likewise.
2152 (dump_binary_op): Likewise.
2153 (dump_unary_op): Likewise.
2154 (type_as_string): Likewise.
2155 (expr_as_string): Likewise.
2156 (decl_as_string): Likewise.
2157 (context_as_string): Likewise.
2158 (lang_decl_name): Likewise.
2159 (cp_file_of): Likewise.
2160 (cp_line_of): Likewise.
2161 (decl_to_string): Likewise.
2162 (expr_to_string): Likewise.
2163 (fndecl_to_string): Likewise.
2164 (code_to_string): Likewise.
2165 (language_to_string): Likewise.
2166 (parm_to_string): Likewise.
2167 (op_to_string): Likewise.
2168 (type_to_string): Likewise.
2169 (assop_to_string): Likewise.
2170 (args_to_string): Likewise.
2171 (cv_to_string): Likewise.
2172 (cxx_print_error_function): Likewise.
2173 (cp_diagnostic_starter): Likewise.
2174 (cp_diagnostic_finalizer): Likewise.
2175 (cp_print_error_function): Likewise.
2176 (function_category): Likewise.
2177 (print_instantiation_full_context): Likewise.
2178 (print_instantiation_partial_context): Likewise.
2179 (maybe_print_instantiation_context): Likewise.
2180 (print_instantiation_context): Likewise.
2181 (cp_printer): Likewise.
2182 (print_integer): Likewise.
2183 (print_non_consecutive_character): Likewise.
2184 (locate_error): Likewise.
2185
3d1df1fa
MM
21862003-03-06 Mark Mitchell <mark@codesourcery.com>
2187
5e256996
MM
2188 PR c++/9965
2189 * call.c (reference_binding): Add ref_is_var parameter.
2190 (implicit_conversion): Adjust call to reference_binding.
2191 (initialize_reference): Likewise.
2192
07681121
MM
2193 PR c++/9400
2194 * decl.c (pushdecl): Don't check for shadowing of DECL_ARTIFICIAL
2195 PARM_DECLs.
2196
3d1df1fa
MM
2197 PR c++/9791
2198 * class.c (get_basefndecls): Use lookup_fnfields_1.
2199
8a6393df
KL
22002003-03-06 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2201
2202 PR c++/9188
2203 * parser.c (cp_parser_type_parameter): Remove redundant `expect'
2204 in error message.
2205 (cp_parser_single_declaration): Likewise.
2206
c965b169
JM
22072003-03-05 Jason Merrill <jason@redhat.com>
2208
2209 PR c++/9440
2210 * call.c (build_conditional_expr): Use convert rather than an
2211 explicit NOP_EXPR.
2212
1d555f7a
MA
22132003-03-02 Matt Austern <austern@apple.com>
2214
2215 * decl.c (cp_binding_level): Add static_decls varray member.
2216 (add_decl_to_level): Add static/inline namespace scope
2217 declarations to static_decls array.
2218 (wrapup_global_for_namespace): Pass static_decls only, instead of
2219 all decls, to wrapup_global_declarations/check_global_declarations.
2220 (push_namespace): Initialize static_decls for ordinary namespaces.
2221 (cxx_init_decl_processing): Initialize static_decls for global
2222 namespace.
40a4184c 2223
8234c6c1
MM
22242003-03-05 Mark Mitchell <mark@codesourcery.com>
2225
2226 * class.c (end_of_class): Correct thinko.
2227
dc2b3526
NN
22282003-03-04 Nathanael Nerode <neroden@gcc.gnu.org>
2229
2230 * config-lang.in: Replace ${libstdcxx_version} by its value.
2231
000d38ea
GDR
22322003-03-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
2233
d9b2742a
ZW
2234 * cp-tree.h (cxx_saved_binding): Declare.
2235 (struct saved_scope): Adjust type of field 'old_binding'.
2236 * decl.c (cxx_saved_binding_make): New macro.
2237 (struct cxx_saved_binding): Define.
2238 (store_bindings): Adjust prototype. Use cxx_saved_binding to save
2239 C++ bindings.
2240 (maybe_push_to_top_level): Adjust local variable type.
2241 (pop_from_top_level): Likewise.
40a4184c 2242
b87141b3
TT
22432003-03-04 Tom Tromey <tromey@redhat.com>
2244
2245 * Make-lang.in (c++.tags): New target.
2246
f20d8e39
NB
22472003-03-04 Neil Booth <neil@daikokuya.co.uk>
2248
2249 * Make-lang.in: Update.
2250
f5d70cc0
JM
22512003-03-03 Jason Merrill <jason@redhat.com>
2252
2253 * decl.c (finish_enum): Do set the type in a template. Simplify.
2254 * pt.c (tsubst_enum, tsubst_copy): Revert last patch.
2255
7993382e
MM
22562003-03-03 Mark Mitchell <mark@codesourcery.com>
2257
2258 PR c++/9878
2259 * call.c (convert_class_to_reference): Correct conversion
2260 sequences.
2261 (reference_binding): Add ref_bound_directly_to_rvalue_p parameter.
2262 (implicit_conversion): Adjust call to reference_binding.
2263 (add_candidate): Change type of candidates parameter.
2264 (add_function_candidate): Likewise.
2265 (add_conv_candidate): Likewise.
2266 (build_builtin_candidate): Likewise.
2267 (add_builtin_candidate): Likewise.
2268 (add_builtin_candidates): Likewise.
2269 (add_template_candidate_real): Likewise.
2270 (add_template_candidate): Likewise.
2271 (add_template_conv_candidate): Likewise.
2272 (build_user_type_conversion_1): Adjust accordingly.
2273 (build_object_call): Likewise.
2274 (build_conditional_expr): Likewise.
2275 (add_candidates): Likewise.
2276 (build_new_op): Likewise.
2277 (convert_like_real): Use USER_CONV_CAND. Use build_nop.
2278 (build_new_method_call): Adjust calls to add_function_candidate.
2279 (make_temporary_var_for_ref_to_temp): New function.
2280 (initialize_reference): Add decl parameter.
2281 * class.c (build_rtti_vtbl_entries): Use build_address and
2282 build_nop.
2283 * cp-tree.h (initialize_reference): Change prototype.
2284 (make_temporary_var_for_ref_to_temp): New function.
2285 (build_type_conversion): Change prototype.
2286 (build_address): New function.
2287 (build_nop): Likewise.
2288 * cvt.c (cp_convert_to_pointer): Adjust call to
2289 build_type_conversion. Avoid indicating redundant NOP_EXPRs.
2290 Use build_nop.
2291 (convert_to_pointer_force): Use build_nop.
2292 (build_up_reference): Use make_temporary_var_for_ref_to_temp.
2293 (convert_to_reference): Adjust call to build_type_conversion.
2294 (ocp_convert): Likewise.
2295 (build_type_conversion): Remove for_sure parameter.
2296 * decl.c (grok_reference_init): Use initialize_reference.
2297 * typeck.c (build_address): New function.
2298 (build_nop): Likewise.
2299 (build_unary_op): Use them.
2300 (build_ptrmemfunc): Tidy slightly.
2301 (convert_for_initialization): Adjust call to
2302 initialize_reference.
2303 * typeck2.c (store_init_value): Remove #if 0'd code.
40a4184c 2304
d1a74aa7
JM
23052003-03-03 Jason Merrill <jason@redhat.com>
2306
2307 * decl.c (start_function): Clear DECL_NUM_STMTS.
2308
2309 * class.c (get_vtable_decl): Use vtbl_type_node.
2310 (build_primary_vtable): Check for it.
2311
6e1b3a7c
AH
23122003-03-02 Aldy Hernandez <aldyh@redhat.com>
2313
08162287 2314 * decl.c (check_initializer): Check for vector_opaque_p.
6e1b3a7c 2315
8a035a6b
AH
23162003-03-02 Ashif Harji <asharji@uwaterloo.ca>
2317
2318 * lang-specs.h (default_compilers): Add -no-integrated-cpp flag to
2319 invoke an external cpp during compilation.
2320
456d8864
GDR
23212003-03-01 Gabriel Dos Reis <gdr@integrable-solutions.net>
2322
2323 * decl.c (duplicate_decls): Convert use of warning_with_decl() to
2324 that of warning().
2325 (start_decl): Likewise.
2326 (start_function): Likewise.
2327
5793b276
NB
23282003-03-01 Neil Booth <neil@daikokuya.co.uk>
2329
2330 * Make-lang.in (CXX_C_OBJS): Update.
2331
b063b379 23322003-02-28 Mark Mitchell <mark@codesourcery.com>
1d62c33e
MM
2333
2334 PR c++/9892
2335 * pt.c (instantiate_decl): Clear DECL_RTL for a VAR_DECL when
2336 instantiating it.
2337
704a0bbd
AH
23382003-02-28 Aldy Hernandez <aldyh@redhat.com>
2339
d9b2742a
ZW
2340 * parser.c (cp_parser_init_declarator): Revert opaque
2341 vector_opaque_p change.
2342 Do not include target.h.
704a0bbd 2343
1cb8292f
MM
23442003-02-28 Mark Mitchell <mark@codesourcery.com>
2345
2346 PR c++/9879
2347 * cp-tree.h (build_zero_init): Add parameter.
2348 * decl.c (cp_finish_decl): Adjust call.
2349 * init.c (build_zero_init): Add nelts parameter. Adjust recursive
2350 calls.
2351 (build_default_init): Add nelts parameter. Adjust calls to
2352 build_zero_init.
2353 (build_new_1): Adjust call to build_default_init.
2354 * typeck2.c (process_init_constructor): Adjust call to build_zero_init.
40a4184c 2355
fdedded1
DP
23562003-02-26 Devang Patel <dpatel@apple.com>
2357
2ef6c975
NS
2358 * decl.c (finish_enum): Merge two 'for' loops. Copy value node if
2359 required. Postpone enum setting for template decls.
2360 (build_enumerator): Delay copying value node until finish_enum
2361 (). Remove #if 0'ed code.
fdedded1
DP
2362 * pt.c (tsubst_enum): Set TREE_TYPE and copy value node.
2363 (tsubst_copy): Add check for enum type.
40a4184c 2364
cec24319
MM
23652003-02-25 Mark Mitchell <mark@codesourcery.com>
2366
2367 PR c++/9683
2368 * decl2.c (prune_vars_needing_no_initialization): Do not throw
2369 away initializations for DECL_EXTERNAL VAR_DECLs.
2370 (finish_file): Adjust accordingly.
2371 * pt.c (instantiate_decl): Do not defer VAR_DECLs.
2372
7d9f2df2
GDR
23732003-02-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
2374
08162287
JM
2375 * decl.c (add_binding): Time TV_NAME_LOOKUP.
2376 (push_class_binding): Likewise.
2377 (set_namespace_binding): Likewise.
7d9f2df2 2378
353b4fc0
MM
23792003-02-24 Mark Mitchell <mark@codesourcery.com>
2380
2381 PR c++/9836
2382 * cp-tree.h (CLASSTYPE_PRIMARY_TEMPLATE): Do not skip from
2383 specializations back to the main template.
2384 * parser.c (cp_parser_diagnose_invalid_type_name):Adjust use.
2385 * pt.c (resolve_typename_type): Likewise.
2386
8b6a662e
JO
23872003-02-24 Jeffrey D. Oldham <oldham@codesourcery.com>
2388
2389 PR c++/9778
2390 * pt.c (tsubst_copy_and_build): For a templated function inside a
2391 scope, process template arguments.
2392
9e236a9d
KL
23932003-02-24 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2394
2395 PR c++/9602
2396 * typeck2.c (abstract_virtuals_error): Don't check when
2397 TYPE is still template parameter dependent.
2398
ca099ac8
MM
23992003-02-23 Mark Mitchell <mark@codesourcery.com>
2400
2401 PR c++/5333
2402 * cp-tree.h (CLASSTYPE_PRIMARY_TEMPLATE): New macro.
2403 * parser.c (cp_parser_diagnose_invalid_type_name): Use it.
2404 * pt.c (instantiate_class_template): Don't try to instantiate
2405 dependent types.
2406 (resolve_typename_type): Use CLASSTYPE_PRIMARY_TEMPLATE.
40a4184c 2407
2fff6d71
MM
24082003-02-21 Mark Mitchell <mark@codesourcery.com>
2409
2410 PR c++/9749
2411 * decl.c (grokdeclarator): Do not allow parameters with variably
2412 modified types.
2413
7fb1c86d
NS
24142003-02-21 Nathan Sidwell <nathan@codesourcery.com>
2415
1f5a253a 2416 * search.c (grow_bfs_bases): Remove. Fold into ...
7fb1c86d
NS
2417 (bfs_walk): ... here, fix fencepost error. Fix merge lossage
2418 in previous patch.
2419
63a3cd3e
MM
24202003-02-20 Mark Mitchell <mark@codesourcery.com>
2421
2422 PR c++/9729
2423 * mangle.c (mangle_conv_op_name_for_type): Issue an error message
2424 when the G++ 3.2 ABI prevents correct compilation.
2425
dbbf88d1
NS
24262003-02-20 Nathan Sidwell <nathan@codesourcery.com>
2427
2428 Change base class access representation. Share virtual base
2429 binfos.
2430 * cp/call.c (build_special_member_call): Remove binfo_for_vbase
2431 call.
2432 * cp/class.c (build_base_path): Likewise.
2433 (build_primary_vtable): Adjust BINFO_NEW_VTABLE_MARKED use.
2434 (build_secondary_vtable): Remove FOR_TYPE arg. Adjust.
2435 (make_new_vtable): Adjust.
2436 (force_canonical_binfo_r): Delete.
2437 (force_canonical_binfo): Delete.
2438 (mark_primary_virtual_base): Delete.
2439 (dfs_unshared_virtual_bases): Delete.
2440 (mark_primary_bases): Adjust.
2441 (maybe_warn_about_overly_private_class): Adjust.
2442 (dfs_base_derived_from): Delete.
2443 (base_derived_from): Follow the inheritance chain.
2444 (struct find_final_overrider_data): Add vpath member.
2445 (dfs_find_final_overrider): Adjust.
2446 (dfs_find_final_overrider_q, dfs_find_final_overrider_post): New.
2447 (find_final_overrider): Adjust.
2448 (update_vtable_entry_for_fn): Adjust.
2449 (modify_all_vtables): Adjust.
2450 (walk_subobject_offsets): Adjust.
2451 (layout_nonempty_base_or_field): Adjust.
2452 (layout_empty_base): Remove last parameter. Adjust.
2453 (build_base_field): Adjust.
2454 (build_base_fields): Adjust.
2455 (propagate_binfo_offsets): Remove last parameter. Adjust.
2456 (dfs_set_offset_for_unshared_vbases): Delete.
2457 (layout_virtual_bases): Adjust.
2458 (finish_struct_1): Adjust.
2459 (init_class_processing): Don't init access nodes.
2460 (dfs_get_primary_binfo): Delete.
2461 (get_primary_binfo): Adjust.
2462 (dump_class_hierarchy_r): Remove most derived arg, add IGO
2463 parameter. Adjust.
2464 (dump_class_hierarchy): Adjust.
2465 (finish_vtbls): Adjust.
2466 (get_original_base): Delete.
2467 (build_vtt_inits): Adjust.
2468 (dfs_build_secondary_vptr_vtt_inits): Adjust.
2469 (dfs_ctor_vtable_bases_queue_p): Adjust.
2470 (build_ctor_vtbl_group): Adjust.
2471 (dfs_accumulate_vtbl_inits): Adjust.
2472 (build_vtbl_initializer): Adjust.
2473 (build_vbase_offset_vtbl_entries): Adjust.
2474 (add_vcall_offset_vtbl_entries_1): Adjust.
2475 * cp/cp-tree.h (CPTI_ACCESS_*): Remove.
2476 (access_*_node): Remove.
2477 (CANONICAL_BINFO): Delete.
2478 (BINFO_UNSHARED_MARKED): Remove.
2479 (BINFO_MARKED): Set LANG_FLAG_0 directly.
2480 (SET_BINFO_MARKED, CLEAR_BINFO_MARKED): Delete.
2481 (BINFO_VTABLE_PATH_MARKED): Set LANG_FLAG_3 directly.
2482 (SET_BINFO_VTABLE_PATH_MARKED, CLEAR_BINFO_VTABLE_PATH_MARKED):
2483 Delete.
2484 (BINFO_NEW_VTABLE_MARKED): Set LANG_FLAG_4 directly.
2485 (SET_BINFO_NEW_VTABLE_MARKED): Adjust.
2486 (SET_BINFO_PUSHDECLS_MARKED, CLEAR_BINFO_PUSHDECLS_MARKED):
2487 Delete.
2488 (BINFO_DEPENDENT_BASE_P): New.
2489 (dfs_walk, dfs_walk_real): Queue function takes derived binfo and
2490 index.
2491 (markedp, unmarkedp): Adjust.
2492 (dfs_unmarked_real_bases_queue_p, dfs_marked_real_bases_queue_p,
2493 dfs_skip_vbases, marked_vtable_pathp, unmarked_vtable_pathp,
2494 find_vbase_instance, binfo_for_vbase): Delete.
2495 (copied_binfo, original_binfo): Declare.
2496 (finish_base_specifier): Add virtual_p arg.
2497 (unshare_base_binfos): Delete.
2498 (copy_base_binfos): Declare.
2499 (reverse_path): Delete.
2500 * cp/decl.c (xref_basetypes): Access and virtuality passed
2501 differently. Don't copy direct base binfos here. Call
2502 copy_base_binfos.
2503 * cp/init.c (dfs_initialize_vtbl_ptrs): Adjust.
2504 (initialize_vtbl_ptrs): Adjust.
2505 (expand_member_init): Adjust.
2506 * cp/parser.c (cp_parser_base_specifier): Adjust.
2507 * cp/pt.c (instantiate_class_template): Adjust.
2508 (get_template_base_recursive): Adjust.
2509 * cp/rtti.c (get_pseudo_ti_init): Adjust.
2510 (get_pseudo_ti_desc): Adjust.
2511 * cp/tree.c (unshare_base_binfos): Rename to ...
2512 (copy_base_binfos): ... here, reimplement.
2513 (make_binfo): Set BINFO_DEPENDENT_BASE_P.
2514 (reverse_path): Remove.
2515 * cp/typeck.c (get_delta_difference): Adjust error messages.
2516 * cp/semantics.c (finish_base_specifier): Add virtual arg, adjust.
2517 * cp/search.c (lookup_base_r): Adjust.
2518 (dynamic_cast_base_recurse): Adjust.
2519 (canonical_binfo): Remove.
2520 (dfs_canonical_queue): Remove.
2521 (dfs_assert_unmarked_p): Remove.
2522 (assert_canonical_unmarked): Remove.
2523 (shared_marked_p, shared_unmarked_p): Remove.
2524 (BINFO_ACCESS, SET_BINFO_ACCESS): Use TREE_PUBLIC & TREE_PRIVATE.
2525 (dfs_access_in_type): Adjust.
2526 (access_in_type): Adjust.
2527 (dfs_accessible_queue_p): Adjust.
2528 (dfs_accessible_p): Adjust.
2529 (is_subobject_of_p_1, is_subobject_of_p): Remove.
2530 (struct lookup_field_info): Remove from_dep_base_p field.
2531 (lookup_field_queue_p): Adjust, test BINFO_DEPENDENT_BASE_P.
2532 (lookup_field_r): Remove dependent base code.
2533 (lookup_member): Likewise.
2534 (dfs_walk, dfs_walk_real): Add access arg to queue fn.
2535 (dfs_unmarked_real_bases_queue_p): Remove.
2536 (dfs_marked_real_bases_queue_p): Remove.
2537 (dfs_skip_vbases): Remove.
2538 (dfs_get_pure_virtuals): Adjust.
2539 (markedp, unmarkedp): Adjust.
2540 (marked_vtable_pathp, unmarked_vtable_pathp): Remove.
2541 (marked_pushdecls_p, unmarked_pushdecls_p): Adjust.
2542 (dfs_unmark): Adjust.
2543 (dfs_get_vbase_types):Remove.
2544 (dfs_build_inheritance_graph_order): Remove.
2545 (get_vbase_types): Remove
2546 (dfs_find_vbase_instance): Remove.
2547 (find_vbase_instance): Remove.
2548 (dfs_debug_unmarkedp): Adjust.
2549 (dependent_base_p): Remove.
2550 (dfs_push_type_decls): Adjust.
2551 (dfs_push_decls): Adjust.
2552 (dfs_no_overlap_yet): Adjust.
2553 (copied_binfo): New function.
2554 (original_binfo): New function.
2555 (binfo_for_vbase): Remove.
2556
860c9ea6
ZW
25572003-02-18 Zack Weinberg <zack@codesourcery.com>
2558
2559 * cp/search.c (grow_bfs_bases): New subroutine of bfs_walk.
2560 (bfs_walk): Rewritten using circular queue of BINFO_BASETYPES
2561 vectors, for speed.
2562
6b99d1c0
MM
25632003-02-18 Mark Mitchell <mark@codesourcery.com>
2564
2565 PR c++/9704
2566 * class.c (layout_class_type): In the 3.2 ABI, take into account
2567 trailing bit fields when computing CLASSTYPE_SIZE_UNIT.
2568
2b59501b 25692003-02-18 Matt Austern <austern@apple.com>
40a4184c 2570
2b59501b
MA
2571 * cp/cp-lang.c: Change lang hooks so that final_write_globals does
2572 nothing for C++.
2573 * cp/decl.c (wrapup_globals_for_namespace): Remove special
2574 handling of global namespace.
40a4184c 2575
e17aafd1
GK
25762003-02-18 Geoffrey Keating <geoffk@apple.com>
2577
2578 * cp-tree.h (rid_to_yy): Delete.
2579 (C_RID_YYCODE): Delete.
2580 (finish_file): Delete redundant declaration.
2581
04b03085
JM
25822003-02-18 Jason Merrill <jason@redhat.com>
2583
2584 PR c++/9623
2585 * decl.c (reshape_init): Don't mess with initializer labels.
2586
08162287
JM
2587 PR c++/9485
2588 * parser.c (cp_parser_postfix_expression): Set idk properly for
2589 object->scope::member.
2590
bf7c02dd
BE
25912003-02-18 Ben Elliston <bje@redhat.com>
2592
2593 PR other/7350
2594 * decl.c (duplicate_decls): Fix typo in comment.
2595
0f3a8219
MEC
25962003-02-17 Michael Elizabeth Chastain <mec@shout.net>
2597
c7adfa01 2598 PR debug/9717
0f3a8219
MEC
2599 * class.c (build_base_field): Mark fields for base classes with
2600 DECL_IGNORED_P.
2601
db77ef4c
KL
26022003-02-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2603
2604 PR c++/9457
2605 * pt.c (tsubst_copy_and_build) [CONSTRUCTOR]: Substitute
2606 CONSTRUCTOR_ELTS only once.
2607
0df4ae96
KL
26082003-02-16 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2609
2610 PR c++/9459
2611 * error.c (dump_type_prefix): Handle TYPEOF_TYPE.
2612 (dump_type_suffix): Likewise.
2613
86ac0575
NS
26142003-02-14 Nathan Sidwell <nathan@codesourcery.com>
2615
2616 * search.c: ANSIfy function declarations and definitions.
2617 * cp-tree.h (lookup_field, lookup_member): Last parameter is a bool.
2618 * call.c (build_method_call, resolve_scoped_fn_name,
2619 build_java_interface_fn_ref): Adjust lookup_field, lookup_member
2620 calls.
2621 * class.c (handle_using_decl): Likewise.
2622 * decl.c (make_typename_type, make_unmound_class_template,
2623 start_decl, compute_array_index_type): Likewise.
2624 * decl2.c (build_expr_from_tree, build_call_from_tree): Likewise.
2625 * init.c (expand_member_init, build_member_call): Likewise.
2626 * pt.c (tsubst_copy, tsubst_copy_and_build, do_decl_instantiation,
2627 resolve_typename_type): Likewise.
2628 * typeck.c (lookup_destructor, finish_class_member_access_exprm
2629 build_prememfunc_access_expr): Likewise.
2630
fd295cb2
GDR
26312003-02-13 Gabriel Dos Reis <gdr@integrable-solutions.net>
2632
2633 * decl2.c: Include "timevar.h".
2634 (namespace_ancestor): Time name lookup.
2635 (add_using_namespace): Likewise.
2636 (lookup_using_namespace): Likewise.
2637 (qualified_lookup_using_namespace): Likewise.
2638 (decl_namespace): Likewise.
2639 (lookup_arg_dependent): Likewise.
2640 * lex.c (do_identifier): Likewise.
2641 (do_scoped_id): Likewise.
2642 * pt.c (lookup_template_class): Likewise.
2643
62ed060f
AP
26442003-02-14 Andrew Pinski <pinskia@physics.uc.edu>
2645
d9b2742a 2646 * decl.c: (define_label): Fix warning for return 0 instead of NULL.
40a4184c 2647
22ffcc6f
GDR
26482003-02-13 Gabriel Dos Reis <gdr@integrable-solutions.net>
2649
2650 * decl.c: Include "timevar.h".
2651 (poplevel): Time name lookup.
2652 (find_binding): Likewise.
2653 (push_namespace): Likewise.
2654 (pop_nested_namespace): Likewise.
2655 (store_bindings): Likewise.
2656 (maybe_push_to_top_level): Likewise.
2657 (pop_from_top_level): Likewise.
2658 (push_local_name): Likewise.
2659 (pushtag): Likewise.
2660 (pushdecl): Likewise.
2661 (pushdecl_with_scope): Likewise.
2662 (pushdecl_namespace_level): Likewise.
2663 (pushdecl_top_level): Likewise.
2664 (pushdecl_class_level): Likewise.
2665 (push_class_level_binding): Likewise.
2666 (push_using_decl): Likewise.
2667 (push_using_directive): Likewise.
2668 (push_overloaded_decl): Likewise.
2669 (lookup_label): Likewise.
2670 (define_label): Likewise.
2671 (lookup_tag): Likewise.
2672 (lookup_tag_reverse): Likewise.
2673 (lookup_namespace_name): Likewise.
2674 (select_decl): Likewise.
2675 (unqualified_namespace_lookup): Likewise.
2676 (lookup_name_real): Likewise.
2677 (lookup_name_current_level): Likewise.
2678 (lookup_type_current_level): Likewise.
2679 (maybe_inject_for_scope_var): Likewise.
2680 (xref_tag): Likewise.
2681
2682 * Make-lang.in (cp/decl.o): Add dependency on timevar.h
40a4184c 2683
6a540f3c
PE
26842003-02-12 Phil Edwards <pme@gcc.gnu.org>
2685
2686 * decl.c (build_enumerator): Remove unneeded test.
2687
7a93f739
DN
26882003-02-09 Dan Nicolaescu <dann@ics.uci.edu>
2689
2690 * cp-tree.h (struct lang_type_header): Make all fields unsigned
2691 char.
2692
b80f8ef3
MM
26932003-02-03 Mark Mitchell <mark@codesourcery.com>
2694
2695 PR c++/7129
2696 * call.c (z_candidate): Add args.
2697 (convert_class_to_reference): Set it.
2698 (implicit_conversion): Tidy.
2699 (add_candidate): Add args parameter.
2700 (add_function_candidate): Adjust call to add_candidate.
2701 (add_conv_candidate): Likewise.
2702 (build_builtin_candidate): Likewise.
2703 (build_user_type_conversion_1): Eliminate wasteful tree_cons
2704 usage.
2705 (build_new_function_call): Likewise.
2706 (build_object_call): Likewise.
2707 (add_candidates): New function.
2708 (build_new_op): Use it.
2709 (covert_like_real): Adjust call to build_over_call.
2710 (build_over_call): Remove args parameter.
2711 * operators.def: Add <?= and >?=.
2712
271bd540
RS
27132003-02-01 Richard Sandiford <rsandifo@redhat.com>
2714
2715 * typeck.c (build_indirect_ref): Don't check flag_volatile.
2716
db0f613d
KL
27172003-01-31 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2718
2719 PR c++/8849
2720 * pt.c (resolve_overloaded_unification): Handle FUNCTION_DECL.
2721
1824b90d
NS
27222003-01-31 Nathan Sidwell <nathan@codesourcery.com>
2723
2724 * cp-tree.h (BINFO_SUBVTT_INDEX, BINFO_VPTR_INDEX,
2725 BINFO_PRIMARY_BASE_OF): Use BINFO_ELTS.
2726 (BINFO_LANG_ELTS): New #define.
2727 * tree.c (make_binfo): Use BINFO_LANG_ELTS.
2728
f099d360
GK
27292003-01-30 Geoffrey Keating <geoffk@apple.com>
2730
2731 * cp/Make-lang.in: Remove -Wno-error from cp/decl.o.
2732
5552b43c
MM
27332003-01-30 Mark Mitchell <mark@codesourcery.com>
2734
2735 * class.c (check_field_decls): Only check C_TYPE_FIELDS_READONLY
2736 for class types.
2737 * cp-tree.h (C_TYPE_FIELDS_READONLY): Use a lang-specific bit
2738 rather than TYPE_LANG_FLAG_0.
2739 (TYPE_BUILT_IN): Remove.
2740 (TYPE_DEPENDENT_P): New macro.
2741 (TYPE_DEPENDENT_P_VALID): Likewise.
2742 (lang_type_class): Add fields_readonly.
2743 * decl.c (record_builtin_type): Don't set TYPE_BUILT_IN.
2744 * pt.c (dependent_type_p_r): New function, split out from ...
2745 (dependent_type_p): ... here. Memoize results.
2746 * search.c (dependent_base_p): Use dependent_type_p, not
2747 uses_template_parms.
2748 * typeck.c (build_modify_expr): Only check C_TYPE_FIELDS_READONLY
2749 for class types.
2750
14d22dd6
MM
27512003-01-29 Mark Mitchell <mark@codesourcery.com>
2752
2753 * call.c (build_field_call): Use build_new_op, not build_opfncall.
2754 (prep_operand): New function.
2755 (build_new_op): Use it. Remove dead code.
2756 * class.c (pushclass): Change "modify" parameter type from int to
2757 bool.
2758 (currently_open_class): Use same_type_p, not pointer equality.
2759 (push_nested_class): Adjust calls to pushclass, remove modify
2760 parameter.
2761 * cp-tree.h (INTEGRAL_OR_ENUMERATION_TYPE_P): New macro.
2762 (pushclass): Change prototype.
2763 (push_nested_class): Likewise.
2764 (grokoptypename): Remove.
2765 (build_opfncall): Remove.
2766 (value_dependent_expression_p): Declare.
2767 (resolve_typename_type): Likewise.
2768 (resolve_typename_type_in_current_instantiation): Likewise.
2769 (enter_scope_of): Remove.
2770 (tsubst): Remove.
2771 (tsubst_expr): Likewise.
2772 (tsubst_copy): Likewise.
2773 (tsubst_copy_and_build): Likewise.
2774 * decl.c (warn_about_implicit_typename_lookup): Remove.
2775 (finish_case_label): Return error_mark_node for erroneous labels.
2776 (start_decl): Adjust calls to push_nested_class.
2777 (grokfndecl): Call push_scope/pop_scope around call to
2778 duplicate_decls.
2779 (grokdeclarator): Do not call tsubst.
2780 (start_function): Adjust calls to push_nested_class.
2781 * decl2.c (grok_array_decl): Use build_new_op, not build_opfncall.
2782 (check_classfn): Use push_scope/pop_scope around type comparisions.
2783 (grokoptypename): Remove.
2784 (push_sscope): Adjust call to push_nested_class.
2785 * error.c (dump_type): Show cv-qualification of typename types.
2786 * init.c (build_member_call): Use build_new_op, not
2787 build_opfncall.
2788 * method.c (build_opfncall): Remove.
2789 * parser.c (cp_parser): Add allow_non_constant_expression_p and
2790 non_constant_expression_p.
2791 (cp_parser_constant_expression): Adjust prototype.
2792 (cp_parser_resolve_typename_type): Remove.
2793 (cp_parser_non_constant_expression): New function.
2794 (cp_parser_non_constant_id_expression): Likewise.
2795 (cp_parser_new): Set allow_non_constant_expression_p and
2796 non_constant_expression_p.
2797 (cp_parser_primary_expression): Reject `this' and `va_arg' in
2798 constant-expressions. Note that dependent names aren't really
2799 constant.
2800 (cp_parser_postfix_expression): Reject conversions to non-integral
2801 types in constant-expressions. Neither are increments or
2802 decrements.
2803 (cp_parser_unary_expression): Reject increments and decrements in
2804 constant-expressions.
2805 (cp_parser_direct_new_declarator): Adjust call to
2806 cp_parser_constant_expression.
2807 (cp_parser_cast_expression): Reject conversions to non-integral
2808 types in constant-expressions.
2809 (cp_parser_assignment_expression): Rejects assignments in
2810 constant-expressions.
2811 (cp_parser_expression): Reject commas in constant-expressions.
2812 (cp_parser_labeled_statement): Adjust call to
2813 cp_parser_constant_expression.
2814 (cp_parser_direct_declarator): Simplify array bounds, even in
2815 templates, when they are non-dependent. Use
2816 resolve_typename_type, not cp_parser_resolve_typename_type.
2817 (cp_parser_class_head): Use resolve_typename_type, not
2818 cp_parser_resolve_typename_type.
2819 (cp_parser_member_declaration): Adjust call to
2820 cp_parser_constant_expression.
2821 (cp_parser_constant_initializer): Likewise.
2822 (cp_parser_constructor_declarator): Use resolve_typename_type, not
2823 cp_parser_resolve_typename_type.
2824 (cp_parser_late_parsing_default_args): Adjust call to
2825 push_nested_class.
2826 * pt.c (tsubst): Give it internal linkage.
2827 (tsubst_expr): Likewise.
2828 (tsubst_copy): Likewise.
2829 (tsubst_copy_and_build): Likewise.
2830 (push_access_scope_real): Likewise.
2831 (tsubst_friend_class): Likewise.
2832 (instantiate_class_template): Adjust call to pushclass.
2833 (value_dependent_expression_p): Give it external linkage.
2834 Robustify.
2835 (resolve_typename_type): New function.
2836 * semantics.c (finish_call_expr): Use build_new_op, not
2837 build_opfncall.
2838 (begin_constructor_declarator): Remove.
2839 (begin_class_definition): Adjust call to pushclass.
2840 (enter_scope_of): Remove.
2841 * typeck.c (comptypes): Resolve typename types as appropriate.
2842 (build_x_indirect_ref): Use build_new_op, not build_opfncall.
2843 (build_x_compound_expr): Likewise.
2844 (build_modify_expr): Likewise.
2845 (build_x_modify_expr): Likewise.
2846 * typeck2.c (build_x_arrow): Likewise.
40a4184c 2847
be5a07ac
FJ
28482003-01-29 Fariborz Jahanian <fjahanian@apple.com>
2849
d9b2742a 2850 * pt.c (last_pending_template) Declare GTY().
be5a07ac 2851
710b73e6
KL
28522003-01-29 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2853
2854 PR c++/8591
2855 * parser.c (cp_parser_elaborated_type_specifier): Convert
2856 TEMPLATE_DECL to TYPE_DECL only when processing template friends.
2857 (cp_parser_maybe_treat_template_as_class): Remove redundant tests.
2858
f2ce60b8
NS
28592003-01-28 Nathan Sidwell <nathan@codesourcery.com>
2860
9ae58faf
NS
2861 PR c++/9437
2862 * pt.c (unify): Don't unify '*T' with 'U C::*'.
2863
f2ce60b8
NS
2864 PR c++/3902
2865 * parser.c (cp_parser_decl_specifier_seq): Cannot have constructor
2866 inside a declarator.
2867
a2ddc397
NS
28682003-01-27 Nathan Sidwell <nathan@codesourcery.com>
2869
2870 * class.c (update_vtable_entry_for_fn): Add index parameter.
2871 Generate vcall thunk for covariant overriding from a virtual
2872 primary base.
2873 (dfs_modify_vtables): Adjust.
2874
bbaab916
NS
28752003-01-25 Nathan Sidwell <nathan@codesourcery.com>
2876
2877 PR c++/9403
2878 * parser.c (cp_parser_class_or_namespace_name): Reject duplicate
2879 template keyword.
2880 (cp_parser_base_specifier): Look for and consume a
2881 TEMPLATE keyword. Replace switch with array index.
2882
2883 PR c++/795
2884 * semantics.c (finish_non_static_data_member): Remember the
2885 field's type even in a template.
2886
2887 PR c++/9415
2888 * pt.c (tsubst_copy_and_build, CALL_EXPR): BASELINK exprs are
2889 already scoped.
40a4184c 2890
bbaab916
NS
2891 PR c++/8545
2892 * parser.c (cp_parser_cast_expression): Be more tentative.
2893
fb8eab96
KL
28942003-01-25 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
2895
2896 * cp-tree.h (flagged_type_tree_s): Remove.
2897 (check_for_new_type): Likewise.
2898 * typeck2.c (check_for_new_type): Likewise.
2899
c38e9817
NN
29002003-01-23 Nathanael Nerode <neroden@gcc.gnu.org>
2901
ee42dd9d
NN
2902 * dump.c: ANSIfy function declarations and definitions.
2903
c38e9817
NN
2904 * cp-tree.h, decl.h: Get rid of PARAMS. Again.
2905
c006d942
MM
29062003-01-22 Mark Mitchell <mark@codesourcery.com>
2907
2908 PR c++/9354
2909 * init.c (build_new): Set the type of the new-expression, even
2910 when processing_templte_decl.
2911
2912 PR c++/9216
2913 * parser.c (cp_parser_primary_expression): Improve error message
2914 for templates used in an expression context.
2915
2916 PR c++/8696
2917 * parser.c (cp_parser_decl_specifier_seq): Commit to tentative
2918 parse when encountering "typedef".
2919
94edc4ab
NN
29202003-01-22 Nathanael Nerode <neroden@gcc.gnu.org>
2921
2922 * class.c, parser.c: ANSIfy function definitions and declarations.
2923
e0860732
MM
29242003-01-22 Mark Mitchell <mark@codesourcery.com>
2925
65a5559b
MM
2926 PR c++/9328
2927 * error.c (dump_decl): For an OVERLOAD, just print the name of the
2928 function; it doesn't make sense to try to print its type.
2929 * semantics.c (finish_typeof): Issue errors about invalid uses.
2930
e0860732
MM
2931 PR c++/9298
2932 * parser.c (cp_parser_consume_semicolon_at_end_of_statement): New
2933 function.
2934 (cp_parser_expression_statement): Use it.
2935 (cp_parser_explicit_instantiation): Likewise.
2936 * pt.c (do_decl_instantiation): Improve error handling logic.
40a4184c 2937
1fb3244a
MM
29382003-01-22 Mark Mitchell <mark@codesourcery.com>
2939
4eb6d609
MM
2940 PR c++/9384
2941 * parser.c (cp_parser_using_declaration): Issue error messages
2942 about name resolution failures here.
2943
1fb3244a
MM
2944 PR c++/9388
2945 * class.c (currently_open_derived_class): Use dependent_type_p.
2946 * cp-tree.h (dependent_type_p): New function.
2947 (dependent_template_arg_p): Likewise.
2948 (dependent_template_p): Likewise.
2949 (type_dependent_expression_p): Likewise.
2950 * parser.c (cp_parser_dependent_type_p): Remove.
2951 (cp_parser_value_dependent_type_p): Likewise.
2952 (cp_parser_type_dependent_expression_p): Likewise.
2953 (cp_parser_dependent_template_arg_p): Likewise.
2954 (cp_parser_dependent_template_id_p): Likewise.
2955 (cp_parser_dependent_template_p): Likewise.
2956 (cp_parser_diagnose_invalid_type_name): Replace
2957 cp_parser_dependent_type_p with dependent_type_p, etc.
2958 (cp_parser_primary_expresion): Likewise.
2959 (cp_parser_nested_name_specifier_opt): Likewise.
2960 (cp_parser_postfix_expression): Likewise.
2961 (cp_parser_unary_expression): Likewise.
2962 (cp_parser_template_name): Likewise.
2963 (cp_parser_class_name): Likewise.
2964 (cp_parser_lookup_name): Likewise.
2965 * pt.c (dependent_type_p): New function.
2966 (value_dependent_expression_p): Likewise.
2967 (type_dependent_expression_p): Likewise.
2968 (dependent_template_arg_p): Likewise.
2969 (dependent_template_id_p): Likewise.
2970 (dependent_template_p): Likewise.
40a4184c 2971
1fb3244a
MM
2972 PR c++/9285
2973 PR c++/9294
00b51d29 2974 * parser.c (cp_parser_simple_declaration): Return quickly when
d9b2742a 2975 encountering errors.
1fb3244a 2976
dd859b8a
KG
29772003-01-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2978
2979 Make-lang.in (cp/decl.o-warn): Add -Wno-error.
2980
753225c1
JM
29812003-01-17 Jason Merrill <jason@redhat.com>
2982
2983 PR c++/9167, c++/9358
2984 * decl.c (require_complete_types_for_parms): Also update DECL_ARG_TYPE.
2985
77b996cc
JM
29862003-01-17 Jason Merrill <jason@redhat.com>
2987
2988 PR c++/9342
2989 * call.c (build_conditional_expr): Always do lvalue-rvalue
2990 conversion.
2991
5dae1114
MM
29922003-01-17 Mark Mitchell <mark@codesourcery.com>
2993
2994 PR c++/9294
2995 * cp-tree.def (BASELINK): Make it class 'x', not class 'e'.
2996 * cp-tree.h (BASELINK_BINFO): Adjust.
2997 (BASELINK_FUNCTIONS): Likewise.
2998 (BASELINK_ACCESS_BINFO): Likewise.
2999 (tree_baselink): New structure.
3000 (cp_tree_node_structure_enum): Add TS_CP_BASELINK.
3001 (lang_tree_node): Add baselink.
3002 * decl.c (cp_tree_node_structure): Add BASELINK case.
3003 * search.c (build_baselink): Adjust.
3004 * tree.c (cp_walk_subtrees): Add BASELINK case. Remove BASELINK_P
3005 test from TREE_LIST case.
3006
3007 PR c++/9272
3008 * parser.c (cp_parser_constructor_declarator_p): Do not assume
3009 that a constructor cannot be declared outside of its own class.
40a4184c 3010
5dae1114
MM
3011 * parser.c (cp_parser_resolve_typename_type): If the scope cannot
3012 be resolved, neither can the qualified name.
3013
3014 * rtti.c (get_pseudo_ti_desc): Fix thinko.
3015
a48cccea
JM
30162003-01-16 Jason Merrill <jason@redhat.com>
3017
3018 PR c++/8564
3019 * init.c (build_vec_init): Re-add maxindex parm.
3020 (perform_member_init, build_aggr_init): Pass it.
3021 (build_new_1): Pass it. Use an incomplete array type for full_type.
3022 * typeck.c (build_modify_expr): Pass it.
3023 * cp-tree.h: Adjust.
3024
cc23546e
JO
30252003-01-16 Jeffrey D. Oldham <oldham@codesourcery.com>
3026
3027 * cp-tree.h (tsubst_copy_and_build): New declaration.
3028 * pt.c (tsubst_copy): Remove 'build_expr_from_tree' from comment.
3029 (tsubst_expr): Use 'tsubst_copy_and_build'. Update initial comment.
3030 (tsubst_copy_and_build): New function.
3031
8fbc5ae7
MM
30322003-01-16 Mark Mitchell <mark@codesourcery.com>
3033
3034 * cp-tree.h (lang_type_class): Remove is_partial_instantiation.
3035 (PARTIAL_INSTANTIATION_P): Remove.
3036 (IMPLICIT_TYPENAME_P): Likewise.
3037 (IMPLICIT_TYPENAME_TYPE_DECL_P): Likewise.
3038 (build_typename_type): Remove declaration.
3039 (parmlist_is_exprlist): Likewise.
3040 * decl.c (build_typename_type): Make it static, remove third
3041 parameter.
3042 (push_class_binding): Don't do implicit typename stuff.
3043 (make_typename_type): Likewise.
3044 (lookup_name_real): Likewise.
3045 (grokdeclarator): Don't try to convert declarations into
3046 initializations. Don't do implicit typename stuff.
3047 (parmlist_is_exprlist): Remove.
3048 (xref_basetypes): Simplify.
3049 * decl2.c (grokfield): Don't try to convert declarations into
3050 initializations.
3051 (build_anon_union_vars): Do this while processing templates, too.
3052 (finish_anon_union): Likewise.
3053 * error.c (dump_type): Remove implicit typename handling.
3054 * parser.c (cp_parser_diagnose_invalid_type_name): New method.
3055 (cp_parser_primary_expression): Correct handling of names not
3056 found by unqualified name lookup in templates.
3057 (cp_parser_nested_name_specifier_opt): Avoid checking dependency
3058 of types when possible.
3059 (cp_parser_simple_declaration): Complain intelligently about some
3060 invalid declarations.
3061 (cp_parser_member_declaration): Likewise.
3062 (cp_parser_constructor_declarator_p): Don't check when we're in a
3063 function scope.
3064 * pt.c (instantiate_class_template): Remove
3065 PARTIAL_INSTANTIATION_P gunk.
3066 * search.c (lookup_field_r): Don't build implicit typenames.
3067 (marked_pushdecls_p): Don't enter dependent base types.
3068 (unmarked_pushdecls_p): Likewise.
3069 * semantics.c (begin_class_definition): Remove implicit typename
3070 stuff.
3071
712becab
NS
30722003-01-16 Nathan Sidwell <nathan@codesourcery.com>
3073
3074 PR c++/9212
3075 * parser.c (cp_parser_direct_declarator): If accepting either
3076 abstract or named, the name must be an unqualified-id.
3077
fc555370
KG
30782003-01-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
3079
3080 * class.c (layout_virtual_bases): Avoid signed/unsigned warning.
3081
dd1b7476
KG
30822003-01-14 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
3083
3084 * decl2.c (check_classfn): Fix uninitialized warning.
3085 (build_anon_union_vars): Likewise.
3086 * pt.c (tsubst_copy): Likewise.
3087
a7189b49
JO
30882003-01-14 Jeffrey D. Oldham <oldham@codesourcery.com>
3089
3090 Further conform g++'s __vmi_class_type_info to the C++ ABI
3091 specification.
3092 * rtti.c (dfs_class_hint_mark): Do not set hints not specified by
3093 the specification.
3094 (class_hint_flags): Likewise.
3095
cf22909c
KL
30962003-01-14 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
3097
3098 * config-lang.in: Add semantics.c to gtfiles.
3099 * cp-tree.h (flagged_type_tree_s): Remove lookups field.
3100 (saved_scope): Likewise.
3101 (type_lookups): Remove.
3102 (deferred_access): New structure.
3103 (type_access_control): Remove.
3104 (save_type_access_control): Likewise.
3105 (reset_type_access_control): Likewise.
3106 (decl_type_access_control): Likewise.
3107 (push_deferring_access_checks): Declare.
3108 (resume_deferring_access_checks): Likewise.
3109 (stop_deferring_access_checks): Likewise.
3110 (pop_deferring_access_checks): Likewise.
3111 (get_deferred_access_checks): Likewise.
3112 (pop_to_parent_deferring_access_checks): Likewise.
3113 (perform_deferred_access_checks): Likewise.
3114 (perform_or_defer_access_check): Likewise.
3115 * decl.c (make_typename_type): Use perform_or_defer_access_check.
3116 (make_unbound_class_template): Likewise.
3117 (grokdeclarator): Don't call decl_type_access_control.
3118 * parser.c (cp_parser_context): Remove deferred_access_checks
3119 and deferring_access_checks_p fields.
3120 (cp_parser_context_new): Adjust.
3121 (cp_parser): Remove access_checks_lists.
3122 (cp_parser_defer_access_check): Remove.
3123 (cp_parser_start_deferring_access_checks): Remove.
3124 (cp_parser_stop_deferring_access_checks): Remove.
3125 (cp_parser_perform_deferred_access_checks): Remove.
3126 (cp_parser_nested_name_specifier_opt): Use new deferred access
3127 functions.
3128 (cp_parser_simple_declaration): Likewise.
3129 (cp_parser_template_id): Likewise.
3130 (cp_parser_function_definition): Likewise.
3131 (cp_parser_class_specifier): Likewise.
3132 (cp_parser_lookup_name): Likewise.
3133 (cp_parser_single_declaration): Likewise.
3134 (cp_parser_pre_parsed_nested_name_specifier): Likewise.
3135 (cp_parser_parse_tentatively): Likewise.
3136 (cp_parser_parse_definitely): Likewise.
3137 (yyparse): Likewise.
3138 (cp_parser_init_declarator): Remove access_checks parameter.
3139 Use new deferred access functions.
3140 (cp_parser_function_definition_from_specifiers_and_declarator):
3141 Likewise.
3142 (cp_parser_class_head): Remove deferring_access_checks_p and
3143 saved_access_checks parameters. Use new deferred access functions.
3144 (cp_parser_member_specification_opt): Don't call
3145 reset_type_access_control.
3146 * search.c (type_access_control): Remove.
3147 * semantics.c: Include "gt-cp-semantics.h".
3148 (deferred_type_access_control): Remove.
3149 (deferred_access_stack): New variable.
3150 (deferred_access_free_list): Likewise.
3151 (push_deferring_access_checks): New function.
3152 (resume_deferring_access_checks): Likewise.
3153 (stop_deferring_access_checks): Likewise.
3154 (pop_deferring_access_checks): Likewise.
3155 (get_deferred_access_checks): Likewise.
3156 (pop_to_parent_deferring_access_checks): Likewise.
3157 (perform_deferred_access_checks): New function, adapted from
3158 cp_parser_perform_deferred_access_checks.
3159 (perform_or_defer_access_check): New function, adapted from
3160 cp_parser_defer_access_check.
3161 (current_type_lookups): Remove.
3162 (deferred_type_access_control): Likewise.
3163 (decl_type_access_control): Likewise.
3164 (save_type_access_control): Likewise.
3165 (reset_type_access_control): Likewise.
3166 (begin_function_definition): Adjust.
3167 (begin_class_definiton): Likewise.
3168
f576dfc4
JM
31692003-01-13 Jason Merrill <jason@redhat.com>
3170
3171 PR c++/8748
3172 * class.c (build_base_path): Take the address before calling save_expr.
3173
3174 * call.c (build_user_type_conversion_1): Do set ICS_BAD_FLAG if
3175 all the ambiguous conversions are bad.
3176
3177 * class.c (maybe_warn_about_overly_private_class): Don't stop
3178 searching when we find a nonprivate method.
3179
3180 * typeck.c (build_class_member_access_expr): Use unary_complex_lvalue.
3181
8fa1ad0e
MM
31822003-01-12 Mark Mitchell <mark@codesourcery.com>
3183
3184 * cp-tree.h (get_arglist_len_in_bytes): Remove.
3185
3186 PR c++/9264
3187 * parser.c (cp_parser_elaborated_type_specifier): Handle erroneous
3188 typeame types more robustly.
3189
15d2cb19
PE
31902003-01-11 Phil Edwards <pme@gcc.gnu.org>
3191
3192 * parser.c: Fix comment typos.
3193
a6f6052a
MM
31942003-01-10 Mark Mitchell <mark@codesourcery.com>
3195
99152b95 3196 PR c++/9099
a6f6052a
MM
3197 * parser.c (cp_parser_scope_through_which_access_occurs): Handle
3198 an object_type which is not a class type.
3199
3466b292
GK
32002003-01-10 Geoffrey Keating <geoffk@apple.com>
3201
3202 * parser.c (cp_parser_late_parsing_for_member): Don't cast to void.
3203 (cp_parser_late_parsing_default_args): Likewise.
3204
b2f29cd9
NN
32052003-01-10 Nathanael Nerode <neroden@gcc.gnu.org>
3206
3207 * cfns.gperf: ANSIfy function declarations.
3208 * cfns.h: Regenerate.
3209 * cp-tree.h: ANSIfy function declarations.
3210
2050a1bb
MM
32112003-01-10 Mark Mitchell <mark@codesourcery.com>
3212
3213 * cp-tree.h (reparse_absdcl_as_expr): Remove.
3214 (reparse_absdcl_as_casts): Likewise.
3215 (reparse_decl_as_expr): Likewise.
3216 (finish_decl_parsing): Likewise.
3217 * decl2.c (reparse_absdcl_as_expr): Remove.
3218 (reparse_absdcl_as_casts): Likewise.
3219 (repase_decl_as_expr): Likewise.
3220 (finish_decl_parsing): Likewise.
3221
3222 PR c++/9128
3223 PR c++/9153
3224 PR c++/9171
3225 * parser.c (cp_parser_pre_parsed_nested_name_specifier): New
3226 function.
3227 (cp_parser_nested_name_specifier_opt): Correct the
3228 check_dependency_p false.
3229 (cp_parser_postfix_expression): Fix formatting.
3230 (cp_parser_decl_specifier_seq): Avoid looking for constructor
3231 declarators when possible.
3232 (cp_parser_template_id): Avoid performing name-lookup when
3233 possible.
3234 (cp_parser_class_head): Do not count specializations when counting
3235 levels of templates.
3236 (cp_parser_constructor_declarator_p): Return immediately if
3237 there's no chance that the tokens form a constructor declarator.
3238 * rtti.c (throw_bad_typeid): Add comment. Do not return an
3239 expression with reference type.
3240 (get_tinfo_decl_dynamic): Do not return an expression with
3241 reference type.
3242 (build_typeid): Add comment. Do not return an expression with
3243 reference type.
3244 * typeck.c (build_class_member_access_expr): Improve handling of
3245 conditionals and comma-expressions as objects.
3246
45225759
NN
32472003-01-09 Nathanael Nerode <neroden@gcc.gnu.org>
3248
d9b2742a
ZW
3249 * cfns.gperf: ANSIfy function declarations.
3250 * cfns.h: Regenerate.
3251 * cp-tree.h: ANSIfy function declarations.
3252 * parser.c: ANSIfy function declarations & definitions.
b2f29cd9 3253
45225759
NN
3254 * decl.c (bad_specifiers): Fix parameter order error I introduced.
3255
17211ab5
GK
32562003-01-09 Geoffrey Keating <geoffk@apple.com>
3257
3258 Merge from pch-branch:
3259
3260 2003-01-09 Geoffrey Keating <geoffk@apple.com>
3261
3262 Merge to tag pch-merge-20030102:
40a4184c 3263
17211ab5
GK
3264 * semantics.c (finish_translation_unit): Don't call finish_file.
3265 * parser.c: Don't include ggc.h.
3266 (cp_lexer_new_main): Rename from cp_lexer_new, only create main lexer,
3267 read first token here. Don't allow PCH files after the first
3268 token is read.
3269 (cp_lexer_new_from_tokens): Duplicate functionality from cp_lexer_new.
3270 (cp_lexer_get_preprocessor_token): Allow LEXER to be NULL.
3271 (cp_parser_new): Call cp_lexer_new_main before allocating GCed memory.
3272 (cp_parser_late_parsing_for_member): Don't duplicate call to
3273 cp_lexer_set_source_position_from_token.
3274 (cp_parser_late_parsing_default_args): Likewise.
3275 (yyparse): Call finish_file after clearing the_parser.
3276
3277 2002-12-11 Geoffrey Keating <geoffk@apple.com>
3278
3279 * Make-lang.in: Remove $(GGC_H) from all dependencies.
3280 (CXX_TREE_H): Add $(GGC_H).
40a4184c 3281 * class.c: Don't include ggc.h.
17211ab5
GK
3282 (field_decl_cmp): Make parameters be 'const void *' to match qsort.
3283 (method_name_cmp): Likewise.
3284 (resort_data): New variable.
3285 (resort_field_decl_cmp): New.
3286 (resort_method_name_cmp): New.
3287 (resort_sorted_fields): New.
3288 (resort_type_method_vec): New.
3289 (finish_struct_methods): Delete cast.
3290 (finish_struct_1): Delete cast.
3291 * cp-tree.h: Include ggc.h.
3292 (struct lang_type_class): Add reorder attribute to field `methods'.
3293 (union lang_decl_u3): Add reorder attribute to field `sorted_fields'.
3294 (resort_sorted_fields): New prototype.
3295 (resort_type_method_vec): New prototype.
3296 * call.c: Don't include ggc.h.
3297 * decl.c: Likewise.
3298 * decl2.c: Likewise.
3299 * init.c: Likewise.
3300 * lex.c: Likewise.
3301 * method.c: Likewise.
3302 * optimize.c: Likewise.
3303 * parse.y: Likewise.
3304 * pt.c: Likewise.
3305 * repo.c: Likewise.
3306 * search.c: Likewise.
3307 * semantics.c: Likewise.
3308 * spew.c: Likewise.
3309 * tree.c: Likewise.
3310
3311 * lang-specs.h: Remove comment.
3312
3313 2002-12-03 Geoffrey Keating <geoffk@apple.com>
3314
3315 * cp-tree.h (struct operator_name_info_t): Mark for GTY machinery.
3316 (operator_name_info): Mark to be saved for PCH, specify size.
3317 (assignment_operator_name_info): Likewise.
3318
3319 2002-11-19 Geoffrey Keating <geoffk@apple.com>
3320
3321 * decl.c (anon_cnt): Mark to be saved for PCH.
3322
3323 2002-10-25 Geoffrey Keating <geoffk@apple.com>
3324
3325 * lex.c (init_reswords): Delete now-untrue comment.
3326 Allocate ridpointers using GGC.
3327
3328 2002-10-04 Geoffrey Keating <geoffk@apple.com>
3329
3330 * cp-tree.h (union lang_decl_u2): Add tags to all fields.
3331
3332 * g++spec.c (lang_specific_driver): Don't include standard
3333 libraries in `added'.
3334
3335 2002-08-27 Geoffrey Keating <geoffk@redhat.com>
3336
3337 * decl2.c (finish_file): Call c_common_write_pch.
3338 * Make-lang.in (CXX_C_OBJS): Add c-pch.o.
3339
3340 2002-08-17 Geoffrey Keating <geoffk@redhat.com>
3341
3342 * g++spec.c (lang_specific_driver): Treat .h files as C++ header
3343 files when using g++.
3344 * lang-specs.h: Handle compiling C++ header files.
3345
ca5dd8b7
JJ
33462003-01-09 Jakub Jelinek <jakub@redhat.com>
3347
3348 * decl.c (start_decl): Only check DECL_THREAD_LOCAL for VAR_DECLs.
3349
0f399e5f
KL
33502003-01-09 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
3351
3352 * pt.c (push_access_scope_real): Call push_to_top_level for
3353 function in namespace scope.
3354 (pop_access_scope): Call pop_from_top_level for function in
3355 namespace scope.
3356
c456a45a
JJ
33572003-01-09 Jakub Jelinek <jakub@redhat.com>
3358
3359 * decl.c (start_decl): Don't set DECL_COMMON for __thread variables.
3360
2c6ce97e
CC
33612003-01-09 Christian Cornelssen <ccorn@cs.tu-berlin.de>
3362
3363 * Make-lang.in (c++.install-common, c++.install-man,
3364 c++.uninstall): Prepend $(DESTDIR) to destination paths in
3365 all (un)installation commands.
3366 (c++.install-common): Rewrite $(LN) commands to support
3367 DESTDIR with "ln" as well as with "ln -s".
3368
f74dbcec
JM
33692003-01-08 Jason Merrill <jason@redhat.com>
3370
3371 * parser.c (cp_parser_primary_expression): See through explicitly
3372 scoped ALIAS_DECLs, too.
3373
11f6b451
NN
33742003-01-08 Nathanael Nerode <neroden@gcc.gnu.org>
3375
1774f99d
NN
3376 * decl.c: Remove some #if 0 code.
3377
11f6b451
NN
3378 * decl.c: ANSIfy function declarations.
3379
8caf4c38
MM
33802003-01-07 Mark Mitchell <mark@codesourcery.com>
3381
3382 * parser.c (cp_parser_asm_definition): Correct handling of omitted
3383 operands.
3384
2b59fc25
KL
33852003-01-08 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
3386
3387 PR c++/9030
3388 * decl.c (make_typename_type): Check access only when tf_error.
3389 (make_unbound_class_template): Likewise.
3390 * pt.c (saved_access_scope): New variable.
3391 (push_access_scope_real): New function.
3392 (push_access_scope): Likewise.
3393 (pop_access_scope): Likewise.
3394 (tsubst_default_argument): Use them.
3395 (instantiate_template): Likewise.
3396 (regenerate_decl_from_template): Likewise.
3397 (instantiate_decl): Likewise.
3398 (get_mostly_instantiated_function_type): Likewise.
3399
3f7617e4
NN
34002003-01-07 Nathanael Nerode <neroden@gcc.gnu.org>
3401
3402 * tree.c: Delete bogus #if 0 code.
3403
c9372112
AS
34042003-01-07 Andreas Schwab <schwab@suse.de>
3405
3406 * class.c (layout_class_type): Don't use
3407 PCC_BITFIELD_TYPE_MATTERS if not defined.
3408
8218bd34
MM
34092003-01-06 Mark Mitchell <mark@codesourcery.com>
3410
c10cdb3d
MM
3411 PR c++/9165
3412 * decl2.c (build_cleanup): Mark the object as used.
3413
69f794a7
MM
3414 * pt.c (retrieve_local_specialization): Revert 2003-01-05 change.
3415 (hash_local_specialization): New function.
3416 (register_local_specialization): Revert 2003-01-05 change.
3417 (instantiate_decl): Use hash_local_specialization when creating
3418 the local_specializations table.
40a4184c 3419
4c4646b5
MM
3420 * decl2.c (mark_used): Do not synthesize thunks.
3421
63e5f567
MM
3422 * class.c (layout_class_type): Correct handling of unnamed
3423 bitfields wider than their types.
3424
8218bd34
MM
3425 PR c++/9189
3426 * parser.c (cp_parser): Remove default_arg_types. Update
3427 documentation for unparsed_functions_queues.
3428 (cp_parser_late_parsing_default_args): Take a FUNCTION_DECL as the
3429 parameter.
3430 (cp_parser_new): Don't set parser->default_arg_types.
3431 (cp_parser_function_definition): Adjust usage of
3432 unparsed_funtions_queues.
3433 (cp_parser_class_specifier): Don't mess with
3434 parser->default_arg_types. Handle default argument processing in
3435 a separate phase from function body processing.
3436 (cp_parser_template_declaration_after_export): Adjust usage of
3437 unparsed_functions_queues.
3438 (cp_parser_late_parsing_for_member): Do not handle default
3439 arguments.
3440
62b8a44e
NS
34412003-01-06 Nathan Sidwell <nathan@codesourcery.com>
3442
3443 PR c++/9109
3444 * parser.c (cp_parser_declarator_kind): New enum.
3445 (cp_parser_declarator): Adjust.
3446 (cp_parser_direct_declarator): Adjust. Allow for either named or
3447 abstract declarator. Prefer abstract, if possible. Allow
3448 parenthesized function name.
3449 (cp_parser_condition): Adjust cp_parser_declarator call.
3450 (cp_parser_explicit_instantiation): Likewise.
3451 (cp_parser_init_declarator): Likewise.
3452 (cp_parser_type_id): Likewise.
3453 (cp_parser_function_definition): Likewise.
3454 (cp_parser_member_declaration): Likewise.
3455 (cp_parser_parameter_declaration): Use cp_parser_declarator to do
3456 the tentative parsing.
3457 (cp_parser_exception_declaration): Likewise.
3458
ec194454
MM
34592003-01-05 Mark Mitchell <mark@codesourcery.com>
3460
3461 * parser.c (cp_parser_template_parameter): Adjust call to
3462 cp_parser_parameter_declaration.
3463 (cp_parser_parameter_declaration_list): Likewise.
3464 (cp_parser_parameter_declaration): Replace
3465 greater_than_is_operator_p with template_parm_p parameter. Do not
3466 cache tokens for template default arguments.
3467
3468 * pt.c (retrieve_local_specialization): Use htab_find, not
3469 htab_find_with_hash.
3470 (register_local_specialization): Use htab_find_slot, not
3471 htab_find_slot_with_hash.
3472 (instantiate_decl): Pass a hash function to htab_create.
40a4184c 3473
39b1af70
KG
34742003-01-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
3475
3476 * parser.c (cp_parser_binary_expression,
3477 cp_parser_multiplicative_expression,
3478 cp_parser_additive_expression, cp_parser_shift_expression,
3479 cp_parser_relational_expression, cp_parser_equality_expression,
3480 cp_parser_and_expression, cp_parser_exclusive_or_expression,
3481 cp_parser_inclusive_or_expression,
3482 cp_parser_logical_and_expression, cp_parser_logical_or_expression,
3483 cp_parser_binary_expression): Const-ify.
3484
1bb2cc34
MM
34852003-01-04 Mark Mitchell <mark@codesourcery.com>
3486
3487 * method.c (use_thunk): Disable access control while building the
3488 body of the thunk.
3489
3fd5abcf
NN
34902003-01-03 Nathanael Nerode <neroden@gcc.gnu.org>
3491
40a4184c 3492 * cvt.c, decl.c, decl2.c: This is the C++ front end, not the C
3fd5abcf
NN
3493 front end.
3494
9aad8f83
MA
34952003-01-03 Matt Austern <austern@apple.com>
3496
3497 * cp-tree.h (struct lang_type_class): add field for key method
3498 (cp_global_trees): rename dynamic_classes to keyed_classes
3499 (key_method): add definition
3500 * class.c (finish_struct_1): compute class's key method, and add
3501 the class to keyed_classes list if there is no key method.
3502 * decl.c (finish_function): add class to keyed_classes list if we
3503 see a definition of the class's key method.
3504 * pt.c (instantiate_class_template): add template specialization
3505 of a dynamic class to keyed_classes list.
3506 * decl2.c (key_method): remove
3507 (finish_file): iterate only through keyed_classes list when
3508 deciding whether to emit vtables, remove class from its list after
3509 we do the emission.
40a4184c 3510
6cce57b0
JM
35112003-01-02 Jason Merrill <jason@redhat.com>
3512
4e8dca1c
JM
3513 * call.c (build_conditional_expr): Stabilize lvalues properly.
3514 * cvt.c (ocp_convert): Don't build NOP_EXPRs of class type.
3515 * tree.c (lvalue_p_1): Don't allow sloppy NOP_EXPRs as lvalues.
3516 Don't allow CALL_EXPR or VA_ARG_EXPR, either.
3517
3518 * call.c (convert_like_real): Call decl_constant_value for an
3519 IDENTITY_CONV even if there are no more conversions.
3520
3521 * cvt.c (build_up_reference): Don't push unnamed temps.
3522
3523 * decl2.c (do_namespace_alias): Namespace aliases are DECL_EXTERNAL.
3524
3525 * dump.c (cp_dump_tree): Don't try to dump class-specific fields
3526 for a backend struct.
3527
3528 * except.c (wrap_cleanups_r, build_throw): Make
3529 MUST_NOT_THROW_EXPRs void.
3530 * init.c (expand_default_init): Update to handle MUST_NOT_THROW_EXPR.
3531
3532 * init.c (build_vec_delete_1): Pre-evaluate the base address.
3533
3534 * init.c (get_temp_regvar): Simplify logic.
3535
3536 * tree.c (cp_copy_res_decl_for_inlining): Only do debug tweaks if
3537 our replacement is a decl.
3538
6cce57b0
JM
3539 * decl.c (cp_make_fname_decl): Push the decls inside the
3540 outermost scope.
3541
31758337
NS
35422003-01-03 Nathan Sidwell <nathan@codesourcery.com>
3543
3544 PR c++/45, c++/3784
3545 * tree.c (cp_tree_equal, TEMPLATE_PARM_INDEX): The types must be
3546 the same too.
3547
24c0ef37
GS
35482003-01-03 Graham Stott <graham.stott@btinternet.com>
3549
3550 * parser.c (struct cp_parser): Add access_checks_lists field
3551 (cp_parser_simple_declaration): Use.
40a4184c 3552 (cp_parser_init_declarator): Likewise.
24c0ef37 3553
5e8a153a
MM
35542003-01-02 Mark Mitchell <mark@codesourcery.com>
3555
1092805d
MM
3556 * parser.c (cp_parser_declaration): Accept the __extension__
3557 keyword before the declaration.
3558
4971227d
MM
3559 PR c++/2843
3560 * parser.c (cp_parser_parameter_declaration): Allow attributes to
3561 appear after the declarator.
3562
5e8a153a
MM
3563 * call.c (build_new_method_call): Fix typo in message format
3564 string.
3565
3beb3abf
MM
35662003-01-02 Mark Mitchell <mark@codesourcery.com>
3567
f7b5ecd9
MM
3568 * parser.c (cp_lexer_next_token_is): Declare it inline.
3569 (cp_lexer_set_source_position_from_token): Likewise.
3570 (cp_lexer_debugging_p): Likewise.
3571 (cp_parser_parsing_tentatively): Likewise.
3572 (cp_parser_nested_name_specifier_opt): Reduce the number of calls
3573 to the cp_lexer_peek_token.
1092805d 3574
3beb3abf
MM
3575 * parser.c (cp_parser_sizeof_operand): Do not evaluate the
3576 expression.
3577
43c6a96a
SB
35782003-01-02 Steven Bosscher <s.bosscher@student.tudelft.nl>
3579
3580 * cp/except.c, cp/expr.c, cp/friend.c, cp/g++spec.c,
3581 cp/lang-options.h, cp/lang-specs.h, cp/lex.h, cp/ptree.c,
3582 cp/repo.c: Fix copyright years.
3583
c58b209a
NB
35842003-01-01 Neil Booth <neil@daikokuya.co.uk>
3585
3586 * lex.c: Remove superfluous include of cpplib.h.
3587 (CONSTRAINT): Define without conditions.
3588 (init_cp_pragma): Use c_register_pragma.
3589
7347c2c5
NB
35902002-12-31 Neil Booth <neil@daikokuya.co.uk>
3591
3592 * .cvsignore: Remove.
3593
f5adbb8d
SB
35942002-12-31 Steven Bosscher <s.bosscher@student.tudelft.nl>
3595
3596 * call.c, class.c, cp-lang.c, cp-tree.h, cvt.c, dump.c, error.c,
3597 except.c, expr.c friend.c, g++spec.c, init.c, lang-options.h,
3598 lang-specs.h, lex.c, mangle.c, method.c, optimize.c, parser.c,
3599 pt.c, ptree.c, repo.c, rtti.c, search.c, semantics.c, tree.c,
3600 typeck.c, typeck2.c: Replace "GNU CC" with "GCC" in the
3601 copyright header.
3602 * lex.h: parse.y is dead, so don't mention it. Also replace the
3603 copyright header with the default GNU copyright header.
3604
f1aba0a5
MM
36052002-12-31 Mark Mitchell <mark@codesourcery.com>
3606
eea9800f
MM
3607 * cp-tree.h (LOOKUP_TEMPLATES_EXPECTED): Remove.
3608 (lookup_name_namespace_only): Likewise.
3609 (begin_only_namespace_names): Likewise.
3610 (end_only_namespace_names): Likewise.
3611 * decl.c (only_namespace_names): Remove.
3612 (qualify_lookup): Do not check LOOKUP_TEMPLATES_EXPECTED.
3613 (lookup_name_real): Do not check only_namespace_names.
3614 (lookup_name_namespace_only): Remove.
3615 (begin_only_namespace_names): Likewise.
3616 (end_only_namespace_names): Likewise.
3617 * parser.c (cp_parser_nested_name_specifier_opt): Handle erroneous
3618 nested-name-specifiers more gracefully.
3619 (cp_parser_class_or_namespace_name): Avoid looking up namespace
3620 names when they cannot possibly appear.
3621 (cp_parser_template_name): Adjust call to cp_parser_lookup_name.
3622 (cp_parser_elaborated_type_specifier): Likewise.
3623 (cp_parser_namespace_name): Only look for namespace names.
3624 (cp_parser_lookup_name): Add is_namespace parameter.
3625 (cp_parser_lookup_name_simple): Adjust call to
3626 cp_parser_lookup_name.
3627
f1aba0a5
MM
3628 * parser.c (cp_parser_dependent_type_p): Fix thinko.
3629
eea9800f
MM
36302002-12-31 Neil Booth <neil@daikokuya.co.uk>
3631
3632 * .cvsignore: Update.
3633
3cfabe60
NS
36342002-12-31 Nathan Sidwell <nathan@codesourcery.com>
3635
3636 * class.c (modify_vtable_entry): Remove unused variable.
3637 (get_vcall_index): Always expect a non-thunk.
3638 (update_vtable_entry_for_fn): Combine covariant adjustments, when
3639 overriding a thunk. Pass get_vcall_index a non-thunk.
3640
3641 * decl2.c (finish_file): Mark undefined inlines as extern.
3642
92bc1323
MM
36432002-12-31 Mark Mitchell <mark@codesourcery.com>
3644
3645 * cp-tree.def (RETURN_INIT): Remove.
3646 * cp-tree.h (DECL_IN_MEMORY_P): Remove.
3647 (scope_kind): Add sk_block, sk_try, sk_catch, sk_for.
3648 (note_level_for_for): Remove.
3649 (note_level_for_try): Likewise.
3650 (note_level_for_catch): Likewise.
3651 (finish_named_return_value): Likewise.
3652 (do_pushlevel): Change prototype.
3653 (pending_lang_change): Remove.
3654 * decl.c (begin_scope): Handle sk_block, sk_try, sk_catch,
3655 sk_for.
3656 (note_level_for_for): Remove.
3657 (note_level_for_try): Likewise.
3658 (note_level_for_catch): Likewise.
3659 (maybe_inject_for_scope_var): Remove use of DECL_IN_MEMORY_P.
3660 * parser.c (cp_parser_context_free_list): Make it "deletable".
3661 (cp_parser_template_argument): Remove misleading comment.
3662 * pt.c (tsubst_expr): Remove RETURN_INIT code.
3663 * semantics.c (genrtl_named_return_value): Remove.
3664 (do_pushlevel): Take a scope kind as an argument.
3665 (begin_if_stmt): Adjust.
3666 (begin_while_stmt): Likewise.
3667 (begin_for_stmt): Likewise.
3668 (finish_for_init_stmt): Likewise.
3669 (begin_switch_stmt): Likewise.
3670 (begin_handler): Likewise.
3671 (begin_compound_stmt): Likewise.
3672 (finish_named_return_value): Remove.
3673 (cp_expand_stmt): Remove RETURN_INIT case.
3674 * tree.c (cp_statement_code_p): Remove RETURN_INIT case.
43c6a96a 3675
abda8efe
MM
36762002-12-31 Mark Mitchell <mark@codesourcery.com>
3677
3678 PR c++/9112
3679 * parser.c (cp_parser_direct_declarator): Handle erroneous
3680 parenthesized declarators correctly.
3681
eddcae5a
GDR
36822002-12-31 Gabriel Dos Reis <gdr@integrable-solutions.net>
3683
3684 * cp-tree.h (pending_lang_change): Declare.
3685
c838d82f
MM
36862002-12-30 Mark Mitchell <mark@codesourcery.com>
3687
e5976695
MM
3688 * parser.c (cp_parser_context_free_list): New variable.
3689 (cp_parser_context_new): Use it.
3690 (cp_parser_error): Check return code from
3691 cp_parser_simulate_error.
3692 (cp_parser_simulate_error): Return a value.
3693 (cp_parser_id_expression): Optimize common case.
3694 (cp_parser_class_name): Likewise.
3695 (cp_parser_class_specifier): Adjust call to
3696 cp_parser_late_parsing_default_args.
3697 (cp_parser_lookup_name): Optimize common case.
3698 (cp_parser_late_parsing_for_member): Adjust call to
3699 cp_parser_late_parsing_default_args.
3700 (cp_parser_late_parsing_default_args): Add scope parameter.
3701 (cp_parser_require): Avoid creating the error message unless it's
3702 needed.
3703 (cp_parser_parse_definitely): Place free'd contexts on the free
3704 list.
3705
c838d82f
MM
3706 * parser.c (cp_parser_declaration_seq_opt): Handle pending_lang_change.
3707
c73aecdf
DE
37082002-12-30 David Edelsohn <edelsohn@gnu.org>
3709
3710 * parser.c (cp_parser_parameter_declaration_clause): Treat system
3711 header as extern "C" if NO_IMPLICIT_EXTERN_C undefined.
3712
b599b135
NN
37132002-12-30 Nathanael Nerode <neroden@gcc.gnu.org>
3714
43c6a96a 3715 * config-lang.in, Make-lang.in, operators.def, cp-tree.def:
b599b135
NN
3716 GCC, not GNU CC.
3717
946d5e45
MM
37182002-12-30 Mark Mitchell <mark@codesourcery.com>
3719
afd9b9dd
MM
3720 * parse.y: Remove.
3721 * spew.c: Likewise.
3722 * Make-lang.in (gt-cp-spew.h): Remove.
3723 * cp-tree.h (do_pending_lang_change): Remove.
3724 (do_identifier): Change prototype.
3725 (finish_id_expr): Remove.
3726 * decl.c (lookup_name_real): Remove yylex variable.
3727 * decl2.c (build_expr_from_tree): Adjust call to do_identifier.
3728 * lex.c (init_cpp_parse): Remove.
3729 (reduce_cmp): Likewise.
3730 (token_cmp): Likewise.
3731 (yychar): Likewise.
3732 (lastiddecl): Likewise.
3733 (token_count): Likewise.
3734 (reduce_count): Likewise.
3735 (yyhook): Likewise.
3736 (print_parse_statistics): Likewise.
3737 (do_pending_lang_change): Likewise.
3738 (do_identifier): Remove parsing parameter.
3739 * lex.h (lastiddecl): Remove.
3740 (looking_for_typename): Remove.
3741 (looking_for_template): Likewise.
3742 (pending_lang_change): Likewise.
3743 (yylex): Likewise.
3744 * semantics.c (finish_id_expr): Remove.
43c6a96a 3745
946d5e45
MM
3746 * decl.c (grokdeclarator): Diagnost "extern thread" and "static
3747 thread" correctly.
3748
1c313945
NN
37492002-12-30 Nathanael Nerode <neroden@gcc.gnu.org>
3750
3751 * decl.c, decl2.c, decl.h: GCC, not GNU CC. This is the C++ front
3752 end, not the C front end.
3753
8e268f72
NS
37542002-12-30 Nathan Sidwell <nathan@codesourcery.com>
3755
3756 * cp-tree.h (THUNK_TARGET): New macro.
3757 (THUNK_VIRTUAL_OFFSET): For result thunks it is always a binfo.
3758 (finish_thunk): Remove offset parms.
3759 * class.c (find_final_overrider): Look through thunks.
3760 (get_vcall_index): Use THUNK_TARGET.
3761 (update_vtable_entry_for_fn): Look through thunks. Set covariant
3762 fixed offset here. Adjust finish_thunk call.
3763 (build_vtbl_initializer): Adjust finish_thunk calls.
3764 * mangle.c (mangle_call_offset): Remove superfluous if.
3765 (mangle_thunk): Adjust.
3766 * method.c (make_thunk): Adjust.
3767 (finish_thunk): Adjust.
3768 (thunk_adjust): Remove assert.
3769 (use_thunk): Use THUNK_TARGET
3770 * dump1.c (cp_dump_tree): Adjust thunk dumping.
3771
3772 PR c++/9054
3773 * class.c (layout_class_type): Set TYPE_CONTEXT of type for base.
3774 * dump.c (cp_dump_tree, RECORD_TYPE): Deal with type for base types.
3775
848eed92
GDR
37762002-12-28 Gabriel Dos Reis <gdr@integrable-solutions.net>
3777
3778 Remove traditional C constructs 4/n.
3779 * decl2.c (grok_method_quals, warn_if_unknown_interface,
3780 grok_x_components, cp_build_parm_decl, build_artificial_parm,
3781 maybe_retrofit_in_chrg, grokclassfn, grok_array_decl,
3782 delete_sanity, check_member_template, check_java_method,
3783 check_classfn, finish_static_data_member_decl, grokfield,
3784 grokbitfield, grokoptypename, grok_function_init,
3785 cplus_decl_attributes, constructor_name, defer_fn,
3786 build_anon_union_vars, finish_anon_union, coerce_new_type,
3787 coerce_delete_type, comdat_linkage, maybe_make_one_only,
3788 key_method, import_export_vtable, import_export_class,
3789 output_vtable_inherit, import_export_decl, import_export_tinfo,
3790 build_cleanup, get_guard, get_guard_bits, get_guard_cond,
3791 set_guard, start_objects, finish_objects,
3792 start_static_storage_duration_function,
3793 finish_static_storage_duration_function, get_priority_info,
3794 start_static_initialization_or_destruction,
3795 finish_static_initialization_or_destruction,
3796 do_static_initialization, do_static_destruction,
3797 prune_vars_needing_no_initialization, write_out_vars,
3798 reparse_decl_as_expr, finish_decl_parsing, namespace_ancestor,
3799 add_using_namespace, merge_functions, ambiguous_decl,
3800 lookup_using_namespace, lookup_using_namespace,
3801 qualified_lookup_using_namespace, set_decl_namespace,
3802 decl_namespace, current_decl_namespace, push_decl_namespace,
3803 pop_decl_namespace, push_scope, pop_scope, add_function,
3804 arg_assoc_namespace, arg_assoc_template_arg, arg_assoc,
3805 lookup_arg_dependent, do_namespace_alias,
3806 validate_nonmember_using_decl, do_nonmember_using_decl,
3807 do_toplevel_using_decl, do_local_using_decl,
3808 do_class_using_decl, do_using_directive, check_default_args,
3809 mark_used, handle_class_head): Use C90 prototypings. Use booleans.
3810 * parser.c (cp_parser_class_head): Use booleanss.
3811 * decl.c (walk_globals, walk_vtables): Likewise.
3812 * cp-tree.h (walk_globals_pred, walk_globals_fn, walk_vtables,
3813 walk_globals): Change return type from 'int' to 'bool'.
3814 * rtti.c (init_rtti_processing, build_headof, throw_bad_cast
3815 throw_bad_typeid, get_tinfo_decl_dynamic, typeid_ok_p,
3816 build_typeid, tinfo_name, get_tinfo_decl, get_tinfo_ptr,
3817 get_typeid, ifnonnull, build_dynamic_cast_1, build_dynamic_cast,
3818 qualifier_flags, tinfo_base_init, generic_initializer,
3819 ptr_initializer, dfs_class_hint_mark, ptm_initializer,
3820 dfs_class_hint_unmark, class_hint_flags, class_initializer,
3821 typeinfo_in_lib_p, get_pseudo_ti_init, create_pseudo_type_info,
3822 get_pseudo_ti_desc, create_tinfo_types, emit_support_tinfos,
3823 unemitted_tinfo_decl_p, emit_tinfo_decl): Likewise.
3824 * repo.c (repo_compile_flags, repo_template_declared,
3825 repo_template_defined, repo_class_defined, repo_get_id,
3826 repo_template_used, repo_vtable_used, repo_inline_used,
3827 repo_tinfo_used, repo_template_instantiated, extract_string,
3828 open_repo_file, afgets, init_repo, reopen_repo_file_for_write,
3829 finish_repo): Likewise.
3830 * ptree.c (cxx_print_decl, cxx_print_type, cxx_print_identifier,
3831 cxx_print_xnode): Likewise..
3832 * cp-lang.c (ok_to_generate_alias_set_for_type, cxx_get_alias_set,
3833 cxx_warn_unused_global_decl, cp_expr_size): Likewise.
3834 * cxxfilt.c (demangle_it, print_demangler_list, usage,
3835 standard_symbol_characters, hp_symbol_characters, main, fatal):
43c6a96a 3836 Likewise.
848eed92
GDR
3837 (strip_underscore): Change type from 'int' to 'bool'.
3838 (main): Use boolean constants.
3839
b746c5dc
GDR
38402002-12-28 Gabriel Dos Reis <gdr@integrable-solutions.net>
3841
3842 Remove traditional C constructs 3/n.
3843 * cvt.c (cp_convert_to_pointer, convert_to_pointer_force,
3844 build_up_reference, warn_ref_binding, convert_to_reference,
3845 convert_from_reference, convert_lvalue, cp_convert, ocp_convert,
3846 convert_to_void, convert, convert_force, build_type_conversion,
3847 build_expr_type_conversion, type_promotes_to,
3848 perform_qualification_conversions): Use C90 prototyping style.
3849 * decl2.c (grok_array_decl): Use boolean constant.
3850 (delete_sanity): Likewise.
3851 * typeck.c (build_unary_op): Likewise.
3852 * semantics.c (finish_switch_cond): Likewise.
3853 * parser.c (cp_parser_direct_new_declarator): Likewise.
3854 * init.c (build_new): Likewise.
3855
a723baf1
MM
38562002-12-27 Mark Mitchell <mark@codesourcery.com>
3857
3858 * Make-lang.in (po-generated): Remove parse.c.
3859 (CXX_OBJS): Remove parse.o and spew.o. Add parser.o.
3860 ($(srcdir)/cp/parse.h): Remove target.
3861 ($(srcdir)/cp/parse.c): Likewise.
3862 (gt-cp-parse.h): Likewise.
3863 (gt-cp-parser.h): New target.
3864 (c++.distclean): Do not remove parse.output.
3865 (c++.maintainer-clean): Do not remove parse.c or parse.h.
3866 (cp/spew.o): Remove target.
3867 (cp/lex.o): Adjust dependencies.
3868 (cp/pt.o): Likewise.
3869 (cp/parse.o): Likewise.
3870 (cp/TAGS): Do not mention parse.c.
3871 (cp/parser.o): New target.
3872 * NEWS: Mention the new parser.
3873 * call.c (build_scoped_method_call): Simplify.
3874 (build_method_call): Likewise.
3875 (build_new_function_call): Adjust calls to add_function_candidate
3876 and add_template_candidate.
3877 (build_new_op): Improve handling of erroroneous operands.
3878 (convert_default_arg): Remove circular argument processing.
3879 (name_as_c_string): New function.
3880 (build_new_method_call): Use it.
3881 (perform_implicit_conversion): Use error_operand_p.
3882 * class.c (finish_struct_anon): Use constructor_name_p.
3883 (check_field_decls): Likewise.
3884 (pop_nested_class): Use OVL_NEXT, not OVL_CHAIN.
3885 (resolve_address_of_overloaded_function): Likewise.
3886 (instantiate_type): Tweak pointer-to-member handling.
3887 (get_primary_binfo): Remove incorrect assertion.
3888 * config-lang.in (gtfiles): Add parser.c, remove parse.c.
3889 * cp-tree.h (DEFARG_TOKENS): New macro.
3890 (default_arg): New structure.
3891 (cp_tree_node_structure_enum): Add TS_CP_DEFAULT_ARG.
3892 (lang_tree_node): Add default_arg.
3893 (cp_tree_index): Add CPTI_TYPE_INFO_REF_TYPE.
3894 (type_info_ref_type): New macro.
3895 (saved_scope): Make processing_explicit_instantiation a boolean.
3896 (check_access): New field.
3897 (unparsed_text): Remove.
3898 (language_function): Remove unparsed_inlines.
3899 (error_operand_p): New macro.
3900 (lang_decl): Adjust pending_inline_info.
3901 (DEFARG_POINTER): Remove.
3902 (tag_types): Add typenames.
3903 (lookup_ualified_name): Declare.
3904 (lookup_name_real): Likewise.
3905 (shadow_tag): Adjust prototype.
3906 (get_scope_of_declarator): Declare it.
3907 (process_next_inline): Remove it.
3908 (check_for_missing_semicolon): Likewise.
3909 (maybe_get_template_decl_from_type_decl): Declare it.
3910 (finish_label_stmt): Adjust prototype.
3911 (finish_non_static_data_meber): Declare it.
3912 (finish_pseudo_destructor_call_expr): Rename to ...
3913 (finish_pseudo_destructor_expr): ... this.
3914 (finish_compound_literal): Declare it.
3915 (begin_inline_definitions): Remove it.
3916 (init_spew): Remove.
3917 (peekyylex): Likewise.
3918 (arbitrate_lookup): Likewise.
3919 (frob_opname): Likewise.
3920 (maybe_snarf_defarg): Likewise.
3921 (add_defarg_fn): Likewise.
3922 (do_pending_defargs): Likewise.
3923 (done_pending_defargs): Likewise.
3924 (unprocessed_defarg_fn): Likewise.
3925 (replace_defarg): Likewise.
3926 (end_input): Likewise.
3927 (get_overloaded_fn): Likewise.
3928 * cvt.c (convert_to_reference): Improve error handling.
3929 * decl.c (lookup_name_real): Do not declare it static.
3930 (maybe_push_to_top_level): Set check_access.
3931 (identifier_type_value): Adjust call to lookup_name_real.
3932 (lookup_qualified_name): New method.
3933 (lookup_name_real): Remove special-case parsing code.
3934 (lookup_name-nonclass): Adjust call to lookup_name_real.
3935 (lookup_name_namespace_only): Likewise.
3936 (lookup_name): Likewise.
3937 (check_tag_decl): Return the type declared.
3938 (shadow_tag): Likewise.
3939 (register_dtor_fn): Tweak check_access.
3940 (grokfndecl): Use constructor_name_p.
3941 (get_scope_of_declarator): New function.
3942 (grokdeclarator): Obscure tweaks for slightly different declarator
3943 representations.
3944 (start_method): Return error_mark_node to indicate failure.
43c6a96a 3945 (cp_tree_node_structure_enum): Use TS_CP_DEFAULT_ARG for DEFAULT_ARGs.
a723baf1
MM
3946 * decl2.c (constructor_name_full): Simplify.
3947 (constructor_name): Use it.
3948 (build_expr_from_tree): Adjust for changes to do new parser.
3949 (push_scope): Improve robustness.
3950 (validate_nonmember_using_decl): Process declarations, not names.
3951 (do_class_using_decl): Likewise.
3952 (handle_class_head): Do not mess with CLASSTYPE_DECLARED_CLASS
3953 here.
3954 * error.c (dump_expr): Handle IDENTIFIER_NODEs and BASELINKs.
3955 * expr.c (cxx_expand_expr): Handle BASELINKs.
3956 * init.c (member_init_ok_or_else): Issue more errors.
3957 (build_offset_ref): Tweak handling of FUNCTION_DECLs.
3958 * lex.c: Do not include parse.h.
3959 (yypring): Do not declare.
3960 (yylval): Likewise.
3961 (make_reference_declarator): Remove error-generating code.
3962 (rid_to_yy): Remove.
3963 (cxx_init): Do not call init_spew.
3964 (yypring): Remove.
3965 (check_for_missing_semicolon): Remove.
3966 * lex.h (got_scope): Remove.
3967 (got_object): Remove.
3968 * method.c (hack_identifier): Use finish_non_static_data_member.
3969 (implicitly_declare_fn): Adjust use of constructor_name.
3970 * parser.c: New file.
3971 * pt.c (parse.h): Do not include it.
3972 (maybe_get_template_decl_from_template): Do not declare it.
3973 (finish_member_template_decl): Tweak.
3974 (begin_explicit_instantiation): Adjust for
3975 processing_explicit_instantiation being boolean.
3976 (end_explicit_instantiation): Likewise.
3977 (maybe_process_partial_specialization): Tighten specialization
3978 test.
3979 (retrieve_local_specialization): Adjust ue of hash table.
3980 (eq_local_specializations): New function.
3981 (register_local_specialization): Likewise.
3982 (push_template_decl_real): Remove unnecessary test.
3983 (maybe_get_template_decl_from_type_decl): Don't make it static.
3984 (for_each_template_parm_r): Handle TYPEOF_TYPE.
3985 (tsubst_copy): Use retrieive_local_specialization to handle
3986 PARM_DECL. Adjust handling of CONST_DECLs. Handle BASELINKs.
3987 Handle COMPONENT_REFs with pseudo-destructor-expressions.
3988 Simplify handling of CALL_EXPR and METHOD_CALL_EXPR.
3989 (tsubst_expr): Pass decls, not names, to do_local_using_decl.
3990 (unify): Tweak handling of CONST_DECLs.
3991 (regenerate_decl_from_template): Use push_nested_class.
3992 (template_for_substitution): New funciton.
3993 (instantiate_decl): Use it. Register parameters as local
3994 specializations.
3995 * rtti.c (init_rtti_processing): Set type_info_ref_type.
3996 (build_typeid): Use it.
3997 (get_typeid): Likeise.
3998 * search.c (accessible_p): Use check_access, not
3999 flag_access_control.
4000 (adjust_result_of_qualified_name_lookup): Pay attention to the
4001 context_class.
4002 * semantics.c (finish_asm_stmt): Adjust error handling.
4003 (finish_label_stmt): Return the statement.
4004 (finish_non_static_data_member): New function.
4005 (finish_class_expr): Handle BASELINKs.
4006 (finish_call_expr): Handle PSEUDO_DTOR_EXPR.
4007 (finish_object_call_expr): Simplify handling during templates.
4008 (finish_pseudo_destructor_call_expr): Rename to ...
4009 (finish_pseudo_dtor_expr): ... this.
4010 (finish_compound_literal): New function.
4011 (begin_inline_definitions): Remove.
4012 (finish_sizeof): Remove special template handling.
4013 * spew.c: Do not include parse.h.
4014 * tree.c (get_overloaded_fn): Remove.
4015 * typeck.c (build_class_member_access_expr): Handle
4016 PSEUDO_DTOR_EXPR. Adjust handling of static member functions.
4017 (lookup_destructor): New function.
4018 (finish_class_member_access_expr): Use it.
4019 (convert_arguments): Simplify.
4020 (build_unary_op): Handle BASELINKs.
43c6a96a 4021
aac1406f
NS
40222002-12-26 Nathan Sidwell <nathan@codesourcery.com>
4023
eab5474f
NS
4024 PR c++/4803
4025 * decl2.c (mark_used): Defer inline functions.
4026 (finish_file): Merge deferred_fns loops. Check all used
4027 inline functions have a definition.
4028 * method.c (make_thunk): Thunks are not inline.
4029
aac1406f
NS
4030 PR c++/5116, c++/764
4031 * call.c (build_new_op): Make sure template class operands are
4032 instantiated.
4033
b9201622
NS
40342002-12-24 Nathan Sidwell <nathan@codesourcery.com>
4035
3e14cd30
NS
4036 PR C++/7964
4037 * cp-tree.h (resolve_scoped_fn_name): Prototype.
4038 * call.c (resolve_scoped_fn_name): New function. Deal with
4039 more template expansion. Broken out of ...
4040 * parse.y (parse_finish_call_expr): ... here. Call it.
4041 * decl2.c (build_expr_from_tree, CALL_EXPR): Use
4042 resolve_scoped_fn_name and build_call_from_tree.
4043
b9201622
NS
4044 PR c++/9053
4045 * decl.c (duplicate_decls): Templates may be disambiguated by
4046 return type.
43c6a96a 4047
b9201622
NS
4048 PR c++/8702
4049 * decl2.c (check_classfn): Use lookup_fnfield_1. List all
4050 conversion operators on failure.
4051
94be8403
GDR
40522002-12-23 Gabriel Dos Reis <gdr@integrable-solutions.net>
4053
b746c5dc
GDR
4054 Remove traditional C constructs 2/n.
4055 * call.c (tourney, build_field_call, equal_functions, joust,
4056 compare_ics, build_over_call, build_java_interface_fn_ref,
4057 convert_like_real, op_error, build_object_call, resolve_args,
4058 build_vfield_ref, check_dtor_name, build_scoped_method_call,
4059 build_addr_func, build_call, build_method_call, null_ptr_cst_p,
4060 sufficient_parms_p, build_conv, non_reference, strip_top_quals,
4061 standard_conversion, reference_related_p,
4062 reference_compatible_p, convert_class_to_reference,
4063 direct_reference_binding, reference_binding,
4064 ,implicit_conversion, is_complete, promoted_arithmetic_type_p,
4065 add_template_conv_candidate, any_viable, any_strictly_viable,
4066 build_this, splice_viable, print_z_candidates,
4067 build_user_type_conversion, build_new_function_call,
4068 conditional_conversion, build_conditional_expr, build_new_op,
4069 build_op_delete_call, enforce_access, call_builtin_trap,
4070 convert_arg_to_ellipsis, build_x_va_arg, cxx_type_promotes_to,
4071 convert_default_arg, type_passed_as, convert_for_arg_passing,
4072 in_charge_arg_for_name, is_properly_derived_from,
4073 maybe_handle_implicit_object, maybe_handle_ref_bind,
4074 source_type, add_warning, can_convert, can_convert_arg,
4075 perform_implicit_conversion, can_convert_arg_bad,
4076 initialize_reference, add_conv_candidate,
4077 add_template_candidate_real, add_template_candidate): Ansify.
94be8403 4078
081cebb2
NS
40792002-12-22 Nathan Sidwell <nathan@codesourcery.com>
4080
4081 PR c++/8572
4082 * cp-tree.h (grokoptypename): Add SCOPE parameter.
4083 * decl2.c (grokoptypename): Add SCOPE parameter. tsubst the type
4084 if in a template scope.
4085 * parse.y (unoperator): Return the scope.
4086 (operator_name): Adjust grokoptypename call.
4087
4f09be91
KL
40882002-12-22 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4089
4090 * cp-tree.h (make_unbound_class_template): Use tsubst_flags_t.
4091 * decl.c (make_unbound_class_template): Adjust. Check for tf_error.
4092 * pt.c (tsubst) [OFFSET_TYPE]: Check for tf_error.
4093
4639c5c6
KH
40942002-12-20 Kazu Hirata <kazu@cs.umass.edu>
4095
4096 * ChangeLog: Fix a typo.
4097 * class.c: Fix comment typos.
4098 * cp-tree.h: Likewise.
4099
0ca7178c
JM
41002002-12-18 Jason Merrill <jason@redhat.com>
4101
4102 Handle anonymous unions at the tree level.
4103 C++ ABI change: Mangle anonymous unions using the name of their
4104 first named field (by depth-first search). Should not cause
4105 binary compatibility problems, though, as the compiler previously
4106 didn't emit anything for affected unions.
4107 * cp-tree.def (ALIAS_DECL): New tree code.
4108 * decl2.c (build_anon_union_vars): Build ALIAS_DECLs. Return the
4109 first field, not the largest.
4110 (finish_anon_union): Don't mess with RTL. Do set DECL_ASSEMBLER_NAME,
4111 push the decl, and write it out at namespace scope.
4112 * decl.c (lookup_name_real): See through an ALIAS_DECL.
4113 (pushdecl): Add namespace bindings for ALIAS_DECLs.
4114 * rtti.c (unemitted_tinfo_decl_p): Don't try to look at the name
4115 of a decl which doesn't have one.
4116 * typeck.c (build_class_member_access_expr): Don't recurse if
4117 we already have the type we want.
4118
da9701a6
KL
41192002-12-18 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4120
4121 PR c++/8099
4122 * friend.c (make_friend_class): Allow partial specialization
4123 when declaration is not a template friend.
4124
cab7a9a3
KL
41252002-12-18 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4126
4127 PR c++/3663
4128 * pt.c (lookup_template_class): Copy TREE_PRIVATE and
4129 TREE_PROTECTED to created decl nodes.
4130
50cb9059
MM
41312002-12-18 Mark Mitchell <mark@codesourcery.com>
4132
4133 * class.c (build_base_field): Do not set DECL_PACKED on the
4134 FIELD_DECL.
4135
e220f0a4
GDR
41362002-12-18 Gabriel Dos Reis <gdr@integrable-solutions.net>
4137
4138 * cp-tree.h (struct tree_srcloc): Use location_t.
4139 (SOURCE_LOCUS): New.
4140 (SRCLOC_FILE, SRCLOC_LINE): Adjust.
4141
efc7052d
JM
41422002-12-17 Jason Merrill <jason@redhat.com>
4143
4144 * decl.c (finish_function): Also complain about no return in
4145 templates.
43c6a96a 4146 * semantics.c (finish_return_stmt): Also call check_return_expr in
efc7052d
JM
4147 templates.
4148 * typeck.c (check_return_expr): In a template, just remember that we
4149 saw a return.
4150
9f175208
JM
41512002-12-16 Jason Merrill <jason@redhat.com>
4152
89ea02fb
JM
4153 * semantics.c (simplify_aggr_init_exprs_r): Don't change the type
4154 of the CALL_EXPR.
4155
9f175208
JM
4156 * semantics.c (do_pushlevel): Call pushlevel after adding the
4157 SCOPE_STMT.
4158 (do_poplevel): Call poplevel before adding the SCOPE_STMT.
4159 * parse.y (function_body): Go back to using compstmt.
4160 * decl.c (pushdecl): Skip another level to get to the parms level.
4161
4162 * call.c (build_new_method_call): Use is_dummy_object to determine
4163 whether or not to evaluate the object parameter to a static member
4164 function.
4165
4977bab6
ZW
41662002-12-14 Jason Merrill <jason@redhat.com>
4167
4168 * semantics.c (simplify_aggr_init_exprs_r): Also prepend the
4169 return slot for normal functions. Set CALL_EXPR_HAS_RETURN_SLOT_ADDR.
4170 * tree.c (build_cplus_new): If the type isn't TREE_ADDRESSABLE,
4171 don't bother with an AGGR_INIT_EXPR.
4172 (cp_copy_res_decl_for_inlining): If the type isn't TREE_ADDRESSABLE,
4173 just generate a new decl normally. Take return slot parm.
4174 * cp-tree.h: Adjust prototype.
4175
75c525d7
GDR
41762002-12-13 Gabriel Dos Reis <gdr@integrable-solutions.net>
4177
4178 PR C++/8031
43c6a96a 4179 * cvt.c (convert_to_pointer_force): Don't try comparing against
75c525d7
GDR
4180 erronous type.
4181
8c6ae51f
GK
41822002-12-13 Geoffrey Keating <geoffk@apple.com>
4183
4184 * cp-tree.h: Have the multiple-include guards around
4185 the entire file.
4186
4977bab6
ZW
41872002-12-10 David Edelsohn <edelsohn@gnu.org>
4188
4189 * cp/spew.c (feed_input): Change limit to last_pos and pos to cur_pos
4190 for SPEW_DEBUG.
4191 (snarf_method): Same.
4192 (snarf_defarg): Same.
4193
d23faea1
MM
41942002-12-10 Mark Mitchell <mark@codesourcery.com>
4195
4196 PR c++/8372
4197 * pt.c (tsubst_copy): Handle destructor names more correctly.
4198
3932057c 41992002-12-10 Matt Austern <austern@apple.com>
d23faea1 4200
3932057c 4201 * cp-tree.h: get rid of needs_virtual_reinit bit.
43c6a96a 4202
dcba9b0f
MM
42032002-12-09 Mark Mitchell <mark@codesourcery.com>
4204
43c6a96a 4205 * NEWS: Document removal of in-class initialization extension for
dcba9b0f
MM
4206 static data members of non-arithmetic, non-enumeration type.
4207 * decl.c (check_static_variable_definition): Do not allow that
4208 extension.
4209 * decl2.c (grokfield): Do not call digest_init when processing
4210 templates.
4211
42b99e03
KG
42122002-12-05 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4213
4214 * error.c (dump_expr): Fix format specifier warning.
4215
6c73ad72
GK
42162002-12-04 Geoffrey Keating <geoffk@apple.com>
4217
4218 * class.c (finish_struct_1): Correct comment.
4219 * cp-tree.c (DECL_SORTED_FIELDS): Likewise.
4220
8c048a52
GDR
42212002-12-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
4222
4223 PR C++/8799
4224 * error.c (dump_expr): Don't ever try to dump a non-existent
43c6a96a 4225 expression.
8c048a52 4226
4977bab6
ZW
42272002-12-03 Nathan Sidwell <nathan@codesourcery.com>
4228
4229 Implement covariant returns.
4230 * cp-tree.h (IS_AGGR_TYPE_2): Remove.
4231 (struct lang_decl_flags): Add this_thunk_p flag.
4232 Rename vcall_offset to virtual_offset.
4233 (struct lang_decl): Rename delta to fixed_offset.
4234 (DECL_THIS_THUNK_P, DECL_RESULT_THUNK_P): New #defines.
4235 (SET_DECL_THUNK_P): Add THIS_ADJUSTING arg.
4236 (THUNK_DELTA, THUNK_VCALL_OFFSET): Rename to ...
4237 (THUNK_FIXED_OFFSET, THUNK_VIRTUAL_OFFSET): ... here.
4238 (make_thunk): Add this_adjusting arg.
4239 (finish_thunk): Declare.
4240 (mangle_thunk): Add this_adjusting arg.
4241 * class.c (get_vcall_index): Use base function for lookup.
4242 (update_vtable_entry_for_fn): Generate covariant thunk.
4243 (finish_struct_1): Set DECL_VINDEX to NULL for thunks.
4244 (build_vtbl_initializer): Use base function for lookup.
4245 Finish covariant thunk here. Adjust thunk generation.
4246 * dump.c (cp_dump_tree): Simplify DECL_GLOBAL_[CD]TOR_P handling.
4247 Adjust thunk dumping.
4248 * mangle.c (mangle_call_offset): New function.
4249 (mangle_thunk): Adjust for covariant thunks.
4250 * method.c (make_thunk): Adjust. Do not set name here.
4251 (finish_thunk): New function. Set name here.
4252 (use_thunk): Generate covariant thunks too.
4253 (thunk_adjust): New function.
4254 * search.c (covariant_return_p): Remove. Fold into ...
4255 (check_final_overrider): ... here. Simplify.
4256 * semantics.c (emit_associated_thunks): Walk covariant thunk lists.
4257
c203334d
JM
42582002-12-03 Jason Merrill <jason@redhat.com>
4259
c246c65d
JM
4260 PR c++/8674
4261 * call.c (build_over_call): Check specifically for TARGET_EXPR
4262 when eliding.
4263
4264 PR c++/8461, c++/8625
4265 * call.c (convert_for_arg_passing): Don't mess with error_mark_node.
4266 (cp_convert_parm_for_inlining): Remove.
43c6a96a 4267 * cp-lang.c (LANG_HOOKS_TREE_INLINING_CONVERT_PARM_FOR_INLINING):
c246c65d
JM
4268 Remove.
4269 * cp-tree.h (ADDR_IS_INVISIREF): Remove.
4270 * except.c (stabilize_throw_expr): Remove ADDR_IS_INVISIREF code.
4271
c203334d
JM
4272 * call.c (build_user_type_conversion_1): Don't set ICS_BAD_FLAG on
4273 an ambiguous conversion.
4274
ee7ecb29
MM
42752002-12-03 Mark Mitchell <mark@codesourcery.com>
4276
4277 PR c++/8688
4278 * decl.c (reshape_init): Handle erroneous initializers.
4279
5089de93
MM
42802002-12-02 Mark Mitchell <mark@codesourcery.com>
4281
4282 PR c++/8720
4283 * spew.c (remove_last_token): Make sure that last_chunk is set
4284 correctly.
4285
4286 PR c++/8615
4287 * error.c (dump_expr): Handle character constants with
4288 TREE_OVERFLOW set.
43c6a96a 4289
218e0eb6
KL
42902002-12-02 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4291
4292 DR 180
4293 * decl.c (grokdeclarator): Require class-key for all friend class.
4294 Output the correct type and context in the error message.
4295
a82d6da5
MM
42962002-12-01 Mark Mitchell <mark@codesourcery.com>
4297
94fc547c
MM
4298 PR c++/5919
4299 * pt.c (unify): Use variably_modified_type_p to test validity of
4300 template argument types.
43c6a96a 4301
a82d6da5
MM
4302 PR c++/8727
4303 * cp-tree.h (lang_type_class): Add typeinfo_var.
4304 (CLASSTYPE_TYPEINFO_VAR): New macro.
4305 * rtti.c (get_tinfo_decl): Use it.
4306
4307 PR c++/8663
4308 * init.c (expand_member_init): Always get the main variant of a
4309 base class.
4310
c9f8536c
MM
43112002-12-01 Mark Mitchell <mark@codesourcery.com>
4312
4313 PR c++/8332
4314 PR c++/8493
4315 * decl.c (cxx_init_decl_processing): Use size_type_node, not
4316 c_size_type_node.
4317 * decl2.c (coerce_new_type): Likewise.
4318 * except.c (do_allocate_exception): Likewise.
4319
4977bab6
ZW
43202002-11-30 Zack Weinberg <zack@codesourcery.com>
4321
4322 * call.c, class.c, cp-lang.c, cvt.c, cxxfilt.c, decl.c, decl2.c,
4323 dump.c, error.c, except.c, expr.c, friend.c, g++spec.c, init.c,
4324 lex.c, mangle.c, method.c, optimize.c, parse.y, pt.c, ptree.c,
4325 repo.c, rtti.c, search.c, semantics.c, spew.c, tree.c, typeck.c,
4326 typeck2.c: Include coretypes.h and tm.h.
4327 * Make-lang.in: Update dependencies.
4328
c17707f1
MM
43292002-11-30 Mark Mitchell <mark@codesourcery.com>
4330
328de7c2
MM
4331 PR c++/8227
4332 * decl.c (layout_var_decl): Deal gracefully with erroneous types.
4333 (check_initializer): Validate the type of the initialized
4334 variable, even if the initializer is absent.
4335 * typeck.c (cp_type_quals): Deal gracefully with erroneous types.
43c6a96a 4336
c17707f1
MM
4337 PR c++/8214
4338 * typeck.c (convert_for_assignment): Do not use
4339 decl_constant_value on the operand.
4340
65f8b0fb
MM
4341 PR c++/8511
4342 * pt.c (instantiate_decl): Handle template friends defined outside
4343 of the class correctly.
4344
f6a83eb0
JB
43452002-11-29 Joe Buck <jbuck@synopsys.com>
4346
4347 * parse.y (class_head_defn): Set CLASSTYPE_DECLARED_CLASS for
4348 anonymous structs.
43c6a96a 4349
ff944b49
MM
43502002-11-29 Mark Mitchell <mark@codesourcery.com>
4351
4352 * class.c (walk_subobject_offsets): Recur on binfos as well as on
4353 types.
4354 (layout_nonempty_base_or_field): Pass it a binfo when processing a
4355 base class.
4356 (layout_empty_base): Likewise.
4357 (build_base_field): Likewise.
43c6a96a 4358
21b3d0ba
MM
43592002-11-27 Mark Mitchell <mark@codesourcery.com>
4360
4361 * class.c (build_base_field): Make sure we get the canonical base
4362 when descending through primary bases.
4363
a16f2357
GK
43642002-11-26 Geoffrey Keating <geoffk@apple.com>
4365
4366 * decl.c (check_initializer): Don't error on initialisation of
4367 a scalar with a brace-enclosed expression.
4368
688f6688
NS
43692002-11-26 Nathan Sidwell <nathan@codesourcery.com>
4370
4371 * cp-tree.h (DECL_LANG_FLAG_4): Document more uses.
4372 (template_parms_equal): Remove prototype.
4373 * typeck.c (buuld_indirect_ref): Reformat.
4374
4977bab6
ZW
43752002-11-25 Jason Merrill <jason@redhat.com>
4376
4377 * init.c (build_vec_init): Use a FOR_STMT instead of an IF_STMT
4378 and a DO_STMT.
4379
b82ddab4
MM
43802002-11-25 Mark Mitchell <mark@codesourcery.com>
4381
2003cd37
MM
4382 * tree.c (cp_build_qualified_type_real): Correct handling of
4383 array types.
4384 * class.c (walk_subobject_offsets): Fix thinko.
4385 (build_base_field): Record offsets of empty bases in primary
4386 virtual bases.
4387 (layout_class_type): Record offsets of empty bases in fields.
43c6a96a 4388
b82ddab4
MM
4389 * search.c (is_subobject_of_p_1): Fix thinko.
4390 (lookup_field_queue_p): Likewise.
4391
8a874cb4
MM
43922002-11-24 Mark Mitchell <mark@codesourcery.com>
4393
4394 * class.c (layout_class_type): Reuse tail padding when laying out
4395 virtual bases.
4396
05abed76
MM
43972002-11-22 Mark Mitchell <mark@codesourcery.com>
4398
4399 * rtti.c (qualifier_flags): Fix thinko.
4400
4977bab6
ZW
44012002-11-21 Gabriel Dos Reis <gdr@integrable-solutions.net>
4402
4403 Remove traditional C constructs 1/n.
4404 * cp-tree.h (init_method, set_mangled_name_for_decl,
4405 build_opfncall, hack_identifier, make_thunk, use_thunk,
4406 synthesize_method, implicitly_declare_fn,
4407 skip_artificial_parms_for, optimize_function, calls_setjmp_p,
4408 maybe_clone_body): Remove use of PARAMS.
4409
4410 * method.c (do_build_assign_ref, do_build_copy_constructor,
4411 synthesize_exception_spec, locate_dtor, locate_ctor, locate_copy):
4412 Likewise.
4413 (synthesize_method): Use 'bool' type and constants instead of
4414 'int'.
4415 (locate_copy): Likewise.
4416 (implicitly_declare_fn): Likewise.
4417
4418 * optimize.c (calls_setjmp_r, update_cloned_parm, dump_function):
4419 Remove old-style declaration.
4420 (maybe_clone_body): Use 'bool' type and constants.
4421
1c83ea9f
GN
44222002-11-21 Glen Nakamura <glen@imodulo.com>
4423
4424 PR c++/8342
4425 * typeck.c (get_member_function_from_ptrfunc): Make sure that a
4426 SAVE_EXPR for instance_ptr doesn't get evaluated first inside one
4427 of the branches of a COND_EXPR.
4428
ad2ae3b2
MM
44292002-11-19 Mark Mitchell <mark@codesourcery.com>
4430
4431 * pt.c (for_each_template_parm): Free allocated memory.
4432 * search.c (is_subobject_of_p_1): New function.
4433 (is_subobject_of_p): Avoid walking virtual bases multiple times.
4434
f3226a90
JT
44352002-11-19 Jason Thorpe <thorpej@wasabisystems.com>
4436
4437 * g++spec.c (lang_specific_spec_functions): New.
4438
90024bdc
KH
44392002-11-15 Kazu Hirata <kazu@cs.umass.edu>
4440
4441 * ChangeLog: Follow spelling conventions.
4442 * class.c: Likewise.
4443 * decl2.c: Likewise.
4444
fa7b533b
ZW
44452002-11-14 Zack Weinberg <zack@codesourcery.com>
4446
4447 * search.c (dfs_push_decls): Do not try to reorder elements
4448 3..n of method_vec if method_vec has only two elements.
4449 Reverse order of two tests to avoid accessing unallocated
4450 memory.
4451
95675950
MM
44522002-11-14 Mark Mitchell <mark@codesourcery.com>
4453
4454 * class.c (dfs_find_final_overrider): Adjust so that the most
4455 derived object is a binfo, rather than a class type.
4456 (find_final_overrider): Likewise.
4457 (add_vcall_offset_vtbl_entries_1): Simplify accordingly.
4458 (add_vcall_offset): Likewise.
4459
5c74d5b0
KL
44602002-11-09 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4461
4462 PR c++/8389
4463 * pt.c (instantiate_template): Push class scope for member
4464 functions.
4465 (get_mostly_instantiated_function_type): Likewise. Don't call
4466 tsubst on context. Remove CONTEXTP and TPARMSP parameters.
4467 * cp-tree.h (get_mostly_instantiated_function_type): Adjust.
4468 * mangle.c (write_encoding, write_unqualified_name): Adjust.
4469
4f2c9d7e
MM
44702002-11-07 Mark Mitchell <mark@codesourcery.com>
4471
e6a66567
MM
4472 * class.c (add_vcall_offset_vtbl_entries_1): Correct ordering of
4473 vcall offfsets. Split out ...
4474 (add_vcall_offset): ... new function.
4475
4f2c9d7e
MM
4476 PR c++/8338
4477 * pt.c (for_each_template_parm): Add htab parameter.
4478 (process_partial_specialization): Adjust call.
4479 (push_template_decl_real): Likewise.
4480 (pair_fn_data): Add visited.
4481 (for_each_template_parm_r): Avoid walking duplicates more than
4482 once.
4483 (uses_template_parms): Adjust call to for_each_template_parm.
4484
f72ab53b
MM
44852002-11-07 Mark Mitchell <mark@codesourcery.com>
4486
4487 * class.c (add_implicitly_declared_members): Put implicitly
4488 declared functions at the end of TYPE_METHODs when -fabi-version
4489 is at least 2.
4490
0a288b9a
GK
44912002-11-05 Geoffrey Keating <geoffk@apple.com>
4492
4493 * decl2.c (finish_file): Correct spelling.
4494
548502d3
MM
44952002-11-03 Mark Mitchell <mark@codesourcery.com>
4496
4497 * call.c (build_special_member_call): Do not try to lookup VTTs by
4498 name.
4499 * class.c (vtbl_init_data): Add generate_vcall_entries.
4500 (get_vtable_decl): Do not look up virtual tables by name.
4501 (copy_virtuals): Do not use BV_USE_VCALL_INDEX_P.
4502 (set_primary_base): Do not set CLASSTYPE_RTTI.
4503 (determine_primary_base): Likewise.
4504 (get_matching_virtual): Remove.
4505 (get_vcall_index): New function.
4506 (update_vtable_entry_for_fn): Do not try to use virtual thunks
4507 when they are not required. Assign vcall indices at this point.
4508 (finish_struct_1): Do not set CLASSTYPE_NEEDS_VIRTUAL_REINIT.
4509 Do update dynamic_classes.
4510 (build_vtt): Do not add VTTs to the symbol table.
4511 (build_ctor_vtbl_group): Likewise.
4512 (build_vtbl_initializer): Simplify handling of vcall indices.
4513 (build_vcall_offset_vtbl_entries): Pretend to build vcall offsets
4514 for the most derived class.
4515 (add_vcall_offset_vtbl_entries_1): But do not actually add them to
4516 the vtable.
4517 * cp-tree.h (dynamic_classes): New macro.
4518 (lang_type_class): Remove rtti. Add vtables. Add vcall_indices.
4519 (CLASSTYPE_RTTI): Remove.
4520 (CLASSTYPE_NEEDS_VIRTUAL_REINIT): Remove.
4521 (CLASSTYPE_VCALL_INDICES): New macro.
4522 (CLASSTYPE_VTABLES): Likewise.
4523 (BV_USE_VCALL_INDEX_P): Remove.
4524 (build_vtable_path): Remove.
4525 * decl2.c (finish_vtable_vardecl): Remove.
4526 (key_method): Remove #if 0'd code.
4527 (finish_vtable_vardecl): Rename to ...
4528 (maybe_emit_vtables): ... this.
4529 (finish_file): Use it.
4530 * search.c (look_for_overrides_here): Update comment.
4531
04d57dd5
ZW
45322002-11-01 Zack Weinberg <zack@codesourcery.com>
4533
4534 PR c/7353 redux
4535 * decl2.c (grokfield): Reject TYPE_DECLs with initializers.
4536
bab076f7
JM
45372002-10-30 Jason Merrill <jason@redhat.com>
4538
4539 PR c++/8186
4540 * cp-tree.h (ADDR_IS_INVISIREF): New macro.
4541 * call.c (convert_for_arg_passing): Set it.
4542 * except.c (stabilize_throw_expr): Recurse for such an arg.
4543
14b4829d
MM
45442002-10-31 Mark Mitchell <mark@codesourcery.com>
4545
4546 * cp-tree.h (lang_decl_flags): Remove init_priority.
4547 (lang_decl): Add delta.
4548 (GLOBAL_INIT_PRIORITY): Remove.
4549 (THUNK_DELTA): Revise definition.
4550 * decl2.c (start_objects): Don't set GLOBAL_INIT_PRIORITY.
4551 * dump.c (cp_dump_tree): Don't dump it.
4552
8c081e84
MM
45532002-10-30 Mark Mitchell <mark@codesourcery.com>
4554
4555 PR c++/8160
4556 * typeck2.c (process_init_constructor): Call complete_array_type.
4557
4558 PR c++/8149
4559 * decl.c (make_typename_type): Issue errors about invalid results.
04d57dd5 4560
7088fca9
KL
45612002-10-30 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4562
4563 Core issue 287, PR c++/7639
4564 * cp-tree.h (lang_type_class): Add decl_list field.
4565 (CLASSTYPE_DECL_LIST): New macro.
4566 (maybe_add_class_template_decl_list): Add declaration.
4567 * class.c (duplicate_tag_error): Initialize CLASSTYPE_DECL_LIST.
4568 (unreverse_member_declarations): Reverse CLASSTYPE_DECL_LIST.
4569 (maybe_add_class_template_decl_list): New function.
4570 (add_implicitly_declared_members): Use it.
4571 * decl.c (maybe_process_template_type_declaration): Likewise.
4572 (pushtag): Likewise.
4573 * friend.c (add_friend): Likewise.
4574 (make_friend_class): Likewise.
4575 * semantics.c (finish_member_declaration): Likewise.
4576 (begin_class_definition): Initialize CLASSTYPE_DECL_LIST.
4577 * pt.c (instantiate_class_template): Use CLASSTYPE_DECL_LIST
4578 to process members and friends in the order of declaration.
4579
5633b37c
MM
45802002-10-29 Mark Mitchell <mark@codesourcery.com>
4581
4582 PR c++/8287
4583 * decl.c (finish_destructor_body): Create the label to jump to
4584 when returning from a destructor here.
4585 (finish_function_body): Rather than here.
4586
f65e1183
ZW
45872002-10-25 Zack Weinberg <zack@codesourcery.com>
4588
4589 PR c++/7266
4590 * decl.c (grokdeclarator): Check that TREE_OPERAND 0 of a
4591 SCOPE_REF is not null before dereferencing it.
4592
bb5e8a7f
MM
45932002-10-25 Mark Mitchell <mark@codesourcery.com>
4594
e93ee644
MM
4595 * call.c (build_over_call): Use DECL_CONTEXT, not
4596 DECL_VIRTUAL_CONTEXT.
4597 * class.c (modify_vtable_entry): Don't mess with
4598 DECL_VIRTUAL_CONTEXT.
4599 (set_vindex): Remove.
4600 (set_primary_base): Remove vfuns_p parameter.
4601 (determine_primary_base): Likewise.
4602 (modify_all_vtables): Likewise.
4603 (layout_class_type): Likewise. Adjust calls to other functions
4604 accordingly.
4605 (finish_struct_1): Adjust calls to modified functions. Set
4606 DECL_VINDEX here.
4607 * cp-tree.h (lang_type_class): Remove vsize.
4608 (CLASSTYPE_VSIZE): Remove.
4609 (lang_decl): Remove thunks.
4610 (DECL_THUNKS): Adjust.
4611 (DECL_VIRTUAL_CONTEXT): Remove.
4612 (duplicate_decls): Don't copy it.
4613 * pt.c (build_template_decl): Don't set it.
4614 (tsubst_decl): Likewise.
4615 * typeck.c (expand_ptrmemfunc_cst): Don't use it.
04d57dd5 4616
bb5e8a7f
MM
4617 * class.c (build_vtbl_initializer): Don't use build_vtable_entry.
4618 (build_vtable_entry): Remove.
4619 * cp-tree.h (BINFO_VIRTUALS): Expand documentation.
4620 (lang_decl): Add thunks.
4621 (DECL_THUNKS): New macro.
4622 * decl.c (duplicate_decls): Copy it.
4623 * method.c (make_thunk): Simplify, and add thunks to DECL_THUNKS.
4624 * semantics.c (emit_associated_thunks): Simplify.
f65e1183 4625
6eb35968
DE
46262002-10-24 David Edelsohn <edelsohn@gnu.org>
4627
4628 PR c++/7228
4629 * cp-tree.h (CLASSTYPE_READONLY_FIELDS_NEED_INIT): Check that
4630 lang_type structure exists before accessing field.
4631 (SET_CLASSTYPE_READONLY_FIELDS_NEED_INIT): New macro.
4632 (CLASSTYPE_REF_FIELDS_NEED_INIT): Similar.
4633 (SET_CLASSTYPE_REF_FIELDS_NEED_INIT): New macro.
4634 * class.c (check_field_decls): Use new macros.
4635 * typeck2.c (process_init_constructor): Remove redundant check for
4636 existence of lang_type structure.
4637
0cee073d
MM
46382002-10-24 Mark Mitchell <mark@codesourcery.com>
4639
ba9a991f
MM
4640 * class.c (end_of_base): New method.
4641 (end_of_class): Use it. Check indirect virtual bases.
4642
0cee073d
MM
4643 * class.c (check_field_decls): Fix typo.
4644
e6f052b7
MM
46452002-10-23 Mark Mitchell <mark@codesourcery.com>
4646
6b607ffd
MM
4647 PR c++/8067
4648 * decl.c (maybe_inject_for_scope_var): Ignore __FUNCTION__ and
4649 related variables.
4650
e6f052b7
MM
4651 PR c++/7679
4652 * spew.c (next_token): Do not return an endless stream of
4653 END_OF_SAVED_INPUT tokens.
4654 (snarf_method): Add three END_OF_SAVED_INPUT tokens to the end of
4655 the cached token stream.
4656 (snarf_defarg): Likewise.
4657
8bcefb43
ZW
46582002-10-23 Zack Weinberg <zack@codesourcery.com>
4659
4660 * cp-lang.c (cp_var_mod_type_p): New: C++ hook for
4661 variably_modified_type_p.
4662 * cp-tree.h: Remove prototype of variably_modified_type_p.
4663 * tree.c (variably_modified_type_p): Remove; now implemented
4664 in language-independent code.
4665
ad4f9910
MM
46662002-10-22 Mark Mitchell <mark@codesourcery.com>
4667
4668 PR c++/6579
4669 * spew.c (snarf_parenthesized_expression): New function.
4670 (snarf_block): Use it.
4671
3961e8fe
RH
46722002-10-22 Richard Henderson <rth@redhat.com>
4673
4674 * method.c (use_thunk): Always compute vcall_value; assert that
4675 it is not zero. Use can_output_mi_thunk; use output_mi_thunk
4676 for vcall thunks as well.
4677
5ec1192e
MM
46782002-10-21 Mark Mitchell <mark@codesourcery.com>
4679
7ba539c6
MM
4680 * class.c (empty_base_at_nonzero_offset_p): New function.
4681 (layout_nonempty_base_or_field): Do not check for conflicts when
4682 laying out a virtual base using the GCC 3.2 ABI.
4683 (build_base_field): Correct checking for presence of empty classes
90024bdc 4684 at nonzero offsets when clearing CLASSTYPE_NEARLY_EMPTY_P.
7ba539c6 4685
e3ccdd50
MM
4686 * class.c (include_empty_classes): Use normalize_rli.
4687 (layout_class_type): Likewise.
4688
42328048
MM
4689 * decl.c (reshape_init): Tweak handling of character arrays.
4690
5ec1192e
MM
4691 PR c++/8218
4692 * cp-tree.h (lang_type_class): Add contains_empty_class_p.
4693 (CLASSTYPE_CONTAINS_EMPTY_CLASS_P): New macro.
4694 * class.c (check_bases): Update CLASSTYPE_CONTAINS_EMPTY_CLASS_P.
4695 (check_field_decls): Likewise.
4696 (layout_class_type): Likewise.
4697 (finish_struct_1): Initialize it.
4698 (walk_subobject_offsets): Use it to prune searches.
4699
eb0424da
MM
47002002-10-20 Mark Mitchell <mark@codesourcery.com>
4701
4702 * method.c (use_thunk): Compute the vcall index as a HOST_WIDE_INT.
4703 * optimize.c (optimize_function): Replace ASM_OUTPUT_MI_THUNK with
4704 TARGET_ASM_OUTPUT_MI_THUNK in comments.
8bcefb43 4705
4a7510cb
ZW
47062002-10-18 Zack Weinberg <zack@codesourcery.com>
4707
4708 * decl.c (start_decl): Point users of the old initialized-
4709 typedef extension at __typeof__.
4710
483ab821
MM
47112002-10-18 Mark Mitchell <mark@codesourcery.com>
4712
4713 * Make-lang.in (method.o): Depend on TARGET_H.
4714 * method.c (target.h): Include it.
4715 (use_thunk): Use target hooks. Use vcall thunks, if available.
4716
e4f4feba
MM
47172002-10-18 Mark Mitchell <mark@codesourcery.com>
4718
4719 * class.c (base_derived_from): Make sure return value is a bool.
4720
9368208b
MM
47212002-10-18 Mark Mitchell <mark@codesourcery.com>
4722
4723 * class.c (find_final_overrider_data_s): Remove overriding_fn and
4724 overriding_base.
4725 (dfs_base_derived_from): New function.
4726 (base_derived_from): Likewise.
4727 (dfs_find_final_overrider): Use base_derived_from.
4728 (find_final_overrider): Adjust.
4729
5275f2bf
JM
47302002-10-18 Jason Merrill <jason@redhat.com>
4731
4732 PR c++/8080
4733 * semantics.c (finish_for_cond, finish_while_cond): Don't mess
4734 with condition decls in a template.
4735
8a188e24
NS
47362002-10-17 Nathan Sidwell <nathan@codesourcery.com>
4737
4738 * class.c (add_method): Compare template parms too.
4739
b216f69b
MM
47402002-10-17 Mark Mitchell <mark@codesourcery.com>
4741
982216be
MM
4742 PR c++/7584
4743 * class.c (handle_using_decl): Allow the declaration used to be
4744 from an ambiguous base.
4745
d768a589
MM
4746 * pt.c (convert_template_argument): Revert this change:
4747 2002-10-16 Mark Mitchell <mark@codesourcery.com>
4748 * pt.c (convert_template_argument): Do not fold non-type
4749 template rguments when inside a template.
4750
b216f69b
MM
4751 * init.c (expand_default_init): Handle brace-enclosed initializers
4752 correctly.
4753
2303a079
MM
47542002-10-16 Mark Mitchell <mark@codesourcery.com>
4755
d3133e68
MM
4756 * mangle.c (write_expression): Correct handling of enumeration
4757 constants.
4758 (write_template_arg): Likewise.
4759 * pt.c (convert_template_argument): Do not fold non-type template
4760 arguments when inside a template.
4761
2303a079
MM
4762 PR c++/7478
4763 * cvt.c (convert_to_reference): Allow references as the incoming
4764 type.
4765
451c0899
MM
47662002-10-16 Mark Mitchell <mark@codesourcery.com>
4767
4768 PR c++/7524
4769 * method.c (do_build_assign_ref): Use cp_build_qualified_type, not
4770 build_qualified_type.
4771
da6eec72
RH
47722002-10-15 Richard Henderson <rth@redhat.com>
4773
4774 * error.c (dump_expr): Use real_to_decimal directly, and with
4775 the new arguments.
4776
3fa3c4bd
MM
47772002-10-15 Mark Mitchell <mark@codesourcery.com>
4778
4779 * decl.c (reshape_init): Fix typo.
4780
4781 * cp-tree.h (operator_name_info_t): Add arity.
4782 * lex.c (init_operators): Initialize it.
4783 * mangle.c (write_conversion_operator_name): New function.
4784 (write_unqualified_name): Use it.
4785 (write_template_args): Accept template arguments as a TREE_LIST.
4786 (write_expression): Adjust handling of qualified names to match
4787 specification.
4788
1a55127d
JM
47892002-10-15 Jason Merrill <jason@redhat.com>
4790
4791 * call.c (call_builtin_trap): New fn.
4792 (convert_arg_to_ellipsis): Use it. Downgrade error to warning.
4793 (build_call): Don't set current_function_returns_abnormally outside
4794 a function.
4795
58731fd1
MM
47962002-10-14 Mark Mitchell <mark@codesourcery.com>
4797
4798 * class.c (check_field_decls): Remove empty_p parameter. Instead,
4799 clear CLASSTYPE_EMPTY_P.
4800 (build_base_field): Likewise.
4801 (build_base_fields): Likewise.
4802 (check_bases_and_members): Likewise.
4803 (create_vtbl_ptr): Likewise.
4804 (layout_class_type): Likewise. Ensure that empty classes have
4805 size zero when used as base classes in the 3.2 ABI.
4806 (finish_struct_1): Initialize CLASSTYPE_EMPTY_P and
4807 CLASSTYPE_NEARLY_EMPTY_P. Adjust calls to avoid passing empty_p
4808 parameter.
4809 (is_empty_class): Correct definition when using post-3.2 ABI.
4810 * cp-tree.h (lang_type_class): Add empty_p.
4811 (CLASSTYPE_EMPTY_P): New macro.
4812
6742d92b
NS
48132002-10-12 Nathan Sidwell <nathan@codesourcery.com>
4814
4815 * init.c (build_delete): Do not apply save_expr for arrays.
4816 (build_vec_delete): Likewise.
4817
77631fa7
MM
48182002-10-14 Mark Mitchell <mark@codesourcery.com>
4819
4a7510cb 4820 * decl.c (layout_var_decl): Call layout_decl even for variables
7de85f7e
MM
4821 whose type is an array with unspecified bounds.
4822
77631fa7
MM
4823 PR c++/7176
4824 * lex.c (do_identifier): Add another option for the parsing
4825 parameter.
4826 * parse.y (do_id): Use it.
4827
2ee366b5
GDR
48282002-10-11 Gabriel Dos Reis <gdr@integrable-solutions.net>
4829
4830 PRs C++/6803, C++/7721 and C++/7803
4831 * decl.c (grokdeclarator): Gracefully handle template-name as
4832 decl-specifier.
4833
01c3fb15
JM
48342002-10-11 Jason Molenda <jmolenda@apple.com>
4835
4836 * init.c (build_field_list): Provide uses_unions_p with a default
4837 value.
4838
8e3df2de
MM
48392002-10-11 Mark Mitchell <mark@codesourcery.com>
4840
dac45b5c
MM
4841 PR c++/5661
4842 * cp-tree.h (variably_modified_type_p): New function.
4843 (grokdeclarator) Tighten check for variably modified types as
4844 fields.
4845 * pt.c (convert_template_argument): Do not allow variably modified
4846 types as template arguments.
4a7510cb 4847 * tree.c (variably_modified_type_p): New function.
dac45b5c 4848
8e3df2de
MM
4849 * NEWS: Document removal of "new X = ..." extension.
4850 * class.c (initialize_array): Set TREE_HAS_CONSTRUCTOR on
4851 brace-enclosed initializers.
4852 * cp-tree.h (CP_AGGREGATE_TYPE_P): New macro.
4853 (initialize_local_var): Remove declaration.
4854 (expand_static_init): Likewise.
4855 * decl.c (next_initializable_field): New function.
4856 (reshape_init): Likewise.
4857 (check_initializer): Use them. Build dynamic initializer for
4858 aggregates here too.
4859 (initialize_local_var): Simplify, and incorporate cleanup
4860 insertion code as well.
4861 (destroy_local_var): Remove.
4862 (cp_finish_decl): Tidy.
4863 (expand_static_init): Fold checks for whether or not a variable
4864 needs initialization into this function. Simplify.
4865 * decl2.c (do_static_initialization): Simplify.
4866 * init.c (build_init): Do not set TREE_SIDE_EFFECTS when it will
4867 be done for us automatically.
4868 (expand_default_init): Handle brace-enclosed initializers
4869 correctly.
4870 (expand_aggr_init_1): Remove RTL-generation code.
4871 (build_vec_init): Remove "new X = ..." support.
4872 * parse.y (new_initializer): Likewise.
4873 * rtti.c (get_pseudo_ti_init): Set TREE_HAS_CONSTRUCTOR on
4874 brace-enclosed initializer.
4875 (create_pseudo_type_info): Likewise.
4876 * typeck2.c (store_init_value): Don't try to handle digest_init
4877 being called more than once.
4878 (digest_init): Tidy handling of brace-enclosed initializers.
01c3fb15 4879
7bdfd72e
KG
48802002-10-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4881
4882 * decl.c (typename_hash): Use htab_hash_pointer.
4883
e89fe41c
JW
48842002-10-10 Jim Wilson <wilson@redhat.com>
4885
4886 * decl.c (duplicate_decls): Don't call decl_attributes.
4887
95f79357
ZW
48882002-10-09 Zack Weinberg <zack@codesourcery.com>
4889
85cd7be8 4890 PR c/7353
95f79357
ZW
4891 * decl.c (start_decl): Unconditionally issue error for
4892 'typedef foo = bar'.
4893 (cp_finish_decl): Remove special case for TYPE_DECL with initializer.
4894 (grokdeclarator): Remove redundant error for 'typedef foo = bar'.
4895
10a38dba
KG
48962002-10-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
4897
4898 * decl2.c (prune_vtable_vardecl): Delete unused function.
4899
edebf865
MM
49002002-10-03 Mark Mitchell <mark@codesourcery.com>
4901
4902 PR c++/7754
4903 * decl2.c (finish_anon_union): Do not expand anonymous unions when
4904 procesing template functions.
4905 * pt.c (tsubst_decl, case VAR_DECL): Try to complete the variable
4906 type. Call layout_decl.
4907 (tsubst_expr, case DECL_STMT): Handle anonymous unions.
4908
01f4137f
RH
49092002-10-07 Richard Henderson <rth@redhat.com>
4910
4911 * decl2.c, pt.c: Revert c++/7754 fix.
4912
eb55ce4b
KL
49132002-10-05 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
4914
4915 PR c++/7804
4916 * error.c (dump_expr) [REAL_CST]: Output in decimal format.
4917
bd9bb3d2
MM
49182002-10-03 Mark Mitchell <mark@codesourcery.com>
4919
43c6a96a 4920 PR c++/7931
bd9bb3d2
MM
4921 * pt.c (for_each_template_parm_r): Handle BASELINKs.
4922
4923 PR c++/7754
4924 * decl2.c (finish_anon_union): Do not expand anonymous unions when
4925 procesing template functions.
4926 * pt.c (tsubst_decl, case VAR_DECL): Try to complete the variable
4927 type. Call layout_decl.
4928 (tsubst_expr, case DECL_STMT): Handle anonymous unions.
4929
6397d80b
MM
49302002-10-03 Mark Mitchell <mark@codesourcery.com>
4931
4932 PR c++/8006
4933 * mangle.c (CLASSTYPE_TEMPLATE_ID_P): Handle instances of template
4934 template parameters.
4935 (globals): Add entity and need_abi_warning.
4936 (decl_is_template_id): Use TYPE_TEMPLATE_INFO, not
4937 CLASSTYPE_TEMPLATE_INFO.
4938 (is_std_substitution): Use CLASSTYPE_TI_TEMPLATE, not
4939 TYPE_TI_TEMPLATE.
4940 (write_prefix): Handle typename types correctly.
4941 (write_template_prefix): Handle template template parameters
4942 correctly.
4943 (start_mangling): Add entity parameter.
4944 (finish_mangling): Warn about names whose mangling will change.
4945 (mangle_decl_string): Adjust.
4946 (mangle_type_string): Likewise.
4947 (mangle_special_for_type): Likewise.
4948 (mangle_ctor_vtbl_for_type): Likewise.
4949 (mangle_thunk): Likewise.
4950 (mangle_guard_variable): Likewise.
4951 (mangle_ref_init_variable): Likewise.
4952
2282d28d
MM
49532002-10-02 Mark Mitchell <mark@codesourcery.com>
4954
4955 PR c++/7188.
4956 * cp-tree.def (CTOR_INITIALIZER): Use one slot, not two.
4957 * cp-tree.h (emit_base_init): Rename to ....
4958 (emit_mem_initializers): ... this.
4959 (expand_member_init): Change prototype.
4960 * init.c (perform_member_init): Compute explicit, rather than
4961 requiring it as a parameter.
4962 (sort_member_init): Rename to ...
4963 (sort_mem_initializers): ... this. Process bases and data members
4964 together.
4965 (sort_base_init): Remove.
4966 (emit_base_init): Rename to ...
4967 (emit_mem_initializers): ... this.
4968 (expand_aggr_vbase_init_1): Remove.
4969 (construct_virtual_bases): Rename to ...
4970 (construct_virtual_base): ... this.
4971 (expand_member_init): Rework handling of base initializers.
4972 * method.c (do_build_copy_constructor): Use
4973 finish_mem_initializers.
4974 * parse.y (member_init): Adjust calls to expand_member_init.
4975 * pt.c (tsubst_expr): Simplify CTOR_INITIALIZER case.
4976 (tsubst_initializer_list): Use expand_member_init.
4977 * semantics.c (finish_mem_intiailizers): Simplify.
69788039
MA
4978
49792002-10-02 Matt Austern <austern@apple.com>
4980 * decl.c (walk_vtables_r): Fixed typo that caused result to
4981 never get a nonzero value.
95f79357 4982
f963b5d9
RS
49832002-10-02 Roger Sayle <roger@eyesopen.com>
4984
4985 PR optimization/6627
4986 * cp-tree.h (enum ptrmemfunc_vbit_where_t): Delete definition
4987 from here, and move it to tree.h.
4988 * decl.c (cxx_init_decl_processing): If storing the vbit
4989 in function pointers, ensure that force_align_functions_log
4990 is atleast one.
4991
69788039
MA
49922002-10-02 Matt Austern <austern@apple.com>
4993
4994 * class.c (check_field_decls): Changed warning about const member
4995 variables so that it doesn't get issued for a class aggregate.
95f79357 4996
d881ff25
MM
49972002-10-01 Mark Mitchell <mark@codesourcery.com>
4998
4999 * decl.c (cp_finish_decl): Make sure array types are laid out,
5000 even if the array bounds are unknown.
5001
2e88ae22
SE
50022002-10-01 Steve Ellcey <sje@cup.hp.com>
5003
d881ff25 5004 * class.c (build_vtbl_initializer): Change build_c_cast
2e88ae22
SE
5005 to build1.
5006
b4c20e52
MM
50072002-10-01 Mark Mitchell <mark@codesourcery.com>
5008
d881ff25
MM
5009 * decl.c (cp_finish_decl): Make sure array types are laid out,
5010 even if the array bounds are unknown.
5011
b4c20e52
MM
5012 * decl.c (cp_finish_decl): Correct check for dynamic
5013 initialization of thread-local storage.
5014
5a9a1961
NS
50152002-09-30 Nathan Sidwell <nathan@codesourcery.com>
5016
5017 * tree.c (really_overloaded_fn): TEMPLATE_ID_EXPRs are also
5018 overloaded.
5019
7befdb9f
SE
50202002-09-30 Steve Ellcey <sje@cup.hp.com>
5021
5022 * class.c (build_vtbl_initializer): Add cast.
5023 (add_vcall_offset_vtbl_entries_1):
5024 Use TARGET_VTABLE_DATA_ENTRY_DISTANCE for offset.
5025
17bbb839
MM
50262002-09-30 Mark Mitchell <mark@codesourcery.com>
5027
5028 * class.c (walk_subobject_offsets): Correct the calculation of
5029 offsets for virtual bases. Correct the counting of array
5030 elements.
5031 (layout_nonempty_base_or_field): Simplify. Correct the
5032 calculation of offsets to be propagated through the binfo
5033 hierarchy.
5034 (build_base_field): Avoid creating a FIELD_DECL for empty bases.
5035 Add the FIELD_DECL to TYPE_FIELDS.
5036 (build_base_fields): Adjust accordingly.
5037 (layout_virtual_bases): Use build_base_field.
5038 (end_of_class): Return a tree, not an integer.
5039 (warn_about_ambiguous_direct_bases): Rename to ...
5040 (warn_about_ambiguous_bases): ... this.
5041 (include_empty_classes): New function.
5042 (layout_class_type): Create an alternative version of the type to
5043 be used when as a base class type. Do not call
5044 finish_record_layout until we are done laying out the class.
5045 * cp-tree.h (lang_type_class): Remove size, size_unit. Add
5046 as_base.
5047 (CLASSTYPE_SIZE): Reimplement.
5048 (CLASSTYPE_SIZE_UNIT): Likewise.
5049 (CLASSTYPE_ALIGN): Likweise.
5050 (CLASSTYPE_USER_ALIGN): Likewise.
5051 (CLASSTYPE_AS_BASE): New macro.
5052 (DECL_INITIALIZED_P): Likewise.
5053 (extract_init): Remove prototype.
5054 (build_forced_zero_init): Rename to ...
5055 (build_zero_init): ... this.
5056 (force_store_init_value): Remove.
5057 * decl.c (obscure_complex_init): Remove.
5058 (duplicate_decls): Copy DECL_INITIALIZED_P.
5059 (check_initializer): Do not leave junk in DECL_INITIAL.
5060 (cp_finish_decl): Handle zero-initialization of entities with
5061 static storage duration.
5062 * expr.c (extract_init): Remove.
5063 * init.c (build_forced_zero_init): Remove.
5064 (build_zero_init): New function.
5065 (build_default_init): Use it.
5066 (build_field_list): Skip FIELD_DECLs for base subobjects.
5067 (push_base_cleanups): Likewise.
5068 * method.c (do_build_assign_ref): Likewise.
5069 (synthesize_exception_spec): Likewise.
5070 * pt.c (tsubst_decl): Clear DECL_INITIALIZED_P.
5071 (regenerate_decl_from_template): To not set DECL_INITIAL for a
5072 static data member whose initialization took place in its class.
5073 (instantiate_decl): Do not pass an initializer to cp_finish_decl
5074 in that situation.
5075 * search.c (dfs_push_decls): Skip FIELD_DECLs for base subobjects.
5076 (dfs_unuse_fields): Likewise.
5077 * tree.c (pod_type_p): Handle error_mark_node.
5078 (zero_init_p): Likewise.
95f79357 5079 * typeck.c (lookup_anon_field): Skip FIELD_DECLs for base
17bbb839
MM
5080 subobjects.
5081 * typeck2.c (store_init_value): Remove #if 0'd code.
5082 (force_store_init_value): Remove.
5083 (process_init_constructor): Use build_zero_init.
95f79357 5084
03357c23
NS
50852002-09-29 Nathan Sidwell <nathan@codesourcery.com>
5086
5087 PR c++/7788
5088 * rtti.c (unemitted_tinfo_decl_p): Check it has a field.
5089
27631dae
KH
50902002-09-29 Kazu Hirata <kazu@cs.umass.edu>
5091
5092 * cp-tree.h: Fix comment typos.
5093 * decl.c: Likewise.
5094 * pt.c: Likewise.
5095
956d9305
MM
50962002-09-25 Mark Mitchell <mark@codesourcery.com>
5097
5098 * cp/class.c (contains_empty_class_p): New method.
5099 (walk_subobject_offsets): Correct computation of field offset.
5100 (layout_empty_base): Correct placement of emtpy base classes.
5101 (layout_class_type): Warn about ABI changes.
5102
2d3e278d
MM
51032002-09-23 Mark Mitchell <mark@codesourcery.com>
5104
5105 * cp/class.c (layout_virtual_bases): Do not round the size of the
5106 type to a multiple of the alignment before laying out virtual bases.
5107 (layout_class_type): Correct handling of bit-fields that are wider
5108 than their type inside unions. Round the size of the type to a
5109 even number of bytes when computing the size without virtual
5110 bases.
5111 * cp/cp-tree.h (abi_version_at_least): New macro.
95f79357 5112
838dfd8a
KH
51132002-09-21 Kazu Hirata <kazu@cs.umass.edu>
5114
5115 * ChangeLog: Follow spelling conventions.
5116 * ChangeLog.2: Likewise.
5117 * call.c: Likewise.
5118 * class.c: Likewise.
5119 * cp-tree.h: Likewise.
5120 * cvt.c: Likewise.
5121 * decl.c: Likewise.
5122 * decl2.c: Likewise.
5123 * except.c: Likewise.
5124 * friend.c: Likewise.
5125 * g++spec.c: Likewise.
5126 * init.c: Likewise.
5127 * lex.c: Likewise.
5128 * mangle.c: Likewise.
5129 * method.c: Likewise.
5130 * operators.def: Likewise.
5131 * optimize.c: Likewise.
5132 * pt.c: Likewise.
5133 * rtti.c: Likewise.
5134 * search.c: Likewise.
5135 * semantics.c: Likewise.
5136 * spew.c: Likewise.
5137 * tree.c: Likewise.
5138 * typeck.c: Likewise.
5139
9ced0328
DP
51402002-09-18 Devang Patel <dpatel@apple.com>
5141
5142 * cp/cp-tree.h: New prototype for walk_vtabls().
5143 * cp/decl.c (walk_vtables_r): New function.
5144 (struct cp_binding_level): Add new members, namespaces,
5145 names_size and vtables.
5146 (add_decl_to_level): Add decl in namespaces or vtables
5147 chain, if conditions match.
5148 (walk_vtables): New function.
5149 (walk_namespaces_r): Travers separate namespace chain
5150 for namespace decls.
5151 (wrapup_globals_for_namespace): Use names_size instead
5152 of list_length().
5153 * cp/decl2.c (finish_file): Use walk_vtables() instead of
5154 walk_globals() to walk vtable decls.
5155
dd29188b
NS
51562002-09-18 Nathan Sidwell <nathan@codesourcery.com>
5157
5158 * decl.c (grokdeclarator): Use assert, not internal_error. Don't
5159 ICE with invalid pointers & references.
5160
f989ed67
ZW
51612002-09-17 Zack Weinberg <zack@codesourcery.com>
5162
5163 * Make-lang.in: Remove all references to the demangler.
5164 * cxxfilt.c: Moved to binutils.
5165
171d2f50
NS
51662002-09-16 Nathan Sidwell <nathan@codesourcery.com>
5167
3ec83083
NS
5168 PR c++/7718
5169 * pt.c (tsubst_decl): Remove assert.
5170
171d2f50
NS
5171 Remove DR 295 implementation.
5172 * pt.c (check_cv_quals_for_unify): Disable function & method cases.
5173 * tree.c (cp_build_qualified_type_real): Likewise. Don't warn
5174 about ignoring volatile qualifiers.
5175
5176 * search.c (lookup_member): Correct documentation.
5177
36a5eadd
GK
51782002-09-16 Geoffrey Keating <geoffk@apple.com>
5179
5180 * cp-tree.h (union lang_tree_node): Add chain_next option.
5181
28c56d25
NS
51822002-09-16 Nathan Sidwell <nathan@codesourcery.com>
5183
7979434d
NS
5184 * parse.y (parse_finish_call_expr): Check lookup_member result.
5185
28c56d25
NS
5186 PR c++/7015
5187 * semantic.c (finish_asm_stmt): Fix operand/output_operands
5188 thinko.
5189 * typeck.c (c_expand_asm_operands): Protect from error_mark_node.
5190
3baab484
NS
51912002-09-15 Nathan Sidwell <nathan@codesourcery.com>
5192
5193 PR c++/7919
5194 * call.c (build_over_call): Convert this pointer for fns found by
5195 using decls.
5196
d30d6e7a
KH
51972002-09-15 Kazu Hirata <kazu@cs.umass.edu>
5198
5199 * ChangeLog: Follow spelling conventions.
5200 * ChangeLog.1: Likewise.
5201
c8460010
NS
52022002-09-14 Nathan Sidwell <nathan@codesourcery.com>
5203
5204 PR c++/7768
5205 * pt.c (build_template_decl): Copy DECL_DESTRUCTOR_P.
5206
c6002625
KH
52072002-09-14 Kazu Hirata <kazu@cs.umass.edu>
5208
5209 * error.c: Fix comment formatting.
5210 * except.c: Likewise.
5211 * expr.c: Likewise.
5212 * friend.c: Likewise.
5213 * g++spec.c: Likewise.
5214 * init.c: Likewise.
5215 * lex.c: Likewise.
5216 * mangle.c: Likewise.
5217 * method.c: Likewise.
5218 * optimize.c: Likewise.
5219 * pt.c: Likewise.
5220 * rtti.c: Likewise.
5221 * search.c: Likewise.
5222 * semantics.c: Likewise.
5223 * spew.c: Likewise.
5224 * tree.c: Likewise.
5225 * typeck.c: Likewise.
5226 * typeck2.c: Likewise.
5227
46dd3884
GDR
52282002-09-13 Matt Austern <austern@apple.com>
5229
4a7510cb 5230 PR C++/7828
46dd3884
GDR
5231 * cp/cp-tree.h, cp/tree.c: New function non_cast_lvalue_p.
5232 * cp/call.c: Change call-by-const-reference mechanism to use
5233 non_cast_lvalue_p when deciding whether the create a temporary.
5234 We need a temporary when passing, e.g. (long) x by const ref.
5235
712467a4
NS
52362002-09-13 Nathan Sidwell <nathan@codesourcery.com>
5237
5238 * pt.c (unify, ARRAY_TYPE): Element type can be more qualified.
5239
a1c65f9f
KH
52402002-09-13 Kazu Hirata <kazu@cs.umass.edu>
5241
5242 * decl.c: Fix comment formatting.
5243 * decl2.c: Likewise.
5244
00a17e31
KH
52452002-09-12 Kazu Hirata <kazu@cs.umass.edu>
5246
5247 * call.c: Fix comment formatting.
5248 * class.c: Likewise.
5249 * cp-lang.c: Likewise.
5250 * cp-tree.h: Likewise.
5251 * cvt.c: Likewise.
5252
3fd9d606
ZW
52532002-09-11 Zack Weinberg <zack@codesourcery.com>
5254
5255 * Make-lang.in: Build cp/cxxfilt.o from $(srcdir)/cp/cxxfilt.c,
5256 and c++filt from cxxfilt.o + version.o + $(LIBDEPS).
5257 * cxxfilt.c: New file: split from libiberty/cplus-dem.c, with
5258 minor adjustments (use version_string, eliminate yet another
5259 duplicate of xmalloc)
5260
2515a7ea
KG
52612002-09-08 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
5262
5263 * cp-tree.h (require_complete_eh_spec_types): Add prototype.
5264
5aa3396c
JM
52652002-09-05 Jason Merrill <jason@redhat.com>
5266
5267 * typeck2.c (add_exception_specifier): Only pedwarn for an
5268 incomplete type.
5269 (require_complete_eh_spec_types): New fn.
5270 (cxx_incomplete_type_diagnostic): Also support pedwarning.
5271 * typeck.c (complete_type_or_diagnostic): Likewise.
5272 * call.c (build_call): Call require_complete_eh_spec_types.
5273 * rtti.c (get_pseudo_ti_desc): Give an error rather than aborting
5274 on an incomplete type.
5275
23ccd1f3
JJ
52762002-09-04 Jakub Jelinek <jakub@redhat.com>
5277
5278 * decl.c (start_cleanup_fn): Clear interface_only before
5279 start_function, restore it afterwards.
5280
4977bab6
ZW
52812002-09-02 Nathan Sidwell <nathan@codesourcery.com>
5282
5283 * cp-tree.h (finish_builtin_type): Remove.
5284 * decl2.c (finish_builtin_type): Move to common code.
5285 * decl.c (build_ptrmemfunc_type): Adjust.
5286 * rtti.c (create_pseudo_type_info): Adjust.
5287 (create_tinfo_types): Adjust.
5288
d99f015c
JM
52892002-08-31 Jason Merrill <jason@redhat.com>
5290
5291 * cp-lang.c (cp_expr_size): Allow initialization from a
5292 CONSTRUCTOR.
5293
8a3c9180
RH
52942002-08-30 Richard Henderson <rth@redhat.com>
5295
c9989d09 5296 PR opt/7515
8a3c9180
RH
5297 * tree.c: Include target.h.
5298 (cp_cannot_inline_tree_fn): Don't auto-inline functions that
5299 don't bind locally.
5300 * Makefile.in (tree.o): Update.
5301
eca7f13c
MM
53022002-08-27 Mark Mitchell <mark@codesourcery.com>
5303
5304 * class.c (layout_virtual_bases): Warn about bugs in G++ that
5305 result in incorrect object layouts.
5306 (layout_class_type): Likewise.
f989ed67 5307
13d3f0b6
MA
53082002-08-24 Matt Austern <austern@apple.com>
5309
5310 * tree.c (lvalue_p_1): Add argument for whether casts of lvalues
5311 are allowable.
5312 (real_lvalue_p): Update caller.
5313 (lvalue_p): Ditto.
5314 (non_cast_lvalue_or_else): New.
5315 * tree.h: Declare it.
f989ed67 5316 * typeck.c (build_unary_op): Use non_cast_lvalue_or_else.
13d3f0b6 5317
5b770a96
MM
53182002-08-22 Mark Mitchell <mark@codesourcery.com>
5319
5320 * typeck.c (build_class_member_access_expr): Handle COMPOUND_EXPR
5321 and COND_EXPR specially; fix error message output.
5322
d65b1d77
JM
53232002-08-22 Jason Merrill <jason@redhat.com>
5324
5325 * pt.c (tsubst_expr): RETURN_EXPR is now RETURN_STMT_EXPR.
5326 * semantics.c (nullify_returns_r): Likewise.
5327
8a5f4379
GDR
53282002-08-17 Gabriel Dos Reis <gdr@integrable-solutions.net>
5329
5330 Fix PR/7621
5331 * typeck.c (finish_class_member_access_expr): Diagnose cases where
5332 name lookup finds nothing.
5333
5d764395
JM
53342002-08-15 Jason Merrill <jason@redhat.com>
5335
5336 * semantics.c (finish_then_clause): Remove redundant assignment.
5337 (finish_if_stmt, begin_switch_stmt, finish_switch_stmt): Move the
5338 extra binding level outside the if/switch statement.
5339 (finish_while_cond, finish_for_cond): Rewrite complex condition
5340 into the loop body.
5341
c01b9ec8
AO
53422002-08-15 Alexandre Oliva <aoliva@redhat.com>
5343
5344 * parse.y (sizeof, alignof, typeof): New non-terminals to
5345 increment skip_evaluation. Replace terminals with them and
5346 decrement skip_evaluation at the end of rules using them.
5347 * decl2.c (mark_used): Don't assemble_external if
5348 skipping evaluation.
5349
e8fe46d4
GDR
53502002-08-15 Gabriel Dos Reis <gdr@nerim.net>
5351
5352 Fix PR/7504
5353 * parse.y (parse_finish_call_expr): Handle incomplete
5354 type used to name a scope.
5355
eac5ce6c
NS
53562002-08-15 Nathan Sidwell <nathan@codesourcery.com>
5357
5358 PR c++/7598
5359 * typeck.c (build_unary_op): Fold offsetof idiom. Fixes
5360 regression caused by my 2002-08-08 patch.
5361
22eadedb
MM
53622002-08-13 Mark Mitchell <mark@codesourcery.com>
5363
5364 * decl.c (pushdecl_class_level): Honor requests to bind names to
5365 OVERLOADs.
5366
e65e6212
KG
53672002-08-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
5368
5369 * decl2.c (build_call_from_tree): Fix uninitialized variable.
5370 * parse.y (parse_finish_call_expr): Likewise.
5371 * repo.c (old_args, old_dir, old_main): Const-ify.
5372
3e72ec9a
GDR
53732002-08-11 Gabriel Dos Reis <gdr@nerim.net>
5374
d78e771d 5375 * decl.c (duplicate_decls): Replace DECL_SOURCE_FILE
3e72ec9a
GDR
5376 DECL_SOURCE_LINE with DECL_SOURCE_LOCATION.
5377 * optimize.c (maybe_clone_body): Likewise.
5378 * pt.c (tsubst_enum): Likewise.
5379 (lookup_template_class): Likewise.
5380 * tree.c (cp_copy_res_decl_for_inlining): Likewise.
5381
f749a36b
NB
53822002-08-10 Neil Booth <neil@daikokuya.co.uk>
5383
5384 * lang-specs.h: Remove -ansi.
5385
3ebf5204
NS
53862002-08-10 Nathan Sidwell <nathan@codesourcery.com>
5387
5388 * tree.c (maybe_dummy_object): Replace // with /* */
5389
9e259dd1
MM
53902002-08-09 Mark Mitchell <mark@codesourcery.com>
5391
5392 * call.c (standard_conversion): Use build_ptrmem_type.
5393 * cp-tree.h (build_ptrmem_type): New function.
5394 (adjust_result_of_qualified_name_lookup): Likewise.
5395 * decl.c (grokvardecl): Do not look for OFFSET_TYPEs to indicate
5396 static data members.
5397 (build_ptrmem_type): New function.
5398 (grokdeclarator): Do not use build_offset_type when encountering a
5399 qualified name.
5400 * parse.y (parse_finish_call_expr): Use
5401 adjust_result_of_qualified_name_lookup.
5402 * search.c (adjust_result_of_qualified_name_lookup): New function.
5403 * typeck.c (qualify_type_recursive): Use TYPE_PTRMEM_* rather than
5404 accessing OFFSET_TYPEs directly.
f989ed67 5405
0e339752
MS
54062002-08-08 Mike Stump <mrs@apple.com>
5407
5408 * call.c (add_builtin_candidate): legal -> valid, illegal -> invalid.
5409 (type_decays_to): Likewise.
5410 * class.c (find_final_overrider): Likewise.
5411 (maybe_note_name_used_in_class): Likewise.
5412 * decl.c (current_tmpl_spec_kind): Likewise.
5413 (add_binding): Likewise.
5414 (push_class_binding): Likewise.
5415 (duplicate_decls): Likewise.
5416 (layout_var_decl): Likewise.
5417 (grokfndecl): Likewise.
5418 (grokdeclarator): Likewise.
5419 (check_default_argument): Likewise.
5420 * decl2.c (handle_class_head): Likewise.
5421 * error.c (dump_template_decl): Likewise.
5422 * init.c (build_offset_ref): Likewise.
5423 * pt.c (check_specialization_scope): Likewise.
5424 (determine_specialization): Likewise.
5425 (check_explicit_specialization): Likewise.
5426 (maybe_check_template_type): Likewise.
5427 (process_partial_specialization): Likewise.
5428 (check_default_tmpl_args): Likewise.
5429 (push_template_decl_real): Likewise.
5430 (convert_template_argument): Likewise.
5431 (try_class_unification): Likewise.
5432 (get_bindings_real): Likewise.
5433 (do_decl_instantiation): Likewise.
5434 * semantics.c (begin_function_definition): Likewise.
5435 (finish_member_declaration): Likewise.
5436 (check_multiple_declarators): Likewise.
5437 * typeck.c (comp_array_types): Likewise.
5438 (comptypes): Likewise.
5439 (expr_sizeof): Likewise.
5440 (build_binary_op): Likewise.
5441 (dubious_conversion_warnings): Likewise.
5442 (check_return_expr): Likewise.
b6ce26ac 5443
a6f5b2d3
MM
54442002-08-08 Mark Mitchell <mark@codesourcery.com>
5445
5446 * typeck.c (build_class_member_access_expr): Do not return
5447 error_mark_node when no error has occurred.
b6ce26ac 5448
c93a26f5
NS
54492002-08-08 Nathan Sidwell <nathan@codesourcery.com>
5450
5451 * typeck.c (build_component_addr): Remove.
5452 (build_unary_op): Just check it's not a bitfield, and then build
5453 an ADDR_EXPR.
5454
5bfc90de
NS
54552002-08-08 Nathan Sidwell <nathan@codesourcery.com>
5456
5457 * class.c (convert_to_base): Correct check for error_mark_node.
5458 (create_vtable_ptr): Remove unused VFUNS_P parm.
5459
22aa533e
NS
54602002-08-08 Nathan Sidwell <nathan@codesourcery.com>
5461
5462 * cp/Make-lang.in (c++.mostlyclean): Remove coverage files.
5463
50ad9642
MM
54642002-08-07 Mark Mitchell <mark@codesourcery.com>
5465
5466 Rework build_component_ref.
5467 * call.c (build_vfield_ref): Do not go through build_component_ref.
5468 (build_field_call): Use build_class_member_access_expr.
5469 (build_user_type_conversion_1): Use BASELINK_FUNCTIONS.
5470 (build_object_call): Likewise.
5471 * class.c (convert_to_base): New function.
5472 (type_requires_array_cookie): Use BASELINK_FUNCTIONS.
5473 (instantiate_type): Handle BASELINKs.
5474 * cp-tree.def (BASELINK): New tree code.
5475 * cp-tree.h (BASELINK_P): Reimplement.
5476 (SET_BASELINK_P): Remove.
5477 (BASELINK_BINFO): Reimplement.
5478 (BASELINK_FUNCTIONS): Likewise.
5479 (BASELINK_ACCESS_BINFO): Likewise.
5480 (BASELINK_OPTYPE): Likewise.
5481 (convert_to_base): New function.
5482 (name_p): Likewise.
5483 (build_object_ref): Remove.
5484 (build_component_ref_1): Likewise.
5485 (build_component_ref): Likewise.
5486 (build_x_component_ref): Likewise.
5487 (build_class_member_access_expr): New function.
5488 (finish_class_member_access_expr): Likewise.
5489 (build_ptrmemfunc_access_expr): Likewise.
5490 * decl.c (grokdeclarator): Handle BASELINKs.
5491 * decl2. (build_expr_from_tree): Handle COMPONENT_REFs by using
5492 finish_class_member_access_expr.
5493 (arg_assoc): Handle BASELINKs.
5494 (do_class_using_decl): Likewise.
5495 * error.c (dump_decl): Likewise.
5496 (dump_expr): Use build_ptrmemfunc_access_expr.
5497 * except.c (dtor_nothrow): Use CLASSTYPE_DESTRUCTORS to find
5498 destructors.
5499 (build_throw): Use BASELINK_FUNCTIONS.
5500 * init.c (perform_member_init): Use
5501 build_class_member_access_expr.
5502 (build_offset_ref): Handle BASELINKs. Use
5503 build_class_member_access_expr.
5504 * method.c (hack_identifier): Likewise.
5505 * parse.y (do_id): Use BASELINK, not TREE_LIST.
5506 (primary): Remove uses of build_object_ref.
5507 * pt.c (lookup_template_function): Handle BASELINKs.
5508 (resolve_overloaded_unification): Likewise.
5509 * search.c (build_baselink): Build a BASELINK, not a TREE_LIST.
5510 (lookup_field): Use BASELINK, not TREE_LIST.
5511 (lookup_fnfiels): Likewise.
5512 (setup_class_bindings): Likewise.
5513 * semantics.c (finish_object_call_expr): Do not use
5514 build_method_call when we already know what function is being
5515 called.
5516 * spew.c (identifier_type): Use BASELINK, not TREE_LIST.
5517 * tree.c (really_overloaded_fn): Use OVL_CHAIN for OVERLOADs, not
5518 TREE_CHAIN.
5519 (name_p): New function.
5520 * typeck.c (build_object_ref): Remove.
5521 (build_component_ref_1): Likewise.
5522 (build_x_component_ref): Likewise.
5523 (build_class_member_access_expr): New function.
5524 (finish_class_member_access_expr): Likewise.
5525 (build_ptrmemfunc_access_expr): Likewise.
5526 (get_member_function_from_ptrfunc): Use
5527 build_ptrmemfunc_access_expr.
5528 (build_binary_op): Likewise.
5529 (build_unary_op): Likewise.
5530 (build_ptrmemfunc): Likewise.
5531 (pfn_from_ptrmemfunc): Likewise.
5532 * typeck2.c (build_m_component_ref): Adjust comment.
b6ce26ac 5533
0b6f2917
NB
55342002-08-07 Neil Booth <neil@daikokuya.co.uk>
5535
5536 * Make-lang.in (CXX_C_OBJS): Update.
5537 * cp-lang.c (LANG_HOOKS_DECODE_OPTION): Use c_common_decode_option.
5538 * cp-tree.h (cxx_decode_option): Remove.
5539 * decl2.c (compare_options, lang_f_options, unsupported_options,
5540 cxx_decode_option): Remove.
5541
1e14c7f0
GDR
55422002-08-06 Gabriel Dos Reis <gdr@nerim.net>
5543
5544 * typeck.c (build_x_unary_op): Handle pointer-to-member.
5545
b3426eb9
GK
55462002-08-05 Geoffrey Keating <geoffk@redhat.com>
5547
5548 * class.c: Don't include obstack.h.
b6ce26ac 5549 (popclass):
b3426eb9
GK
5550 * decl2.c: Delete bogus comment.
5551 * error.c: Don't include obstack.h.
5552 * except.c: Likewise.
5553 (dump_type): Correct comment.
5554 * method.c: Don't include obstack.h.
5555 * tree.c: Likewise.
5556
201fbb7f
GDR
55572002-08-04 Gabriel Dos Reis <gdr@nerim.net>
5558
5559 Fix PR/2213
5560 * cvt.c (cp_convert_to_pointer): Reject conversions from integral
5561 expressions to pointer-to-data-member of pointer-to-member-functions.
5562
6d9f628e
GK
55632002-08-04 Geoffrey Keating <geoffk@redhat.com>
5564
5565 * cvt.c (ocp_convert): Delete obsolete code.
5566 * parse.y (permanent_obstack): Delete declaration.
5567 * pt.c (permanent_obstack): Delete declaration.
5568 * repo.c (permanent_obstack): Delete declaration.
5569 (open_repo_file): Use xmalloc instead of permanent_obstack.
5570 (init_repo): Use xstrdup instead of permanent_obstack.
5571
dd98e14f
NS
55722002-08-04 Nathan Sidwell <nathan@codesourcery.com>
5573
5574 * cp-tree.h (VF_DERIVED_VALUE): Remove.
5575 * class.c (finish_struct_1): Use VF_BINFO_VALUE not VF_DERIVED_VALUE.
5576
e6858a84
NS
55772002-08-03 Nathan Sidwell <nathan@codesourcery.com>
5578
5579 PR 7470.
5580 C++ ABI change - vfunc ordering.
5581 * class.c (add_virtual_function): Remove.
5582 (dfs_modify_all_vtables): Take list of all declared
5583 virtuals. Assign all that are not in primary base.
5584 (check_for_override): Adjust comments.
5585 (create_vtable_ptr): Take single list of virtuals. Build chain
5586 of declared virtuals here.
5587 (layout_class_type): Take single list of virtuals. Adjust.
5588 (finish_struct_1): Keep virtuals on single list. Adjust.
5589
55765de4
MM
55902002-08-02 Mark Mitchell <mark@codesourcery.com>
5591
5592 * init.c (build_member_call): Use build_new_method_call, not
5593 build_method_call.
5594
d0067571
KW
55952002-08-02 Krister Walfridsson <cato@df.lth.se>
5596
5597 * Make-lang.in (spew.o, lex.o, pt.o): Add path to parse.h dependencies.
5598
4a34e0e8
MM
55992002-08-02 Mark Mitchell <mark@codesourcery.com>
5600
5601 * call.c (build_method_call): Issue a more helpful error message
5602 about ambiguous method names.
5603
41ab2ae2
NS
56042002-08-02 Nathan Sidwell <nathan@codesourcery.com>
5605
5606 * tree.c (build_shared_int_cst): Make cache file scope, and
5607 GTY it.
5608
367aa585
JM
56092002-08-02 Jason Merrill <jason@redhat.com>
5610
a77a9a18
JM
5611 * cp-lang.c (LANG_HOOKS_EXPR_SIZE): Define.
5612 (cp_expr_size): New fn.
5613 * call.c (build_over_call): Lose empty class hackery.
5614 (convert_arg_to_ellipsis): Promote non-POD warning to error.
5615 * typeck.c (build_modify_expr): Don't use save_expr on an lvalue.
5616
367aa585
JM
5617 * semantics.c (expand_body): Do tree optimization in the function
5618 context, too.
5619
4078b403
NB
56202002-08-01 Neil Booth <neil@daikokuya.co.uk>
5621
5622 * cp-tree.h: Move all warning and flag declarations to c-common.h.
5623 * decl.c: Move all warning and flag variables to c-common.c.
5624 * decl2.c: Move all warning and flag variables to c-common.c.
5625 * lex.c (flag_digraphs): Remove.
5626 (warn_traditional): Now in c-common.c.
5627
4ba126e4
MM
56282002-07-31 Mark Mitchell <mark@codesourcery.com>
5629
5630 * call.c (build_field_call): Do not look up the field by name.
5631 (build_method_call): Simplify.
5632 (struct z_candidate): Add access_path and conversion_path. Remove
5633 basetype_path.
5634 (convert_class_to_reference): Adjust use of
5635 add_function_candidate.
5636 (add_candidate): Add conversion_path argument.
5637 (add_function_candidate): Use it.
5638 (add_conv_dndidate): Likewise.
5639 (build_builtin_candidate): Likewise.
5640 (add_template_candidate_real): Add conversion_path argument.
5641 (add_template_conv_candidate): Likewise.
5642 (add_template_candidate): Likewise.
5643 (build_user_type_conversion_1): Use it.
5644 (build_new_function_call): Remove name lookup code. Adjust use of
5645 add_template_candidate and add_function_candidate.
5646 (build_new_op): Likewise.
5647 (convert_like_real): Use build_special_member_call.
5648 (build_over_call): Use cand->conversion_path.
5649 (build_special_member_call): New method.
5650 (build_new_method_call): Remove name lookup code.
5651 * cp-tree.def (OFFSET_REF): Update documentation.
5652 (TEMPLATE_ID_EXPR): Likewise.
5653 * cp-tree.h (BASELINK_ACCESS_BINFO): New macro.
5654 (BASELINK_OPTYPE): Likewise.
5655 (build_new_method_call): Adjust prototype.
5656 (build_special_member_call): New method.
5657 (build_baselink): New method.
5658 (build_offset_ref_call_from_tree): Likewise.
5659 (build_call_from_tree): Likewise.
5660 (finish_qualified_call_expr): Remove.
5661 (finish_call_expr): Adjust prototype.
5662 (build_x_function_call): Remove.
5663 * cvt.c (ocp_convert): Use build_special_member_call.
5664 * decl2.c (reparse_absdcl_as_expr): Use finish_call_expr.
5665 (build_expr_from_tree): Adjust handling for TEMPLATE_ID_EXPR and
5666 CALL_EXPR.
5667 (build_offset_ref_call_from_tree): New function.
5668 (build_call_from_tree): Likewise.
5669 * init.c (expand_cleanup): Use build_special_member_call.
5670 (expand_default_init): Likewise.
5671 (build_member_call): Use finish_call_expr.
5672 (build_new_1): Use build_special_member_call.
5673 (push_base_cleanups): Likewise.
5674 * method.c (do_build_assign_ref): Likewise.
5675 * parse.y (template_id): Do not pass a COMPONENT_REF to
5676 lookup_template_function.
5677 (primary): Use parse_finish_call_epxr, not finish_call_expr.
5678 (parse_finish_call_expr): New function.
5679 * pt.c (lookup_template_function): Add assertions.
5680 * search.c (lookup_base): Allow T to be a binfo.
5681 (build_baselink): New function.
5682 (lookup_member): Use it.
5683 * semantics.c (finish_call_expr): Do not do name lookup.
5684 (finish_object_call_expr): Remove #if 0'd code.
5685 (finish_qualified_call_expr): Remove.
5686 * typeck.c (build_x_function_call): Remove.
5687 (build_static_case): Use build_special_member_call.
5688 * typeck2.c (build_functional_cast): Likewise.
b6ce26ac 5689
60b8aa94
FS
56902002-07-30 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
5691
5692 * lang-specs.h: Remove __GXX_ABI_VERSION, moved to gcc.c.
5693
8a4a7242
GDR
56942002-07-30 Gabriel Dos Reis <gdr@nerim.net>
5695
5696 * cp-tree.h (VF_DERIVED_VALUE): Restore from previous deletion.
5697
03fc215c
NS
56982002-07-30 Nathan Sidwell <nathan@codesourcery.com>
5699
5700 * cp-tree.h (CLASSTYPE_VFIELDS, VF_*, BV_*): Add more
5701 documentation.
5702
3f16a8f3
AM
57032002-07-29 Alan Modra <amodra@bigpond.net.au>
5704
5705 * cp-tree.h: Comment typo fix.
5706
c03d566f
RE
57072002-07-29 Richard Earnshaw <rearnsha@arm.com>
5708
5709 * spew.c (space_for_token): Allocate zeroed memory for a new token
5710 chunk.
5711
c2ef6d34
RS
57122002-07-27 Roger Sayle <roger@eyesopen.com>
5713
5714 * decl.c (builtin_function_1): No need to explicitly mark
5715 BUILT_IN_RETURN and BUILT_IN_EH_RETURN as noreturn.
5716
a3926fe1
RS
57172002-07-27 Roger Sayle <roger@eyesopen.com>
5718
5719 * decl2.c (cxx_decode_option): Support -fno-builtin-foo.
5720
8e51619a
JM
57212002-07-26 Jason Merrill <jason@redhat.com>
5722
5723 * call.c (build_over_call): Likewise.
5724 (cp_convert_parm_for_inlining): New fn.
f989ed67
ZW
5725 (convert_for_arg_passing): New fn.
5726 (convert_default_arg, build_over_call): Use it.
8e51619a
JM
5727 (type_passed_as): New fn.
5728 * pt.c (tsubst_decl): Use it.
5729 * decl2.c (cp_build_parm_decl): New fn.
5730 (build_artificial_parm): Use it.
5731 (start_static_storage_duration_function): Likewise.
5732 * decl.c (start_cleanup_fn, grokdeclarater): Likewise.
5733 (grokparms): Don't mess with DECL_ARG_TYPE.
5734 * typeck.c (convert_arguments): Use convert_for_arg_passing.
5735 * cp-lang.c (LANG_HOOKS_TREE_INLINING_CONVERT_PARM_FOR_INLINING):
5736 Define.
5737 * cp-tree.h: Declare new fns.
b6ce26ac 5738
c372b0fa
NB
57392002-07-26 Neil Booth <neil@daikokuya.co.uk>
5740
5741 * cp-tree.h (flag_operator_names): Remove.
5742 * decl2.c (flag_operator_names): Remove.
5743 (lang_f_options): Remove operator-names.
5744 * lex.c (D_OPNAME): Remove.
5745 (reswords): Remove operator names.
5746 (rid_to_yy): Remove operator names.
5747 (init_reswords): No need to handle D_OPNAME.
5748 * spew.c (read_process_identifier): There are no operator
5749 names.
5750
558ee214
JM
57512002-07-26 Jason Merrill <jason@redhat.com>
5752
5753 * dump.c (cp_dump_tree): Call c_dump_tree.
5754 * Make-lang.in (CXX_C_OBJS): Add c-dump.o.
5755
81a1552d
NB
57562002-07-25 Neil Booth <neil@daikokuya.co.uk>
5757
5758 * error.c (print_whitespace): Remove.
5759 * g++spec.c (LIBUNWIND): Move.
5760 * mangle.c (mangled_position, write_signed_number): Remove.
5761
cad2c6b6
NB
57622002-07-25 Neil Booth <neil@daikokuya.co.uk>
5763
5764 * decl2.c (cxx_decode_option): Similarly.
5765
ea793912
GDR
57662002-07-25 Gabriel Dos Reis <gdr@nerim.net>
5767
5768 * cp-tree.h (cxx_sizeof_nowarn): Now a macro.
5769 (cxx_sizeof_or_alignof_type): Take a third argument.
5770 (cxx_sizeof): Adjust definition.
5771 (cxx_alignof): Likewise.
5772 * init.c (build_delete): Use cxx_sizeof_nowarn to reflect reality.
5773 * typeck.c (cxx_sizeof_or_alignof_type): Take a third argument for
5774 complaining.
5775 (c_sizeof_nowarn): Remove definition.
5776 (build_unary_op): Use cxx_sizeof_nowarn.
5777
3cfab7ec
GK
57782002-07-24 Geoffrey Keating <geoffk@redhat.com>
5779
5780 * tree.c (cp_build_qualified_type_real): When copying
5781 pointer-to-method types, unshare the record that holds
5782 the cached pointer-to-member-function type.
5783
c0667597
NB
57842002-07-23 Neil Booth <neil@daikokuya.co.uk>
5785
5786 * cp-tree.h (FILE_FUNCTION_PREFIX_LEN): Remove.
5787
fa72b064
GDR
57882002-07-23 Gabriel Dos Reis <gdr@nerim.net>
5789
5790 Fix PR/7363:
5791 * typeck.c (cxx_sizeof_or_alignof_type): New function.
5792 (c_sizeof): Remove definition.
5793 (expr_sizeof): Use cxx_sizeof.
5794 * decl2.c (build_expr_from_tree): Use cxx_sizeof_or_alignof_type.
5795 * decl.c (finish_destructor_body): Use cxx_sizeof.
5796 * semantics.c (finish_alignof): Likewise.
5797 (finish_alignof): Use cxx_alignof.
5798 * cp-tree.h (cxx_sizeof, cxx_alignof): New macros.
5799 (cxx_sizeof_or_alignof_type): Declare.
5800 (my_friendly_assert): Move to ../c-common.h.
5801
4fa31c2a
NB
58022002-07-23 Neil Booth <neil@daikokuya.co.uk>
5803
5804 * class.c, method.c, pt.c, search.c: Don't define obstack macros.
5805
0e902d98
KL
58062002-07-22 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5807
5808 PR c++/7347, c++/7348
5809 * cp-tree.h (tsubst_flags_t): Add tf_parsing.
5810 * decl.c (make_typename_type): Use it.
5811 (make_unbound_class_template): Likewise.
5812 (lookup_name_real): Don't call type_access_control if scope is
5813 template parameter dependent.
5814 * parse.y (template_arg): Call make_unbound_class_template with
5815 tf_parsing set.
5816 (nest_name_specifier): Call make_typename_type with tf_parsing set.
5817 (typename_sub0): Likewise.
5818 (typename_sub1): Likewise.
5819 (instantiate_decl): Push class scope.
5820 * pt.c (regenerate_decl_from_template): Call pushclass and popclass
5821 for both static variable and member function template.
5822 (instantiate_decl) Call pushclass and popclass when tsubst'ing type
5823 and arguments.
5824 * search.c (type_access_control): Do type access for TEMPLATE_DECL
5825 too.
5826
b886c620
RS
58272002-07-20 Roger Sayle <roger@eyesopen.com>
5828
5829 * decl2.c (cxx_decode_option): Simplify -fhandle-exceptions
5830 test by using positive_option. Make whitespace consistent.
5831
7a561142
GDR
58322002-07-20 Gabriel Dos Reis <gdr@nerim.net>
5833
fa72b064 5834 * spew.c (struct unparsed_test): Replace 'filename' and 'lineno'
7a561142
GDR
5835 members with 'locus'. Adjust use throughout.
5836 (struct feed): Likewise.
5837 (alloc_unparsed_test): Change prototype, take a 'const location_t *'.
5838 Adjust use.
5839 (snarf_defarg): Use error(), not error_with_file_and_line().
5840
059ba716
CD
58412002-07-19 Chris Demetriou <cgd@broadcom.com>
5842
5843 * lang-specs.h (@c++): Include "%2" (cc1plus_spec) wherever
5844 cpp_options is included.
5845
d955f6ea
KL
58462002-07-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5847
5848 PR c++/2862, c++/2863
5849 * pt.c (determine_specialization): Compare the length of
5850 TYPE_ARG_TYPES. Tidy.
5851
d03d18e8
KL
58522002-07-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5853
5854 PR c++/3797
5855 * decl.c (duplicate_decls): Don't propagate inlining parameters from
b6ce26ac 5856 olddecl to newdecl when newdecl is a specialization of the
d03d18e8
KL
5857 instantiation olddecl.
5858
ba59df78
KL
58592002-07-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5860
5861 PR c++/4802, c++/5387
5862 * decl.c (make_typename_type): Use enforce_access.
5863
58f05188
SS
58642002-07-17 Scott Snyder <snyder@fnal.gov>
5865
5866 PR c++/7320
5867 * rtti.c (get_tinfo_decl): Set DECL_COMDAT.
5868
04ec0065
MM
58692002-07-12 Mark Mitchell <mark@codesourcery.com>
5870
5871 * class.c (add_method): Correct handling of conversion operators.
5872
f0ab6bf2
MM
58732002-07-11 Mark Mitchell <mark@codesourcery.com>
5874
5875 PR c++/7224
5876 * class.c (add_method): Simplify.
5877
34902e16
JM
58782002-07-11 Jason Merrill <jason@redhat.com>
5879
5880 PR c++/7279
5881 * tree.c (cp_copy_res_decl_for_inlining): Also copy
5882 TREE_ADDRESSABLE.
5883
6e04241f
GS
58842002-07-10 Graham Stott <graham.stott@btinternet.com>
5885
5886 * pt.c (template_parm_this_level_p, push_template_decl_real):
b6ce26ac 5887 Pass depth as int pointer.
6e04241f 5888
8ac9d31f
TJ
58892002-07-11 Tim Josling <tej@melbpc.org.au>
5890
b6ce26ac 5891 Remove front end hard coding from gengtype.c.
8ac9d31f
TJ
5892
5893 * config-lang.in (gtfiles): Add files needed for this front end.
5894
15c7fb9c
MM
58952002-07-10 Mark Mitchell <mark@codesourcery.com>
5896
5897 * cp-tree.h (unqualified_name_lookup_error): Declare it.
5898 (begin_function_definition): Adjust prototype.
5899 * lex.c (unqualified_name_lookup_error): New function, split out
5900 from ...
5901 (do_identifier): ... here.
5902 * parse.y (parse_begin_function_definition): New function.
5903 (fn.def1): Use it.
5904 * semantics.c (begin_function_definition): Accept decl-specifiers
5905 and attributes as separate parameters.
5906
abf92e26
JM
59072002-07-10 Jason Merrill <jason@redhat.com>
5908
5909 PR c++/6255
5910 * decl.c (lookup_name_real): Build a new TYPENAME_TYPE rather than
5911 modifying the old one.
5912
8ba658ee
MM
59132002-07-09 Mark Mitchell <mark@codesourcery.com>
5914
5915 * cp-tree.h (constructor_name_p): Declare it.
5916 (check_template_template_default_arg): Likewise.
5917 * class.c (handle_using_decl): Use constructor_name_p.
5918 * decl.c (grokdeclarator): Likewise.
5919 * decl2.c (constructor_name_p): Define it.
5920 * init.c (build_member_call): Use constructor_name_p.
5921 * parse.y (template_parm): Use check_template_template_default_arg.
5922 * pt.c (check_explicit_specialization): Use constructor_name_p.
5923 * semantics.c (check_template_template_default_arg): New function.
b6ce26ac 5924
d5372501
KL
59252002-07-08 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5926
5927 * pt.c (can_complete_type_without_circularity): Add static to
5928 function definition.
5929
594bb0e7
MM
59302002-07-08 Mark Mitchell <mark@codesourcery.com>
5931
5932 * cp-tree.h (have_extern_spec): Declare it
5933 * decl.c (have_extern_spec): Define it.
5934 (start_decl): Eliminate use of used_extern_spec.
5935 (start_function): Likewise.
5936 * parse.y (have_extern_spec): Remove declaration.
5937 (used_extern_spec): Likewise.
5938 (frob_specs): Eliminate use of used_extern_spec.
5939 (.hush_warning): Likewise.
5940
eb8845be
MM
59412002-07-07 Mark Mitchell <mark@codesourcery.com>
5942
5943 * Make-lang.in (cp/parse.o): Depend on decl.h.
5944 * cp-tree.h (do_decl_instantiation): Change prototype.
5945 * parse.y: Include decl.h.
5946 (parse_decl_instantiation): New function.
5947 (explicit_instantiation): Use it.
5948 * pt.c (do_decl_instantiation): Accept a DECL, not a DECLARATOR
5949 and DECLSPECS.
b6ce26ac 5950
78abea27
RS
59512002-07-07 Roger Sayle <roger@eyesopen.com>
5952
5953 * error.c (dump_function_name): Use DECL_TEMPLATE_RESULT for
5954 constructor and destructor tests when passed a TEMPLATE_DECL.
5955
98c07d7b
JM
59562002-07-05 Jason Merrill <jason@redhat.com>
5957
212e17fd
JM
5958 * cvt.c (cp_convert_to_pointer): Call force_fit_type for null
5959 pointers.
5960
98c07d7b
JM
5961 PR optimization/7145
5962 * tree.c (cp_copy_res_decl_for_inlining): Also copy DECL_INITIAL.
5963
c6f553d1
NS
59642002-07-05 Nathan Sidwell <nathan@codesourcery.com>
5965
5966 Repair damage on weak-impared targets caused by my previous patch.
5967 * cp-tree.h (import_export_tinfo): Add parameter.
5968 * decl2.c (import_export_tinfo): Add parameter, post adjust
5969 DECL_COMDAT.
5970 * rtti.c (emit_tinfo_decl): DECL_COMDAT is (nearly) always setup by
5971 import_export_tinfo.
5972
b2153b98
KL
59732002-07-03 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5974
5975 PR c++/6944
5976 * init.c (build_aggr_init): Remove qualifiers of init before calling
5977 build_vec_init.
5978 (build_vec_init): Flatten multi-dimensional array during cleanup.
5979 (build_vec_delete_1): Abort if the type of each element is array.
5980
492ff760
GS
59812002-07-03 Graham Stott <graham.stott@btinternet.com>
5982
5983 * pt.c (instantiate_class_template): Fix typo.
5984
04c4491d
KL
59852002-07-02 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5986
06728f70
KL
5987 * typeck2.c (cxx_incomplete_type_diagnostic): Fix typo caused
5988 by CVS conflict in my last patch.
04c4491d 5989
17f29637
KL
59902002-07-02 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
5991
5992 PR c++/6716
5993 * pt.c (can_complete_type_without_circularity): New function.
5994 (instantiate_class_template): Use it.
06728f70
KL
5995 * typeck2.c (cxx_incomplete_type_diagnostic): Improve error
5996 message due to incomplete fields.
17f29637 5997
5d69ba1f
MM
59982002-07-01 Mark Mitchell <mark@codesourcery.com>
5999
6000 PR c++/7112
6001 * mangle.c (write_expression): Add mangling for sizeof when
6002 applied to a type.
6003 * operators.def: Remove stale comment.
6004
d689a8f1
NS
60052002-06-30 Nathan Sidwell <nathan@codesourcery.com>
6006
6007 * cp-tree.h (CPTI_TINFO_DECL_TYPE): Replace with ...
6008 (CPTI_TYPE_INFO_PTR_TYPE): ... this.
6009 (tinfo_decl_type): Replace with ...
6010 (type_info_ptr_type): ... this.
6011 (import_export_tinfo): Declare.
6012 (tinfo_decl_p): Rename to ...
6013 (unemitted_tinfo_decl_p): ... this.
6014 * decl2.c (import_export_decl): Break out tinfo handling into ...
6015 (import_export_tinfo): ... here. New function.
6016 (finish_file): Adjust.
6017 * rtti.c (TINFO_REAL_NAME): New macro.
6018 (init_rtti_processing): Create the tinfo types.
6019 (get_tinfo_decl_dynamic): Use type_info_ptr_type, get_tinfo_ptr.
6020 (get_tinfo_decl): Adjust.
6021 (get_tinfo_ptr): New function.
6022 (get_type_id): Use it.
6023 (tinfo_base_init): Create vtable decl here, if it doesn't exist.
6024 (ptr_initializer): Use get_tinfo_ptr.
6025 (ptm_initializer): Likewise.
6026 (synthesize_tinfo_var): Break into ...
6027 (get_pseudo_ti_init): ... this. Just create the initializer.
6028 (get_pseudo_ti_desc): .. and this.
6029 (create_real_tinfo_var): Remove.
6030 (create_pseudo_type_info): Don't create the vtable decl here.
6031 (get_vmi_pseudo_type_info): Remove.
6032 (create_tinfo_types): Adjust.
6033 (tinfo_decl_p): Rename to ...
6034 (unemitted_tinfo_decl_p): ... here. Adjust.
6035 (emit_tinfo_decl): Adjust. Create the initializer.
6036
5ce49b4b
MM
60372002-06-27 Mark Mitchell <mark@codesourcery.com>
6038
6039 PR c++/6695
6040 * pt.c (tsubst_friend_class): Substitute into the context of the
6041 friend before using it.
6042
88e5899c
MM
60432002-06-26 Mark Mitchell <mark@codesourcery.com>
6044
6045 * cp-tree.h (xref_tag): Change prototype.
6046 (handle_class_head): Likewise.
6047 (build_x_component_ref): Likewise.
6048 * decl.c (cxx_init_decl_processing): Adjust call to xref_tag.
6049 (xref_tag): Take attributes as a separate parameter.
6050 (xref_tag_from_type): Adjust call to xref_tag.
6051 * decl2.c (build_expr_from_tree): Adjust call to
6052 build_x_component_ref.
6053 (handle_class_head): Take attributes as a separate parameter.
6054 * parse.y (parse_xref_tag): New function.
6055 (parse_handle_class_head): Likewise.
6056 (primary): Use parse_xref_tag.
6057 (class_head_decl): Use parse_handle_class_head.
6058 (class_head_defn): Likewise.
6059 * rtti.c (init_rtti_processing): Adjust call to xref_tag.
6060 (build_dynamic_cast_1): Likewise.
6061 (create_pseudo_type_info): Likewise.
6062 (emit_support_tinfos): Likewise.
6063 * typeck.c (build_object_ref): Adjust call to
6064 build_x_component_ref.
6065 (build_x_component_ref): Remove protect parameter.
b6ce26ac 6066
da15dae6
MM
60672002-06-25 Mark Mitchell <mark@codesourcery.com>
6068
6069 * call.c (build_op_delete_call): Use BASELINK_FUNCTIONS.
6070 * class.c (handle_using_decl): Likewise.
6071 (instantiate_type): Likewise.
6072 * cp-tree.h (BASELINK_FUNCTIONS): New macro.
6073 (xref_basetypes): Change prototype.
6074 (begin_mem_initializers): New function.
6075 (get_overloaded_fn): Likewise.
6076 * decl.c (xref_basetypes): Simplify.
6077 * error.c (dump_expr): Use BASELINK_FUNCTIONS.
6078 * init.c (build_offset_ref): Likewise.
6079 * parse.y (base_init): Use begin_mem_initializers().
6080 (structsp): Adjust call to xref_basetypes.
6081 * pt.c (determine_specialization): Use BASELINK_FUNCTIONS.
6082 (instantiate_class_template): Adjust call to xref_basetypes.
6083 * semantics.c (begin_mem_initializers): New function.
6084 * tree.c (is_overloaded_fn): Use BASELINK_FUNCTIONS.
6085 (really_overlaoded_fn): Likewise.
6086 (get_overloaded_fn): New function.'
6087 (get_first_fn): USe BASELINK_FUNCTIONS.
b6ce26ac 6088
5f261ba9
MM
60892002-06-24 Mark Mitchell <mark@codesourcery.com>
6090
6091 * cp-tree.h (SCALAR_TYPE_P): New macro.
6092 (check_for_out_of_scope_variable): New function.
6093 (at_class_scope_p): Likewise.
6094 (finish_fname): Likewise.
6095 * class.c (finish_struct): Use at_function_scope_p.
6096 * decl.c (check_for_out_of_scope_variable): New function, split
6097 out from do_identifier.
6098 (finish_enum): Use at_function_scope_p.
6099 * lex.c (do_identifier): Use check_for_out_of_scope_variable.
6100 * parse.y (VAR_FUNC_NAME): Give it <ttype>. Use finish_fname.
6101 (primary): Use at_function_scope_p.
6102 * search.c (at_class_scope_p): New function.
6103 * semantics.c (finish_fname): Likewise.
6104 (check_multiple_declarators): Use at_function_scope_p.
b6ce26ac 6105
80b1331c
MM
61062002-06-23 Mark Mitchell <mark@codesourcery.com>
6107
6108 * parse.y (parse_scoped_id): New function.
6109 (primary): Use it.
6110 * cp-tree.h (do_scoped_id): Adjust declaration.
6111 * lex.c (do_scoped_id): Remove call to yylex.
6112 * decl2.c (build_expr_from_tree): Adjust use of do_scoped_id.
6113 * typeck2.c (add_exception_specifier): Use tree_cons, rather than
6114 expanding it inline.
b6ce26ac 6115
08c7ae5a
MT
61162002-06-23 Matt Thomas <matt@3am-software.com>
6117
6118 * decl.c (finish_function): Change "#ifdef VMS_TARGET" to
6119 "#if VMS_TARGET".
6120
eb6b51b9
KG
61212002-06-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
6122
6123 * mangle.c (integer_type_codes): Const-ify.
6124
aa8dea09
RH
61252002-06-20 Richard Henderson <rth@redhat.com>
6126
6127 PR c++/6747
f989ed67
ZW
6128 * typeck.c (mark_addressable): Don't test TREE_ADDRESSABLE early.
6129 Call put_var_into_stack.
aa8dea09 6130
62c71f4b
KG
61312002-06-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
6132
6133 * spew.c (remove_last_token): Use ARRAY_SIZE in lieu of explicit
6134 array size calculation.
6135
aa16c0fa
KL
61362002-06-20 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
6137
6138 PR c++/6892
6139 * pt.c (tsubst_expr): Handle FILE_STMT.
6140
342cea95
KL
61412002-06-20 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
6142
6143 PR c++/6723
6144 * pt.c (lookup_template_class): Don't build complete argument of
6145 BOUND_TEMPLATE_TEMPLATE_PARM if appeared as a default template
6146 argument.
6147
84d901be
AD
61482002-06-19 Akim Demaille <akim@epita.fr>
6149
6150 * parse.y (TYPENAME): Rename as tTYPENAME to avoid the clash with
6151 decl.h's TYPENAME.
6152 * spew.c, lex.c: Adjust.
6153 * parse.y (explicit_instantiation): Add empty action to override
6154 the default $$ = $1 where it introduces a type clash.
6155
83b14b88
JM
61562002-06-14 Jason Merrill <jason@redhat.com>
6157
18ba380b
JM
6158 * semantics.c (begin_for_stmt): Push the 'for' scope before
6159 adding the FOR_STMT.
6160
83b14b88
JM
6161 C++ ABI changes.
6162 * class.c (build_base_field): Set DECL_PACKED.
6163 (layout_class_type): Don't use tail padding of PODs.
6164 * mangle.c (write_unqualified_name): Fix template conversion op
6165 mangling.
6166
fd852454
RH
61672002-06-16 Richard Henderson <rth@redhat.com>
6168
6169 PR opt/6793
6170 * tree.c (cp_cannot_inline_tree_fn): Don't short-circuit test
6171 after template instantiation.
6172
750491fc
RH
61732002-06-16 Richard Henderson <rth@redhat.com>
6174
6175 * cp-tree.h, decl2.c (flag_ms_extensions): Move to c-common.
6176
f7d3c5f0
GDR
61772002-06-15 Gabriel Dos Reis <gdr@codesourcery.com>
6178
6179 * cp-tree.h (compiler_error): Remove declaration.
6180 * lex.c (compiler_error): Remove definition.
6181
893a047c
SE
61822002-06-14 Steve Ellcey <sje@cup.hp.com>
6183
6184 * g++spec.c (LIBUNWIND): New.
6185 (lang_specific_driver): Add it if USE_UNWIND_EXCEPTIONS is set.
6186
a6f5e048
RH
61872002-06-13 Jessica Han <jessica@cup.hp.com>
6188
6189 * class.c (build_vtable): Use TARGET_VTABLE_ENTRY_ALIGN.
6190 (build_vtbl_initializer): Honor TARGET_VTABLE_DATA_ENTRY_DISTANCE.
6191 (build_vbase_offset_vtbl_entries): Likewise.
6192 * rtti.c (build_headof): Likewise.
6193 (get_tinfo_decl_dynamic): Likewise.
6194 (create_pseudo_type_info): Likewise.
6195
e4dadd2a
SS
61962002-06-12 Stan Shebs <shebs@apple.com>
6197
6198 * mpw-config.in: Remove file, no longer used.
6199 * mpw-make.sed: Ditto.
6200
09e77dee
ZW
62012002-06-07 Zack Weinberg <zack@codesourcery.com>
6202
6203 * decl2.c: Update call to cpp_handle_option.
6204
4bafaa6f
L
62052002-06-07 H.J. Lu (hjl@gnu.org)
6206
6207 * decl2.c (flag_use_cxa_atexit): Set to DEFAULT_USE_CXA_ATEXIT.
6208
3cb8660c
GDR
62092002-06-06 Gabriel Dos Reis <gdr@codesourcery.com>
6210
6211 * error.c (cp_error_at): Fix typo.
6212
47b69537
GDR
62132002-06-04 Gabriel Dos Reis <gdr@codesourcery.com>
6214
6215 * error.c (cp_diagnostic_starter): Adjust call.
6216 (maybe_print_instantiation_context): Change prototype to take a
6217 'diagnostic_info *'.
6218 (print_instantiation_full_context): Likewise.
6219 (print_instantiation_partial_context): Likewise.
6220 (cp_diagnostic_starter): Likewise.
6221 (cp_diagnostic_finalizer): Likewise.
6222 (cp_print_error_function): Likewise.
6223 (cp_printer): Take a secondary parameter as a 'text_info *'.
6224 Remove output_state savings. Adjust calls.
6225
e2500fed
GK
62262002-06-03 Geoffrey Keating <geoffk@redhat.com>
6227
6228 * pt.c (inline_parm_levels): Mark for GC.
6229
6230 * mangle.c (start_mangling): Allocate G.substitutions here...
6231 (init_mangle): ... rather than here.
6232 (finish_mangling): Clear the varray pointer when done with it.
84d901be
AD
6233 * spew.c (yylexstring): Don't use VARRAY_FREE.
6234 * search.c (bfs_walk): Don't use VARRAY_FREE.
e2500fed
GK
6235 * decl2.c (pending_statics): Use gengtype to mark.
6236 (deferred_fns): Likewise.
6237 (ssdf_decls): Likewise.
6238 (init_decl2): Delete.
6239 * decl.c (pop_from_top_level): Don't use VARRAY_FREE.
6240 (cxx_init_decl_processing): Don't call init_decl2.
6241 (cxx_pop_function_context): Don't use VARRAY_FREE.
6242 * cp-tree.h (struct saved_scope): No need for special marking
6243 of varrays.
6244 (struct language_function): Likewise.
6245 (local_classes): Use gengtype to mark.
6246 (init_decl2): Delete prototype.
6247 * class.c (init_class_processing): Don't use
6248 ggc_add_tree_varray_root.
6249 (build_vtbl_initializer): Don't use VARRAY_FREE.
6250
6251 * decl.c (typename_compare): Don't use same_type_p.
6252
6253 * decl.c: Include hashtab.h instead of hash.h.
6254 (typename_hash): Update to use htab_h.
6255 (typename_compare): Likewise.
6256 (typename_htab): Use gengtype to mark.
6257 (build_typename_type): Update to use htab_h.
6258 * Make-lang.in (cp/decl.o): Use HASHTAB_H instead of hash.h.
6259
6260 * Make-lang.in (gt-cp-tree.h): New rule.
6261 (cp/tree.o): Depend on gt-cp-tree.h.
6262 * config-lang.in (gtfiles): Add cp/tree.c.
6263 * tree.c: Include gt-cp-tree.h.
6264 (list_hash_table): Use gengtype to mark.
6265 (init_tree): Use gengtype to mark trees.
6266
6267 * Make-lang.in (cp/decl.o): Add debug.h dependency.
6268 * call.c (struct z_candidate): Use gengtype.
6269 (USER_CONV_CAND): Use WRAPPER_ZC.
6270 (convert_class_to_reference): Use build_zc_wrapper.
6271 (build_type_conversion_1): Likewise.
6272 (build_over_call): Use WRAPPER_ZC.
6273 (add_warning): Use build_zc_wrapper.
6274 * cp-lang.c (LANG_HOOKS_MARK_TREE): Delete.
6275 * cp-tree.h (struct lang_identifier): Use gengtype.
6276 (struct template_parm_index_s): Likewise.
6277 (struct ptrmem_cst): Likewise.
6278 (struct tree_binding): Likewise.
6279 (struct tree_overload): Likewise.
6280 (struct tree_srcloc): Likewise.
6281 (struct tree_wrapper): Likewise. Also modify to have a pointer
6282 to struct z_candidate rather than void.
6283 (enum cp_tree_node_structure_enum): New.
6284 (union lang_tree_node): New.
6285 (cxx_mark_tree): Delete prototype.
6286 (cp_tree_node_structure): New prototype.
6287 (build_ptr_wrapper): Delete prototype.
6288 (build_int_wrapper): Delete prototype.
6289 (build_zc_wrapper): New prototype.
6290 * decl.c: Include debug.h
6291 (cxx_mark_tree): Delete.
6292 (cp_tree_node_structure): New.
6293 * tree.c (build_ptr_wrapper): Delete.
6294 (build_int_wrapper): Delete.
6295 (build_zc_wrapper): New.
6296
6297 * cp-tree.h [! ENABLE_TREE_CHECKING] (LANG_TYPE_PTRMEM_CHECK):
6298 Correct typo. Patch from k_fukui@highway.ne.jp.
6299
6300 * semantics.c (current_stmt_tree): Update for change to
6301 struct language_function.
6302 (finish_mem_initializers): Likewise.
6303 * decl.c (cxx_init_decl_processing): Don't set mark_lang_status.
6304 * cp-tree.h (struct language_function): Rename from
6305 cp_language_function. Change all uses.
6306 (cp_function_chain): Don't need to cast.
6307
6308 * class.c (duplicate_tag_error): Reset discriminator.
6309 (check_bases_and_members): Update for data structure changes.
6310 * cp-tree.h (struct lang_id2): Use gengtype.
6311 (flagged_type_tree): Likewise.
6312 (SET_LANG_ID): Use GGC on struct lang_id2.
6313 (struct cp_language_function): Use gengtype. Remove field
6314 'x_vcalls_possible_p'.
6315 (current_vcalls_possible_p): Delete.
6316 (struct lang_type_header): New.
6317 (struct lang_type_class): Rename from struct lang_type. Include
6318 struct lang_type_header.
6319 (struct lang_type_ptrmem): New.
6320 (struct lang_type): New.
6321 (LANG_TYPE_CLASS_CHECK): New. Use it in all the appropriate macros.
6322 (LANG_TYPE_PTRMEM_CHECK): New. Use it in all the appropriate macros.
6323 (TYPE_SET_PTRMEMFUNC_TYPE): Set discriminator, update for changes.
6324 (struct lang_decl_flags): Use gengtype. Add discriminators.
6325 (struct lang_decl): Use gengtype. Add and use discriminators.
6326 Update the macros that reference moved fields.
6327 (LANG_DECL_U2_CHECK): New function. Use it when appropriate.
6328 (SET_DECL_THUNK_P): Set discriminator too.
6329 (clear_inline_text_obstack): Delete prototype.
6330 (finish_inline_definitions): Delete prototype.
6331 (mark_pending_inlines): Delete prototype.
6332 (lang_check_failed): New prototype.
6333 * decl.c (struct named_label_use_list): Use gengtype.
6334 (struct named_label_list): Likewise.
6335 (mark_binding_level): Delete.
6336 (mark_named_label_lists): Delete.
6337 (push_local_name): Set discriminator on DECL_LANG_SPECIFIC.
6338 (cxx_init_decl_processing): Use generated marker routine.
6339 (begin_destructor_body): Delete dead set to
6340 current_vcalls_possible_p.
6341 (mark_lang_function): Delete.
6342 (mark_cp_function_context): Delete.
6343 (lang_mark_tree): Use generated marker routines.
6344 * decl2.c (start_objects): Set discriminator when setting
6345 GLOBAL_INIT_PRIORITY.
6346 * lex.c (retrofit_lang_decl): Set discriminators.
6347 (copy_lang_type): Update for changes to lang_type structure.
6348 (cp_make_lang_type): Set discriminator.
6349 * parse.y: Use gengtype on YYLVAL. Don't use dots in identifiers.
6350 * search.c: Include ggc.h.
6351 * semantics.c (anon_aggr_type_p): Use the macro, don't hand-code it.
6352 (finish_inline_definitions): Delete.
6353 * spew.c (struct token): Use gengtype.
6354 (struct token_chunk): New.
6355 (struct unparsed_text): Use gengtype. Store tokens in chunks.
6356 (struct feed): Use gengtype.
6357 (feed_obstack): Delete.
6358 (feed): Mark as GC root.
6359 (pending_inlines): Mark as GC root.
6360 (pending_inlines_tail): Likewise.
6361 (processing_these_inlines): Likewise.
6362 (token_obstack): Make static.
6363 (first_token): Likewise.
d30d6e7a 6364 (init_spew): Don't initialize deleted things; use gengtype for roots.
e2500fed
GK
6365 (clear_inline_text_obstack): Delete.
6366 (feed_input): Use GC for struct feed. Update for changes to
6367 struct unparsed_text.
6368 (mark_pending_inlines): Delete.
6369 (next_token): Rename from add_token. Change all callers. Update
6370 for changes to struct unparsed_text.
6371 (space_for_token): New.
6372 (remove_last_token): New.
6373 (alloc_unparsed_text): New.
6374 (snarf_block): Take an unparsed_text. Update for changes to struct
6375 unparsed_text.
6376 (snarf_method): Update for changes to struct unparsed_text.
6377 (snarf_defarg): Update for changes to struct unparsed_text.
6378 * tree.c (lang_check_failed): New.
6379
6380 * Make-lang.in (gt-cp-call.h gt-cp-decl2.h gt-cp-parse.h
6381 gt-cp-pt.h gt-cp-repo.h gt-cp-spew.h): New rules.
6382 (cp/spew.o): Add dependency on gt-<filename>.h.
6383 (cp/decl2.o): Add dependency on gt-<filename>.h.
6384 (cp/call.o): Add dependency on gt-<filename>.h.
6385 (cp/pt.o): Add dependency on gt-<filename>.h.
6386 (cp/repo.o): Add dependency on gt-<filename>.h.
6387 (cp/parse.o): Add dependency on gt-<filename>.h.
6388 * call.c: Use gengtype for roots.
6389 * config-lang.in (gtfiles): Add cp-tree.h decl.h lex.h call.c
6390 decl2.c parse.y pt.c repo.c spew.c.
6391 * cp-tree.h: Use gengtype for roots.
6392 (struct saved_scope): Use GGC, gengtype.
6393 (cp_parse_init): Delete prototype.
6394 (init_pt): Delete prototype.
6395 * decl.c: Use gengtype for roots.
6396 (mark_saved_scope): Delete.
6397 (cxx_init_decl_processing): Don't call deleted initilisation
6398 routines.
6399 (signed_size_zero_node): Delete, unused.
6400 * decl.h: Use gengtype for roots.
6401 * decl2.c: Use gengtype for roots.
6402 * lex.h: Use gengtype for roots.
6403 * parse.y: Use gengtype for roots.
6404 (cp_parse_init): Delete.
6405 * pt.c: Use gengtype for roots.
6406 (init_pt): Delete.
6407 * repo.c: Use gengtype for roots.
6408 * spew.c: Use gengtype for roots.
6409
6410 * Make-lang.in: Allow for filename changes. Add gtype-cp.h.
6411 (cp/decl.o): Add dependency on gtype-cp.h.
6412 * decl.c: Remove use of add_deletable_root, use GTY marker instead.
6413 Include gtype-cp.h. Allow for filename changes.
6414
6415 * Make-lang.in (cp/gt-decl.h): Generate using gengtype.
6416 (cp/decl.o): Add cp/gt-decl.h dependency.
6417 * config-lang.in (gtfiles): New.
6418 * tree.h: Rename struct binding_level to struct cp_binding_level.
6419 * decl.c: Rename struct binding_level to struct cp_binding_level.
6420 Include cp/gt-decl.h.
6421 (struct cp_binding_level): Use gengtype.
6422 (make_binding_level): Use GGC on struct cp_binding_level.
6423 (mark_binding_level): Use gt_ggc_m_cp_binding_level.
6424 (cxx_init_decl_processing): Mark free_binding_level as
6425 deletable.
6426
6427 * decl.c (mark_cp_function_context): Update calling sequence.
6428
6429 * decl.c (start_function): Don't free 'struct
6430 cp_language_function'.
6431 (pop_cp_function_context): Likewise.
6432 (save_function_data): Allocate it using GC.
6433 * semantics.c (genrtl_start_function): Don't free 'struct
6434 cp_language_function'.
6435
8b968bd1
MW
64362002-05-31 Matthew Woodcraft <mattheww@chiark.greenend.org.uk>
6437
6438 * lang-specs.h: Use cpp_debug_options.
6439
11ad4784
ZW
64402002-05-28 Zack Weinberg <zack@codesourcery.com>
6441
6442 * mangle.c, tree.c: Include real.h.
6443 * Make-lang.in: Update dependency lists.
6444
81a75f0f
NB
64452002-05-25 Neil Booth <neil@daikokuya.demon.co.uk>
6446
6447 * lex.c: Don't include c-lex.h.
6448 * parse.y, spew.c: Don't include c-lex.h; include c-pragma.h.
6449
a97d1398
NB
64502002-05-23 Neil Booth <neil@daikokuya.demon.co.uk>
6451
6452 * spew.c (yyungetc, snarf_block): Remove indent_level handling.
6453
6f001fdf
RH
64542002-05-22 Richard Henderson <rth@redhat.com>
6455
6456 * decl.c (obscure_complex_init): Check for VAR_DECL
6457 before using DECL_THREAD_LOCAL.
6458
7a1f3f5f
RH
64592002-05-22 Richard Henderson <rth@redhat.com>
6460
6461 * decl.c (check_tag_decl): Handle RID_THREAD.
6462 (obscure_complex_init): Reject run-time init of tls.
6463 (grokvardecl, grokdeclarator): Handle RID_THREAD.
6464 * lex.c (reswords): Add __thread.
6465 (rid_to_yy): Map RID_THREAD to SCSPEC.
6466
e5f3b786
NB
64672002-05-22 Neil Booth <neil@daikokuya.demon.co.uk>
6468
6469 * cp-lang.c (LANG_HOOKS_POST_OPTIONS): Use c_common_post_options.
6470 * cp-tree.h (cxx_post_options): Kill.
6471 * cp-lex.c (cxx_post_options): Kill.
6472
3d78f2e9
RH
64732002-05-21 Richard Henderson <rth@redhat.com>
6474
6475 * lex.c (rid_to_yy): Add RID_THREAD.
6476
c8a3d889
AO
64772002-05-21 Alexandre Oliva <aoliva@redhat.com>
6478
6479 * init.c (build_vec_init): Test for trivial copy-assignment when
6480 copy-assigning arrays.
6481
500abaa8
AJ
64822002-05-20 Andreas Jaeger <aj@suse.de>
6483
6484 * init.c (build_default_init): Remove unused variable.
6485
ecc42c14
AO
64862002-05-20 Alexandre Oliva <aoliva@redhat.com>
6487
6488 * call.c (any_strictly_viable): New.
6489 (build_new_op): Use it for COMPOUND_EXPR and ADDR_EXPRs.
6490
4e664ef1
KL
64912002-05-19 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
6492
6493 * error.c (dump_type) [TYPEOF_TYPE]: Fix parenthesis printing.
6494
07782718
KL
64952002-05-19 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
6496
6497 PR c++/186, DR 259
6498 * pt.c (do_decl_instantiation): Don't complain explicit
6499 instantiation after explicit specialization.
6500 (do_type_instantiation): Likewise.
6501
23b4deba
AO
65022002-05-19 Alexandre Oliva <aoliva@redhat.com>
6503
6504 * cp-tree.h (complete_type_or_diagnostic): Changed prototype,
6505 renamed from...
6506 (complete_type_or_else): ... this. Redefined as macro.
6507 (cxx_incomplete_type_diagnostic): Declare.
6508 (cxx_incomplete_type_error): Define as macro.
6509 * init.c (build_delete): Warn about incomplete types other than
6510 void, and use the built-in operator delete for them.
6511 * typeck.c (complete_type_or_diagnostic): Renamed from
6512 complete_type_or_else. Added warn_only argument, passed to...
6513 * typeck2.c (cxx_incomplete_type_diagnostic): ... this. Print
6514 warnings or errors depending on new warn_only argument. Renamed
6515 from...
6516 (cxx_incomplete_type_error): ... this. New implementation in
6517 terms of cxx_incomplete_type_diagnostic.
6518
b41d214e
JM
65192002-05-18 Jason Merrill <jason@redhat.com>
6520
98c07d7b 6521 PR c++/6611
b41d214e
JM
6522 * decl2.c (import_export_decl): If we clear
6523 DECL_NOT_REALLY_EXTERN, make sure DECL_EXTERNAL is set.
6524
e2005c8d
KL
65252002-05-15 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
6526
6527 PR c++/6620
6528 * pt.c (verify_class_unification): Don't check if PARM is template
6529 parameter dependent. Simplify.
6530 (unify) [TEMPLATE_PARM_INDEX]: Handle when ARG is a template
6531 parameter dependent expression.
6532
ff48be5c
JM
65332002-05-14 Jason Merrill <jason@redhat.com>
6534
6535 * rtti.c (get_tinfo_decl): Don't call comdat_linkage.
6536 Do set DECL_COMDAT.
6537 (synthesize_tinfo_var): Take the public decl.
6538 (create_real_tinfo_var): Likewise. Check DECL_COMDAT.
6539 (emit_tinfo_decl): Adjust. Call import_export_decl.
6540 * decl2.c (import_export_decl): Simplify tinfo decl handling.
6541
94e6e4c4
AO
65422002-05-14 Alexandre Oliva <aoliva@redhat.com>
6543
6544 * cp-tree.h (struct lang_type): Added non_zero_init.
0fe1cd70 6545 (CLASSTYPE_NON_ZERO_INIT_P): New macro.
94e6e4c4
AO
6546 (zero_init_p, force_store_init_value, build_forced_zero_init): Declare.
6547 * class.c (check_field_decls): Test non_zero_init.
6548 * cvt.c (convert_to_pointer_force): Use cp_convert_to_pointer for
6549 zero-to-NULL conversions.
6550 * decl.c (obscure_complex_init): Don't reset DECL_INITIAL of a
6551 type that needs zero-initialization without zeros.
6552 (check_initializer_decl): Compute zero-initializer for types
6553 that require a non-trivial one.
6554 * init.c (build_forced_zero_init): New function.
6555 (build_default_init): Use it.
6556 * tree.c (zero_init_p): New function.
6557 * typeck2.c (force_store_init_value): New function.
6558 (process_init_constructor): Create non-trivial zero-initializers
6559 for array members and class fields.
6560
e5f5feea
NB
65612002-05-14 Neil Booth <neil@daikokuya.demon.co.uk>
6562
6563 * lang-specs.h: Remove redundant -lang-c++.
6564
f63ab951
JM
65652002-05-13 Jason Merrill <jason@redhat.com>
6566
6567 * class.c (build_vtbl_ref_1): Use fixed_type_or_null.
6568 (fixed_type_or_null): See through reference vars.
6569 (build_base_path): Vtable contents are constant.
6570 * typeck.c (get_member_function_from_ptrfunc): Likewise.
6571
0d08ea48
JM
65722002-05-12 Jason Merrill <jason@redhat.com>
6573
6574 * cp-lang.c (ok_to_generate_alias_set_for_type): Backend-created
6575 structs are safe.
6576
3df89291
NB
65772002-05-09 Neil Booth <neil@daikokuya.demon.co.uk>
6578
6579 * cp-tree.h (flag_ansi): Remove.
6580 * decl2.c (flag_ansi): Remove.
6581 (cxx_decode_option): Set flag_iso and flag_undef.
6582
c87978aa
JM
65832002-05-09 Jason Merrill <jason@redhat.com>
6584
6585 * typeck.c (get_member_function_from_ptrfunc): Reorganize.
6586 Use subtraction rather than a bitmask to get the index.
6587 * cvt.c (cp_convert_to_pointer): Bail on an error_mark_node.
6588
6589 * pt.c (tsubst_expr) [ASM_STMT]: Copy ASM_INPUT_P.
6590
a5a49440
NB
65912002-05-07 Neil Booth <neil@daikokuya.demon.co.uk>
6592
6593 * Make-lang.in (decl2.o): Update.
6594 * cp-tree.h (warn_multichar): Remove.
6595 * decl2.c: Include c-common.h.
6596 (warn_multichar): Remove.
6597
609688f3
JM
65982002-05-03 Jason Merrill <jason@redhat.com>
6599
0abc082a
JM
6600 * tree.c (build_cplus_array_type): Only const and volatile get
6601 special handling.
6602
609688f3
JM
6603 * decl.c (BOOL_TYPE_SIZE): Move default to defaults.h.
6604
8b16faa2
MM
66052002-04-30 Mark Mitchell <mark@codesourcery.com>
6606
394ab947 6607 ABI change, returning simple classes from functions.
8b16faa2
MM
6608 * class.c (finish_struct_bits): Only mark TREE_ADDRESSABLE if
6609 TYPE_HAS_TRIVIAL_INIT_REF is false or
6610 TYPE_HAS_NONTRIVIAL_DESTRUCTOR is true.
6611
ac905924
JM
66122002-04-30 Jason Merrill <jason@redhat.com>
6613
2cb008af 6614 PR debug/6436
ac905924
JM
6615 * decl.c (grokdeclarator): Don't override TYPE_NAME of an
6616 anonymous class with a typedef if there are attributes.
6617
e6e81f1c 66182002-04-29 Paul Eggert <eggert@twinsun.com>
b819d9e0 6619
e6e81f1c 6620 * parse.y (nomods_initdcl0): Replace $<ttype>3 with $<ttype>$.
b819d9e0 6621
3a73bffb
JJ
66222002-04-29 Jakub Jelinek <jakub@redhat.com>
6623
6624 PR c++/6477
6625 * decl.c (follow_tag_typedef): Check if TYPE_NAME (original) is
6626 non-NULL first.
6627
33dd07ee
MM
66282002-04-29 Mark Mitchell <mark@codesourcery.com>
6629
6630 PR c++/6492
6631 * pt.c (tsubst_friend_class): If the friend has an explicit scope,
6632 enter that scope before name lookup.
6633
6634 PR c++/6486
6635 * method.c (do_build_copy_constructor): Avoid building
6636 cv-qualified reference types.
500abaa8 6637
4bd7c270
NS
66382002-04-29 Nathan Sidwell <nathan@codesourcery.com>
6639
6640 PR c++/5719
500abaa8 6641 * decl.c (grok_op_properties): Assignment ops don't have to return
4bd7c270
NS
6642 by value. operator% should.
6643
45806a3f
FS
66442002-04-28 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
6645
6646 PR c/6343
6647 * decl.c (duplicate_decls): Call merge_weak.
6648
94a50397
RH
66492002-04-26 Richard Henderson <rth@redhat.com>
6650
6651 * parse.y (malloced_yyss, malloced_yyvs): New.
6652 (yyoverflow): Re-add. Set them.
6653 (free_parser_stacks): New.
6654
7d793e9b
MM
66552002-04-26 Mark Mitchell <mark@codesourcery.com>
6656
6657 PR c++/6497
6658 * method.c (do_build_assign_ref): Pass a derivation to
6659 build_method_call when calling base class assignment operators.
6660
bde3c0c0
RH
66612002-04-26 Richard Henderson <rth@redhat.com>
6662
6663 * parse.y (yyoverflow): Revert.
6664
b84a3874
RH
66652002-04-26 Richard Henderson <rth@redhat.com>
6666
6667 PR c/3581
6668 * parse.y (string): Remove. Update all uses to use STRING
6669 instead, and not call combine_strings.
6670 * rtti.c (tinfo_name): Use fix_string_type.
6671 * semantics.c (finish_asm_stmt): Don't call combine_strings.
6672 * spew.c (yylexstring): New.
6673 (read_token): Use it.
6674
6052bef0
RH
66752002-04-25 Richard Henderson <rth@redhat.com>
6676
6677 PR c/2161
6678 * parse.y (yyoverflow): New.
6679
8d1f0f67
JM
66802002-04-25 Jason Merrill <jason@redhat.com>
6681
6682 PR c++/5607
6683 * search.c (check_final_overrider): No longer static.
6684 * class.c (update_vtable_entry_for_fn): Call it.
6685 * cp-tree.h: Adjust.
6686
ff45c01e
NB
66872002-04-25 Neil Booth <neil@daikokuya.demon.co.uk>
6688
6689 * cp-lang.c (LANG_HOOKS_SET_YYDEBUG): Remove.
6690 * cp-tree.h (cxx_set_yydebug): Die.
6691 * lex.c (YYDEBUG): Get from c-lex.h.
6692 (cxx_set_yydebug): Remove.
6693 * parse.y: Include c-lex.h.
6694 (YYDEBUG): Get from c-lex.h.
6695
a62d375f
MM
66962002-04-24 Mark Mitchell <mark@codesourcery.com>
6697
6698 PR c++/6438.
6699 * cvt.c (convert_to_void): Don't unconditionally make COND_EXPRs
6700 void.
6701
349ae713
NB
67022002-04-24 Neil Booth <neil@daikokuya.demon.co.uk>
6703
6704 * cp-lang.c (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE,
6705 LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE, LANG_HOOKS_ATTRIBUTE_TABLE):
6706 Redefine.
6707 * cp-tree.h (cp_attribute_table): Rename.
6708 * decl.c (lang_attribute_table): Remove declaration.
6709 (cxx_init_decl_processing): Don't set it.
6710 * tree.c (cp_attribute_table): Rename.
6711
b602511f
JM
67122002-04-24 Jason Merrill <jason@redhat.com>
6713
985723ce
JM
6714 PR c++/6331
6715 * method.c (do_build_copy_constructor): Use cp_build_qualified_type.
6716 * typeck.c (build_modify_expr): Allow arrays to differ in cv-quals.
a49cfba8
JM
6717 The pedwarn for array assignment is now unconditional.
6718 * tree.c (build_cplus_array_type_1): Still process simple array types
6719 normally in templates.
985723ce 6720
b602511f
JM
6721 PR c++/6395
6722 * decl.c (make_rtl_for_nonlocal_decl): Don't mess with #pragma i/i
6723 stuff for comdats.
6724
29cece2e
JJ
67252002-04-23 Jakub Jelinek <jakub@redhat.com>
6726
6727 * parse.y (check_class_key): Allow KEY to be union/enum/struct/class
6728 node with attributes.
6729
515387dc
DB
67302002-2-23 David O'Brien <obrien@FreeBSD.org>
6731
6732 * g++spec.c (MATH_LIBRARY_PROFILE, LIBSTDCXX_PROFILE): Add.
6733 Use MATH_LIBRARY_PROFILE and LIBSTDCXX_PROFILE if profile flag given.
6734
77adef84
MM
67352002-04-23 Mark Mitchell <mark@codesourcery.com>
6736
6737 PR c++/6256:
6738 * pt.c (tsubst_friend_class): Handle templates with explicit
6739 nested names.
6740
6741 PR c++/6331:
6742 * typeck.c (merge_types): Remember the cv-qualification of pointer
6743 types when merging them.
6744
b03e38e1
NB
67452002-04-20 Neil Booth <neil@daikokuya.demon.co.uk>
6746
6747 * cp-lang.c (LANG_HOOKS_FUNCTION_INIT,
6748 LANG_HOOKS_FUNCTION_FREE, LANG_HOOKS_FUNCTION_MARK): Redefine.
6749 * cp-tree.h (cxx_push_function_context, cxx_pop_function_context,
6750 cxx_mark_function_context): New.
6751 * decl.c (push_cp_function_context, pop_cp_function_context,
6752 mark_cp_function_context): Rename for consistency.
6753 (cxx_init_decl_processing): Don't set old hooks.
6754
ab393bf1
NB
67552002-04-19 Neil Booth <neil@daikokuya.demon.co.uk>
6756
6757 * call.c (convert_type_from_ellipsis): Rename, update.
6758 * cp-lang.c (LANG_HOOKS_TYPE_PROMOTES_TO): Redefine.
6759 * cp-tree.h (convert_type_from_ellipsis): Rename.
6760 * decl.c (cxx_init_decl_processing): Don't set hook.
6761
7a228918
NB
67622002-04-18 Neil Booth <neil@daikokuya.demon.co.uk>
6763
6764 * call.c (build_new_method_call): Update.
6765 * cp-lang.c (LANG_HOOKS_INCOMPLETE_TYPE_ERROR): Redefine.
6766 * cp-tree.h (cxx_incomplete_type_error): New.
6767 * decl.c (grokdeclarator, grokparms): Update.
6768 * decl2.c (check_classfn): Update.
6769 * pt.c (tsubst): Update.
6770 * typeck.c (complete_type_or_else, expr_sizeof,
6771 decay_conversion): Update.
6772 * typeck2.c (incomplete_type_error): Rename.
6773 (add_exception_specifier): Update.
6774
8152c320
JM
67752002-04-18 Jason Merrill <jason@redhat.com>
6776
6777 PR c++/5658
6778 * search.c (setup_class_bindings): A class template qualifies as a
6779 type binding.
6780
32121b96
JJ
67812002-04-17 Jakub Jelinek <jakub@redhat.com>
6782
6783 PR c++/6316
6784 * decl2.c (finish_file): Clear DECL_EXTERNAL in a separate loop
6785 before expanding.
6786
b2123dc0
MM
67872002-04-16 Mark Mitchell <mark@codesourcery.com>
6788
6789 * init.c (begin_init_stmts): Remove commented out code.
6790 (finish_init_stmts): Set STMT_EXPR_NO_SCOPE.
6791 * semantics.c (begin_gobal_stmt_expr): Adjust call to
6792 expand_start_stmt_expr.
500abaa8 6793
0f268005
MM
67942002-04-15 Mark Mitchell <mark@codesourcery.com>
6795
6796 * decl.c (register_dtor_fn): Pass the address of dso_handle, not
6797 dso_handle itself, to __cxa_atexit.
6798
bd6bec6b
GDR
67992002-04-15 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
6800
6801 * error.c (cxx_print_error_function): Adjust call to macros.
6802
0f490a2b
JJ
68032002-04-14 Jakub Jelinek <jakub@redhat.com>
6804
6805 * class.c (layout_virtual_bases): Do all dsize computation on trees.
6806
85b7def6
JM
68072002-04-14 Jason Merrill <jason@redhat.com>
6808
6809 * typeck.c (get_member_function_from_ptrfunc): Don't do
6810 gratuitious division and multiplication on
6811 ptrmemfunc_vbit_in_delta targets.
6812
0481bc21
MM
68132002-04-12 Mark Mitchell <mark@codesourcery.com>
6814
6815 PR c++/5373.
6816 * semantics.c (finish_expr_stmt): Remember the type of the
6817 expression before any conversions are performed.
6818
9928a3d5
MM
68192002-04-12 Mark Mitchell <mark@codesourcery.com>
6820
6821 PR c++/5189.
6822 * call.c (add_template_candidate_real): Do not treat member
6823 templates as copy constructors.
6824
c740732f
MM
68252002-04-12 Mark Mitchell <mark@codesourcery.com>
6826
6827 * decl.c (duplicate_decls): Do not copy the RTL for a variable
6828 declaration if the old variable had an incomplete type and the new
6829 variable does not.
6830 (complete_vars): Do not call layout_decl for completed variables.
6831
4782bd5b
RS
68322002-04-12 Richard Sandiford <rsandifo@redhat.com>
6833
6834 * decl.c (duplicate_decls): Don't try to unify an implicit typedef
6835 with an explicit one.
6836 (follow_tag_typedef): New.
6837 (lookup_tag): Use it to extract the tag of an explicit typedef.
6838 (xref_tag): Likewise.
6839
2f4d058f
AH
68402002-04-11 Andrew Haley <aph@redhat.com>
6841
6842 * typeck.c (type_after_usual_arithmetic_conversions):
6843 If two types have the same variant, return immediately.
500abaa8 6844 When two floating-point operands are the same precision:
2f4d058f
AH
6845 convert to float if one of the operands is float;
6846 if neither operand is one of the standard types, return the type
6847 of the first operand.
500abaa8 6848
ba3307c0
NS
68492002-04-10 Nathan Sidwell <nathan@codesourcery.com>
6850
6851 PR c++/5507
6852 * decl.c (make_typename_type): Remove implicit typenameness.
6853
cd6af0c1
JM
68542002-04-09 Jason Merrill <jason@redhat.com>
6855
edf5cd1d
JM
6856 PR optimization/6189
6857 * semantics.c (genrtl_start_function): Don't free
6858 DECL_SAVED_FUNCTION_DATA for inline functions.
6859
cd6af0c1
JM
6860 * init.c (build_member_call): For now, don't convert to
6861 intermediate base if it would cause an error.
6862
224e6091
PC
68632002-04-08 Paolo Carlini <pcarlini@unitus.it>
6864
6865 * parse.y (namespace_qualifier, maybe_identifier,
6866 begin_explicit_instantiation, end_explicit_instantiation,
6867 apparent_template_type, .finish_template_type,
6868 do_id, maybe_init, defarg_again, component_decl_1):
6869 Add ending ';', in accordance with POSIX.
6870
0154eaa8
MM
68712002-04-06 Mark Mitchell <mark@codesourcery.com>
6872
6873 PR c++/5571
6874 * class.c (layout_class_type): Remember incomplete static
6875 variables.
6876 (finish_struct_1): Call complete_vars, not
6877 hack_incomplete_structures.
6878 * cp-tree.h (hack_incomplete_structures): Rename to ...
6879 (complete_vars): ... this.
6880 (struct saved_scope): Remove incomplete.
6881 (namespace_scope_incomplete): Remove.
6882 * decl.c (struct binding_level): Remove incomplete.
6883 (incomplete_vars): New variable.
6884 (mark_binding_level): Don't mark incomplete.
6885 (print_binding_level): Don't print it.
6886 (mark_saved_scope): Don't mark incomplete.
6887 (pushdecl): Use maybe_register_incopmlete_var.
6888 (cxx_init_decl_processing): Register incomplete_vars for GC.
6889 (start_decl_1): Clarify error message.
6890 (hack_incomplete_vars): Remove.
6891 (maybe_register_incomplete_var): New function.
6892 (complete_vars): Likewise.
6893
f62ea157
JM
68942002-04-06 Jason Merrill <jason@redhat.com>
6895
03da5286
JM
6896 PR c++/4934
6897 * error.c (dump_expr) [CONVERT_EXPR]: Make sure TREE_TYPE (t) is
6898 set before checking it.
6899
a29e1034
JM
6900 PR c++/525
6901 * init.c (build_member_call): Use build_scoped_ref.
6902 (resolve_offset_ref): Likewise.
6903 * call.c (build_scoped_method_call): Likewise.
500abaa8 6904 * tree.c (maybe_dummy_object): Kludge around current_class_type being
a29e1034
JM
6905 wrong.
6906 * typeck2.c (build_scoped_ref): Return the binfo via binfo_p parm.
6907 * cp-tree.h: Adjust.
500abaa8 6908
a29e1034
JM
6909 * init.c (push_base_cleanups): Just use build_scoped_method_call.
6910
f62ea157 6911 PR c++/6179
500abaa8 6912 * method.c (implicitly_declare_fn): Pass unqualified type to
f62ea157
JM
6913 synthesize_exception_spec.
6914
78ef5b89
NB
69152002-04-04 Neil Booth <neil@daikokuya.demon.co.uk>
6916
6917 * cp-lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Redefine.
6918 * cvt.c: Update comment.
6919 * init.c (expand_cleanup_for_base): Update.
6920 * semantics.c (finish_parenthesized_expr): Update.
6921 * typeck.c (cp_truthvalue_conversion): Update.
6922
dffa4176
JM
69232002-04-04 Jason Merrill <jason@redhat.com>
6924
659e5a7a
JM
6925 * semantics.c (finish_eh_cleanup): New fn.
6926 * cp-tree.h: Add prototype.
500abaa8 6927 * init.c (perform_member_init, expand_cleanup_for_base): Use
659e5a7a
JM
6928 finish_eh_cleanup.
6929 * cp-tree.def (SUBOBJECT, CTOR_STMT): Remove.
6930 * cp-tree.h: Remove references.
6931 * decl.c (begin_constructor_body, end_constructor_body): Likewise.
6932 * dump.c (cp_dump_tree): Likewise.
6933 * pt.c (tsubst_expr): Likewise.
6934 * semantics.c (genrtl_ctor_stmt, genrtl_subobject): Remove.
6935 (cp_expand_stmt): Remove handling of CTOR_STMT and SUBOBJECT.
6936 * tree.c (cp_statement_code_p): Likewise.
6937
6938 * init.c (build_new_1): Set CLEANUP_EH_ONLY on deleting cleanup.
6939
6940 PR c++/5636
6941 * semantics.c (nullify_returns_r): Just set CLEANUP_EH_ONLY on
6942 cleanup for nrv.
6943
dffa4176
JM
6944 PR c++/5104
6945 * typeck.c (comptypes) [FUNCTION_TYPE]: Don't compare exception
6946 specifiers.
6947 [METHOD_TYPE]: Use same code as FUNCTION_TYPE.
6948
ef4f94ac
RH
69492002-04-03 Richard Henderson <rth@redhat.com>
6950
6951 * cp-lang.c (cxx_warn_unused_global_decl): New.
6952 (LANG_HOOKS_WARN_UNUSED_GLOBAL_DECL): New.
6953
599bba86
NB
69542002-04-03 Neil Booth <neil@daikokuya.demon.co.uk>
6955
6956 * cp-lang.c (LANG_HOOKS_SET_DECL_ASSEMBLER_NAME): Redefine.
6957 * tree.c (init_tree): Don't set hook.
6958
cba2004a
RS
69592002-04-03 Roger Sayle <roger@eyesopen.com>
6960
6961 PR c++/5998:
6962 * decl.c (duplicate_decls): Don't mess with assembler names when
6963 redeclaring builtin functions as static.
6964
dffd7eb6
NB
69652002-04-01 Neil Booth <neil@daikokuya.demon.co.uk>
6966
6967 * call.c (build_addr_func): Update.
6968 * class.c (resolve_address_of_overloaded_function): Update.
6969 * cp-lang.c (LANG_HOOKS_MARK_ADDRESSABLE): Redefine.
6970 * cp-tree.h (cxx_mark_addressable): New.
6971 * decl.c (register_dtor_fn, cxx_maybe_build_cleanup): Update.
6972 * decl2.c (build_cleanup): Update.
6973 * except.c (build_throw): Update.
6974 * init.c (resolve_offset_ref): Update.
6975 * pt.c (convert_nontype_argument): Update.
6976 * semantics.c (finish_asm_stmt, simplify_affr_init_exprs_r): Update.
6977 * typeck.c (decay_conversion, build_array_ref, build_unary_op,
6978 unary_complex_lvalue): Update.
6979 (mark_addressable): Rename.
6980
04a9d080
RS
69812002-04-01 Roger Sayle <roger@eyesopen.com>
6982
6983 PR c++/5998:
6984 * decl.c (duplicate_decls): Overwrite the RTL when (and only
6985 when) overwriting a built-in function. Don't use COPY_DECL_RTL,
6986 but follow the SET_DECL_RTL idiom used elsewhere in the function.
6987
ceef8ce4
NB
69882002-04-01 Neil Booth <neil@daikokuya.demon.co.uk>
6989
6990 * cp-lang.c (LANG_HOOKS_SIGNED_TYPE, LANG_HOOKS_UNSIGNED_TYPE,
6991 LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): New.
6992 * decl.c (grokdeclarator): Update.
6993 * mangle.c (write_integer_cst): Update.
6994 * typeck.c (build_binary_op): Update.
6995
48a7a235
NB
69962002-03-31 Neil Booth <neil@daikokuya.demon.co.uk>
6997
6998 * cp-lang.c (LANG_HOOKS_UNSAFE_FOR_REEVAL): Redefine.
6999 * lex.c (cxx_init): Don't set hook.
7000
7cb32822
NB
70012002-03-31 Neil Booth <neil@daikokuya.demon.co.uk>
7002
7003 * Make-lang.in (error.o): Update.
7004 * cp-lang.c (LANG_HOOKS_PRINT_ERROR_FUNCTION): Redefine.
7005 * cp-tree.h (struct diagnostic_context): Predeclare.
7006 (cxx_print_error_function): New.
7007 * error.c: Include langhooks-def.h.
7008 (lang_print_error_function): Rename. Update.
7009 (init_error): Don't set hook.
7010
b0c48229
NB
70112002-03-29 Neil Booth <neil@daikokuya.demon.co.uk>
7012
7013 * cp-lang.c (LANG_HOOKS_TYPE_FOR_MODE, LANG_HOOKS_TYPE_FOR_SIZE):
7014 Redefine.
7015 * cvt.c (cp_convert_to_pointer, type_promotes_to): Use new hooks.
7016 * decl.c (finish_enum): Similarly.
7017 * error.c (dump_type): Similarly.
7018 * lex.c (cxx_init): Similarly.
7019 * mangle.c (write_builtin_type): Similarly.
7020 * typeck.c (comptypes): Similarly.
7021
d52e4867
RS
70222002-03-28 Roger Sayle <roger@eyesopen.com>
7023
7024 PR c++/5998:
7025 * decl.c (cxx_init_decl_processing): Re-enable built-in functions
7026 in the g++ front-end.
7027 (duplicate_decl): Allow redefinition of anticipated built-ins.
7028 Fix inlining problem by over-writing the old DECL_RTL.
7029 (lookup_namespace_name): Fail to find an identifier in the
7030 specified namespace if its still anticipated.
7031 (builtin_function_1): New function split out from builtin_function
7032 to create a builtin in the current namespace with given context.
7033 (builtin_function): Call builtin_function_1 to define the
7034 appropriate builtins in both the std and global namespaces.
7035 (select_decl): Don't test for anticipated decls here.
7036 (unqualified_namespace_lookup): Instead ignore them whilst
7037 searching through scopes and namespaces.
7038 * decl2.c (do_nonmember_using_decl): If a using declaration
7039 specifies an anticipated built-in function, mark it as no longer
7040 anticipated in that scope.
7041 (ambiguous_decl): Avoid resolving to an anticipated decl.
7042 * lex.c (do_scoped_id): Fail to find an identifier in the global
7043 namespace if its still anticipated.
7044
f1e639b1
NB
70452002-03-29 Neil Booth <neil@daikokuya.demon.co.uk>
7046
7047 * cp-lang.c (LANG_HOOKS_MAKE_TYPE): Redefine.
7048 * cp-tree.h (cp_make_lang_type): Rename.
7049 * lex.c (cp_make_lang_type): Rename.
7050 (make_aggr_type): Update.
7051 * tree.c (init_tree): Don't set make_lang_type_fn.
7052
c7f4981a
JJ
70532002-03-29 Jakub Jelinek <jakub@redhat.com>
7054
7055 PR c++/6073
7056 * class.c (finish_struct_1): Update static field's DECL_MODE even
7057 if its type is a variant of t.
7058
7ffb4fd2
NB
70592002-03-27 Neil Booth <neil@daikokuya.demon.co.uk>
7060
7061 * cp-lang.c (LANG_HOOKS_INSERT_DEFAULT_ATTRIBUTES): Redefine.
7062 * cp-tree.h (cxx_insert_default_attributes): New.
7063 * decl.c (insert_default_attributes): Rename.
7064
cd4e8331
MM
70652002-03-27 Mark Mitchell <mark@codesourcery.com>
7066
7067 PR c++/4884
7068 * call.c (build_op_delete_call): Allow for the fact the placement
7069 may be a COMPOUND_EXPR.
500abaa8 7070
c9d892a8
NB
70712002-03-27 Neil Booth <neil@daikokuya.demon.co.uk>
7072
7073 * cp-lang.c (LANG_HOOKS_EXPAND_EXPR): Redefine.
7074 * cp-tree.h (init_cplus_expand): Remove.
7075 (cxx_expand_expr): New.
7076 * expr.c (cplus_expand_expr): Rename cxx_expand_expr,
7077 fix prototype.
7078 (init_cplus_expand): Remove.
7079 * lex.c (cxx_init): Don't call init_cplus_expand.
7080
46ff5047
MM
70812002-03-26 Mark Mitchell <mark@codesourcery.com>
7082
7083 PR c++/4884.
7084 * init.c (build_new_1): Allow for the fact the result of
7085 build_function_call may be a COMPOUND_EXPR.
7086
6d4c57a0
NS
70872002-03-26 Nathan Sidwell <nathan@codesourcery.com>
7088
7089 PR c++/5682
7090 * cp-tree.h (BINFO_PRIMARY_P): Explain meaning better.
7091 (dfs_skip_nonprimary_vbases_unmarkedp): Remove.
7092 (dfs_skip_nonprimary_vbases_markedp): Remove.
7093 * search.c (get_shared_vbase_if_not_primary): Remove.
7094 (dfs_skip_nonprimary_vbases_unmarkedp): Remove.
7095 (dfs_skip_nonprimary_vbases_markedp): Remove.
7096 (dfs_unmarked_real_bases_queue_p): Just get the canonical binfo.
7097 (dfs_marked_real_bases_queue_p): Likewise.
7098
4f0ade92
NB
70992002-03-26 Neil Booth <neil@daikokuya.demon.co.uk>
7100
7101 * cp-lang.c (LANG_HOOKS_MARK_TREE): Redefine.
7102 * cp-tree.h (cxx_mark_tree): New.
7103 * decl.c (lang_mark_tree): Rename cxx_mark_tree.
7104
c88770e9
NB
71052002-03-25 Neil Booth <neil@daikokuya.demon.co.uk>
7106
7107 * cp-tree.h (cxx_maybe_build_cleanup): New.
7108 * decl.c (destroy_local_var, hack_incomplete_structures): Update.
7109 (maybe_build_cleanup): Rename cxx_maybe_build_cleanup.
7110 * tree.c (build_target_expr): Update.
7b3e5198 7111 * cp-lang.c (LANG_HOOKS_MAYBE_BUILD_CLEANUP): Redefine.
c88770e9 7112
aaf93206
NB
71132002-03-24 Neil Booth <neil@daikokuya.demon.co.uk>
7114
7115 * decl2.c (cxx_decode_option): Handle -E.
7116 * lang-specs.h (default_compilers): Preprocess with cc1plus.
7117 * lex.c (cxx_init): Exit quickly if c_common_init returns NULL.
7118
e756a7da
JJ
71192002-03-23 Jakub Jelinek <jakub@redhat.com>
7120
7121 PR c++/6037
7122 * decl.c (start_enum): Don't set TREE_ADDRESSABLE on TREE_LIST node.
7123
ea9264e9
GDR
71242002-03-23 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
7125
7126 * error.c (dump_type): Be careful about implicit typenames.
7127
acb044ee
GDR
71282002-03-21 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
7129
7130 PR C++/3656
7131 * semantics.c (finish_base_specifier): Handle erronous base
500abaa8 7132 classes.
acb044ee 7133
b216cd4a
ZW
71342002-03-22 Zack Weinberg <zack@codesourcery.com>
7135
7136 * error.c: Always use REAL_VALUE_TO_DECIMAL; don't test
7137 REAL_IS_NOT_DOUBLE.
7138
9181f8db
JK
71392002-03-22 Jeff Knaggs <jknaggs@redhat.com>
7140
cd6af0c1
JM
7141 * typeck.c (get_member_function_from_ptrfunc): Scale idx down to
7142 an index into the vtable_entry array regardless of
9181f8db
JK
7143 TARGET_PTRMEMFUNC_VBIT_LOCATION.
7144
e019cf95
AH
71452002-03-21 Aldy Hernandez <aldyh@redhat.com>
7146
84d901be 7147 * tree.c (cp_cannot_inline_tree_fn): Same.
e019cf95 7148
43577e6b
NB
71492002-03-21 Neil Booth <neil@daikokuya.demon.co.uk>
7150
7151 * cp-tree.h (pushdecl, pushlevel, poplevel, set_block,
7152 insert_block, getdecls, global_bindings_p): New.
7153
8c152bad
NS
71542002-03-20 Nathan Sidwell <nathan@codesourcery.com>
7155
7156 PR c++/4361
7157 * mangle.c (struct globals) Add internal_mangling_p member.
7158 (write_template_param): Do internal mangling, if needed.
7159 (mangle_conv_op_name_for_type): Request internal mangling.
7160
e3fe84e5
JM
71612002-03-20 Jason Merrill <jason@redhat.com>
7162
7163 PR c++/2136
7164 * init.c (build_delete): Check access for a member op delete here.
7165 * decl2.c (delete_sanity): Not here.
7166
ea122333
JM
71672002-03-19 Jason Merrill <jason@redhat.com>
7168
7169 PR c++/5118
7170 * class.c (get_vfield_name): Use the constructor_name.
7171
7afff7cf
NB
71722002-03-20 Neil Booth <neil@daikokuya.demon.co.uk>
7173
7174 * cp-lang.c (LANG_HOOKS_DECL_PRINTABLE_NAME): Redefine.
7175 * cp-tree.h (lang_printable_name): Rename.
7176 * error.c (lang_decl_name): Use new hook.
7177 * lex.c (cxx_init): Remove old hook.
7178 * pt.c (tsubst_decl): Use new hook.
7179 * tree.c (lang_printable_name): Rename.
7180
ff77ac85
EB
71812002-03-18 Eric Botcazou <ebotcazou@multimania.com>
7182
7183 PR c++/3882
7184 * pt.c (tsubst_decl): Move __PRETTY_FUNCTION__ handling...
7185 (tsubst_expr) [DECL_STMT]: ...here. And substitute the initializer
7186 only after recording the declaration.
7187
ffd696af
JM
71882002-03-18 Jason Merrill <jason@redhat.com>
7189
097955f2
JM
7190 PR c++/2039
7191 * init.c (resolve_offset_ref): Hand off to build_component_ref.
7192
b663bcf3
JM
7193 PR c++/4222, c++/5995
7194 * call.c (build_over_call): Fix empty class logic.
7195
0f4237c2
JM
7196 PR c++/3870
7197 * cp-tree.h (struct saved_scope): Add last_parms field.
7198 * decl.c (maybe_push_to_top_level): Save last_function_parms.
7199 (pop_from_top_level): Restore it.
7200
001ad76c
JM
7201 PR c++/4377
7202 * mangle.c (write_expression): Strip NOP_EXPRs sooner. Also strip
7203 NON_LVALUE_EXPRs.
7204
7205 PR c++/4003
ed2fa432
JM
7206 * pt.c (tsubst_friend_function): Use decl_namespace_context.
7207
ffd696af
JM
7208 PR c++/3948 -- C++ ABI change, followup to 2001-12-18 patch.
7209 * class.c (finish_struct_bits): Also set TREE_ADDRESSABLE for a
7210 type with a nontrivial destructor.
7211
f2606a97
JM
72122002-03-17 Jason Merrill <jason@redhat.com>
7213
7214 PR c++/4460
7215 * class.c (build_base_path): Virtual base layout is fixed in
7216 in-charge [cd]tors.
7217
52dabb6c
NB
72182002-03-17 Neil Booth <neil@daikokuya.demon.co.uk>
7219
7220 * cp-lang.c (LANG_HOOKS_PARSE_FILE): Redefine.
7221 * parse.y (yyparse): Remove macro.
7222
beb9c8a2
JM
72232002-03-17 Jason Merrill <jason@redhat.com>
7224
7225 PR c++/5757
7226 * init.c (build_new_1): Pass the right pointer to op delete.
7227
5dd236e2
NS
72282002-03-16 Nathan Sidwell <nathan@codesourcery.com>
7229
7230 PR c++/4361
7231 * cp-tree.h (CLASSTYPE_METHOD_VEC): Document where templated
7232 conversion operators go.
7233 (struct lang_decl_flags): Add template_conv_p and unused
7234 bitfields.
7235 (DECL_TEMPLATE_CONV_FN_P): New macro.
7236 * call.c (build_user_type_conversion_1): Don't check second type
7237 conversion of overload set first.
7238 * class.c (add_method): Make sure templated conversion operators
7239 all end up on slot 2.
7240 * lex.c (do_identifier): A conversion operator token might be
7241 satisfied by a templated conversion operator.
5dd236e2
NS
7242 * pt.c (check_explicit_specialization): Use
7243 CLASSTYPE_FIRST_CONVERSION_SLOT.
7244 (template_parm_this_level_p): New function.
7245 (push_template_decl_real): Determine DECL_TEMPLATE_CONV_FN_P.
8c152bad 7246 * search.c (lookup_fnfields_1): Template conversions will be on
5dd236e2
NS
7247 the first slot.
7248 * typeck.c (build_component_ref): Preserve the type of an
7249 conversion operator name on the overload type.
7250 (build_x_function_call): Retrieve the conversion operator name.
7251
0ba20759
RH
72522002-03-15 Richard Henderson <rth@redhat.com>
7253
7254 * init.c (build_new_1): Use size_binop instead of cp_build_binary_op.
7255
6e4ae815
MM
72562002-03-15 Mark Mitchell <mark@codesourcery.com>
7257
7258 * cp-tree.h (CLEANUP_DECL): Remove.
7259 (CLEANUP_EXPR): Likewise.
7260 * decl.c (destroy_local_var): Simplify.
7261 (maybe_build_cleanup): Tidy.
7262 * dump.c (cp_dump_tree): Remove handling of CLEANUP_STMT.
7263 * semantics.c (cp_expand_stmt): Likewise.
7264 * cp/tree.c (cp_statement_code_p): Likewise.
7265
5cc90635
JM
72662002-03-15 Jason Merrill <jason@redhat.com>
7267
6da794e8
JM
7268 PR c++/5857
7269 * decl.c (duplicate_decls): Use merge_types instead of common_type.
7270 * typeck.c (common_type): Just hand off to
7271 type_after_usual_arithmetic_conversions and
7272 composite_pointer_type.
7273 (merge_types): New fn.
7274 (commonparms): Use it instead of common_type.
7275 (type_after_usual_arithmetic_conversions): Also handle COMPLEX_TYPE.
7276 (composite_pointer_type): Also handle attributes.
7277 * cp-tree.h: Declare merge_types.
7278
5cc90635
JM
7279 * decl.c (make_rtl_for_nonlocal_decl): Also defer COMDAT
7280 variables.
7281 * decl2.c (maybe_make_one_only): Also mark the decl as needed.
7282
ecb0eece
RH
72832002-03-14 Richard Henderson <rth@redhat.com>
7284
7285 * decl.c: Include c-pragma.h.
7286 (start_decl, start_function): Invoke maybe_apply_pragma_weak.
7287 * Make-lang.in: Update dependencies.
7288
d3f129b3
JJ
72892002-03-14 Jakub Jelinek <jakub@redhat.com>
7290
f6562b37 7291 PR c++/5908
d3f129b3
JJ
7292 * call.c (build_over_call): Set TREE_NO_UNUSED_WARNING too.
7293 * cvt.c (convert_to_void): Preserve TREE_NO_UNUSED_WARNING.
7294
049e6879
RS
72952002-03-12 Richard Sandiford <rsandifo@redhat.com>
7296
7297 * mangle.c (write_builtin_type): Handle 128-bit integers even if
7298 they are not a standard integer type.
7299
872c9284
RS
73002002-03-12 Richard Sandiford <rsandifo@redhat.com>
7301
7302 * cp-tree.h (init_init_processing): Remove declaration.
7303 * init.c (BI_header_type, init_init_processing): Remove old ABI stuff.
7304 * decl.c (cxx_init_decl_processing): Don't call init_init_processing.
7305
2f9834e8
KG
73062002-03-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
7307
7308 * cp-lang.c (tree_code_type, tree_code_length, tree_code_name):
7309 Define.
7310 * decl.c (duplicate_decls): Use TREE_CODE_LENGTH, not
7311 tree_code_length.
7312 * lex.c (cplus_tree_code_type, cplus_tree_code_length,
7313 cplus_tree_code_name): Delete.
7314 (cxx_init): Don't call add_c_tree_codes, instead set
7315 lang_unsafe_for_reeval. Don't try to copy into the various
7316 tree_code arrays.
7317
df867456
NS
73182002-03-12 Nathan Sidwell <nathan@codesourcery.com>
7319
7320 PR c++/5659
7321 * decl.c (xref_tag): Don't set CLASSTYPE_DECLARED_CLASS here.
7322 * decl2.c (handle_class_head): Set CLASSTYPE_DECLARED_CLASS for
7323 definitions.
7324
ab04e34b
NS
73252002-03-11 Nathan Sidwell <nathan@codesourcery.com>
7326
7327 Revert 2001-03-26 Nathan Sidwell <nathan@codesourcery.com>,
7328 DR209 is now not a defect.
7329 * cp-tree.h (skip_type_access_control): Remove.
7330 * decl.c (grokdeclarator): Do type access control for friend
7331 declarations.
7332 * semantics.c (decl_type_access_control): Don't reset
7333 current_type_lookups.
7334 (save_type_access_control): Always save the lookups.
7335 (skip_type_access_control): Remove.
7336 (finish_class_definition): Don't change type_lookups.
7337
999cc24c
NS
73382002-03-11 Nathan Sidwell <nathan@codesourcery.com>
7339
7340 Revert 2000-12-01 Nathan Sidwell <nathan@codesourcery.com>,
7341 It is incorrect.
7342 * typeck.c (build_static_cast): Compare non-qualified types
7343 with pointer to member conversions.
7344
61eece67
DN
73452002-03-11 Dan Nicolaescu <dann@ics.uci.edu>
7346 Daniel Berlin <dan@dberlin.org>
7347
7348 * cp-lang.c (ok_to_generate_alias_set_for_type): New function.
7349 (cxx_get_alias_set): Use it.
7350
644d28d4
KG
73512002-03-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
7352
7353 * cp-tree.h (stabilize_expr): Prototype.
7354
7e326356
CR
73552002-03-08 Craig Rodrigues <rodrigc@gcc.gnu.org>
7356
7357 * cp-tree.h (CLEAR_BINFO_MARKED): Make both parts of
7358 conditional return void.
7359
24965e7a
NB
73602002-03-08 Neil Booth <neil@daikokuya.demon.co.uk>
7361
7362 * cp-lang.c (LANG_HOOKS_UNSAVE): Redefine.
7363 * cp-tree.h (cxx_unsave): New.
7364 * tree.c (cp_unsave): Rename cxx_unsave, update prototype.
7365 (init_tree): Update.
7366
ca7558fc
KG
73672002-03-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
7368
7369 * decl.c (cxx_init_decl_processing): Use ARRAY_SIZE in lieu of
7370 explicit sizeof/sizeof.
7371 * decl2.c (cxx_decode_option): Likewise.
7372 * lex.c (init_reswords, REDUCE_LENGTH, TOKEN_LENGTH): Likewise.
7373
fd87b7a7
NS
73742002-03-02 Nathan Sidwell <nathan@codesourcery.com>
7375
7376 PR c++/775
7377 * decl.c (lookup_tag): Only reject enum/class mismatch, not
7378 class/union mismatch.
7379 * parse.y (check_class_key): New function.
7380 (structsp): Call it.
7381
bfba94bd
MM
73822002-03-01 Michael Matz <matz@suse.de>
7383
7384 * typeck.c (cp_pointer_int_sum): Complete inner type which is
7385 used later by size_in_bytes().
7386
fdc9bf29
PE
73872002-03-01 Phil Edwards <pme@gcc.gnu.org>
7388
7389 * cp-tree.h: Require __GNUC__ to be #defined.
7390 (build_init): Add missing prototype.
7391
6f30f1f1
JM
73922002-03-01 Jason Merrill <jason@redhat.com>
7393
7394 * except.c: Don't include decl.h or obstack.h. Do include
7395 tree-inline.h.
7396 (build_throw): Destroy temporaries from the thrown
500abaa8 7397 expression before calling __cxa_throw. Construct a thrown
6f30f1f1
JM
7398 temporary directly into the exception object.
7399 (stabilize_throw_expr): New function.
7400 (wrap_cleanups_r): New function.
7401 * tree.c (stabilize_expr): New function.
7402 * init.c (build_init): New function.
7403 * Make-lang.in (cp/except.o): Adjust .h deps.
7404
46cfb101
JM
74052002-02-28 Jason Merrill <jason@redhat.com>
7406
07f521fc
JM
7407 * search.c (lookup_base_r): Don't clear is_non_public just because
7408 we found a friendly scope.
7409
46cfb101
JM
7410 * decl.c (finish_function): Only warn about missing return
7411 statement with -Wreturn-type.
7412
63e1b1c4
NB
74132002-02-28 Neil Booth <neil@daikokuya.demon.co.uk>
7414
7415 * class.c (build_clone): Update.
7416 * cp-lang.c (LANG_HOOKS_DUP_LANG_SPECIFIC_DECL): Redefine.
7417 * cp-tree.h (cxx_dup_lang_specific_decl): New.
7418 * lex.c (copy_lang_decl): Rename cxx_dup_lang_specific_decl.
7419 (copy_decl): Update.
7420 * method.c (make_thunk): Update.
7421
f458d1d5
ZW
74222002-02-27 Zack Weinberg <zack@codesourcery.com>
7423
7424 * decl2.c: Delete traditional-mode-related code copied from
7425 the C front end but not used, or used only to permit the
7426 compiler to link.
7427
500abaa8 74282002-02-24 Craig Rodrigues <rodrigc@gcc.gnu.org>
3387d36e
CR
7429
7430 PR c++/4093
7431 * cp-tree.h (SET_BINFO_MARKED): Cast false part of condition
7432 to void.
7433
25c8b645
JJ
74342002-02-22 Jakub Jelinek <jakub@redhat.com>
7435
7436 PR other/5746
7437 * semantics.c (finish_switch_cond): Don't call get_unwidened
7438 if error_mark_node.
7439
4f2b0fb2
NS
74402002-02-22 Nathan Sidwell <nathan@codesourcery.com>
7441
7442 PR c++/2645, DR 295
7443 * cp-tree.h (tsubst_flags_t): Add tf_ignore_bad_quals,
7444 tf_keep_type_decl.
7445 (make_typename_type): Use tsubst_flags_t.
7446 * decl.c (make_typename_type): Adjust. Return non-artificial
7447 TYPE_DECLs, if required.
7448 (grokdeclarator): Simplify CVR qualification handling. Allow bad
7449 qualifiers on typedef types.
7450 * decl2.c (handle_class_head): Adjust make_typename_type call.
7451 * parse.y (nested_name_specifier): Likewise.
7452 (typename_sub0): Likewise.
7453 (typename_sub1): Likewise.
7454 * pt.c (convert_template_argument): Adjust make_typename_type
7455 return value.
7456 (tsubst): Adjust cp_build_qualified_type_real calls.
1a55127d 7457 (check_cv_quals_for_unify): Cope with allowing bad qualifications
4f2b0fb2
NS
7458 on template type parms.
7459 (instantiate_decl): Recheck substitutions to give warnings on bad
7460 qualifications.
7461 * tree.c (cp_build_qualified_type_real): Use tf_allow_bad_quals.
7462
8fc2ba41
AH
74632002-02-21 Aldy Hernandez <aldyh@redhat.com>
7464
84d901be 7465 * cp/decl.c (duplicate_decls): Merge always_inline attribute.
8fc2ba41 7466
84d901be
AD
7467 * cp/tree.c (cp_cannot_inline_tree_fn): Do not inline at -O0
7468 unless DECL_ALWAYS_INLINE.
8fc2ba41 7469
7552da58
JJ
74702002-02-20 Jakub Jelinek <jakub@redhat.com>
7471
7472 * typeck.c (cp_pointer_int_sum): Renamed from
7473 pointer_int_sum, call pointer_int_sum.
7474
00fae85d
JJ
74752002-02-20 Jakub Jelinek <jakub@redhat.com>
7476
7477 * decl.c (duplicate_decls): Return 0 if issued error about
7478 redeclaration.
7479
6ea868b7
JM
74802002-02-19 Jason Merrill <jason@redhat.com>
7481
500abaa8 7482 ABI change: Mangle `void (A::*)() const' as
6ea868b7
JM
7483 M1AKFvvE, not MK1AFvvE.
7484 * mangle.c (write_function_type): Write cv-quals for member
7485 function type here.
7486 (write_pointer_to_member_type): Not here.
7487
c02f5e29
JM
74882002-02-18 Jason Merrill <jason@redhat.com>
7489
7490 * pt.c (do_type_instantiation): Don't pedwarn if in_system_header.
7491 (do_decl_instantiation): Likewise.
7492
624a5800
CR
74932002-02-17 Craig Rodrigues <rodrigc@gcc.gnu.org>
7494
7495 PR c++/5685
7496 * decl.c (duplicate_decls): Make warning unconditional
7497 if duplicate default argument declarations are present.
7498
f6f8ada3
JJ
74992002-02-17 Jakub Jelinek <jakub@redhat.com>
7500
7501 * typeck.c (build_binary_op) [BIT_XOR_EXPR]: Remove explicit
7502 shortening.
7503
8d6e459d
NS
75042002-02-15 Nathan Sidwell <nathan@codesourcery.com>
7505
7506 * decl.c (grokdeclarator): Set typedef_decl for all TYPE_DECLs,
7507 remove incorrect comment. Move #if 0'd code to common path. Use
7508 IMPLICIT_TYPENAME_P. Simplify & reformat ARRAY_TYPE duplication.
7509
ca4feb54
JM
75102002-02-13 Jason Merrill <jason@redhat.com>
7511
57d5032b
JM
7512 * decl.c (builtin_function): Set TREE_THIS_VOLATILE on return fns.
7513 (finish_function): Don't warn if current_function_returns_null.
7514
bb26522d
JM
7515 * typeck2.c (digest_init): Do handle values of vector type.
7516
ca4feb54
JM
7517 * typeck2.c (digest_init, process_init_constructor): Treat vectors
7518 like arrays.
7519
e6b9638b
JM
75202002-02-11 Jason Merrill <jason@redhat.com>
7521
7522 * parse.y (reserved_declspecs): Don't handle attributes.
7523 (reserved_typespecquals): Handle them here.
7524 * Make-lang.in (parse.c): Adjust expected conflicts.
7525
1cf537c5
JJ
75262002-02-08 Jakub Jelinek <jakub@redhat.com>
7527
7528 * parse.y (primary, primary_no_id): Use compstmt_or_stmtexpr
7529 instead of compstmt.
7530 (compstmt_or_stmtexpr): Renamed from compstmt.
7531 (compstmt): In addition to compstmt_or_stmtexpr clear last_expr_type.
7532
c2ea3a40
NS
75332002-02-07 Nathan Sidwell <nathan@codesourcery.com>
7534
7535 Rename instantiate_type_flags to tsubst_flags_t & expand use.
7536 * cp-tree.h (instantiate_type_flags): Rename to ...
7537 (tsubst_flags_t): ... here. Rename itf_complain to tf_error,
7538 add tf_warning flag.
7539 (instantiate_type): Adjust prototype.
7540 (tsubst, tsubst_expr, tsubst_copy, lookup_template_class,
7541 do_type_instantiation, cp_build_qualified_type_real): Likewise.
7542 cp_build_qualified_type: Adjust.
7543 * class.c (instantiate_type): Adjust parameter. Rename itf_* to
7544 tf_*.
7545 * call.c (standard_conversion): Rename itf_* to tf_*.
7546 (reference_binding): Likewise.
7547 (convert_like_real): Likewise.
7548 * cvt.c (cp_convert_to_pointer): Likewise.
7549 (convert_to_reference): Likewise.
7550 * decl.c (lookup_namespace_name): Use tf_* flags.
7551 (make_typename_type): Likewise.
7552 (grokdeclarator): Likewise.
7553 * pt.c (convert_nontype_argument): Adjust COMPLAIN usage.
7554 (coerce_template_template_parms, convert_template_argument,
7555 coerce_template_parms, maybe_get_template_decl_from_type_decl,
7556 lookup_template_class, tsubst_friend_function, tsubst_friend_class,
500abaa8
AJ
7557 instantiate_class_template, tsubst_template_arg_vector,
7558 tsubst_template_parms, tsubst_aggr_type, tsubst_default_argument,
c2ea3a40 7559 tsubst_decl, tsubst_arg_types, tsubst_function_type,
500abaa8 7560 tsubst_call_declarator_parms, tsubst, tsubst_copy, tsubst_expr,
c2ea3a40 7561 instantiate_template, fn_type_unification,
500abaa8
AJ
7562 resolve_overloaded_unification, verify_class_unification,
7563 unify, get_bindings_real, do_type_instantiation,
7564 regenerate_decl_from_template, instantiate_decl,
c2ea3a40
NS
7565 tsubst_initializer_list, tsubst_enum,
7566 get_mostly_instantiated_function_type,
7567 invalid_nontype_parm_type_p): Likewise.
7568 * tree.c (cp_build_qualified_type_real): Likewise.
7569 * typeck.c (build_binary_op): Rename itf_* to tf_*.
7570 (build_ptrmemfunc): Likewise.
7571 (convert_for_assignment): Likewise.
7572
d5614afb
NS
75732002-02-07 Nathan Sidwell <nathan@codesourcery.com>
7574
7575 PR c++/109
7576 * decl.c (grokdeclarator): Allow friend declarations from
8d6e459d 7577 dependent types.
d5614afb
NS
7578 * decl2.c (handle_class_head): Don't push into template parm contexts.
7579 * pt.c (push_template_decl_real): Template parm contexts are never
7580 being defined.
7581
1af6141b
AO
75822002-02-05 Alexandre Oliva <aoliva@redhat.com>
7583
7584 * class.c: Include target.h.
7585 (check_bitfield_decl): Disregard EMPTY_FIELD_BOUNDARY,
7586 BITFIELDS_NBYTES_LIMITED and PCC_BITFIELD_TYPE_MATTERS for MS
7587 bit-field layout.
7588 * Make-lang.in: Adjust deps.
7589
d8a6f584
JM
75902002-02-05 Jason Merrill <jason@redhat.com>
7591
7592 * error.c (dump_type): Be more helpful about VECTOR_TYPE.
7593
6f9fdf4d
JJ
75942002-02-04 Jakub Jelinek <jakub@redhat.com>
7595
7596 * semantics.c (begin_switch_stmt): Clear SWITCH_TYPE.
7597 (finish_switch_cond): Set SWITCH_TYPE.
7598
14691f8d
RH
75992002-02-04 Richard Henderson <rth@redhat.com>
7600
7601 * method.c (use_thunk): Always initialize the block tree. Reindent.
7602 * semantics.c (expand_body): Emit thunks after function, not before.
7603
e89a6075
JM
76042002-02-04 Jason Merrill <jason@redhat.com>
7605
7606 * decl.c (start_function): Call cplus_decl_attributes immediately
7607 after grokdeclarator.
7608
7609 * decl.c (start_function): Combine DECL_RESULT handling code.
7610
9780c24f
JM
76112002-02-03 Jason Merrill <jason@redhat.com>
7612
7613 * xref.c: Remove.
7614 * Make-lang.in (CXX_OBJS): Remove cp/xref.o
7615 (cp/xref.o): Remove dependencies.
7616 * class.c (finish_struct_1, check_methods): Don't call xref fns.
7617 (finish_struct_1): Likewise.
7618 * friend.c (make_friend_class): Likewise.
7619 * lex.c (cxx_init, cxx_finish, extract_interface_info): Likewise.
7620 * spew.c (read_process_identifier): Likewise.
7621
65f36ac8
JM
76222002-02-01 Jason Merrill <jason@redhat.com>
7623
efe49da0 7624 PR c++/4872
500abaa8 7625 * decl.c (finish_function): Warn about a non-void function with
efe49da0
JM
7626 no return statement and no abnormal exit.
7627 * cp-tree.h (struct cp_language_function): Add returns_abnormally.
7628 (current_function_returns_abnormally): New macro.
7629 * call.c (build_call): Set it.
7630
f2d9afec
JM
7631 * typeck.c (build_component_ref): Always complain about offsetof
7632 constructs on non-PODs. Only make it an error for members of
7633 virtual bases.
7634
65f36ac8
JM
7635 * error.c (dump_scope): Don't add TFF_DECL_SPECIFIERS.
7636 (dump_function_decl): Always dump parms.
7637
7638 * decl2.c (finish_static_data_member_decl): Complain about a local
7639 class with a static data member.
7640
7641 PR c++/4286
7642 * search.c (lookup_field_1): Don't xref a static data member
7643 just because we looked it up.
7644
98884b26
JM
76452002-01-31 Jason Merrill <jason@redhat.com>
7646
b88c0704
JM
7647 * Make-lang.in (parse.c): Handle .output file.
7648
a588fe25
JM
7649 PR c++/3395
7650 * decl.c (xref_tag): Remember early attributes in TYPE_ATTRIBUTES,
7651 not TREE_TYPE.
7652 * semantics.c (finish_class_definition): Adjust.
7653
98884b26
JM
7654 Allow attributes in parms and casts.
7655 * parse.y (named_parm): Don't strip attrs.
7656 (declmods): Remove 'attributes' production.
7657 (nonempty_cv_qualifiers): Accept attributes.
7658 (ATTRIBUTE): Give precedence.
7659 * decl.c (groktypename): Handle attributes.
7660 (grokparms): Likewise.
7661
ffdeea47
JJ
76622002-01-29 Jakub Jelinek <jakub@redhat.com>
7663
7664 * decl2.c (cxx_decode_option): Pass 0 as last argument to
7665 cpp_handle_option.
7666 * lang-specs.h: Use cpp_unique_options instead of cpp_options
7667 when used together with cc1_options.
7668
b8b98c66
NS
76692002-01-29 Nathan Sidwell <nathan@codesourcery.com>
7670
7671 PR c++/5132
7672 * typeck2.c (digest_init): Make sure non-array core type is
7673 instantiated.
7674 * decl2.c (reparse_absdcl_as_casts): Just store the type in the
7675 constructor, rather than build a new one.
7676 (build_expr_from_tree, CONSTRUCTOR case): Be careful with the
7677 PURPOSE of constructor elts.
7678
7437519c
ZW
76792002-01-23 Zack Weinberg <zack@codesourcery.com>
7680
7681 * Make-lang.in (parse.c): Adjust expected number of
7682 shift-reduce conflicts.
7683 (decl.o): Depend on diagnostic.h.
7684 * decl.c: Include diagnostic.h.
7685 (grokdeclarator): Check for null pointer.
7686 (finish_function): Don't abort when
7687 current_binding_level->parm_flag != 1, if errors have
7688 occurred; throw away the statement tree and extra binding
7689 levels, and continue.
7690 * lex.c (note_list_got_semicolon): Check for null pointer.
7691 * method.c (hack_identifier): Just return error_mark_node if
7692 value is error_mark_node.
7693 * parse.y (primary: TYPEID(type_id)): No need to use
7694 TYPE_MAIN_VARIANT here.
7695 (handler_seq): Accept an empty list of catch clauses and
7696 generate a fake handler block to avoid later crashes.
7697 (ansi_raise_identifier): Accept the error token too.
7698 * semantics.c (begin_class_definition,
7699 finish_class_definition): Check for error_mark_node.
7700
c588e52b
ZW
77012002-01-23 Zack Weinberg <zack@codesourcery.com>
7702
7703 * typeck2.c (friendly_abort): Delete definition.
7704 * cp-tree.h (friendly_abort): Don't prototype.
7705 (my_friendly_assert): Use fancy_abort.
7706
d55ecaa4
CR
77072002-01-23 Craig Rodrigues <rodrigc@gcc.gnu.org>
7708
7709 * cp-tree.h (my_friendly_abort): Remove.
7710
0a01c261
JJ
77112002-01-23 Jakub Jelinek <jakub@redhat.com>
7712
7713 * spew.c (pending_inlines, pending_inlines_tail,
7714 processing_these_inlines): Make static.
7715 (mark_pending_inlines): Remove static.
7716 (begin_parsing_inclass_inline): If in function, save pi
7717 for GC to cp_function_chain->unparsed_inlines instead.
7718 (process_next_inline): Likewise.
7719 * cp-tree.h (struct cp_language_function): Add unparsed_inlines.
7720 (mark_pending_inlines): Add prototype.
7721 * decl.c (spew_debug): Remove unused extern.
7722 (mark_lang_function): Call mark_pending_inlines.
7723
a98facb0
CR
77242002-01-23 Craig Rodrigues <rodrigc@gcc.gnu.org>
7725
c588e52b
ZW
7726 * call.c, class.c, decl.c, decl2.c, error.c, expr.c, friend.c,
7727 init.c, lex.c, mangle.c, method.c, pt.c, repo.c, rtti.c, search.c,
7728 semantics.c, spew.c, tree.c, typeck.c, typeck2.c, xref.c:
a98facb0
CR
7729 Change my_fancy_abort() to abort().
7730
f893c16e
JM
77312002-01-23 Jason Merrill <jason@redhat.com>
7732
608afcc5
JM
7733 PR c++/5453
7734 * class.c (fixed_type_or_null): Fix thinko.
7735
f893c16e
JM
7736 PR c++/3331
7737 * init.c (resolve_offset_ref): Use build_indirect_ref.
6bc34b14 7738
b2115575
JM
7739 * decl2.c (grokclassfn): Don't set DECL_REGISTER on 'this'.
7740
f893c16e
JM
77412002-01-22 Jason Merrill <jason@redhat.com>
7742
b5856475
JM
7743 * parse.y (function_body): Suppress the block for the outermost
7744 curly braces.
7745 * decl.c (pushdecl): Don't try to skip it.
7746 (begin_function_body): Keep the block we create, not the next one.
7747 * init.c (emit_base_init): Don't mess with keep_next_level.
7748
6bc34b14
JM
7749 * class.c (build_base_path): Tweak formatting.
7750
3807621a
NS
77512002-01-19 Nathan Sidwell <nathan@codesourcery.com>
7752
7753 Fix regression introduced with patch for c++/775
7754 * parse.y (class_head_defn): Check for template specializations
7755 with a different class-key.
7756
cdd2559c
JM
77572002-01-17 Jason Merrill <jason@redhat.com>
7758
7759 * decl.c (begin_constructor_body, begin_destructor_body): New fns.
7760 (begin_function_body): Call them and keep_next_level.
7761 * init.c (emit_base_init): Call keep_next_level.
7762 * semantics.c (setup_vtbl_ptr): Lose.
7763 * cp-tree.h (struct cp_language_function): Remove vtbls_set_up_p.
7764 (vtbls_set_up_p): Lose.
7765 * pt.c (tsubst_expr, CTOR_INITIALIZER): Call emit_base_init.
7766 * method.c (do_build_copy_constructor): Likewise.
7767 (synthesize_method): Call finish_mem_initializers.
7768 * parse.y (nodecls): Likewise.
ad6b1795
JM
7769
7770 * error.c (dump_type_suffix): Print the exception specs before
7771 recursing.
7772 (dump_function_decl): Here, too.
7773
7774 * cp-tree.h (TMPL_PARMS_DEPTH): Cast to signed HOST_WIDE_INT.
7775
195a5def
IR
77762002-01-10 Ira Ruben <ira@apple.com>
7777
6bc34b14 7778 PR c++/907
195a5def
IR
7779 * decl.c (start_method): Handle attrlist.
7780
f21ee879
JJ
77812002-01-10 Jakub Jelinek <jakub@redhat.com>
7782
7783 * decl2.c (max_tinst_depth): Increase default limit to 500.
7784
77852002-01-10 Graham Stott <grahams@redhat.com>
8fabd4e2
GS
7786
7787 * spew.c (YYCHAR): Uppercase macro parameter and add
7788 parenthesis.
7789 (YYCODE): Likewise.
7790 (NAME): Uppercase macro parameter.
7791
c3af729a
GS
77922002-01-09 Graham Stott <grahams@redhat.com>
7793
6bc34b14 7794 * decl.h (grokdeclarator): Wrap long line.
5d8b4235 7795
c3af729a
GS
7796 * semantics.c (FINISH_COND): Uppercase macro paramaters and
7797 add parenthesis.
7798
91800747
GS
77992002-01-08 Graham Stott <grahams@redhat.com>
7800
7801 * xref.c (FILE_NAME_ABSOLUTE_P): Add parenthesis.
7802 (PALLOC): Uppercase macro parameter and whitespace.
7803 (SALLOC): Uppercase macro parameter.
7804 (SFREE): Uppercase macros parameter, add parenthese and
7805 whitespace.
7806 (STREQL): Uppercase macro parameter and whitespace.
7807 (STRNEQ): Likewise.
7808 (STRLSS): Likewise.
7809 (STRLEQ): Likewise.
7810 (STRGTR): Likewise.
7811 (STRGEQ): Likewise.
7812
7813 * call.c (convert_like): Add parenthesis and wrap.
7814 (convert_like_with_context): Likewise.
7815 (ICS_RANK): Whitespace.
7816 (NEED_TEMPORARY_P): Remove parenthesis.
7817
7818 * class.c (VTT_TOP_LEVEL_P): Uppercase macro parameter and
7819 whitespace.
7820 (VTT_MARKED_BINFO_P): Likewise.
7821
7822 * decl.c (BINDING_LEVEL): Add parenthesis.
7823 (DEF_OPERATOR): Likewise.
7824
91800747
GS
7825 * mangle.c (MANGLE_TRACE): Add parenthesis.
7826 (MANGLE_TRACE_TREE): Likewise.
7827 (write_signed_number): Likewise.
7828 (write_unsigned_number): Likewise.
7829
7830 * pt.c (ccat): Uppercase macro parameter.
7831 (cat): Likewise
7832
7833 * search.c (SET_BINFO_ACCESS): Add parenthesis.
7834
15eb1e43
JM
78352002-01-07 Jason Merrill <jason@redhat.com>
7836
7837 * decl2.c (coerce_new_type): Downgrade error for size_t mismatch
7838 to pedwarn.
7839
6bc34b14 7840 PR c++/3536
15eb1e43
JM
7841 * method.c (make_thunk): If !flag_weak, give the thunk the
7842 function's linkage.
7843 (use_thunk): Here, too.
7844
b34c06e3
GS
78452002-01-07 Graham Stott <grahams@redhat.com>
7846
6bc34b14
JM
7847 * error.c: Update copyright date.
7848 (print_scope_operator): Add parenthesis.
7849 (print_left_paren): Likewise.
7850 (print_right_paren): Likewise.
7851 (print_left_bracket): Likewise.
7852 (print_right_bracket): Likewise.
7853 (print_template_argument_list_start): Likewise.
7854 (print_template_argument_list_end): Likewise.
7855 (print_non_consecutive_character): Likewise.
7856 (print_tree_identifier): Likewise.
7857 (print_identifier): Likewise.
7858 (NEXT_CODE): Uppercase macro parameter.
7859 (ident_fndecl): Delete unused.
7860 (GLOBAL_THING): Likewise.
b34c06e3 7861
98e40e83
GS
78622002-01-06 Graham Stott <grahams@redhat.com>
7863
7864 * cp-tree.h (VAR_OR_FUNCTION_DECL_CHECK): Add parenthesis.
7865 (VAR_FUNCTION_OR_PARM_DECL_CHECK): Likewise.
7866 (VAR_TEMPL_TYPE_OR_FUNCTION_DECL_CHECK) Likewise.
7867 (RECORD_OR_UNION_TYPE_CHECK): Likewise.
7868 (BOUND_TEMPLATE_TEMPLATE_PARM_TYPE_CHECK): Likewise.
7869 (C_IS_RESERVED_WORD): Uppercase macro parameter.
7870 (C_RID_YYCODE) Likewise.
7871 (ptrmem_cst): Use rtx.
7872 (LOCAL_BINDING_P): Add whitespace.
7873 (INHERITED_VALUE_BINDING_P): Likewise.
7874 (BINDING_SCOPE): Wrap long line.
7875 (BINDING_HAS_LEVEL_P): Remove parenthesis.
7876 (BINDING_VALUE): Wrap long line.
7877 (BINDING_TYPE): Whitespace.
7878 (IDENTIFIER_GLOBAL_VALUE): Add parenthesis.
7879 (SET_IDENTIFIER_GLOBAL_VALUE): Likewise.
c588e52b 7880 (IDENTIFIER_NAMESPACE_VALUE): Likewise.
98e40e83
GS
7881 (SET_IDENTIFIER_NAMESPACE_VALUE: Likewise.
7882 (same_type_p): Uppercase macro parameters.
7883 (same_type_ignoring_top_level_qualifiers_p): Likewise.
7884 (OVL_FUNCTION): Wrap long line.
7885 (OVL_CHAIN): Whitespace.
b34c06e3 7886 (OVL_CURRENT): Add parenthesis and whitespace.
98e40e83
GS
7887 (OVL_NEXT): Whitespace.
7888 (OVL_USED): Likewise.
7889 (IDENTIFIER_TYPE_VALUE): Likewise.
7890 (REAL_IDENTIFIER_TYPE_VALUE): Remove parenthesis.
7891 (SET_IDENTIFIER_TYPE_VALUE): Add parenthesis and whitespace.
7892 (LANG_ID_FIELD): Whitespace.
7893 (SET_LANG_ID(NODE,VALUE,NAME): Likewise.
7894 (IDENTIFIER_LABEL_VALUE): Whitespace and wrap.
7895 (SET_IDENTIFIER_LABEL_VALUE): Whitespace.
7896 (IDENTIFIER_IMPLICIT_DECL): Whitespace and wrap.
7897 (SET_IDENTIFIER_IMPLICIT_DECL); Whitespace.
7898 (IDENTIFIER_ERROR_LOCUS): Whitespace and wrap.
7899 (SET_IDENTIFIER_ERROR_LOCUS); Whitespace.
7900 (IDENTIFIER_VIRTUAL_P): Likewise.
7901 (IDENTIFIER_OPNAME_P): Likewise.
7902 (IDENTIFIER_TYPENAME_P): Remove parenthesis.
7903 (C_TYPE_FIELDS_READONLY): Uppercase macro parameters.
7904 (C_SET_EXP_ORIGINAL_CODE): Likewise.
7905 (TYPE_ASSEMBLER_NAME_STRING): Wrap long line.
7906 (TYPE_ASSEMBLER_NAME_LENGTH): Likewise.
7907 (IS_AGGR_TYPE): Uppercase macro parameter.
7908 (CLASS_TYPE_P): Likewise.
7909 (IS_AGGR_TYPE_CODE): Uppercase macro parameter and parenthesis.
7910 (IS_AGGR_TYPE_2): Whitespace.
7911 (TAGGED_TYPE_P): Uppercase macro parameter.
7912 (TYPE_BUILT_IN): Whitespace.
7913 (TYPE_FOR_JAVA): Likewise.
7914 (FUNCTION_ARG_CHAIN): Remove parenthesis.
7915 (FUNCTION_FIRST_USER_PARMTYPE): Add parenthesis.
7916 (FUNCTION_FIRST_USER_PARAM): Likewise.
7917 (PROMOTES_TO_AGGR_TYPE): Whitespace.
7918 (DERIVED_FROM_P): Add parenthesis and wrap.
7919 (UNIQUELY_DERIVED_FROM_P): Likewise.
7920 (ACCESSIBLY_UNIQUELY_DERIVED_P): Likewise.
7921 (PUBLICLY_UNIQUELY_DERIVED_P): Likewise.
7922 (CLASSTYPE_USE_TEMPLATE): Whitespace.
7923 (CLASSTYPE_INLINE_FRIENDS): Remove parenthesis.
7924 (TYPE_GETS_DELETE): Add parenthesis.
7925 (TYPE_HAS_CONVERSION): Add parenthesis and wrap.
7926 (TYPE_HAS_ASSIGN_REF): Likewise,
7927 (TYPE_HAS_CONST_ASSIGN_REF): Likewise.
7928 (TYPE_HAS_INIT_REF): Likewise.
7929 (TYPE_HAS_CONST_INIT_REF): Likewise.
7930 (TYPE_BEING_DEFINED): Likewise.
7931 (TYPE_LANG_SPECIFIC): Likewise.
7932 (CLASSTYPE_RTTI): Likewise.
7933 (TYPE_OVERLOADS_CALL_EXPR): Likewise.
7934 (TYPE_OVERLOADS_ARRAY_REF): Likewise.
7935 (TYPE_OVERLOADS_ARROW): Likewise.
7936 (TYPE_USES_MULTIPLE_INHERITANCE): Likewise.
7937 (TYPE_USES_VIRTUAL_BASECLASSES): Add parenthesis.
7938 (CLASSTYPE_METHOD_VEC): Likewise.
7939 (CLASSTYPE_MARKED_N): Likewise.
7940 (CLASSTYPE_MARKED): Likewise.
7941 (CLASSTYPE_MARKED2): Likewise.
7942 (CLASSTYPE_MARKED3): Likewise.
7943 (CLASSTYPE_MARKED4): Likewise.
7944 (CLASSTYPE_MARKED5): Likewise.
7945 (CLASSTYPE_MARKED6): Likewise.
7946 (SET_CLASSTYPE_MARKED): Whitespace.
7947 (CLEAR_CLASSTYPE_MARKED): Likewise.
7948 (SET_CLASSTYPE_MARKED2): Likewise.
7949 (CLEAR_CLASSTYPE_MARKED2): Likewise.
7950 (SET_CLASSTYPE_MARKED3): Likewise.
7951 (CLEAR_CLASSTYPE_MARKED3): Likewise.
7952 (SET_CLASSTYPE_MARKED4): Likewise.
7953 (CLEAR_CLASSTYPE_MARKED4): Likewise.
7954 (SET_CLASSTYPE_MARKED5): Likewise.
7955 (CLEAR_CLASSTYPE_MARKED5): Likewise.
7956 (SET_CLASSTYPE_MARKED6): Likewise.
7957 (CLEAR_CLASSTYPE_MARKED6): Likewise.
7958 (CLASSTYPE_TAGS): Likewise.
7959 (CLASSTYPE_VSIZE): Likewise.
7960 (CLASSTYPE_VBASECLASSES): Likewise.
7961 (CANONICAL_BINFO): Add parenthesis.
7962 (CLASSTYPE_SIZE(NODE): Likewise.
7963 (CLASSTYPE_SIZE_UNIT): Likewise.
7964 (CLASSTYPE_ALIGN(NODE): Likewise.
7965 (CLASSTYPE_USER_ALIGN): Likewise.
7966 (TYPE_JAVA_INTERFACE): Likewise.
7967 (CLASSTYPE_PURE_VIRTUALS): Likewise.
7968 (CLASSTYPE_NEEDS_VIRTUAL_REINIT): Whitespace and wrap.
7969 (TYPE_HAS_DEFAULT_CONSTRUCTOR): Likewise.
7970 (CLASSTYPE_HAS_MUTABLE): Likewise.
7971 (CLASSTYPE_FRIEND_CLASSES): Likewise. Likewise.
7972 (CLASSTYPE_DECLARED_CLASS): Whitespace and wrap.
7973 (CLASSTYPE_READONLY_FIELDS_NEED_INIT): Likewise.
7974 (CLASSTYPE_REF_FIELDS_NEED_INIT): Likewise.
7975 (CLASSTYPE_INTERFACE_ONLY): Likewise.
7976 (CLASSTYPE_INTERFACE_KNOWN): Likewise.
7977 (CLASSTYPE_INTERFACE_UNKNOWN): Likewise.
7978 (SET_CLASSTYPE_INTERFACE_UNKNOWN_X): Likewise.
7979 (SET_CLASSTYPE_INTERFACE_UNKNOWN): Likewise.
7980 (SET_CLASSTYPE_INTERFACE_KNOWN): Likewise.
7981 (CLASSTYPE_DEBUG_REQUESTED): Whitespace and wrap.
7982 (BINFO_UNSHARED_MARKED): Whitespace.
7983 (BINFO_MARKED): Whitespace and wrap.
7984 (SET_BINFO_MARKED): Likewise.
7985 (CLEAR_BINFO_MARKED): Likewise.
7986 (BINFO_VTABLE_PATH_MARKED): Likewise.
7987 (SET_BINFO_VTABLE_PATH_MARKED): Likewise.
7988 (CLEAR_BINFO_VTABLE_PATH_MARKED): Likewise.
7989 (BINFO_SUBVTT_INDEX): Remove parenthesis.
7990 (BINFO_VPTR_INDEX): Likewise.
7991 (BINFO_PRIMARY_BASE_OF): Likewise,
7992 (CLASSTYPE_VFIELDS): Whitespace.
7993 (VF_DERIVED_VALUE): Wrap long line.
7994 (NAMESPACE_LEVEL): Whitespace.
6bc34b14
JM
7995 (CAN_HAVE_FULL_LANG_DECL_P): Remove parenthesis.
7996 (DEFARG_POINTER): Whitespace.
7997 (DECL_NEEDED_P): Remove parenthesis.
7998 (DECL_LANGUAGE): Whitespace.
7999 (SET_DECL_LANGUAGE): Add parenthesis.
8000 (DECL_CONSTRUCTOR_P): Whitespace and wrap.
8001 (DECL_OVERLOADED_OPERATOR_P): Remove parenthesis.
8002 (DECL_IN_AGGR_P): Whitespace.
8003 (DECL_FRIEND_P): Likewise.
8004 (DECL_BEFRIENDING_CLASSES): Likewise.
8005 (DECL_STATIC_FUNCTION_P): Whitespace and wrap.
8006 (DECL_NONCONVERTING_P): Whitespace.
8007 (DECL_PURE_VIRTUAL_P): Likewise.
8008 (DECL_NEEDS_FINAL_OVERRIDER_P): Likewise.
8009 (DECL_PENDING_INLINE_INFO): Whitespace.
8010 (DECL_SORTED_FIELDS): Likewise.
8011 (DECL_DEFERRED_FN): Likewise.
8012 (DECL_TEMPLATE_INFO): Likewise.
8013 (CLASSTYPE_TEMPLATE_INFO): Whitespace and wrap.
8014 (TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO); Likewise.
8015 (SET_TYPE_TEMPLATE_INFO): Add parenthesis.
8016 (TMPL_ARGS_LEVEL): Likewise.
8017 (SET_TMPL_ARGS_LEVEL): Likewise.
8018 (INNERMOST_TEMPLATE_PARMS): Whitespace.
8019 (C_TYPEDEF_EXPLICITLY_SIGNED): Uppercase macro parameter.
8020 (INTEGRAL_CODE_P(CODE): Add parenthesis.
8021 (CP_INTEGRAL_TYPE_P): Remove parenthesis.
8022 (TYPE_HAS_CONSTRUCTOR): Whitespace.
8023 (TREE_HAS_CONSTRUCTOR): Likewise.
8024 (TYPE_HAS_DESTRUCTOR): Likewise.
8025 (TYPE_HAS_REAL_ASSIGN_REF): Likewise.
8026 (TYPE_HAS_COMPLEX_ASSIGN_REF): Likewise.
8027 (TYPE_HAS_ABSTRACT_ASSIGN_REF): Likewise.
8028 (TYPE_HAS_COMPLEX_INIT_REF): Likewise.
8029 (TYPE_HAS_NONTRIVIAL_DESTRUCTOR): Likewise.
8030 (TYPE_PTRMEMFUNC_P): Likewise.
8031 (TYPE_PTRMEMFUNC_FLAG): Likewise.
8032 (TYPE_GET_PTRMEMFUNC_TYPE): Likewise.
8033 (TYPE_SET_PTRMEMFUNC_TYPE): Likewise.
8034 (TYPE_PTRMEM_CLASS_TYPE): Remove parenthesis.
8035 (TYPE_PTRMEM_POINTED_TO_TYPE): Likewise.
8036 (DECL_ACCESS): Whitespace.
8037 (DECL_GLOBAL_CTOR_P): Remove parenthesis.
8038 (DECL_GLOBAL_DTOR_P): Likewise.
8039 (GLOBAL_INIT_PRIORITY): Likewise.
98e40e83 8040 (DECL_TEMPLATE_PARMS): Likewise.
6bc34b14
JM
8041 (DECL_TEMPLATE_RESULT): Likewise.
8042 (DECL_TEMPLATE_INSTANTIATIONS): Likewise.
8043 (DECL_TEMPLATE_SPECIALIZATIONS): Likewise.
8044 (DECL_IMPLICIT_TYPEDEF_P): Remove parenthesis.
8045 (SET_DECL_IMPLICIT_TYPEDEF_P): Likewise.
8046 (PRIMARY_TEMPLATE_P): Add parenthesis.
8047 (DECL_USE_TEMPLATE): Whitespace.
8048 (CLASSTYPE_IMPLICIT_INSTANTIATION): Likewise.
8049 (SET_CLASSTYPE_IMPLICIT_INSTANTIATION): Likewise.
8050 (CLASSTYPE_EXPLICIT_INSTANTIATION): Likewise.
8051 (SET_CLASSTYPE_EXPLICIT_INSTANTIATION): Likewise.
8052 (CALL_DECLARATOR_PARMS): Remove parenthesis.
8053 (CALL_DECLARATOR_QUALS): Likewise.
8054 (CALL_DECLARATOR_EXCEPTION_SPEC): Likewise.
8055 (TEMP_NAME_P): Wrap.
8056 (VFIELD_NAME_P): Likewise.
8057 (B_SET): Uppercase macro parameters and add parenthesis.
8058 (B_CLR): Likewise.
8059 (B_TST): Likewise.
8060 (LOOKUP_NAMESPACES_ONLY): Uppercase macro parameters.
8061 (LOOKUP_TYPES_ONLY): Uppercase macro parameters.
8062 (LOOKUP_QUALIFIERS_ONLY): Uppercase macro parameters.
8063 (same_or_base_type_p): Likewise.
8064 (cp_deprecated): Likewise.
98e40e83 8065
c28abdf0
RH
80662002-01-05 Richard Henderson <rth@redhat.com>
8067
15eb1e43 8068 * semantics.c (expand_body): Revert last change.
c28abdf0 8069
f11ee281
JM
80702002-01-04 Jason Merrill <jason@redhat.com>
8071
195a5def 8072 PR c++/4122
f11ee281
JM
8073 * class.c (update_vtable_entry_for_fn): Set delta to zero for a
8074 lost primary.
8075
8076 * class.c (build_vtbl_initializer): Check for a lost primary
8077 before calculating the vtable entry to throw away.
8078
a4200657
JM
80792002-01-02 Jason Merrill <jason@redhat.com>
8080
8081 * semantics.c (expand_body): Call outlining_inline_function when
8082 emitting an inline function out of line.
8083
40e593d7
NS
80842002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8085
8086 PR c++/5116, c++/764 reversion
8087 * call.c (build_new_op): Revert the instantiations. They are
8088 incorrect.
c588e52b 8089
323728aa
NS
80902002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8091
8092 PR c++/5089
8093 * decl2.c (reparse_absdcl_as_casts): Don't warn about casts to void.
8094
46c895ac
NS
80952002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8096
8097 PR c++/3716
8098 * pt.c (tsubst_aggr_type): Move pmf handling into tsubst.
8099 (tsubst, case POINTER_TYPE): Handle pmfs here.
8100 (tsubst, case OFFSET_TYPE): Check it is not an offset to
8101 reference. If it is offset to FUNCTION_TYPE, create a METHOD_TYPE.
8102
833aa4c4
NS
81032002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8104
8105 PR c++/35
8106 * cp-tree.h (DECL_LANG_FLAG_0): Used for PARM_DECL too.
8107 (DECL_TEMPLATE_PARM_P): A PARM_DECL might be one too.
8108 * pt.c (process_template_parm): SET_DECL_TEMPLATE_PARM_P on the
8109 PARM_DECL.
8110 (tsubst_template_parms): Break up loop statements.
8111 (tsubst_decl, case PARM_DECL): Copy DECL_TEMPLATE_PARM_P. Template
8112 parm PARM_DECLs don't get promoted.
8113
18976b21
NS
81142002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8115
8116 PR c++/5123
8117 * typeck.c (build_component_ref): Cope with a TEMPLATE_ID_EXPR.
8118 (build_x_function_call): Cope with a COMPONENT_REF containing a
8119 TEMPLATE_ID_EXPR.
8120
303d1c55
NS
81212002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8122
8123 PR c++/5213
8124 * pt.c (convert_template_argument): Be more careful determining
8125 when RECORD_TYPE templates are or are not templates.
8126
d46a33b3
NS
81272002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8128
8129 PR c++/775
8130 * cp-tree.h (handle_class_head): Adjust prototype.
8131 * decl2.c (handle_class_head): Add DEFN_P and NEW_TYPE_P
8132 parameters. Use for all class heads.
8133 * parse.y (named_class_head_sans_basetype, named_class_head,
8134 named_complex_class_head_sans_basetype,
8135 named_class_head_sans_basetype_defn,
8136 unnamed_class_head): Remove.
8137 (class_head, class_head_apparent_template): Recognize class heads
8138 (class_head_decl, class_head_defn): New reductions. Process class
8139 heads.
8140 (structsp): Adjust class definition and class declaration
8141 reductions.
8142 (maybe_base_class_list): Give diagnostic on empty list.
8143
4542128e
NS
81442002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8145
8146 PR c++/4379
8147 * typeck.c (build_x_unary_op): Don't destroy the OFFSET_REF on a
8148 single non-static member.
8149 (unary_complex_lvalue): If it cannot be a pointer to member, don't
8150 make it so. Check it is not pointer to reference.
8151
903c6234
NS
81522002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8153
8154 PR c++/5132
8155 * decl2.c (reparse_absdcl_as_casts): Don't digest_init if we
8156 are processing a template decl.
8157
477558bf
NS
81582002-01-02 Nathan Sidwell <nathan@codesourcery.com>
8159
8160 PR c++/5116, c++/764
8161 * call.c (build_new_op): Make sure template class operands are
8162 instantiated. Simplify arglist construction.
8163
41f5d4b1
NS
81642001-12-29 Nathan Sidwell <nathan@codesourcery.com>
8165
8166 * call.c (build_user_type_conversion_1): Use my_friendly_assert
8167 rather than if ... abort.
8168 * cvt.c (convert_to_reference): Likewise.
8169 * semantics.c (setup_vtbl_ptr): Likewise.
8170 * pt.c (lookup_template_class): Comment typo.
c588e52b 8171
f3368a90
NS
81722001-12-29 Nathan Sidwell <nathan@codesourcery.com>
8173
8174 PR c++/5125
8175 * pt.c (push_template_decl_real): Make sure DECL has
8176 DECL_LANG_SPECIFIC.
8177
03c9c274
NS
81782001-12-29 Nathan Sidwell <nathan@codesourcery.com>
8179
8180 PR c++/335
8181 * init.c (resolve_offset_ref): Copy cv qualifiers of this pointer
8182 for non-reference fields.
8183 * typeck.c (require_complete_type): Use resolve_offset_ref).
8184
7d8e8369
NS
81852001-12-26 Nathan Sidwell <nathan@codesourcery.com>
8186
8187 PR c++/196
03c9c274 8188 * parse.y (bad_parm): Better diagnostic when given a SCOPE_REF.
7d8e8369 8189
a56ca899
NS
81902001-12-24 Nathan Sidwell <nathan@codesourcery.com>
8191
8192 PR c++/160
8193 * typeck.c (build_modify_expr): Remove old unreachable code & tidy
8194 up. Don't stabilize_references when initializing a reference.
8195
0b5826ac
KG
81962001-12-23 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8197
8198 * decl2.c (lang_f_options): Const-ify.
8199
38be19f6
JM
82002001-12-20 Joseph S. Myers <jsm28@cam.ac.uk>
8201
8202 * config-lang.in (diff_excludes): Remove.
8203
2e4cf9dc
NS
82042001-12-19 Nathan Sidwell <nathan@codesourcery.com>
8205
8206 PR c++/90
8207 * typeck.c (build_function_call_real): Use original function
8208 expression for errors.
8209
00e4119c
JM
82102001-12-18 Jason Merrill <jason@redhat.com>
8211
195a5def 8212 PR c++/3242
00e4119c
JM
8213 * class.c (add_method): Do compare 'this' quals when trying to match a
8214 used function. Don't defer to another used function.
8215
3ad97789
NS
82162001-12-18 Nathan Sidwell <nathan@codesourcery.com>
8217
8218 * pt.c (instantiate_clone): Remove, fold into ...
8219 (instantiate_template): ... here. Simplify by removing mutual
8220 recursion.
8221 * typeck2.c (build_m_component_ref): Don't cv qualify the function
8222 pointed to by a pointer to function.
8223 * class.c (delete_duplicate_fields_1): Typo.
8224
f21add07
JM
82252001-12-18 Jason Merrill <jason@redhat.com>
8226
8227 C++ ABI change: destroy value arguments in caller.
8228 * semantics.c (genrtl_start_function, genrtl_finish_function): Don't
8229 create an extra binding level for the parameters.
8230 * decl.c (store_parm_decls): Don't do parameter cleanups.
8231
ea50ad82
NS
82322001-12-18 Nathan Sidwell <nathan@codesourcery.com>
8233
8234 * call.c (build_new_method_call): Use '%#V'.
8235 * error.c (cv_to_string): Use V parameter to determine padding.
8236
3855d0d1
JM
82372001-12-18 Joseph S. Myers <jsm28@cam.ac.uk>
8238
8239 * call.c, decl2.c, init.c: Use "built-in" and "bit-field"
8240 spellings in messages.
8241
33bd39a2
ZW
82422001-12-17 Zack Weinberg <zack@codesourcery.com>
8243
8244 * cp-tree.h: Delete #defines for cp_error, cp_warning,
8245 cp_pedwarn, and cp_compiler_error.
8246 * call.c, class.c, cp-tree.h, cvt.c, decl.c, decl2.c, error.c,
8247 except.c, friend.c, init.c, lex.c, method.c, parse.y, pt.c,
8248 rtti.c, search.c, semantics.c, spew.c, tree.c, typeck.c,
8249 typeck2.c: Change calls to the above macros to use their
8250 language-independent equivalents: error, warning, pedwarn, and
8251 internal_error respectively.
8252
317c26c3
NB
82532001-12-16 Neil Booth <neil@daikokuya.demon.co.uk>
8254
8255 * decl2.c (finish_file): Remove back_end_hook.
8256
aba649ba
JM
82572001-12-16 Joseph S. Myers <jsm28@cam.ac.uk>
8258
8259 * ChangeLog.1, ChangeLog.2, ChangeLog, NEWS, call.c, class.c,
8260 cp-tree.h, decl.c, decl2.c, except.c, operators.def, optimize.c,
8261 pt.c, rtti.c, semantics.c, typeck.c: Fix spelling errors.
8262
1737c953
JM
82632001-12-15 Joseph S. Myers <jsm28@cam.ac.uk>
8264
8265 * lang-options.h: Use American spelling in messages.
8266
4a90862e
JM
82672001-12-13 Jason Merrill <jason@redhat.com>
8268
ade3dc07
JM
8269 * Make-lang.in (parse.h): Separate rule, just depend on parse.c.
8270
8271 Use cleanups to run base and member destructors.
8272 * init.c (push_base_cleanups): New function, split out from...
8273 (build_delete): ...here. Lose !TYPE_HAS_DESTRUCTOR code.
8274 * decl.c (finish_destructor_body): Move vbase destruction code to
8275 push_base_cleanups.
8276 (begin_function_body, finish_function_body): New fns.
8277 (finish_function): Move [cd]tor handling and call_poplevel to
8278 finish_function_body.
8279 (pushdecl): Skip the new level.
8280 * semantics.c (genrtl_try_block): Don't call end_protect_partials.
8281 (setup_vtbl_ptr): Call push_base_cleanups.
8282 * method.c (synthesize_method): Call {begin,end}_function_body.
8283 * pt.c (tsubst_expr): Handle COMPOUND_STMT_BODY_BLOCK.
8284 * cp-tree.h: Declare new fns.
8285 * parse.y (function_body, .begin_function_body): New nonterminals.
8286 (fndef, pending_inline, function_try_block): Use function_body.
8287 (ctor_initializer_opt, function_try_block): No longer has a value.
8288 (base_init): Remove .set_base_init token.
8289 (.set_base_init, compstmt_or_error): Remove.
8290 * Make-lang.in (parse.c): Expect two fewer s/r conflicts.
8291
4a90862e
JM
8292 * optimize.c (maybe_clone_body): Fix parameter updating.
8293
a0de9d20
JM
82942001-12-12 Jason Merrill <jason@redhat.com>
8295
8296 * decl.c (store_parm_decls): Remove parms_have_cleanups cruft.
8297 * semantics.c (genrtl_start_function): Don't pass
8298 parms_have_cleanups or push an extra binding level.
8299 (genrtl_finish_function): Lose cleanup_label cruft.
8300
8301 * cp-tree.h (struct cp_language_function): Remove x_ctor_label.
8302 (ctor_label): Remove.
8303 * semantics.c (finish_return_stmt): Lose ctor_label support.
8304 * decl.c (finish_constructor_body, mark_lang_function): Likewise.
33bd39a2 8305 * typeck.c (check_return_expr): Check DECL_DESTRUCTOR_P, not
a0de9d20
JM
8306 dtor_label.
8307
8308 * call.c (build_new_method_call): Let resolves_to_fixed_type_p
8309 check for [cd]tors.
8310 * class.c (fixed_type_or_null, case INDIRECT_REF): Fix.
8311
8312 * decl.c (finish_function): Check VMS_TARGET, not VMS.
8313
8314 * decl.c (start_cleanup_fn): Remove redundant pushlevel.
8315 (end_cleanup_fn): And poplevel.
8316
8317 * semantics.c (setup_vtbl_ptr): Always build a CTOR_INITIALIZER
8318 if we're in a template.
8319
dc5c569a
JJ
83202001-12-12 Jakub Jelinek <jakub@redhat.com>
8321
8322 * cp-tree.h (DESTRUCTOR_DECL_PREFIX, DESTRUCTOR_NAME_P,
8323 ANON_PARMNAME_FORMAT, ANON_PARMNAME_P, DESTRUCTOR_NAME_FORMAT,
8324 THIS_NAME_P): Delete.
8325 * spew.c (read_process_identifier): Remove DESTRUCTOR_NAME_P,
8326 THIS_NAME_P and ANON_PARMNAME_P tests from warning about clash
8327 with internal naming scheme.
8328 * error.c (dump_decl): Remove DESTRUCTOR_NAME_P use.
8329
ad1a6d45
NS
83302001-12-12 Nathan Sidwell <nathan@codesourcery.com>
8331
8332 * decl.c (grokdeclarator): Deprecated implicit typename use.
8333
270d8c65
NS
83342001-12-11 Nathan Sidwell <nathan@codesourcery.com>
8335
8336 PR g++/51
8337 * parse.y (frob_specs): Indicate it is a language linkage which
8338 contained the extern.
8339 * decl.c (grokdeclarator): Allow extern language linkage with
8340 other specifiers.
8341
9aaceb4b
NS
83422001-12-10 Nathan Sidwell <nathan@codesourcery.com>
8343
8344 PR g++/72
8345 * decl.c (add_binding): Don't reject duplicate typedefs involving
8346 template parameters.
8347
a23c9413
NB
83482001-12-10 Neil Booth <neil@daikokuya.demon.co.uk>
8349
8350 * parse.y, semantics.c: Similarly.
8351
9aaceb4b 83522001-12-09 Nathan Sidwell <nathan@codesourcery.com>
271e6f02
NS
8353
8354 PR g++/87
8355 * cp-tree.h (DECL_COPY_CONSTRUCTOR_P): Use copy_fn_p.
8356 (copy_args_p): Rename to ...
8357 (copy_fn_p): ... here.
8358 (grok_special_member_properties): New function.
8359 (grok_op_properties): Lose VIRTUALP parameter.
8360 (copy_assignment_arg_p): Remove.
8361 * call.c (build_over_call): Use copy_fn_p.
8362 * decl.c (grokfndecl): Reformat. Adjust call to
8363 grok_op_properties.
8364 (copy_args_p): Rename to ...
8365 (copy_fn_p): ... here. Reject template functions. Check for pass
8366 by value.
8367 (grok_special_member_properties): Remember special functions.
8368 (grok_ctor_properties): Don't remember them here, just check.
8369 (grok_op_properties): Likewise.
8370 (start_method): Call grok_special_member_properties.
8371 * decl2.c (grokfield): Likewise.
8372 (copy_assignment_arg_p): Remove.
8373 (grok_function_init): Don't remember abstract assignment here.
8374 * pt.c (instantiate_class_template): Call
8375 grok_special_member_properties.
8376 (tsubst_decl): Adjust grok_op_properties call.
8377
bdd8737f
AH
83782001-12-08 Aldy Hernandez <aldyh@redhat.com>
8379
33bd39a2
ZW
8380 * lex.c (rid_to_yy): Add RID_CHOOSE_EXPR and
8381 RID_TYPES_COMPATIBLE_P.
bdd8737f 8382
46af705a
JDA
83832001-12-08 John David Anglin <dave@hiauly1.hia.nrc.ca>
8384
8385 * semantics.c (simplify_aggr_init_exprs_r): Add DIRECT_BIND flag in
8386 call to build_aggr_init.
8387 * cp-tree.h (DIRECT_BIND): Document new use of DIRECT_BIND.
8388
cb97d97d
NB
83892001-12-08 Neil Booth <neil@daikokuya.demon.co.uk>
8390
8391 * parse.y: Replace uses of the string non-terminal with STRING.
8392 Don't perform string concatentaion here.
8393 (string): Remove non-terminal.
8394 * semantics.c (finish_asm_stmt): Don't concatenate strings here.
8395
742a37d5
JM
83962001-12-05 Jason Merrill <jason@redhat.com>
8397
8398 * cp-lang.c (LANG_HOOKS_TREE_INLINING_START_INLINING): Define.
8399 (LANG_HOOKS_TREE_INLINING_END_INLINING): Define.
8400 * tree.c (cp_start_inlining, cp_end_inlining): New fns.
8401 * pt.c (push_tinst_level): No longer static.
8402 * cp-tree.h: Declare them.
8403
8404 * init.c (resolve_offset_ref): Don't check access for the base
8405 conversion to access a FIELD_DECL.
8406
8407 * cp-tree.h (TYPE_REFFN_P): New macro.
8408 * decl.c (bad_specifiers): Check it, too.
8409
8410 * rtti.c (create_pseudo_type_info): Set CLASSTYPE_INTERFACE_ONLY
8411 on the __*_type_info type if we haven't seen a definition.
8412
26f943fd
NB
84132001-12-05 Neil Booth <neil@daikokuya.demon.co.uk>
8414
8415 * decl.c: Include c-common.h.
8416 (shadow_warning): Move to c-common.c.
8417
d2a6f3c0 84182001-12-05 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
37a08a29
RK
8419
8420 * decl.c (duplicate_decls): Don't copy DECL_NO_CHECK_MEMORY_USAGE.
8421
9471d3e2
NS
84222001-12-04 Nathan Sidwell <nathan@codesourcery.com>
8423
8424 * pt.c (end_template_parm_list): Clear TREE_CHAIN of each parm.
8425
713ccd0c
NS
84262001-12-04 Nathan Sidwell <nathan@codesourcery.com>
8427
8428 PR g++/164
8429 * init.c (sort_base_init): Allow binfos to be directly specified.
8430 * method.c (do_build_copy_constructor): Explicitly convert to the
8431 base instance.
8432 (do_build_assign_ref): Likewise.
8433
591382c4
HPN
84342001-12-03 Hans-Peter Nilsson <hp@bitrange.com>
8435
8436 * decl.c (xref_basetypes): Don't use C99 construct in tag_code
8437 declaration and initialization.
8438
c725bd79
NB
84392001-12-03 Neil Booth <neil@daikokuya.demon.co.uk>
8440
8441 * typeck2.c: Remove leading capital from diagnostic messages, as
8442 per GNU coding standards.
8443
a5d7c4a3
MK
84442001-12-03 Mumit Khan <khan@nanotech.wisc.edu>
8445
8446 PR c++/3394
9fe038e8
HPN
8447 * decl.c (xref_basetypes): Handle attributes between
8448 'class' and name.
a5d7c4a3 8449
f1880e13
NS
84502001-12-03 Nathan Sidwell <nathan@codesourcery.com>
8451
8452 PR g++/3381
8453 * parse.y (named_complex_class_head_sans_basetype): Add new
8454 reduction.
8455 * Make-lang.in (parse.c): Adjust expected conflict count.
8456
ff668506
JM
84572001-12-03 Jason Merrill <jason@redhat.com>
8458
8459 * class.c (finish_vtbls): Fill in BINFO_VPTR_FIELD in the
8460 immediate binfos for our virtual bases.
8461
1f978f5f
NB
84622001-12-02 Neil Booth <neil@daikokuya.demon.co.uk>
8463
8464 * call.c (build_java_interface_fn_ref): Similarly.
8465 * except.c (is_admissible_throw_operand): Similarly.
8466 * init.c (build_java_class_ref): Similarly.
8467 * xref.c (open_xref_file): Similarly.
8468
357351e5
NB
84692001-12-01 Neil Booth <neil@daikokuya.demon.co.uk>
8470
8471 * class.c (finish_struct): Remove trailing periods from messages.
8472 * decl.c (check_tag_decl): Similarly.
8473 * lex.c (cxx_set_yydebug): Similarly.
8474 * typeck2.c (friendly_abort): Similarly.
8475
998979e6
MM
84762001-11-29 Mark Mitchell <mark@codesourcery.com>
8477
8478 PR c++/3048
8479 * cp-tree.h (ovl_member): Remove.
33bd39a2 8480 * decl2.c (merge_functions): Handle extern "C" functions
998979e6
MM
8481 specially.
8482 * tree.c (ovl_member): Remove.
8483
7d5b8b11
MM
84842001-11-29 Mark Mitchell <mark@codesourcery.com>
8485
8486 PR c++/4842
8487 * class.c (get_basefndecls): Take an IDENTIFIER_NODE, not a
8488 FUNCTION_DECL, as input.
8489 (mark_overriders): Remove.
8490 (warn_hidden): Rework for the new ABI.
8491
b67db529
MM
84922001-11-29 Mark Mitchell <mark@codesourcery.com>
8493
8494 PR c++/3471
8495 * call.c (convert_like_real): Do not build additional temporaries
8496 for rvalues of class type.
8497
2db1ab2d
NS
84982001-11-28 Nathan Sidwell <nathan@codesourcery.com>
8499
8500 * cp-tree.h (UNIQUELY_DERIVED_FROM_P): Use lookup base.
8501 (ACCESSIBLY_UNIQUELY_DERIVED_FROM_P): Likewise.
8502 (PUBLICLY_UNIQUELY_DERIVED_FROM_P: Likewise.
8503 (DERIVED_FROM_P): Likewise.
8504 (enum base_access): Renumber, add ba_quiet bit mask.
8505 (get_binfo): Remove.
8506 (get_base_distance): Remove.
8507 (binfo_value): Remove.
8508 (ACCESSIBLY_DERIVED_FROM_P): Remove.
8509 * call.c (standard_conversion): Use lookup_base.
8510 * class.c (strictly_overrides): Likewise.
8511 (layout_virtual_bases): Likewise.
8512 (warn_about_ambiguous_direct_bases): Likewise.
8513 (is_base_of_enclosing_class): Likewise.
8514 (add_vcall_offset_vtbl_entries_1): Likewise.
8515 * cvt.c (build_up_reference): Adjust comment.
8516 * init.c (build_member_call): Reformat.
8517 * search.c (get_binfo): Remove.
8518 (get_base_distance_recursive): Remove.
8519 (get_base_distance): Remove.
8520 (lookup_base_r): Tweak.
8521 (lookup_base): Add ba_quiet control. Complete the types here.
8522 (covariant_return_p): Use lookup_base.
8523 * tree.c (binfo_value): Remove.
8524 (maybe_dummy_object): Use lookup_base.
8525 * typeck.c (build_static_cast): Use lookup_base.
8526 (get_delta_difference): Likewise.
8527 * typeck2.c (binfo_or_else): Use lookup_base.
8528 (build_scoped_ref): Add back error_mark_check.
8529 (build_m_component_ref): Use lookup_base.
8530
d3945f0a
JM
85312001-11-29 Joseph S. Myers <jsm28@cam.ac.uk>
8532
8533 * Make-lang.in (c++.generated-manpages): New dummy target.
8534
d2a6f3c0 85352001-11-27 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
ac79cd5a
RK
8536
8537 * Make-lang.in (cp-lang.o): Depends on c-common.h.
8538 * cp-lang.c (c-common.h): Include.
8539 (LANG_HOOKS_EXPAND_CONSTANT, LANG_HOOKS_SAFE_FROM_P): New hooks.
8540 * decl.c (cxx_init_decl_processing): Don't set lang_safe_from_p.
8541 * expr.c (init_cplus_expand): Don't set lang_expand_constant.
8542
4d6baafa
NB
85432001-11-26 Neil Booth <neil@daikokuya.demon.co.uk>
8544
8545 * decl2.c (c_language): Move to c-common.c.
8546 * lex.c (cxx_post_options, cxx_init_options): Use c-common.c
8547 functions.
8548 (cxx_init): Update.
8549
5b0c5896
JM
85502001-11-26 Jason Merrill <jason@redhat.com>
8551
8552 * call.c (joust): Remove COND_EXPR hack.
8553
4bdd26e6
AH
85542001-11-25 Aldy Hernandez <aldyh@redhat.com>
8555
195a5def 8556 * search.c (lookup_base_r): Declare bk in variable declaration
4bdd26e6 8557 space.
33bd39a2 8558
338d90b8
NS
85592001-11-25 Nathan Sidwell <nathan@codesourcery.com>
8560
8561 PR g++/3145
8562 * class.c (build_vbase_pointer): Remove.
8563 (build_vbase_path): Remove.
8564 (build_base_path): New function.
8565 * cp-tree.h (base_access, base_kind): New enumerations.
8566 (build_base_path): Declare.
8567 (convert_pointer_to_real): Remove.
8568 (convert_pointer_to): Remove.
8569 (lookup_base): Declare.
8570 (convert_pointer_to_vbase): Remove.
8571 * call.c (build_scoped_method_call): Use lookup_base &
8572 build_base_path instead of convert_pointer_to_real,
8573 get_base_distance & get_binfo.
8574 (build_over_call): Likewise.
8575 * cvt.c (cp_convert_to_pointer): Likewise.
8576 (convert_to_pointer_force): Likewise.
8577 (build_up_reference): Likewise.
8578 (convert_pointer_to_real): Remove.
8579 (convert_pointer_to): Remove.
8580 * init.c (dfs_initialize_vtbl_ptrs): Use build_base_path
8581 instead of convert_pointer_to_vbase & build_vbase_path.
8582 (emit_base_init): Use build_base_path instead of
8583 convert_pointer_to_real.
8584 (expand_virtual_init): Lose unrequired conversions.
8585 (resolve_offset_ref): Use lookup_base and build_base_path
8586 instead of convert_pointer_to.
8587 * rtti.c (build_dynamic_cast_1): Use lookup_base &
8588 build_base_path instead of get_base_distance & build_vbase_path.
8589 * search.c (get_vbase_1): Remove.
8590 (get_vbase): Remove.
8591 (convert_pointer_to_vbase): Remove.
07f521fc 8592 (lookup_base_r): New function.
338d90b8
NS
8593 (lookup_base): New function.
8594 * typeck.c (require_complete_type): Use lookup_base &
8595 build_base_path instead of convert_pointer_to.
8596 (build_component_ref): Likewise.
8597 (build_x_function_call): Likewise.
8598 (get_member_function_from_ptrfunc): Likewise.
8599 (build_component_addr): Likewise.
8600 * typeck2.c (build_scoped_ref): Likewise.
8601
89d684bb
BM
86022001-11-22 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
8603
8604 * cp-tree.h (CP_TYPE_QUALS): Removed.
8605 * decl.c (cxx_init_decl_processing): Don't set lang_dump_tree.
33bd39a2 8606 * cp-lang.c: Set LANG_HOOKS_TREE_DUMP_DUMP_TREE_FN and
89d684bb 8607 LANG_HOOKS_TREE_DUMP_TYPE_QUALS_FN.
33bd39a2 8608 * dump.c (cp_dump_tree): Use void* dump_info argument to match
89d684bb
BM
8609 lang-hooks prototype.
8610 * call.c, cp-tree.h, cvt.c, decl.c, init.c, mangle.c, method.c, pt.c,
8611 rtti.c, semantics.c, tree.c, typeck.c, typeck2.c: All references to
8612 CP_TYPE_QUALS changed to cp_type_quals.
8613 * Make-lang.in: References to c-dump.h changed to tree-dump.h.
8614 (CXX_C_OBJS): Remove c-dump.o.
8615
12eb9f93 86162001-11-21 Mark Mitchell <mark@codesourcery.com>
2d2e8123
MM
8617
8618 PR c++/3637
12eb9f93
MM
8619 * pt.c (lookup_template_class): Ensure that all specializations
8620 are registered on the list corresponding to the most general
8621 template.
8622
86232001-11-20 Mark Mitchell <mark@codesourcery.com>
8624
2d2e8123 8625 * call.c (non_reference): Add documentation.
33bd39a2 8626 (convert_class_to_reference): Do not strip reference types
2d2e8123
MM
8627 from conversion operators.
8628 (maybe_handle_ref_bind): Simplify.
8629 (compare_ics): Correct handling of references.
8630
78a40378
MM
86312001-11-19 John Wilkinson <johnw@research.att.com>
8632
8633 * dump.c (dump_op): New function.
8634 (cp_dump_tree): Dump CLASSTYPE_TEMPLATE_SPECIALIZATION. Use
8635 dump_op. Dump DECL_MUTABLE, access and staticness for VAR_DECLs.
8636 DECL_PURE_VIRTUAL_P, DECL_VIRTUAL_P,
33bd39a2 8637
78a40378
MM
86382001-11-19 Mark Mitchell <mark@codesourcery.com>
8639
8640 PR4629
8641 * semantics.c (finish_sizeof): Make sure that expression created
8642 while processing a template do not have a type.
8643 (finish_alignof): Likewise.
8644 * typeck.c (c_sizeof): Likewise.
8645 (expr_sizeof): Likewise.
8646
22703ccc
NB
86472001-11-18 Neil Booth <neil@daikokuya.demon.co.uk>
8648
8649 * lex.c (cxx_finish): Call c_common_finish.
8650 (finish_parse): Remove.
8651
b3faacfd
KL
86522001-11-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8653
8654 * decl.c (create_array_type_for_decl): Check if NAME is NULL_TREE
8655 when displaying error message about missing array bounds.
8656
873ff987
KL
86572001-11-17 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8658
8659 * mangle.c (write_expression): Handle CAST_EXPR, STATIC_CAST_EXPR,
8660 CONST_CAST_EXPR.
8661 * operators.def: Add CAST_EXPR, STATIC_CAST_EXPR, CONST_CAST_EXPR.
8662
08f3a861
NB
86632001-11-16 Neil Booth <neil@daikokuya.demon.co.uk>
8664
8665 * cp-tree.h (print_class_statistics): Restore.
8666
8a2b77e7
JM
86672001-11-15 Jason Merrill <jason@redhat.com>
8668
3b1a4132
JM
8669 * method.c (use_thunk): Don't emit debugging information for thunks.
8670
8a2b77e7
JM
8671 * parse.y: Add ... IDENTIFIER SCOPE and ... PTYPENAME SCOPE expansions.
8672 * decl.c (make_typename_type): Handle getting a class template.
8673 * search.c (lookup_field_r): A class template is good enough for
8674 want_type.
8675
8676 * call.c (convert_like_real): Only use cp_convert for the bad part.
8677 (standard_conversion): Also allow bad int->enum.
8678 * typeck.c (ptr_reasonably_similar): Also allow functions to
8679 interconvert. Pointers to same-size integers are reasonably
8680 similar.
8681
8682 * cvt.c (convert_to_void): If we build a new COND_EXPR, always
8683 give it void type.
8684
36a68fe7
NS
86852001-11-15 Nathan Sidwell <nathan@codesourcery.com>
8686
8687 PR g++/3154
8688 * init.c (sort_base_init): Remove unreachable code.
8689 (expand_member_init): Adjust comment to reflect reality. Simplify
8690 and remove unreachable code.
8691
f5e99456
NB
86922001-11-15 Neil Booth <neil@daikokuya.demon.co.uk>
8693
8694 * cp-tree.h (init_reswords, cxx_init_decl_processing): New.
8695 (cxx_init): Update prototype.
8696 * decl.c (init_decl_processing): Rename. Move null node init
8697 to its creation time.
8698 * lex.c (cxx_init_options): Update.
8699 (cxx_init): Combine with old init_parse; also call
8700 cxx_init_decl_processing.
8701
fe5b6c1c
RS
87022001-11-14 Richard Sandiford <rsandifo@redhat.com>
8703
8a2b77e7
JM
8704 * decl.c (check_initializer): Try to complete the type of an
8705 array element before checking whether it's complete. Don't
8706 complain about arrays with complete element types but an
8707 unknown size.
8708 (cp_finish_decl): Build the hierarchical constructor before
8709 calling maybe_deduce_size_from_array_init.
fe5b6c1c 8710
77bd67cb
JM
87112001-11-14 Joseph S. Myers <jsm28@cam.ac.uk>
8712
8713 * Make-lang.in: Change all uses of $(manext) to $(man1ext).
8714
b02922a4
NS
87152001-11-13 Nathan Sidwell <nathan@codesourcery.com>
8716
8717 PR g++/4206
8718 * parse.y (already_scoped_stmt): Remove.
8719 (simple_stmt, WHILE & FOR): Use implicitly_scoped_stmt.
8720
abfc1ef6
L
87212001-11-12 H.J. Lu <hjl@gnu.org>
8722
195a5def 8723 * cvt.c (ocp_convert): Don't warn the address of a weak
abfc1ef6
L
8724 function is always `true'.
8725
5d69f816
NB
87262001-11-09 Neil Booth <neil@daikokuya.demon.co.uk>
8727
8728 * cp-lang.c (LANG_HOOKS_PRINT_DECL, LANG_HOOKS_PRINT_TYPE,
8729 LANG_HOOKS_PRINT_STATISTICS, LANG_HOOKS_PRINT_XNODE,
8730 LANG_HOOKS_PRINT_IDENTIFIER, LANG_HOOKS_SET_YYDEBUG): Override.
8731 * cp-tree.h (print_class_statistics): Remove.
8732 (cxx_print_statistics, cxx_print_xnode, cxx_print_decl, cxx_print_type,
8733 cxx_print_identifier, cxx_set_yydebug): New.
8734 * lex.c (set_yydebug): Rename c_set_yydebug.
8735 * ptree.c (print_lang_decl, print_lang_type, print_lang_identifier,
8736 lang_print_xnode): Rename.
8737 * tree.c (print_lang_statistics): Rename.
8738
4fdc14ca
KG
87392001-11-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8740
8741 * class.c (dump_array): Fix format specifier warning.
8742
3ac88239
NB
87432001-11-09 Neil Booth <neil@daikokuya.demon.co.uk>
8744
8745 * cp-lang.c (LANG_HOOKS_NAME): Override.
8746 (struct lang_hooks): Constify.
8747 * lex.c (cxx_init_options): Update.
8748 (lang_identify): Remove.
33bd39a2 8749 * parse.y (language_string): Remove.
3ac88239 8750
b21d216c
AF
87512001-11-08 Andreas Franck <afranck@gmx.de>
8752
8753 * Make-lang.in (CXX_INSTALL_NAME, GXX_CROSS_NAME,
8754 DEMANGLER_CROSS_NAME): Handle program_transform_name the way
8755 suggested by autoconf.
8756 (GXX_TARGET_INSTALL_NAME, CXX_TARGET_INSTALL_NAME): Define.
8757 (c++.install-common): Use the transformed target alias names.
8758
d23c55c2
NB
87592001-11-06 Neil Booth <neil@cat.daikokuya.demon.co.uk>
8760
8761 * Make-lang.in: Update.
8762 * cp-lang.c: Include langhooks-def.h.
8763
2a2b1d56
KL
87642001-11-04 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8765
8766 * pt.c (tsubst_copy): Call tsubst for TYPEOF_EXPR.
8767
76648a8b
KG
87682001-11-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8769
8770 * lex.c (copy_lang_type): Add static prototype.
8771
fccef71e
KL
87722001-11-02 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8773
8774 * pt.c (unify): Handle SCOPE_REF.
8775
19989812
JJ
87762001-11-01 Jakub Jelinek <jakub@redhat.com>
8777
8778 * tree.c (cp_copy_res_decl_for_inlining): Adjust
8779 DECL_ABSTRACT_ORIGIN for the return variable.
8780
5b7874aa
ZW
87812001-10-31 Zack Weinberg <zack@codesourcery.com>
8782
8783 * Make-lang.in: Replace $(INTL_TARGETS) with po-generated.
8784
306ef644
JM
87852001-10-28 Joseph S. Myers <jsm28@cam.ac.uk>
8786
8787 * ChangeLog.1, ChangeLog.2, ChangeLog, class.c, decl2.c, search.c,
8788 semantics.c, spew.c: Fix spelling errors.
8789
76543000
KL
87902001-10-27 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8791
8792 * decl2.c (validate_nonmember_using_decl): Handle NAMESPACE_DECL.
8793
37207ee7
ZW
87942001-10-25 Zack Weinberg <zack@codesourcery.com>
8795
8796 * cp-lang.c: Redefine LANG_HOOKS_CLEAR_BINDING_STACK to
8797 pop_everything.
8798
d2a6f3c0 87992001-10-23 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
8ac61af7
RK
8800
8801 * cp-lang.c (cxx_get_alias_set): New function.
8802 Point LANG_HOOKS_GET_ALIAS_SET to it.
8803
f1e09fa2 88042001-10-23 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
b8c6534b
KL
8805
8806 * cp-tree.def (UNBOUND_CLASS_TEMPLATE): New tree node.
8807 * cp-tree.h (make_unbound_class_template): Prototype new function.
8808 * decl.c (make_unbound_class_template): New function.
8809 * decl2.c (arg_assoc_template_arg): Handle UNBOUND_CLASS_TEMPLATE.
8810 * error.c (dump_type): Likewise.
8811 * mangle.c (write_type): Likewise.
8812 * parse.y (template_parm): Likewise.
8813 (template_argument): Use make_unbound_class_template.
8814 * pt.c (convert_template_argument): Handle UNBOUND_CLASS_TEMPLATE.
8815 (tsubst): Likewise.
8816 (tsubst_copy): Likewise.
8817 (unify): Likewise.
8818 * tree.c (walk_tree): Likewise.
8819 * typeck.c (comptypes): Likewise.
8820
0df6c2c7
KG
88212001-10-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8822
8823 * xref.c (GNU_xref_member): Use safe-ctype macros and/or fold
8824 extra calls into fewer ones.
8825
97055d5c
AO
88262001-10-18 Alexandre Oliva <aoliva@redhat.com>
8827
8828 * decl.c (duplicate_decls): Propagate DECL_UNINLINABLE.
8829 Warn when merging inline with attribute noinline.
8830 (start_decl, start_function): Warn if inline and attribute
8831 noinline appear in the same declaration.
8832
b5823a44
L
88332001-10-16 H.J. Lu <hjl@gnu.org>
8834
8835 * cp-tree.h (BOUND_TEMPLATE_TEMPLATE_PARM_TYPE_CHECK): Defined
8836 for tree checking disabled.
8837
dc8ad298
HPN
88382001-10-16 Hans-Peter Nilsson <hp@axis.com>
8839
8840 * cp-tree.h (VFIELD_NAME_FORMAT) [NO_DOLLAR_IN_LABEL &&
8841 NO_DOT_IN_LABEL]: Adjust to match VFIELD_NAME.
8842
d9f818d9
RS
88432001-10-15 Richard Sandiford <rsandifo@redhat.com>
8844
8845 * pt.c (UNIFY_ALLOW_MAX_CORRECTION): Define.
8846 (unify): Only handle MINUS_EXPR specially if the above flag is set
8847 and the subtracted constant is 1. Clear the flag on recursive calls.
8848 Set it when unifying the maximum value in an INTEGER_TYPE's range.
8849
e1be26f4
RS
88502001-10-15 Richard Sandiford <rsandifo@redhat.com>
8851
8852 * decl.c (bad_specifiers): Don't allow exception specifications
8853 on any typedefs.
8854
a5da89c6
NB
88552001-10-14 Neil Booth <neil@daikokuya.demon.co.uk>
8856
8857 * cp/lex.c (init_cp_pragma): Similarly.
8858
4f96ff63
KL
88592001-10-13 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8860
8861 * pt.c (lookup_template_class): Build complete template arguments
8862 for BOUND_TEMPLATE_TEMPLATE_PARM.
8863
11e74ea6
KL
88642001-10-12 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8865
8866 * cp-tree.h (TYPE_BINFO): Update comment.
8867 (BOUND_TEMPLATE_TEMPLATE_PARM_TYPE_CHECK): New macro.
8868 (TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO): Use template_info.
8869 (TYPENAME_TYPE_FULLNAME): Use TYPE_FIELDS.
8870 (copy_type): Prototype new function.
8871 * lex.c (copy_lang_decl): Gather tree node statistics.
8872 (copy_lang_type): New function.
8873 (copy_type): Likewise.
8874 (cp_make_lang_type): Create lang_type for
8875 BOUND_TEMPLATE_TEMPLATE_PARM. Set TYPE_BINFO for TYPENAME_TYPE
8876 and BOUND_TEMPLATE_TEMPLATE_PARM.
8877 * pt.c (tsubst): Use copy_type instead of copy_node.
8878 * search.c (lookup_field_1): Ignore TYPENAME_TYPE.
8879
f5d47abd
KL
88802001-10-12 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
8881
8882 * pt.c (determine_specialization): Ignore functions without
8883 DECL_TEMPLATE_INFO.
8884
e60505a5
NS
88852001-10-12 Nathan Sidwell <nathan@codesourcery.com>
8886
8887 PR g++/4476
8888 * typeck2.c (abstract_virtuals_error): Ignore incomplete classes.
8889
6f32162a
JM
88902001-10-11 Jason Merrill <jason_merrill@redhat.com>
8891
8892 * typeck2.c (store_init_value): Don't re-digest a bracketed
8893 initializer.
8894
8895 * class.c (finish_struct_anon): Use TYPE_ANONYMOUS_P instead of
8896 ANON_AGGR_TYPE_P.
8897
4a8d0c9c
RH
88982001-10-11 Richard Henderson <rth@redhat.com>
8899
8900 * class.c (build_vtable_entry_ref): Create a VTABLE_REF instead
8901 of an asm statement.
8902 (build_vtbl_ref_1): Split out from build_vtbl_ref.
8903 (build_vfn_ref): Use it to handle vtable descriptors before
8904 calling build_vtable_entry_ref.
8905 * decl2.c (output_vtable_inherit): Use assemble_vtable_inherit.
8906
84b72302
RH
89072001-10-10 Richard Henderson <rth@redhat.com>
8908
37207ee7 8909 * parse.y (asm_operand): Allow named operands.
84b72302 8910 * semantics.c (finish_asm_stmt): Tweek for changed location
4639c5c6 8911 of the operand constraint.
84b72302 8912
48c8b0be 89132001-10-09 Jason Merrill <jason_merrill@redhat.com>
72a08131
JM
8914
8915 * call.c (standard_conversion): Add bad conversion between
8916 integers and pointers.
8917 (convert_like_real): Don't use convert_for_initialization for bad
8918 conversions; complain here and use cp_convert.
8919 (build_over_call): Don't handle bad conversions specially.
8920 (perform_implicit_conversion): Allow bad conversions.
8921 (can_convert_arg_bad): New fn.
8922 * cp-tree.h: Declare it.
8923 * typeck.c (convert_for_assignment): Use it.
8924 (ptr_reasonably_similar): Any target type is similar to void.
8925
19551f29
AO
89262001-10-08 Alexandre Oliva <aoliva@redhat.com>
8927
8928 * Make-lang.in (CXX_OBJS): Added cp-lang.o.
8929 (cp/cp-lang.o): New rule.
8930 * cp-tree.h: Declare hooks.
8931 * tree.c: Make hooks non-static.
8932 (init_tree): Don't initialize hooks here.
8933 * lex.c: Likewise. Move definition of lang_hooks to...
8934 * cp-lang.c: ... new file.
8935
31ed8fea
RH
89362001-10-08 Richard Henderson <rth@redhat.com>
8937
8938 * cp-tree.h (struct lang_decl_flags): Remove declared_inline.
8939 (DECL_DECLARED_INLINE_P): Use the bit in struct c_lang_decl.
8940
8b60264b
KG
89412001-10-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
8942
8943 * class.c (build_vtable_entry_ref): Const-ify.
8944 * decl.c (predefined_identifier,
37207ee7 8945 initialize_predefined_identifiers): Likewise.
8b60264b
KG
8946 * init.c (build_new_1): Likewise.
8947 * lex.c (cplus_tree_code_type, cplus_tree_code_length, resword):
8948 Likewise.
8949
bc4c7159
AO
89502001-10-05 Alexandre Oliva <aoliva@redhat.com>
8951
8952 * optimize.c (struct inline_data): Moved to ../tree-inline.c.
8953 (INSNS_PER_STMT): Likewise.
8954 (remap_decl, remap_block, copy_scopy_stmt, copy_body_r): Likewise.
8955 (copy_body, initialize_inlined_parameters): Likewise.
8956 (declare_return_variable, inlinable_function_p): Likewise.
8957 (expand_call_inline, expand_calls_inline): Likewise.
8958 (optimize_inline_calls, clone_body): Likewise.
8959 * tree.c (walk_tree): Moved to ../tree-inline.c.
8960 (walk_tree_without_duplicates): Likewise.
8961 (copy_tree_r, remap_save_expr): Likewise.
8962
25af8512
AO
89632001-10-04 Alexandre Oliva <aoliva@redhat.com>
8964
8965 * Make-lang.in (cp/decl.o, cp/tree.o): Depend on tree-inline.h.
8966 (cp/pt.o, cp/semantics.o, cp/optimize.o): Likewise.
8967 * cp-tree.h (lang_decl): Moved inlined_fns to tree_decl.
8968 (TREE_READONLY_DECL_P, DECL_INLINED_FNS): Moved to ../tree.h.
8969 (flag_inline_trees): Moved declaration to ../tree-inline.h.
8970 (walk_tree): Moved declaration to ../tree-inline.h.
8971 (walk_tree_without_duplicates, copy_tree_r): Likewise.
8972 (remap_save_expr): Likewise.
8973 * decl.c: Include tree-inline.h.
8974 (lang_mark_tree): Don't mark inlined_fns.
8975 * decl2.c (flag_inline_trees): Moved defn to ../tree-inline.c.
8976 * optimize.c: Include tree-inline.h.
8977 (optimize_inline_calls): Move declaration to ../tree.h, as
8978 non-static.
8979 (remap_decl): Use language-independent constructs and hooks.
8980 (remap_block, copy_body_r, declare_return_variable): Likewise.
8981 (inlinable_function_p): Likewise. Don't test for
8982 DECL_LANG_SPECIFIC before DECL_INLINED_FNS as inlined_fns is
8983 no longer language-specific.
8984 (optimize_inline_calls): Likewise. Make it non-static. Moved
8985 call of dump_function to...
8986 (optimize_function): Here...
8987 (clone_body): New function, extracted from...
8988 (maybe_clone_body): ... here. Build decl_map locally and pass
8989 it on to clone_body.
8990 * pt.c, semantics.c: Include tree-inline.h.
8991 * tree.c: Likewise.
8992 (cp_walk_subtrees): New language-specific hook for tree inlining.
8993 (cp_cannot_inline_tree_fn, cp_add_pending_fn_decls,
8994 cp_is_overload_p, cp_auto_var_in_fn_p,
8995 cp_copy_res_decl_for_inlining): Likewise.
8996 (walk_tree): Move language-specific constructs into...
8997 (cp_walk_subtrees): this new function.
8998 (copy_tree_r): Use language-independent constructs and hooks.
8999 (init_tree): Initialize tree inlining hooks.
9000 (remap_save_expr): Adjust prototype so that the declaration
9001 does not require the definition of splay_tree.
9002
6a4af81f
JDA
90032001-10-03 John David Anglin <dave@hiauly1.hia.nrc.ca>
9004
9005 * rtti.c (get_tinfo_decl): Call typeinfo_in_lib_p with the type used
9006 to build the declaration instead of the declaration itself.
9007
0caee1c6
JM
90082001-10-02 Jason Merrill <jason_merrill@redhat.com>
9009
48c8b0be
JM
9010 * decl2.c (cxx_decode_option): Add 'else'.
9011
0caee1c6
JM
9012 * spew.c (end_input): No longer static.
9013 * cp-tree.h: Declare it.
9014 * parse.y (datadef): Add "error END_OF_SAVED_INPUT" expansion.
9015
80a497e4
JM
90162001-10-02 Joseph S. Myers <jsm28@cam.ac.uk>
9017
9018 * call.c (build_over_call), typeck.c (build_function_call_real):
9019 Pass type attributes to check_function_format rather than name or
9020 assembler name. Don't require there to be a name or assembler
9021 name to check formats.
9022
6431177a
JM
90232001-10-02 Joseph S. Myers <jsm28@cam.ac.uk>
9024
9025 * decl.c (init_decl_processing): Don't call
9026 init_function_format_info. Initialize lang_attribute_table
9027 earlier.
9028 (builtin_function): Call decl_attributes.
9029 (insert_default_attributes): New.
9030
55b3d665
JM
90312001-10-01 Jason Merrill <jason_merrill@redhat.com>
9032
9033 * decl.c (grokdeclarator): Copy array typedef handling from C
9034 frontend.
9035
9036 * decl.c (grokdeclarator): Copy too-large array handling from C
9037 frontend.
9038
9f57ca19
AO
90392001-09-29 Alexandre Oliva <aoliva@redhat.com>
9040
9041 * config-lang.in (target_libs): Added target-gperf, so that we
9042 don't try to build it if C++ is disabled.
9043
749ced52
ZW
90442001-09-23 Zack Weinberg <zack@codesourcery.com>
9045
9046 * Make-lang.in (CXX_OBJS): Take out cp/errfn.o.
9047 (cp/errfn.o): Delete rule.
9048 (cp/error.o): Depend on flags.h.
9049 * errfn.c: Delete file.
9050 * cp-tree.h: Declare warn_deprecated. Remove definitions of
9051 TFF_NAMESPACE_SCOPE, TFF_CLASS_SCOPE, TFF_CHASE_NAMESPACE_ALIAS,
9052 and TFF_TEMPLATE_DEFAULT_ARGUMENTS. #define cp_error, cp_warning,
9053 cp_pedwarn, and cp_compiler_error to error, warning, pedwarn, and
9054 internal_error respectively. Make cp_deprecated into a macro.
9055 Don't define cp_printer typedef or declare cp_printers.
9056 * error.c: Include flags.h.
9057 Delete: struct tree_formatting_info, print_function_argument_list,
9058 print_declaration, print_expression, print_function_declaration,
9059 print_function_parameter, print_type_id, print_cv_qualifier_seq,
9060 print_type_specifier_seq, print_simple_type_specifier,
9061 print_elaborated_type_specifier, print_rest_of_abstract_declarator,
9062 print_parameter_declaration_clause, print_exception_specification,
9063 print_nested_name_specifier, and definition of cp_printers.
9064 (locate_error): New function.
9065 (cp_error_at, cp_warning_at, cp_pedwarn_at): Moved here and
9066 rewritten in terms of locate_error and diagnostic.c.
9067 (cp_tree_printer): Rename cp_printer; wire up to *_to_string
9068 instead of deleted print_* routines. Handle %C, %L, %O, %Q also.
9069 (init_error): Adjust to match.
9070
d2a6f3c0 90712001-09-22 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
bb9f8221
RK
9072
9073 * Make-lang.in (CXX_C_OBJS): Add attribs.o.
9074
67231816
RH
90752001-09-21 Richard Henderson <rth@redhat.com>
9076
9077 * class.c (set_vindex): Mind TARGET_VTABLE_USES_DESCRIPTORS.
9078 (build_vtbl_initializer): Likewise.
9079 (build_vfn_ref): New.
9080 * cp-tree.h: Declare it.
9081 * call.c (build_over_call): Use it.
9082 * decl2.c (mark_vtable_entries): Mark FDESC_EXPR.
9083 * typeck.c (get_member_function_from_ptrfunc): Mind descriptors.
9084
d2a6f3c0 90852001-09-21 J"orn Rennecke <amylaar@redhat.com>
c9574c9f
R
9086
9087 * decl.c (grokdeclarator): Use C syntax for attr_flags declaration.
9088
91d231cb
JM
90892001-09-21 Joseph S. Myers <jsm28@cam.ac.uk>
9090
9091 Table-driven attributes.
9092 * decl.c: Rename DECL_MACHINE_ATTRIBUTES to DECL_ATTRIBUTES.
9093 * decl2.c (cplus_decl_attributes): Only take one attributes
9094 parameter.
9095 * cp-tree.c (cplus_decl_attributes): Update prototype.
9096 * class.c (finish_struct), decl.c (start_decl, start_function),
9097 decl2.c (grokfield), friend.c (do_friend), parse.y
9098 (parse_bitfield): Update calls to cplus_decl_attributes.
9099 * decl.c (grokdeclarator): Take a pointer to a single ordinary
9100 attribute list.
9101 * decl.h (grokdeclarator): Update prototype.
9102 * decl2.c (grokfield): Take a single ordinary attribute list.
9103 * friend.c (do_friend): Likewise.
9104 * decl.c (shadow_tag, groktypename, start_decl,
9105 start_handler_parms, grokdeclarator, grokparms, start_function,
9106 start_method), decl2.c (grokfield, grokbitfield, grokoptypename),
9107 parse.y (parse_field, parse_bitfield, component_decl_1), pt.c
9108 (process_template_parm, do_decl_instantiation): Pass single
9109 ordinary attribute lists around.
9110 * decl.c (grokdeclarator): Correct handling of nested attributes.
9111 Revert the patch
9112 1998-10-18 Jason Merrill <jason@yorick.cygnus.com>
9113 * decl.c (grokdeclarator): Embedded attrs bind to the right,
9114 not the left.
9115 .
9116 * cp-tree.h (cp_valid_lang_attribute): Remove declaration
9117 (cp_attribute_table): Declare.
9118 * decl.c (valid_lang_attribute): Don't define.
9119 (lang_attribute_table): Define.
9120 (init_decl_processing): Initialize lang_attribute_table instead of
9121 valid_lang_attribute.
9122 * tree.c (cp_valid_lang_attribute): Remove.
9123 (handle_java_interface_attribute, handle_com_interface_attribute,
9124 handle_init_priority_attribute): New functions.
9125 (cp_attribute_table): New array.
9126 * decl2.c (import_export_class): Don't use
9127 targetm.valid_type_attribute.
9128
a1bda5f1
GDR
91292001-09-15 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
9130
e6b9638b
JM
9131 * Make-lang.in (cp/error.o): Depend on real.h
9132 * error.c: #include "real.h"
a1bda5f1 9133
cb6edbcb
KG
91342001-09-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9135
9136 * mangle.c (mangle_conv_op_name_for_type): Use concat in lieu of
9137 xmalloc/strcpy/strcat.
9138
83182544
KG
91392001-09-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9140
9141 * decl.c (warn_extern_redeclared_static, cp_make_fname_decl):
9142 Const-ification.
9143 * pt.c (tsubst_decl): Likewise.
9144
40008eda
KG
91452001-09-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9146
9147 * decl2.c (lang_f_options): Const-ification.
9148 * lex.c (cplus_tree_code_name): Likewise.
9149 * spew.c (yyerror): Likewise.
9150
39e78d8b
NS
91512001-09-06 Nathan Sidwell <nathan@codesourcery.com>
9152
9153 PR c++/3986
9154 * class.c (force_canonical_binfo_r): Check & move an indirect
9155 primary base first.
9156 (force_canonical_binfo): Check that it's not already
9157 canonical.
9158 (mark_primary_virtual_base): Remove BINFO parameter.
9159 (mark_primary_bases): Adjust, set BINFO_LOST_PRIMARY_P here.
9160
6d0a3f67
NS
91612001-09-06 Nathan Sidwell <nathan@codesourcery.com>
9162
9163 Remove TYPE_NONCOPIED_PARTS.
9164 * cp-tree.h (CLASSTYPE_INLINE_FRIENDS): Map onto
9165 CLASSTYPE_PURE_VIRTUALS.
9166 (TYPE_RAISES_EXCEPTIONS): Map onto TYPE_BINFO.
9167 * class.c (duplicate_tag_error): Remove TYPE_NONCOPIED_PARTS.
72a08131 9168 (layout_class_type): Don't call fixup_inline_methods here ...
6d0a3f67
NS
9169 (finish_struct_1): ... call it here.
9170
4f8e1232
MM
91712001-09-04 Mark Mitchell <mark@codesourcery.com>
9172
9173 * decl.c (duplicate_decls): Remove code deadling with
9174 DECL_SAVED_INSNS.
9175 * decl2.c (finish_file): Likewise.
9176 * pt.c (instantiate_decl): Likewise.
9177 * semantics.c (expand_body): Don't defer local functions if
9178 they wouldn't be deferred for some other reason. Don't
9179 generate RTL for functions that will not be emitted.
9180 (genrtl_start_function): Remove code deadling with
9181 DECL_SAVED_INSNS.
9182 (genrtl_finish_function): Likewise.
9183
da86f08f
NS
91842001-09-04 Nathan Sidwell <nathan@codesourcery.com>
9185
9186 PR c++/4203
9187 * call.c (build_over_call): Do not optimize any empty base
9188 construction.
9189
38066e83
KL
91902001-08-31 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
9191
9192 * error.c (dump_template_decl): Output template parameters
9193 together with their specifiers.
9194 Output `class' prefix for template template parameter.
9195 (dump_decl): Fix formatting.
9196
598e9ba5 91972001-08-30 Kurt Garloff <garloff@suse.de>
749ced52 9198
598e9ba5
KG
9199 * optimize.c (inlinable_function_p): Allow only smaller single
9200 functions. Halve inline limit after reaching recursive limit.
749ced52 9201
f232e4a5
JR
92022001-08-30 Joern Rennecke <amylaar@redhat.com>
9203 Jason Merrill <jason_merrill@redhat.com>
9204
9205 * class.c (build_vtable_entry_ref): Subtract in char*, not
9206 ptrdiff_t.
9207
0213a355
JM
92082001-08-23 Jason Merrill <jason_merrill@redhat.com>
9209
9210 * tree.c (cp_build_qualified_type_real): Use get_qualified_type.
9211 (build_cplus_array_type): Use cp_build_qualified_type, not
9212 TYPE_MAIN_VARIANT, to get an unqualified version.
9213
9214 * decl2.c (grok_alignof): Lose.
9215 (build_expr_from_tree): Use expr_sizeof and c_alignof_expr.
9216 * typeck.c (c_alignof): Lose.
9217 * semantics.c (finish_sizeof, finish_alignof): New.
9218 * parse.y: Use them.
9219 * cp-tree.h: Declare them.
9220
fd10dd09
JM
92212001-08-22 Jason Merrill <jason_merrill@redhat.com>
9222
9223 * pt.c (tsubst_expr): Hand off to the TREE_CHAIN of a statement.
9224 Don't loop in COMPOUND_STMT, FOR_STMT or TRY_BLOCK.
9225 * tree.c (cp_statement_code_p): A TAG_DEFN is a statement.
9226
baeb4732
JJ
92272001-08-19 Jakub Jelinek <jakub@redhat.com>
9228
9229 * typeck2.c (add_exception_specifier): Only require complete type if
9230 not in processing template declaration.
9231
1c0cc57e
KG
92322001-08-18 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
9233
9234 * decl.c: Cast argument to size_t, not HOST_WIDE_INT, in calls to
9235 GNU_xref_start_scope and GNU_xref_end_scope.
9236
9237 * tree.c (TYPE_HASH): Moved to ../tree.h.
9238
9a52d09b
MM
92392001-08-16 Mark Mitchell <mark@codesourcery.com>
9240
9241 * cvt.c (convert_to_void): Preserve TREE_SIDE_EFFECTS
9242 on COMPOUND_EXPRs.
9243
b5d1cbd2
RH
92442001-08-14 Richard Henderson <rth@redhat.com>
9245
9246 * class.c, cp-tree.h (build_vfn_ref): Remove.
9247 * call.c, rtti.c: Replace all refernces with build_vtbl_ref.
9248
63d6f87a
MM
92492001-08-13 Mark Mitchell <mark@codesourcery.com>
9250
9251 * call.c (build_over_call): Mark COMPOUND_EXPRs generated for
9252 empty class assignment as having side-effects to avoid
9253 spurious warnings.
9254
e78d8e51
ZW
92552001-08-13 Zack Weinberg <zackw@panix.com>
9256
9257 * Make-lang.in (cp/except.o): Add libfuncs.h to dependencies.
9258 * except.c: Include libfuncs.h.
9259
a60af04a
GDR
92602001-08-11 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
9261
9262 * decl.c (grokdeclarator): Clarify diagnostic message.
9263
3605b283
KL
92642001-08-13 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
9265
9266 * decl2.c (do_nonmember_using_decl): Replace using directive
9267 with using declaration in the error message.
9268
4d5f3fbd
KL
92692001-08-11 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
9270
9271 * pt.c (maybe_fold_nontype_arg): Use TREE_TYPE of ARG as the
9272 criterion to avoid rebuilding expression tree instead of
9273 processing_template_decl.
9274
07b2f2fd
JM
92752001-08-07 Jason Merrill <jason_merrill@redhat.com>
9276
9277 Support named return value optimization for inlines, too.
9278 * decl.c (finish_function): Nullify returns here.
9279 * semantics.c (genrtl_start_function): Not here.
9280 (cp_expand_stmt): Don't mess with CLEANUP_STMTs.
9281 (nullify_returns_r): No longer static. Just clear RETURN_EXPR.
9282 Also nullify the CLEANUP_STMT for the nrv.
9283 * cp-tree.h: Declare it.
9284 * optimize.c (declare_return_variable): Replace the nrv with the
9285 return variable.
9286 * typeck.c (check_return_expr): Be more flexible on alignment check.
9287 Ignore cv-quals when checking for a matching type.
9288
2cc07db4
RH
92892001-08-09 Richard Henderson <rth@redhat.com>
9290
9291 * decl2.c (finish_objects): Use target hooks instead of
9292 assemble_constructor and assemble_destructor.
9293
0ca179b2
JDA
92942001-08-08 John David Anglin <dave@hiauly1.hia.nrc.ca>
9295
9296 * g++spec.c (lang_specific_driver): Quote argument after `-Xlinker'.
9297
0830ae44
NS
92982001-08-07 Nathan Sidwell <nathan@codesourcery.com>
9299
9300 PR c++/3820
9301 Stop using TYPE_NONCOPIED_PARTS.
9302 * call.c (build_over_call): Be careful when copy constructing
9303 or assigning to an empty class.
9304 * class.c (check_bases_and_members): It has a
9305 COMPLEX_ASSIGN_REF if it has a vptr.
9306 (layout_class_type): Don't add empty class padding to
9307 TYPE_NONCOPIED_PARTS.
9308 (finish_struct_1): Don't add the VFIELD either.
9309 * cp-tree.h (TYPE_HAS_TRIVIAL_INIT_REF): Mention _copy_
9310 initialization.
9311
59a13e0f
JM
93122001-08-07 Jason Merrill <jason_merrill@redhat.com>
9313
9314 * tree.c (walk_tree): Walk siblings even if !walk_subtrees.
9315
47907859
RH
93162001-08-06 Richard Henderson <rth@redhat.com>
9317
9318 * decl2.c (finish_objects): Pass a symbol_ref and priority to
9319 assemble_{constructor,destructor}. Remove priority handling.
9320
eac69b8a
GDR
93212001-08-05 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
9322
9323 Don't allow template-id in using-declaration.
9324 * decl2.c (validate_nonmember_using_decl): Handle template-ids.
9325 (do_class_using_decl): Likewise.
9326
ef6e958a
NB
93272001-08-04 Neil Booth <neil@cat.daikokuya.demon.co.uk>
9328
9329 * cp/spew.c (read_token): No need to pop buffers.
9330
dff94ad7
SS
93312001-08-02 Stan Shebs <shebs@apple.com>
9332
9333 * cp-tree.h (FNADDR_FROM_VTABLE_ENTRY): Remove, no longer used.
9334 (fnaddr_from_vtable_entry): Remove decl.
9335 * method.c (use_thunk): Update comment.
9336
026c3f13
AC
93372001-08-01 Andrew Cagney <ac131313@redhat.com>
9338
9339 * repo.c (get_base_filename): Change return value to const char
9340 pointer.
9341
1dbb6023
NS
93422001-08-02 Nathan Sidwell <nathan@codesourcery.com>
9343
9344 Kill -fhonor-std.
9345 * NEWS: Document.
9346 * cp-tree.h (flag_honor_std): Remove.
9347 (CPTI_FAKE_STD): Remove.
9348 (std_node): Remove comment about it being NULL.
9349 (fake_std_node): Remove.
9350 * decl.c (in_fake_std): Remove.
9351 (walk_namespaces_r): Remove fake_std_node check.
9352 (push_namespace): Remove in_fake_std code.
9353 (pop_namespace): Likewise.
9354 (lookup_name_real): Remove fake_std_node check.
9355 (init_decl_processing): Always create std_node. Always add
9356 std:: things there.
9357 (builtin_function): Always put non '_' fns in std.
9358 * decl2.c (flag_honor_std): Remove.
9359 (lang_f_options): Remove honor-std.
9360 (unsupported_options): Add honor-std.
9361 (set_decl_namespace): Remove fake_std_node check.
9362 (validate_nonmember_using_decl): Likewise.
9363 (do_using_directive): Likewise.
9364 (handle_class_head): Likewise.
9365 * dump.c (cp_dump_tree): Likewise.
9366 * except.c (init_exception_processing): Adjust.
9367 * init.c (build_member_call): Remove fake_std_node check.
9368 (build_offset_ref): Likewise.
9369 * lang-options.h: Remove -fhonor-std, -fno-honor-std.
9370 * rtti.c (init_rtti_processing): Adjust.
9371
6ad7895a
APB
93722001-07-31 Alexandre Petit-Bianco <apbianco@redhat.com>
9373
9374 * tree.c (cp_tree_equal): WITH_CLEANUP_EXPR node to use its second
9375 operand while calling cp_tree_equal.
9376
befe7c61
NS
93772001-07-31 Nathan Sidwell <nathan@codesourcery.com>
9378
9379 The 3.0 ABI no longer has vbase pointer fields.
9380 * cp-tree.h (VBASE_NAME, VBASE_NAME_FORMAT, VBASE_NAME_P,
9381 FORMAT_VBASE_NAME): Remove.
9382 * method.c (do_build_copy_constructor): Adjust.
9383 (do_build_assign_ref): Adjust.
9384 * search.c (lookup_field_r): Adjust.
9385 * typeck.c (build_component_ref): Adjust.
9386
9387 The 3.0 ABI always has a vtable pointer at the start of every
9388 polymorphic class.
9389 * rtti.c (build_headof_sub): Remove.
9390 (build_headof): Adjust.
9391 (get_tinfo_decl_dynamic): No need to check flag_rtti
9392 here. Adjust.
9393 (create_real_tinfo_var): Explain why we need a hidden name.
9394
20dde49d
NS
93952001-07-31 Nathan Sidwell <nathan@codesourcery.com>
9396
9397 PR c++/3631
9398 * class.c (update_vtable_entry_for_fn): The fixed adjustment
9399 of a virtual thunk should be from declaring base.
9400
b7ad2f8b
NS
94012001-07-31 Nathan Sidwell <nathan@codesourcery.com>
9402
9403 * class.c (dfs_ctor_vtable_bases_queue_p): Always walk into
9404 the shared virtual base, so preserving inheritance graph order.
9405
57cb6d52
AJ
94062001-07-30 Andreas Jaeger <aj@suse.de>
9407
749ced52 9408 * decl2.c: Remove unused var global_temp_name_counter.
57cb6d52 9409
594280a3
RH
94102001-07-28 Richard Henderson <rth@redhat.com>
9411
9412 * method.c (pending_inlines): Remove.
9413
0ab142b0
NS
94142001-07-27 Nathan Sidwell <nathan@codesourcery.com>
9415
9416 * class.c (mark_primary_virtual_base): Don't adjust base
9417 offsets here.
9418 (dfs_unshared_virtual_bases): Adjust them here.
9419 (mark_primary_bases): Explain why we adjust at the end.
9420
d60d223b
NS
94212001-07-27 Nathan Sidwell <nathan@codesourcery.com>
9422
9423 * class.c (finish_struct_1): When copying the primary base's
9424 VFIELD, make sure we find it is at offset zero.
9425
db3ef87b
KL
94262001-07-26 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
9427
9428 * pt.c (tsubst_template_parms): Call maybe_fold_nontype_arg and
9429 tsubst_expr for default template arguments.
9430
312b7c9d
NS
94312001-07-26 Nathan Sidwell <nathan@codesourcery.com>
9432
d60d223b 9433 PR c++/3621
312b7c9d 9434 * spew.c (yylex): Only copy the token's lineno, if it is
838dfd8a 9435 nonzero.
312b7c9d 9436
648c2206
NS
94372001-07-26 Nathan Sidwell <nathan@codesourcery.com>
9438
9439 PR c++/3624
9440 * call.c (resolve_args): Simplify, call
9441 convert_from_reference.
9442 (build_new_op): Resolve and convert from reference ARG1
9443 earlier. Adjust ARG2 & ARG3 resolve and conversion.
9444
969fd501
NS
94452001-07-26 Nathan Sidwell <nathan@codesourcery.com>
9446
9447 * decl.c (last_function_parm_tags): Remove.
9448 (current_function_parm_tags): Remove.
9449 (init_decl_processing): Adjust.
9450 (start_function): Adjust.
9451 (store_parm_decls): Adjust.
9452
9453 PR c++/3152
9454 * decl.c (grokdeclarator): Detect when a function typedef is
9455 declaring a function, and create last_function_parms correctly.
9456
08ac397c 94572001-07-25 Jason Merrill <jason_merrill@redhat.com>
749ced52 9458
08ac397c
JM
9459 * call.c (joust): Only prefer a non-builtin candidate to a builtin
9460 one if they have the same signature.
9461
9462 * cvt.c (build_up_reference): Take DECL parm. Check TREE_STATIC on
9463 it rather than toplevel_bindings_p. Give it a mangled name if static.
9464 (convert_to_reference): Adjust.
9465 * decl2.c (get_temp_name): Lose.
9466 * mangle.c (mangle_ref_init_variable): New fn.
9467 (mangle_guard_variable): Strip the ref-init header.
9468 * cp-tree.h: Adjust.
9469 * decl.c (cp_finish_decl): Add the DECL_STMT after processing the
9470 initializer.
9471 (grok_reference_init): Always use DECL_INITIAL.
9472
40260429
NS
94732001-07-25 Nathan Sidwell <nathan@codesourcery.com>
9474
9475 PR c++/3416
9476 * call.c (build_conditional_expr): Recheck args after
9477 conversions.
9478 * cp-tree.h (build_conditional_expr): Move to correct file.
9479 * typeck.c (decay_conversion): Diagnose any unknown types
9480 reaching here.
9481 (build_binary_op): Don't do initial decay or default
9482 conversions on overloaded functions.
9483 (build_static_cast): Don't do a decay conversion here.
9484
ab085207
NS
94852001-07-25 Nathan Sidwell <nathan@codesourcery.com>
9486
9487 PR c++/3543
9488 * typeck.c (condition_conversion): Resolve an OFFSET_REF.
9489 * expr.c (cplus_expand_expr): An OFFSET_REF should never get here.
9490
0abe00c5
NS
94912001-07-25 Nathan Sidwell <nathan@codesourcery.com>
9492
9493 * class.c (build_vtbl_or_vbase_field): Remove, move into ...
9494 (create_vtbl_ptr): ... here.
9495
90b1ca2f
NS
94962001-07-25 Nathan Sidwell <nathan@codesourcery.com>
9497
9498 * class.c (build_vbase_offset_vbtl_entries): Look for
9499 non-primary base of which we are a sub vtable.
9500
cfe5dc31
PE
95012001-07-24 Phil Edwards <pme@sources.redhat.com>
9502
9503 * semantics.c (finish_this_expr): Remove unused code.
9504
7f54a851
NS
95052001-07-24 Nathan Sidwell <nathan@codesourcery.com>
9506
9507 Simplify rtti, now we've only one ABI.
9508 * cp-tree.h (cp_tree_index): Remove CPTI_TINFO_DECL_ID,
9509 CPTI_TINFO_VAR_ID.
9510 (tinfo_decl_id, tinfo_var_id): Remove.
9511 (get_typeid_1): Remove.
9512 * rtti.c
9513 (init_rtti_processing): Remove tinfo_decl_id & tinfo_var_id.
9514 (typeid_ok_p): New function.
9515 (build_type_id): Call typeid_ok_p. Don't call tinfo_from_decl.
9516 (get_tinfo_decl): Remove old abi documentation.
9517 (tinfo_from_decl): Remove.
9518 (get_type_id): Call typeid_ok_p. Absorb get_typeid_1.
9519 (get_typeid_1): Remove.
9520 (get_base_offset): Remove.
9521 (synthesize_tinfo_var): Absorb get_base_offset.
9522 (create_real_tinfo_var): Don't use tinfo_decl_id.
9523
18fee3ee
GS
95242001-07-23 Graham Stott <grahams@redhat.com>
9525
d30d6e7a 9526 * cp/class.c (type_requires_array_cookie): Fix use of uninitialized
18fee3ee
GS
9527 variable has_two_argument_delete_p.
9528
c4372ef4
NS
95292001-07-21 Nathan Sidwell <nathan@codesourcery.com>
9530
9531 Remove flag_vtable_thunk. It is always on for the 3.0 ABI.
9532 * cp-tree.h (CPTI_DELTA2_IDENTIFIER): Remove.
9533 (CPTI_INDEX_IDENTIFIER): Remove.
9534 (CPT_PFN_OR_DELTA2_IDENTIFIER): Remove.
9535 (delta2_identifier): Remove.
9536 (index_identifier): Remove.
9537 (pfn_or_delta2_identifier): Remove.
9538 (flag_vtable_thunks): Remove.
9539 (VTABLE_DELTA2_NAME): Remove.
9540 (VTABLE_INDEX_NAME): Remove.
9541 (FNADDR_FROM_VTABLE_ENTRY): Adjust.
9542 (vfunc_ptr_type_node): Adjust.
9543 (VTABLE_NAME_PREFIX): Adjust.
9544 (build_vfn_ref): Lose first parameter.
9545 (fixup_all_virtual_upcast_offsets): Remove.
9546 * decl.c (initialize_predefined_identifiers): Remove
9547 delta2_identifier, index_identifier, pfn_or_delta2_identifier.
9548 (init_decl_processing): Remove no-vtable-thunk code.
9549 * decl2.c (flag_vtable_thunks): Remove.
9550 (mark_vtable_entries): Remove no-vtable-thunk code.
9551 * error.c (dump_decl): Remove no-vtable-thunk code.
9552 (dump_expr): Adjust ptr to member function code.
9553 * init.c (initialize_vtable_ptrs): Remove no-vtable-thunk
9554 code.
9555 * rtti.c (build_headof): Remove no-vtable-thunk code.
9556 (get_tinfo_decl_dynamic): Adjust build_vfn_ref call.
9557 * search.c (get_base_distance): Remove expand_upcast_fixups case.
9558 (virtual_context) Remove.
9559 (expand_upcast_fixups): Remove.
9560 (fixup_virtual_upcast_offsets): Remove.
9561 (fixup_all_virtual_upcast_offsets): Remove.
9562 * typeck.c (get_member_function_from_ptrfunc): Remove
9563 no-vtable-thunk code.
9564 * call.c (build_over_call): Adjust call to build_vfn_ref.
9565 * class.c (build_vfn_ref): Lose first parameter. Remove
9566 no-vtable-thunk code.
9567 (build_rtti_vtbl_entries): Remove no-vtable-thunk code.
9568 (build_vtable_entry): Remove no-vtable-thunk code.
9569
3461fba7
NS
95702001-07-20 Nathan Sidwell <nathan@codesourcery.com>
9571
9572 Remove old-abi remnants. Remove comments about old abi
838dfd8a 9573 behavior. Remove references to 'new-abi' in comments.
3461fba7
NS
9574 * cp-tree.h: Adjust comments.
9575 (vbase_offsets_in_vtable_p): Delete.
9576 (vcall_offsets_in_vtable_p): Delete.
9577 (vptrs_present_everywhere_p): Delete.
9578 (all_overridden_vfuns_in_vtables_p): Delete.
9579 (merge_primary_and_secondary_vtables_p): Delete.
9580 (TYPE_CONTAINS_VPTR_P): Adjust.
9581 (VTT_NAME_PREFIX): Remove.
9582 (CTOR_VTBL_NAME_PREFIX): Remove.
9583 (init_vbase_pointers): Remove.
9584 * class.c: Adjust coments.
9585 (build_vbase_pointer_fields): Delete.
9586 (build_vbase_pointer): Remove old-abi code.
9587 (build_secondary_vtable): Likewise.
9588 (modify_all_vtables): Likewise.
9589 (create_vtable_ptr): Likewise.
9590 (layout_class_type): Likewise.
9591 (finish_struct_1): Likewise.
9592 (finish_vtbls): Likewise.
9593 (dfs_finish_vtbls): Delete.
9594 (build_vbase_offset_vtbl_entries): Remove old-abi code.
9595 * cvt.c: Adjust comments.
9596 * decl.c: Adjust comments.
9597 * decl2.c: Adjust comments.
9598 * init.c: Adjust comments.
9599 (construct_virtual_bases): Remove old-abi code.
9600 * lang-specs.h: Remove -fno-new-abi.
9601 * mangle.c: Adjust comments.
9602 * rtti.c: Adjust comments.
9603 (get_base_offset): Remove old-abi-code.
9604 * search.c: Adjust comments.
9605 (dfs_init_vbase_pointers): Remove.
9606 (dfs_vtable_path_unmark): Remove.
9607 (init_vbase_pointers): Remove.
9608 * semantics.c: Adjust comments.
9609 (emit_associated_thunks): Remove old-abi code.
9610 * typeck.c: Adjust comments.
9611
1c432a87
DB
96122001-07-20 Daniel Berlin <dan@cgsoftware.com>
9613
9614 * Make-lang.in (cp/optimize.o): Depend on $(PARAMS_H), not
9615 params.h.
9616
b7076960
MM
96172001-07-19 Mark Mitchell <mark@codesourcery.com>
9618
9619 * class.c (finish_struct_anon): Forbid nested classes.
9620
2b85879e
NB
96212001-07-19 Neil Booth <neil@daikokuya.demon.co.uk>
9622
9623 * decl2.c: Don't include dwarfout.h and dwarf2out.h.
9624 * optimize.c: Include debug.h.
9625 (maybe_clone_body): Use debug hook.
9626 * semantics.c: Include debug.h.
9627 (expand_body): Use debug hook.
9628
c60e94a7
NB
96292001-07-19 Neil Booth <neil@daikokuya.demon.co.uk>
9630
9631 * spew.c (read_token, yyerror): Remove CPP_INT, CPP_FLOAT cases.
9632
dbc957f1
MM
96332001-07-18 Mark Mitchell <mark@codesourcery.com>
9634
9635 * class.c (type_requires_array_cookie): New function.
9636 (check_methods): Don't try to figure out whether the type needs a
9637 cookie here.
9638 (check_bases_and_members): Set TYPE_VEC_NEW_USES_COOKIE here.
9639 * cp-tree.h (TYPE_VEC_DELETE_TAKES_SIZE): Remove.
9640 (TYPE_VEC_NEW_USES_COOKIE): Reimplement.
9641 * pt.c (instantiate_class_template): Don't set
9642 TYPE_VEC_DELETE_TAKES_SIZE.
9643 * NEWS: Document ABI changes from GCC 3.0.
57cb6d52 9644
7ba0b0f7 96452001-07-18 Xavier Delacour <xavier@fmaudio.net>,
749ced52 9646 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
7ba0b0f7
XD
9647
9648 * NEWS (Changes in GCC 3.0): Fix typo.
9649
59387d2e
JM
96502001-07-13 Joseph S. Myers <jsm28@cam.ac.uk>
9651
9652 * decl2.c (cplus_decl_attributes): Take a pointer to the node to
9653 which attributes are to be attached, and a flags argument. Update
9654 call to decl_attributes.
9655 (grokfield): Update call to decl_attributes.
9656 * class.c (finish_struct): Update call to cplus_decl_attributes.
9657 * cp-tree.h (cplus_decl_attributes): Update prototype.
9658 * decl.c (start_decl, grokdeclarator, start_function): Update
9659 calls to decl_attributes and cplus_decl_attributes.
9660 * friend.c (do_friend): Update call to cplus_decl_attributes.
9661 * parse.y (parse_bitfield): Update call to cplus_decl_attributes.
9662
7ed47c04
MM
96632001-07-12 Mark Mitchell <mark@codesourcery.com>
9664
9665 * decl.c (make_rtl_for_nonlocal_decl): Set DECL_C_HARD_REGISTER
9666 for `register' variables with an asm-specification.
9667
40b18c0a
MM
96682001-07-11 Mark Mitchell <mark@codesourcery.com>
9669
9670 * semantics.c (finish_asm_stmt): Mark the output operands
9671 to an asm addressable, if necessary.
9672
517c3b80
BE
96732001-07-11 Ben Elliston <bje@redhat.com>
9674
219670f1
BE
9675 * Revert this change -- there is a subtle bug.
9676
517c3b80
BE
9677 PR c++/80
9678 * decl.c (finish_enum): New "attributes" argument; pass it to
9679 cplus_decl_attributes. Use a narrower type if the enum is packed.
9680 * cp-tree.h (finish_enum): Adjust prototype.
9681 * parse.y (enum_head): New non-terminal.
9682 (structsp): Use it. Enums now may be preceded or followed by
9683 optional attributes -- pass their chained tree to finish_enum().
9684 * pt.c (tsubst_enum): Pass NULL_TREE for the new argument.
9685
2ba9c47e
MM
96862001-07-10 Mark Mitchell <mark@codesourcery.com>
9687
9688 * pt.c (tsubst_decl): Set DECL_CONTEXT for namespace-scope
9689 variables.
9690
35241192
JM
96912001-07-10 Jason Merrill <jason_merrill@redhat.com>
9692
9693 * semantics.c (cp_expand_stmt): Fix for null
9694 current_function_return_value.
9695
07167a18
JM
96962001-07-10 Jan van Male <jan.vanmale@fenk.wau.nl>
9697
9698 * call.c (build_op_delete_call): Initialize fn.
9699 (convert_like_real): Delete conditional.
9700 (joust): Initialize *w and *l.
9701 * class.c: Add prototype for binfo_ctor_vtable.
9702 (get_primary_binfo): Initialize result.
9703 * init.c (build_java_class_ref): Initialize name.
ae818d3b 9704
35241192
JM
97052001-07-09 Erik Rozendaal <dlr@acm.org>
9706
ae818d3b
ER
9707 * typeck.c (unary_complex_lvalue): Do not duplicate the
9708 argument to modify, pre-, or post-increment when used as an
9709 lvalue and when the argument has side-effects.
9710
12a68f1f
JM
97112001-07-08 Joseph S. Myers <jsm28@cam.ac.uk>
9712
9713 * decl.c (start_decl): Don't call SET_DEFAULT_DECL_ATTRIBUTES.
9714 (start_function): Don't call SET_DEFAULT_DECL_ATTRIBUTES. Call
9715 cplus_decl_attributes even if attrs is NULL.
9716 * friend.c (do_friend): Don't call SET_DEFAULT_DECL_ATTRIBUTES.
9717
f7a4cec0
JM
97182001-07-08 Joseph S. Myers <jsm28@cam.ac.uk>
9719
9720 * decl.c (grokdeclarator), decl2.c (cplus_decl_attributes): Update
9721 calls to decl_attributes.
9722
c80106a4
IR
97232001-07-06 Ira Ruben <ira@apple.com>
9724
ae818d3b 9725 * cp-tree.def (TEMPLATE_DECL): Update comment. DECL_RESULT should
c80106a4
IR
9726 be DECL_TEMPLATE_RESULT.
9727
dac65501
KL
97282001-07-05 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
9729
9730 * cp-tree.h (copy_template_template_parm): Rename to ...
9731 (bind_template_template_parm): ... here.
9732 * tree.c (copy_template_template_parm): Rename to ...
9733 (bind_template_template_parm): ... here. Remove the case when
9734 NEWARGS is NULL_TREE.
9735 (copy_tree_r): Don't copy TEMPLATE_TEMPLATE_PARM and
9736 BOUND_TEMPLATE_TEMPLATE_PARM.
9737 * pt.c (lookup_template_class): Adjust.
9738
01f9e964
JM
97392001-07-05 Jason Merrill <jason_merrill@redhat.com>
9740
9741 * cvt.c (convert_lvalue): New fn.
9742 * cp-tree.h: Declare it.
9743 * method.c (do_build_assign_ref): Use it.
9744 (do_build_copy_constructor): Convert parm to base types
9745 before calling base constructors.
9746
9747 * typeck.c (check_return_expr): Check DECL_ALIGN instead of
9748 DECL_USER_ALIGN. Check flag_elide_constructors instead of
9749 optimize.
9750 * semantics.c (cp_expand_stmt): Don't destroy the named return value.
9751
6be77748
NS
97522001-07-02 Nathan Sidwell <nathan@codesourcery.com>
9753
9754 * optimize.c (optimize_inline_calls): New function, broken out
9755 of ...
9756 (optimize_function): ... here. Call it. Don't inline if it is
9757 a thunk.
9758 (dump_function): Print name of dump flag causing this dump.
9759 * semantics.c (expand_body): Move thunk inline check to
9760 optimize_function.
9761
8d8e52be
JM
97622001-06-29 Joseph S. Myers <jsm28@cam.ac.uk>
9763
9764 * typeck.c (COMP_TYPE_ATTRIBUTES): Don't define.
9765 (comptypes): Use target.comp_type_attributes.
9766
5a0db193
NS
97672001-06-29 Nathan Sidwell <nathan@codesourcery.com>
9768
9769 * cp-tree.h (flag_dump_class_layout): Remove unneeded declaration.
9770
46f018e1
GDR
97712001-06-28 Gabriel Dos Reis <gdr@merlin.codesourcery.com>
9772
9773 * error.c (lang_print_error_function): Add a `diagnostic_context *'
9774 parameter. Tweak.
9775
501990bb
NB
97762001-06-27 Neil Booth <neil@cat.daikokuya.demon.co.uk>
9777
9778 * decl2.c (import_export_class): Update.
9779
f68fc4db
GDR
97802001-06-26 Gabriel Dos Reis <gdr@codesourcery.com>
9781
9782 * error.c (init_error): Adjust settings.
9783
9596ddd6
GDR
97842001-06-26 Gabriel Dos Reis <gdr@codesourcery.com>
9785
9786 * error.c (init_error): Adjust settings.
9787
c93586fa
RS
97882001-06-19 Richard Sandiford <rsandifo@redhat.com>
9789
9790 * except.c (initialize_handler_parm): Expect __cxa_begin_catch to
9791 return pointers to data members by reference rather than by value.
9792
0d97bf4c
JM
97932001-06-18 Jason Merrill <jason_merrill@redhat.com>
9794
9795 Implement the Named Return Value optimization.
9796 * cp-tree.h (struct cp_language_function): Add x_return_value.
9797 (current_function_return_value): Now a macro.
9798 * decl.c: Don't define it.
9799 (define_label, finish_case_label): Don't clear it.
9800 (init_decl_processing): Don't register it with GC.
9801 * semantics.c (genrtl_finish_function): Don't check it for
9802 no_return_label. Copy the RTL from the return value to
9803 current_function_return_value and walk, calling...
9804 (nullify_returns_r): ...this new fn.
9805 * typeck.c (check_return_expr): Set current_function_return_value.
9806
13de7ec4
JM
98072001-06-15 Jason Merrill <jason_merrill@redhat.com>
9808
9809 * class.c (dfs_accumulate_vtbl_inits): Just point to the base we're
9810 sharing a ctor vtable with. Merge code for cases 1 and 2.
9811 (binfo_ctor_vtable): New fn.
9812 (build_vtt_inits, dfs_build_secondary_vptr_vtt_inits): Use it.
9813
3ea099f1
JM
98142001-06-14 Jason Merrill <jason_merrill@redhat.com>
9815
9816 * class.c (dfs_find_final_overrider): Fix logic.
9817
9818 * class.c (update_vtable_entry_for_fn): Uncomment optimization to use
9819 virtual thunk instead of non-virtual.
9820 (get_matching_virtual): Uncomment.
9821
9822 * pt.c (unify): Don't recurse between the POINTER_TYPE and the
9823 OFFSET_TYPE. If we're adding cv-quals, the extra ones would be on
9824 PARM, not ARG.
9825
87326ba8
NS
98262001-06-14 Nathan Sidwell <nathan@codesourcery.com>
9827
9828 * class.c (dfs_accumulate_vtbl_inits): For case 2 & 3, make sure
9829 we've not emerged from the hierarchy of RTTI_BINFO on reaching
9830 a non-virtual base.
9831
e065a36e
MM
98322001-06-13 Mark Mitchell <mark@codesourcery.com>
9833
9834 * NEWS: Update release number.
9835
623fe76a
NS
98362001-06-12 Nathan Sidwell <nathan@codesourcery.com>
9837
9838 PR c++/3130, c++/3131, c++/3132
9839 * cp-tree.h (BINFO_UNSHARED_MARKED): New #define.
9840 * class.c (force_canonical_binfo_r): Move
9841 BINFO_UNSHARED_MARKED, BINFO_LOST_PRIMARY_P. Don't move
9842 virtual bases unless they're primary and what they're primary
9843 too has been moved.
9844 (dfs_unshared_virtual_bases): Use BINFO_UNSHARED_MARKED. Cope
9845 with morally virtual bases. Duplicate BINFO_LOST_PRIMARY_P and
9846 BINFO_PRIMARY_BASE_OF. Clear BINFO_VTABLE for all but the most
9847 derived binfo.
9848 (mark_primary_bases): Use BINFO_UNSHARED_MARKED.
9849 (layout_nonempty_base_or_field): Add most derived type
9850 parameter. Adjust.
9851 (layout_empty_base): Likewise.
9852 (build_base_field): Likewise.
9853 (build_base_fields): Likewise.
9854 (propagate_binfo_offsets): Add most derived type
9855 parameter. Skip non canonical virtual bases too.
9856 (dfs_set_offset_for_unshared_vbases): Don't skip primary
9857 bases. Do skip canonical bases.
9858 (layout_virtual_bases): Adjust.
9859 (layout_class_type): Adjust.
9860 (dfs_get_primary_binfo): Build list of virtual primary base
9861 candidates.
9862 (get_primary_binfo): Check that the shared virtual primary
9863 base candidate was found first.
9864 (accumulate_vtbl_inits): Don't do anything for non-vptr
9865 containing binfos. For case 1 primary virtual bases, keep
9866 checking that we've not emerged from the hierarchy of RTTI_BINFO.
9867
7bdcf888
NS
98682001-06-12 Nathan Sidwell <nathan@codesourcery.com>
9869
9870 PR c++/3089
9871 * class.c (dfs_accumulate_vtbl_inits): Always walk down the
9872 hierarchy looking for primary bases for a ctor
9873 vtable. Recursively call oneself, if we meet our primary via
9874 this route and haven't met it yet via inheritance graph order.
9875
25b5b465
MM
98762001-06-11 Mark Mitchell <mark@codesourcery.com>
9877
9878 * lang-options.h: Emit documentation for -fno-honor-std, not
9879 -fhonor-std.
9880
eb2d0614
AO
98812001-06-10 Alexandre Oliva <aoliva@redhat.com>
9882
9883 * typeck.c (get_member_function_from_ptrfunc) [vbit_in_delta]:
9884 Don't clobber delta.
9885 (expand_ptrmemfunc_cst) [ptrmemfunc_vbit_in_delta]: Adjust pfn.
9886
2a2b2d43
GDR
98872001-06-10 Mark Mitchell <mark@codesourcery.com>
9888 Gabriel Dos Reis <gdr@codesourcery.com>
9889
9890 * Make-lang.in (cp/call.o): Depend on diagnostic.h
9891 (cp/typeck.o): Depend on diagnostic.h
9892 (cp/typeck2.o): Depend on diagnostic.h
07167a18 9893 (cp/repo.o): Depend on dignostic.h
2a2b2d43
GDR
9894 * typeck.c: #include diagnostic.h
9895 (convert_for_initialization): Remove extern declaration for
9896 warningcount and errorcount.
9897
9898 * call.c: #include diagnostic.h
9899 (convert_like_real): Remove extern declaration for warnincount and
07167a18 9900 errorcount.
2a2b2d43
GDR
9901
9902 * repo.c: #include diagnostic.h
9903 * typeck2.c: #include diagnostic.h
9904
06d5e633
NS
99052001-06-08 Nathan Sidwell <nathan@codesourcery.com>
9906
9907 * decl.c (duplicate_decls): Fix DECL_TEMPLATE_RESULT thinko
9908 in previous change.
9909
9ac1bd2e
NS
99102001-06-08 Nathan Sidwell <nathan@codesourcery.com>
9911
9912 PR c++/2929
9913 * friend.c (do_friend): Use push_decl_namespace for classes at
9914 namespace scope.
9915
85a9a0a2
NS
99162001-06-08 Nathan Sidwell <nathan@codesourcery.com>
9917 Jason Merrill <jason_merrill@redhat.com>
9918
9919 PR c++/3061
9920 * class.c (build_secondary_vtable): Use assert, rather than an error
9921 message.
9922 (dfs_fixup_binfo_vtbls): BINFO_VTABLE might be NULL.
9923 (dfs_accumulate_vtbl_inits): A lost primary virtual base may
9924 be between ORIG_BINFO and RTTI_BINFO, but neither of them.
9925 Don't set BINFO_VTABLE for a primary virtual base.
9926
daa8df65
MM
99272001-06-07 Mark Mitchell <mark@codesourcery.com>
9928
9929 * decl.c (duplicate_decls): Update source position information
9930 when a template function is defined.
9931
37344b9b
PE
99322001-06-07 Phil Edwards <pme@sources.redhat.com>
9933
9934 * lang-specs.h: Move -D_GNU_SOURCE to config/linux.h.
9935
fcebb2dd
NS
99362001-06-07 Nathan Sidwell <nathan@codesourcery.com>
9937
9938 PR c++/2914
9939 * decl.c (pushtag): Don't push into a complete type's scope.
9940
d0cd8b44
JM
99412001-06-06 Jason Merrill <jason_merrill@redhat.com>
9942
9943 * cp-tree.h (THUNK_GENERATE_WITH_VTABLE_P): Lose.
9944 (struct lang_decl_flags): Lose generate_with_vtable_p.
9945 (BV_GENERATE_THUNK_WITH_VTABLE_P): Lose.
9946 * class.c (copy_virtuals): Adjust.
9947 * decl2.c (mark_vtable_entries): Adjust.
9948 * method.c (make_thunk, build_vtable_entry): Adjust.
9949 * class.c (update_vtable_entry_for_fn): Only look as far as the
9950 first defining class.
07167a18 9951 (build_vtbl_initializer): Put nothing in the slot for a function only
d0cd8b44 9952 defined in a lost primary virtual base.
07167a18 9953 (add_vcall_offset_vtbl_entries_1): Use the same code for
d0cd8b44
JM
9954 the lost primary case and the normal case.
9955 (dfs_unshared_virtual_bases): Don't lose a non-virtual primary base.
9956 (get_vfield_offset, get_derived_offset): Lose.
9957 (dfs_find_final_overrider): Use look_for_overrides_here.
9958 (get_matching_virtual): New fn.
9959 * semantics.c (emit_associated_thunks): Check BV_USE_VCALL_INDEX_P,
9960 not BV_VCALL_INDEX.
9961 * search.c (look_for_overrides_here): Split out from...
9962 (look_for_overrides_r): Here.
9963
9964 * class.c (find_final_overrider): Return error_mark_node on error.
9965
9966 * decl2.c (key_method): #if 0 accidental change.
9967
acf97e0b
JDA
99682001-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
9969
9970 * call.c (convert_default_arg): Use INTEGRAL_TYPE_P.
9971 (build_over_call): Likewise.
9972 * decl.c (grokparms): Likewise.
9973 * pt.c (tsubst_decl): Likewise.
9974 * typeck.c (convert_arguments): Likewise.
9975
7e9abee9
MM
99762001-06-05 Mark Mitchell <mark@codesourcery.com>
9977
47ee8904
MM
9978 * semantics.c (begin_class_definition): Robustify.
9979
7e9abee9
MM
9980 * pt.c (instantiate_decl): Tell the repository code about the
9981 clones, not the cloned functions.
9982 * repo.c (repo_template_used): Explicitly instantiate the cloned
9983 function, not the clones.
9984
bea09693
NS
99852001-06-05 Nathan Sidwell <nathan@codesourcery.com>
9986
9987 * call.c (build_user_type_conversion_1): Set ICS_USER_FLAG and
9988 ICS_BAD_FLAG on created conversion.
9989 (compare_ics): Break out rank.
9990
8f7550ca
NS
99912001-06-05 Nathan Sidwell <nathan@codesourcery.com>
9992
9993 * decl.c (xref_tag): Remove extraneous %s on dependent name
9994 lookup warning.
9995
442e01b6
NS
99962001-06-05 Nathan Sidwell <nathan@codesourcery.com>
9997
9998 * class.c (layout_vtable_decl): Fix off by one error on
9999 build_index_type.
10000 (build_vtt): Likewise.
10001 (build_ctor_vtbl_group): Likewise.
10002
b7442fb5
NS
100032001-06-05 Nathan Sidwell <nathan@codesourcery.com>
10004
10005 * class.c (maybe_indent_hierarchy): New function.
10006 (dump_class_hierarchy_r): Add flags. Dump extra binfo
10007 information, if enabled. Use maybe_indent_hierarchy. Adjust
10008 output format.
10009 (dump_class_hierarchy): Adjust prototype. Adjust output format.
10010 (dump_array, dump_vtable, dump_vtt): New functions.
10011 (finish_struct_1): Adjust hierarchy dumping.
10012 (initialize_vtable): Call dump_vtable.
10013 (build_vtt): Call dump_vtt.
10014 (build_ctor_vtbl_group): Call dump_vtable.
10015 * decl2.c (flag_dump_class_layout): Remove.
10016 (cxx_decode_option): Remove dump translation unit
10017 and dump class hierarchy check. Call dump_switch_p.
10018 (finish_file): Adjust dumping.
10019 (dump.c): Only dump base classes if not TDF_SLIM.
10020 Only dump namespace members if not TDF_SLIM.
10021 * optimize.c (dump_function): New function.
10022 (optimize_function): Call dump_function.
10023 * semantics.c (expand_body): Use dump_enabled_p.
10024
e5410b32
NS
100252001-06-01 Nathan Sidwell <nathan@codesourcery.com>
10026
10027 PR g++/2936
10028 Part missed from first commit
10029 * decl2.c (finish_anon_union): Copy context.
10030
e97c9488
NS
100312001-05-30 Nathan Sidwell <nathan@codesourcery.com>
10032
10033 PR g++/2936
e97c9488
NS
10034 * optimize.c (remap_decl): Remap anonymous aggregate members too.
10035
87d9ac49
NS
100362001-05-26 Nathan Sidwell <nathan@codesourcery.com>
10037
10038 PR g++/2823
10039 * semantics.c (expand_body): Don't optimize thunks.
10040
88657302
RH
100412001-05-25 Sam TH <sam@uchicago.edu>
10042
10043 * cp-tree.h lex.h: Fix header include guards.
10044
100452001-05-25 Mark Mitchell <mark@codesourcery.com>
10841285
MM
10046
10047 * decl.c (init_decl_processing): Tweak.
10048
0b1161fc
MM
100492001-05-24 Mark Mitchell <mark@codesourcery.com>
10050
10051 * decl.c (duplicate_decls): Tidy.
10052 (init_decl_processing): Always set flag_no_builtin.
10053
6f56d925
NS
100542001-05-24 Nathan Sidwell <nathan@codesourcery.com>
10055
10056 PR c++/2184
10057 * decl2.c (do_local_using_decl): Push the decls, even in a
10058 template.
10059
39e0656d
MM
100602001-05-22 Mark Mitchell <mark@codesourcery.com>
10061
10062 * optimize.c (initialize_inlined_parameters): Don't set
10063 TREE_READONLY for a VAR_DECL taking the place of an inlined
10064 PARM_DECL.
10065
0401d499
JM
100662001-05-22 Jason Merrill <jason_merrill@redhat.com>
10067
10068 * class.c, cp-tree.h, rtti.c: Remove com_interface attribute support.
10069 * tree.c (cp_valid_lang_attribute): Warn about use of com_interface
10070 attribute.
10071
14fc3426
JM
100722001-05-22 Joseph S. Myers <jsm28@cam.ac.uk>
10073
10074 * parse.y: Refer to compound literals as such, not as
10075 constructor-expressions.
10076
3f41ffd8
MM
100772001-05-21 Mark Mitchell <mark@codesourcery.com>
10078
10079 * call.c (build_op_delete_call): Ignore exception-specifications
10080 when looking for matching delete operators.
10081 * init.c (build_new_1): Compute whether or not the allocation
10082 function used is a placement allocation function or not, and
10083 communicate this information to build_op_delete_call.
10084
1a6025b4
JM
100852001-05-21 Jason Merrill <jason_merrill@redhat.com>
10086
90ecce3e
JM
10087 * class.c (build_vtable_entry_ref): Lose vtbl parm. Fix for new abi.
10088 (build_vtbl_ref): Adjust.
10089 (dfs_accumulate_vtbl_inits): Set TREE_CONSTANT on the vtable address.
10090 * decl2.c (lang_f_options): Remove huge-objects, vtable-thunks.
10091 Re-add vtable-gc.
10092 (unsupported_options): Correspondingly.
10093
10094 * decl2.c (maybe_make_one_only): Check flag_weak, not
10095 supports_one_only().
10096
1a6025b4
JM
10097 * cp-tree.def (START_CATCH_STMT): Lose.
10098 * dump.c (cp_dump_tree): Don't dump it. Do dump HANDLER_PARMS.
10099 * tree.c (cp_statement_code_p): Don't case it.
10100 * semantics.c (cp_expand_stmt): Likewise.
10101 * cp-tree.h (START_CATCH_TYPE): Lose.
10102 (HANDLER_TYPE): New.
10103 * except.c (expand_start_catch_block): Don't start any blocks.
10104 Return the type.
10105 (expand_end_catch_block): Don't end any blocks.
10106 * parse.y (handler): Don't pass anything from finish_handler_parms
10107 to finish_handler.
10108 * pt.c (tsubst_expr): Likewise.
10109 * semantics.c (begin_handler): Call note_level_for_catch here.
10110 (finish_handler_parms): Don't return anything.
10111 (genrtl_catch_block, begin_catch_block): Lose.
10112 (genrtl_handler): Call expand_start_catch here.
10113
101142001-05-18 Jason Merrill <jason_merrill@redhat.com>
10115
10116 * class.c (build_vtable): Set DECL_ASSEMBLER_NAME for vtables here.
10117 (get_vtable_decl, build_vtt): Not here.
10118
d30a825a
NS
101192001-05-20 Nathan Sidwell <nathan@codesourcery.com>
10120
10121 PR c++/2781
10122 * optimize.c (update_cloned_parm): Copy addressability and other
10123 flags.
10124
3b82c249
KL
101252001-05-20 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
10126
10127 * pt.c (determine_specialization): Ignore artificial functions.
10128
2a967f3d
NB
101292001-05-20 Neil Booth <neil@daikokuya.demon.co.uk>
10130
10131 * cp-tree.h (struct lang_identifier, C_RID_YYCODE): Update.
10132 (C_RID_CODE): Remove.
10133 * lex.c (cxx_init_options): Call set_identifier_size. Update.
10134 (init_parse): Don't do it here.
10135
f99df08e
DN
101362001-05-18 Diego Novillo <dnovillo@redhat.com>
10137
10138 * decl2.c (finish_objects): Use the original SYMBOL_REF from the
10139 function declaration to avoid stripping the symbol's attributes.
10140
2b0cbc5d
NS
101412001-05-18 Nathan Sidwell <nathan@codesourcery.com>
10142
10143 * decl.c (pushdecl): Adjust error string.
10144 (xref_tag): Adjust friend class injection warning. Remove the
10145 inherited name from the class shadowed scope.
10146
e6855a2d
MM
101472001-05-17 Mark Mitchell <mark@codesourcery.com>
10148
10149 * except.c (cp_protect_cleanup_actions): New function.
07167a18 10150 (init_exception_processing): Don't set protect_cleanup_actions
e6855a2d
MM
10151 here. Do set lang_protect_cleanup_actions.
10152
cc469ee9
NS
101532001-05-16 Nathan Sidwell <nathan@codesourcery.com>
10154
10155 * spew.c (read_token): Call yyerror on all unexpected tokens.
10156
3f0a9b35
NS
101572001-05-16 Nathan Sidwell <nathan@codesourcery.com>
10158
10159 * init.c (member_init_ok_or_else): Take a tree rather than
10160 string for name.
10161 (expand_member_init): Adjust.
10162
8d0cb60d
NC
101632001-05-14 Nick Clifton <nickc@cambridge.redhat.com>
10164
10165 * decl.c (duplicate_decls): Suppress warning about duplicate
749ced52 10166 decls if the first decl is a friend.
8d0cb60d 10167
1f730ff7
ZW
101682001-05-12 Zack Weinberg <zackw@stanford.edu>
10169
10170 * except.c (choose_personality_routine): Export. Add
10171 explanatory comment. Take an enum languages, not a boolean.
10172 (initialize_handler_parm): Adjust to match.
10173 * cp-tree.h: Prototype choose_personality_routine.
10174 * lex.c (handle_pragma_java_exceptions): New function.
10175 (init_cp_pragma): Register #pragma GCC java_exceptions.
10176
90e0c410
NB
101772001-05-12 Neil Booth <neil@cat.daikokuya.demon.co.uk>
10178
10179 * method.c (build_mangled_C99_name): Remove unused prototype.
10180
cb7fdde2
AO
101812001-05-12 Alexandre Oliva <aoliva@redhat.com>
10182
10183 * cp-tree.h (ptrmemfunc_vbit_where_t): Declare type.
10184 * typeck.c (get_member_function_from_ptrfunc,
10185 build_ptrmemfunc, expand_ptrmemfunc_cst): Take
10186 TARGET_PTRMEMFUNC_VBIT_LOCATION into account.
18ae7f63
AO
10187
10188 Reverted Geoff Keating's 2001-05-03's patch.
10189
401deb20
IR
101902001-05-11 Ira Ruben <ira@apple.com>
10191
10192 * cp/cp-tree.h (C_EXP_ORIGINAL_CODE): Delete; declared in c-common.h.
10193
8e93d446
NB
101942001-05-11 Neil Booth <neil@daikokuya.demon.co.uk>
10195
10196 * cp-tree.h (finish_label_expr, lookup_label): Delete.
10197 * parse.y: Update for '&&'; don't issue warning here.
10198 * semantics.c (finish_label_expr): Delete.
10199
5cdba4ff
MM
102002001-05-07 Mark Mitchell <mark@codesourcery.com>
10201
10202 * splay-tree.h (splay_tree_max): New function.
10203 (splay_tree_min): Likewise.
10204
8e9eff6b
GK
102052001-05-03 Geoffrey Keating <geoffk@redhat.com>
10206
10207 * cp-tree.h (enum cp_tree_index): Add CPTI_PFN_VFLAG_IDENTIFIER.
10208 (pfn_vflag_identifier): Define.
10209 Update comment about layout of pointer functions.
10210 (build_ptrmemfunc1): Update prototype.
10211 (expand_ptrmemfunc_cst): Update prototype.
10212 * decl.c (initialize_predefined_identifiers): Initialize
10213 pfn_vflag_identifier.
10214 (build_ptrmemfunc_type): When FUNCTION_BOUNDARY < 16, add
10215 an extra field to the type.
07167a18 10216 * expr.c (cplus_expand_constant): Pass 'flag' between
8e9eff6b
GK
10217 expand_ptrmemfunc_cst and build_ptrmemfunc1.
10218 * typeck.c (get_member_function_from_ptrfunc): When
10219 FUNCTION_BOUNDARY < 16, look at additional field to determine
10220 if a pointer-to-member is a real pointer or a vtable offset.
10221 (build_ptrmemfunc1): Add new parameter to contain extra field.
10222 (build_ptrmemfunc): Pass the extra field around.
10223 (expand_ptrmemfunc_cst): Add new parameter to return extra field.
10224 (pfn_from_ptrmemfunc): Ignore the extra field.
10225
acc72c37
MM
102262001-05-03 Mark Mitchell <mark@codesourcery.com>
10227
10228 * cp-tree.h (flag_inline_trees): Update documentation.
10229 * decl.c (init_decl_processing): Adjust handling of
10230 flag_inline_functions and flag_inline_trees to support -O3.
10231 (grokfndecl): Set DECL_INLINE on all functions if that's what
10232 the user requested.
10233 (save_function_data): Clear DECL_INLINE in
10234 current_function_cannot_inline is non-NULL.
10235 * decl2.c (flag_inline_trees): Update documentation.
10236
5158d7ee
NS
102372001-05-03 Nathan Sidwell <nathan@codesourcery.com>
10238
10239 * dump.c (cp_dump_tree, USING_STMT case): New case.
10240 * tree.c (cp_statement_code_p): Add USING_STMT.
10241 * decl2.c (do_using_directive): Add the using directive statement.
10242
10243 * tree.c (walk_tree): Reformat an if block.
10244
80f5bb34
MM
102452001-05-02 Mark Mitchell <mark@codesourcery.com>
10246
10247 * decl.c (compute_array_index_type): Don't try to do anything with
10248 the indices when processing a template.
10249
3e411c3f
KG
102502001-05-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10251
10252 * call.c: NULL_PTR -> NULL.
10253 * class.c: Likewise.
10254 * cvt.c: Likewise.
10255 * decl.c: Likewise.
10256 * decl2.c: Likewise.
10257 * except.c: Likewise.
10258 * init.c: Likewise.
10259 * rtti.c: Likewise.
10260 * search.c: Likewise.
10261 * tree.c: Likewise.
10262 * typeck.c: Likewise.
10263 * typeck2.c: Likewise.
10264
46188dca
MM
102652001-05-02 Mark Mitchell <mark@codesourcery.com>
10266
10267 * decl2.c (do_using_directive): Revert previous patch.
10268
9da99f7d
NS
102692001-05-01 Nathan Sidwell <nathan@codesourcery.com>
10270
10271 * cp-tree.def (USING_STMT): New statement node.
10272 * cp-tree.h (USING_STMT_NAMESPACE): New macro.
10273 * decl2.c (do_using_directive): Add USING_STMT to statement
10274 tree. Don't emit errors when processing template decl.
10275 * pt.c (tsubst_expr, USING_STMT case): New case.
10276 * semantics.c (cp_expand_stmt, USING_STMT case): New case.
10277
4b48a93e
NS
102782001-05-01 Nathan Sidwell <nathan@codesourcery.com>
10279
10280 * call.c (build_new_op): Convert args from reference here.
10281 (build_conditional_expr): Don't convert here.
10282
1bcea8d7
NS
102832001-05-01 Nathan Sidwell <nathan@codesourcery.com>
10284
10285 * spew.c (last_token_id): New static variable.
10286 (read_token): Set it here.
10287 (yyerror): Use it here.
10288
d72040f5
RH
102892001-04-30 Richard Henderson <rth@redhat.com>
10290
749ced52 10291 * cvt.c: Downcase C_PROMOTING_INTEGER_TYPE_P invocations.
d72040f5
RH
10292 * decl.c: Likewise.
10293
c3aac512
MM
102942001-04-30 Mark Mitchell <mark@codesourcery.com>
10295
10296 * gxxint.texi: Remove.
10297 * Make-lang.in: Remove all traces of gxxint.texi.
10298
d2a6f3c0 102992001-04-30 Mark P Mitchell <mark@codesourcery.com>
5fd893d5
MM
10300
10301 * decl2.c (start_static_initialization_or_destruction): Correct
10302 logic to handle the -fno-use-cxa-atexit case.
10303
d60e5448
MM
103042001-04-30 Mark Mitchell <mark@codesourcery.com>
10305
10306 * optimize.c (update_cloned_parm): New function.
10307 (maybe_clone_body): Use it. Update the `this' parameter too.
10308
7200764f
JM
103092001-04-29 Joseph S. Myers <jsm28@cam.ac.uk>
10310
10311 * decl2.c (unsupported_options): Add new-abi.
10312 * lang-options.h: Remove no longer supported options.
10313
2d46ec83
NS
103142001-04-27 Nathan Sidwell <nathan@codesourcery.com>
10315
10316 * except.c (can_convert_eh): Don't check template parms,
10317 typename types etc.
10318
02a1a68c
NS
103192001-04-27 Nathan Sidwell <nathan@codesourcery.com>
10320
10321 * optimize.c (maybe_clone_body): Copy parameter names and locations.
10322
5f6eeeb3
NS
103232001-04-27 Nathan Sidwell <nathan@codesourcery.com>
10324
10325 * cp-tree.h (adjust_clone_args): Prototype new function.
10326 * class.c (adjust_clone_args): New function.
10327 * decl.c (start_function): Call it for in charge ctors.
10328
1b28d441
MM
103292001-04-26 Mark Mitchell <mark@codesourcery.com>
10330
10331 * method.c (use_thunk): Make sure that thunks really are emitted
10332 when requested.
10333
0576ec13
NS
103342001-04-26 Nathan Sidwell <nathan@codesourcery.com>
10335
10336 * mangle.c (write_chars): New macro.
10337 (hwint_to_ascii): New function
10338 (write_number): Use it.
10339 (write_integer_cst): Deal with really big numbers.
10340
b96ada87
MM
103412001-04-25 Mark Mitchell <mark@codesourcery.com>
10342
10343 * optimize.c (maybe_clone_body): Copy TREE_PUBLIC before emitting
10344 the clone.
10345
6bda7a5e
NS
103462001-04-25 Nathan Sidwell <nathan@codesourcery.com>
10347
10348 * decl.c (grokdeclarator): Set context of namespace scope
10349 TYPE_DECLS.
10350
11fe225a
ZW
103512001-04-24 Zack Weinberg <zackw@stanford.edu>
10352
10353 * cp/optimize.c: Include hashtab.h.
10354 (struct inline_data): Add tree_pruner.
10355 (expand_call_inline, expand_calls_inline): Use it when calling
10356 walk_tree.
10357 (optimize_function): Initialize and free tree_pruner.
10358
0ba8a114
NS
103592001-04-24 Nathan Sidwell <nathan@codesourcery.com>
10360
10361 Lazy __FUNCTION__ generation.
10362 * cp-tree.def (FUNCTION_NAME): Remove.
10363 * cp-tree.h (function_name_declared_p): Remove.
10364 (cp_fname_init): Prototype.
10365 * decl.c (init_decl_processing): Don't generate __FUNCTION__ et al ids,
10366 don't call declare_function_name. Call start_fname_decls.
10367 (cp_make_fname_decl): Adjust parameters. Generate the name. Don't
10368 clobber the line number.
10369 (cp_fname_init): New function.
10370 (start_function): Call start_fname_decls.
10371 (finish_function): Call finish_fname_decls.
10372 * lex.c (reswords): Add slots for __FUNCTION__ et al.
10373 (rid_to_yy): Add mappings for __FUNCTION__ et al.
10374 * optimize.c (maybe_clone_body): Remove function_name_declared_p.
10375 * parse.y (VAR_FUNC_NAME): New token.
10376 (primary): Add VAR_FUNC_NAME.
10377 * pt.c (tsubst_decl): Adjust a DECL_PRETTY_FUNCTION_P's
10378 generation.
10379 (tsubst, FUNCTION_NAME case): Remove.
10380 (tsubst_copy, FUNCTION_NAME case): Remove.
10381 (tsubst_expr, DECL_STMT case): Be careful with a
10382 DECL_PRETTY_FUNCTION_P.
10383 (instantiate_decl): Remove function_name_declared_p.
10384 * semantics.c (begin_compound_statement): Don't call
10385 declare_function_name here.
10386 (setup_vtbl_ptr). Don't save & restore function_name_declared_p.
10387 (finish_translation_unit): Call finish_fname_decls.
10388 (expand_body): Remove function_name_declared_p.
10389 * typeck2.c (digest_init): Allow any ERROR_MARK.
10390
dfbb4f34
NS
103912001-04-24 Nathan Sidwell <nathan@codesourcery.com>
10392
10393 * pt.c (tsubst_decl): Use VOID_TYPE_P.
10394 * semantics.c: Fix some typos.
10395
e2584c52
PE
103962001-04-23 Phil Edwards <pme@sources.redhat.com>
10397
10398 * cp/decl2.c (flag_honor_std): Always initialize to 1.
10399
d4c3ec27
KG
104002001-04-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10401
10402 * xref.c (GNU_xref_file): Use concat in lieu of xmalloc/sprintf.
10403
2ac8a0f9
JM
104042001-04-23 Jason Merrill <jason_merrill@redhat.com>
10405
10406 * except.c (build_throw): Wrap the initialization of the exception
10407 object in a MUST_NOT_THROW_EXPR.
10408 (do_free_exception): #if 0.
10409
968b956a
MM
104102001-04-20 Mark Mitchell <mark@codesourcery.com>
10411
10412 * cp-tree.h (finish_enum): Change prototype.
10413 * decl.c (finish_enum): Reorganize.
10414 * parse.y (structsp): Adjust calls to finish_enum.
11fe225a 10415
aa1826e2
NS
104162001-04-20 Nathan Sidwell <nathan@codesourcery.com>
10417
10418 * tree.c (cp_tree_equal): Adjust final switch formatting. Add
10419 't' case.
10420
06d9f09f
NS
104212001-04-20 Nathan Sidwell <nathan@codesourcery.com>
10422
10423 * class.c (dfs_unshared_virtual_bases): Add ATTRIBUTE_UNUSED.
10424 (layout_empty_base): Return at end flag.
10425 (build_base_field): Likewise.
10426 (build_base_fields): Likewise.
10427 (layout_virtual_bases): Don't add 1 to eoc value.
10428 (end_of_class): Use full size for empty bases.
10429 (layout_class_type): Clear CLASSNEARLY_EMPTY_P if we appended
10430 empty bases. Don't add 1 to eoc value. Only add trailing padding
10431 if we're an empty class with no empty bases.
10432 (dump_class_hierarchy): Dump size and alignment.
10433
351a0f00
JJ
104342001-04-20 Jakub Jelinek <jakub@redhat.com>
10435
10436 * call.c (maybe_handle_ref_bind): Copy ICS_USER_FLAG and
10437 ICS_BAD_FLAG.
10438
881cae05
JJ
104392001-04-20 Jakub Jelinek <jakub@redhat.com>
10440
10441 * search.c (lookup_field_r): If looking for type and non-TYPE_DECL
10442 is found, look first if name does not match the structure name.
10443
5d2ed28c
MM
104442001-04-19 Mark Mitchell <mark@codesourcery.com>
10445
10446 * cp-tree.h (DECL_LANGUAGE): Don't assume DECL_LANG_SPECIFIC is
10447 set.
10448 (SET_DECL_LANGUAGE): New macro.
10449 * decl.c (duplicate_decls): Use SET_DECL_LANGUAGE.
10450 (pushdecl): Likewise.
10451 (build_library_fn_1): Likewise.
10452 (build_cp_library_fn): Likewise.
10453 (grokfndecl): Likewise.
10454 (grokvardecl): Mark `extern "C"' variables as having C linkage.
10455 * decl2.c (grokclassfn): Use SET_DECL_LANGUAGE.
10456 * lex.c (retrofit_lang_decl): Likewise.
10457 * mangle.c (mangle_decl_string): Don't mangle the names of
10458 variables declared with C language linkage.
10459 * semantics.c (finish_member_declaration): Use SET_DECL_LANGUAGE.
11fe225a 10460
41251458
JDA
104612001-04-18 John David Anglin <dave@hiauly1.hia.nrc.ca>
10462
10463 * semantics.c (simplify_aggr_init_exprs_r): Don't restore
10464 flag_access_control from uninitialized storage.
10465
1b4a93f7
MM
104662001-04-15 Mark Mitchell <mark@codesourcery.com>
10467
24272dc0
MM
10468 * cp-tree.h (TYPE_PTRMEM_CLASS_TYPE): Improve documentation.
10469 * mangle.c (write_pointer_to_member_type): Fix mangling of
10470 pointers to cv-qualified member function types.
10471
1b4a93f7
MM
10472 * init.c (build_delete): Create a SAVE_EXPR for the address if
10473 we're going to use it more than once.
10474
530ec96d
MM
104752001-04-13 Mark Mitchell <mark@codesourcery.com>
10476
10477 * cp-tree.h (DELTA2_FROM_PTRMEMFUNC): Remove.
10478 (expand_ptremfunc_cst): Change prototype.
10479 (delta2_from_ptrmemfunc): Remove.
10480 * expr.c (cplus_expand_constant): Adjust call to
10481 expand_ptrmemfunc_cst.
10482 * typeck.c (build_ptrmemfunc1): Simplify.
10483 (build_ptrmemfunc): Make sure that casting a PTRMEM_CST still
10484 results in a constant.
10485 (expand_ptrmemfunc_cst): Remove idx and delta2 parameters.
10486 (delta2_from_ptrmemfunc): Remove.
10487 (pfn_from_ptrmemfunc): Adjust call to expand_ptrmemfunc_cst.
11fe225a 10488
ee8fc32b
JM
104892001-04-12 Jason Merrill <jason_merrill@redhat.com>
10490
10491 * cp-tree.h (decl_namespace_list): New macro.
10492 (struct saved_scope): Add decl_ns_list.
10493 * decl.c (mark_saved_scope): Mark it.
10494 * decl2.c: Lose static decl_namespace_list.
10495 (init_decl2): Don't save it.
10496
48857160
KG
104972001-04-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10498
10499 * cp-tree.h (warn_return_type, yylex): Delete redundant
10500 declarations.
11fe225a 10501
48857160
KG
10502 * decl.c (current_class_depth, global_namespace): Likewise.
10503
10504 * decl2.c (current_class_depth, flag_gnu_xref): Likewise
10505
10506 * repo.c (flag_use_repository): Likewise.
10507
845e14ed
KG
105082001-04-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10509
10510 * cp-tree.h (pedantic, convert, global_bindings_p, insert_block,
10511 set_block, pushdecl, getdecls, gettags, init_decl_processing,
10512 maybe_build_cleanup, copy_lang_decl, prep_stmt, lvalue_p,
10513 lvalue_or_else, print_lang_statistics, comp_target_types,
10514 unsigned_type, signed_type, signed_or_unsigned_type,
10515 build_function_call, mark_addressable, incomplete_type_error):
10516 Delete redundant declarations.
10517
1951a1b6
JM
105182001-04-11 Jason Merrill <jason_merrill@redhat.com>
10519
10520 * cp-tree.h (TYPE_LINKAGE_IDENTIFIER): New macro.
10521 (TYPE_ANONYMOUS_P): New macro.
10522 (TAGGED_TYPE_P): New macro.
10523 * decl.c (check_tag_decl): Use TYPE_ANONYMOUS_P.
10524 (grokfndecl, grokvardecl, grokdeclarator): Likewise.
10525 * tree.c (no_linkage_helper): Likewise.
10526 * semantics.c (begin_class_definition): Likewise.
10527 * pt.c (convert_template_argument): Likewise.
10528 * lex.c (check_for_missing_semicolon): Likewise.
10529
0fb3018c
NS
105302001-04-12 Nathan Sidwell <nathan@codesourcery.com>
10531
10532 * class.c (dfs_unshared_virtual_bases): New function.
10533 (mark_primary_bases): Call it.
10534 (check_bases): Ignore virtual bases when determining
10535 nearly-emptiness.
10536
bbb53468
NS
105372001-04-12 Nathan Sidwell <nathan@codesourcery.com>
10538
10539 * method.c (make_thunk): Clear DECL_CLONED_FUNCTION.
10540
9b7949d5
MM
105412001-04-11 Mark Mitchell <mark@codesourcery.com>
10542
10543 * optimize.c (maybe_clone_body): Copy DECL_NUM_STMTS from the
10544 cloned function to the clone.
10545
d6684bc8
KG
105462001-04-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10547
10548 * Make-lang.in (cp/semantics.o): Depend on $(EXPR_H).
10549
10550 * semantics.c: Include expr.h.
10551
a2095778
NS
105522001-04-11 Nathan Sidwell <nathan@codesourcery.com>
10553
10554 * method.c (implicitly_declare_fn): Commonize code for copy ctor
10555 and assignment op. Set TREE_USED for parameter.
10556
78b45a24
MM
105572001-04-10 Mark Mitchell <mark@codesourcery.com>
10558
10559 * class.c (find_final_overrider_data): Add `candidates'.
10560 (dfs_find_final_overrider): Don't issue error messages
10561 prematurely.
10562 (find_final_overrider): Issue error messages here.
10563 (build_base_field): Don't warn about amgibuous direct bases here.
10564 (warn_about_ambiguous_direct_bases): New function.
10565 (layout_class_type): Use it.
10566
0450d74d
RH
105672001-04-10 Richard Henderson <rth@redhat.com>
10568
10569 * typeck.c (build_array_ref): Push the array reference inside
10570 COMPOUND_EXPR and COND_EXPR.
10571
79065db2
MM
105722001-04-05 Mark Mitchell <mark@codesourcery.com>
10573
10574 * cp-tree.h (DECL_THIS_INLINE): Rename to DECL_DECLARED_INLINE_P.
10575 * decl.c (duplicate_decls): Adjust accordingly.
10576 (maybe_commonize_var): Likewise.
10577 (grokfndecl): Likewise.
10578 (start_function): Likewise.
10579 (start_method): Likewise.
10580 * decl2.c (key_method): Likewise.
10581 (import_export_decl): Likewise.
10582 * method.c (implicitly_declare_fn): Likewise.
10583 * optimize.c (maybe_clone_body): Likewise.
11fe225a 10584
fdecbf8a
BK
105852001-04-05 Benjamin Kosnik <bkoz@redhat.com>
10586
b03eced6 10587 * lang-specs.h: Add __DEPRECATED.
fdecbf8a 10588
d2a6f3c0 105892001-04-05 J"orn Rennecke <amylaar@redhat.com>
0b4c1646
R
10590
10591 * search.c (get_dynamic_cast_base_type): When building a new
10592 constant, set its type to ssizetype.
10593
e59d6709
JJ
105942001-04-04 Jakub Jelinek <jakub@redhat.com>
10595
10596 * optimize.c (expand_call_inline): Only add newly inlined statements
10597 into inlined_stmts.
10598
0c918ce5
MM
105992001-04-03 Mark Mitchell <mark@codesourcery.com>
10600
10601 * cp-tree.h (OPERATOR_ASSIGN_FORMAT): Remove.
10602 (OPERATOR_FORMAT): Likewise.
10603 (OPERATOR_TYPENAME_FORMAT): Likewise.
10604 * operators.def: Remove old name-mangling information.
10605 * decl.c (grok_op_properties): Adjust accordingly.
10606 * lex.c (init_operators): Likewise.
10607 * rtti.c (get_tinfo_decl): Issue error messages about types that
10608 have variable size.
10609
92788413
MM
106102001-04-03 Mark Mitchell <mark@codesourcery.com>
10611
11fe225a 10612 * decl2.c (import_export_decl): Don't call import_export_class
92788413
MM
10613 when processing an inline member function.
10614 * semantics.c (expand_body): Call import_export_decl before
10615 emitting inline functions.
10616
52a11cbf
RH
106172001-03-28 Richard Henderson <rth@redhat.com>
10618
10619 IA-64 ABI Exception Handling:
10620 * cp-tree.def (EH_SPEC_BLOCK): New.
10621 (MUST_NOT_THROW_EXPR): New.
10622 * cp-tree.h: Update changed function declarations.
10623 (CPTI_PUSH_EXCEPTION_IDENTIFIER): Remove.
10624 (CPTI_CALL_UNEXPECTED): New.
10625 (struct cp_language_function): Rename x_eh_spec_try_block
10626 to x_eh_spec_block.
10627 (EH_SPEC_STMTS, EH_SPEC_RAISES): New.
11fe225a 10628 * decl.c (current_binding_level): If no current function
52a11cbf
RH
10629 bindings, revert to scope_chain.
10630 (initialize_predefined_identifiers): Remove __cp_push_exception.
10631 (store_parm_decls): Use begin_eh_spec_block.
10632 (finish_function): Use finish_eh_spec_block.
10633 (mark_lang_function): Update for name changes.
10634 * decl2.c (finish_file): No mark_all_runtime_matches.
10635 * dump.c (cp_dump_tree): Handle new tree codes.
10636 * error.c (dump_expr) [BIND_EXPR]: Fix typo.
10637 * except.c (catch_language_init, catch_language): Remove.
10638 (init_exception_processing): Don't set language code.
10639 Initialize call_unexpected_node, protect_cleanup_actions,
10640 eh_personality_libfunc, lang_eh_runtime_type.
10641 (call_eh_info, push_eh_info, get_eh_info, get_eh_value): Remove.
10642 (get_eh_type, get_eh_caught, get_eh_handlers): Remove.
10643 (prepare_eh_type): Split out type canonicalizations ...
10644 (build_eh_type_type): ... from here.
10645 (build_eh_type_type_ref): Remove.
10646 (mark_all_runtime_matches): Remove.
10647 (build_exc_ptr): New.
10648 (do_begin_catch, do_end_catch): New.
10649 (do_pop_exception): Remove.
10650 (build_terminate_handler): Remove.
10651 (choose_personality_routine): Split out language choice from ...
10652 (initialize_handler_parm): ... here.
10653 Use MUST_NOT_THROW_EXPR.
10654 (expand_start_catch_block): Use do_begin_catch. Simplify Java
10655 exception object handling.
10656 (expand_start_eh_spec, expand_end_eh_spec): Remove.
10657 (expand_exception_blocks, alloc_eh_object): Remove.
10658 (begin_eh_spec_block, finish_eh_spec_block): New.
10659 (do_allocate_exception, do_free_exception): New.
10660 (expand_throw): Merge into ...
10661 (build_throw): ... here. Update for abi.
10662 * expr.c (cplus_expand_expr): No expand_internal_throw.
10663 Handle MUST_NOT_THROW_EXPR.
10664 * pt.c (tsubst_expr): Handle EH_SPEC_BLOCK.
10665 * semantics.c (*) Update for except.h name changes.
10666 (genrtl_try_block): No protect_with_terminate.
10667 (genrtl_eh_spec_block): New.
10668 (genrtl_handler): Don't emit the goto here.
10669 (cp_expand_stmt): Handle EH_SPEC_BLOCK.
10670 (genrtl_finish_function): Don't expand_exception_blocks.
10671 * tree.c (cp_statement_code_p): Handle EH_SPEC_BLOCK.
10672
826840d9
RH
106732001-03-28 Richard Henderson <rth@redhat.com>
10674
10675 * decl.c (struct named_label_list): Rename eh_region to
10676 in_try_scope, add in_catch_scope.
10677 (struct binding_level): Rename eh_region to is_try_scope,
10678 add is_catch_scope.
10679 (note_level_for_try): Rename from note_level_for_eh.
10680 (note_level_for_catch): New.
10681 (poplevel): Copy both is_try_scope and is_catch_scope to
10682 the named_label_list struct.
10683 (check_previous_goto_1): Don't check for catch block via
10684 DECL_ARTIFICIAL; use in_try_scope instead.
10685 (check_goto): Likewise.
10686 * cp-tree.h (note_level_for_try, note_level_for_catch): Declare.
10687 * except.c (expand_start_catch_block): Call note_level_for_catch.
10688 * semantics.c (begin_compound_stmt): Update for note_level_for_try.
10689
531073e7
RH
106902001-03-27 Richard Henderson <rth@redhat.com>
10691
10692 * except.c: Use USING_SJLJ_EXCEPTIONS instead of
10693 exceptions_via_longjmp.
10694
8653a2c3
PE
106952001-03-27 Phil Edwards <pme@sources.redhat.com>
10696
10697 * pt.c (check_default_tmpl_args): Make error messages clearer.
10698
106992001-03-26 Phil Edwards <pme@sources.redhat.com>
10700
10701 * error.c: Also undefine 'A' macro used for cp_printers definition.
10702
911e6107
KG
107032001-03-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10704
10705 * Make-lang.in: Depend on $(SYSTEM_H), not system.h.
10706
005a5cb0
MY
107072001-03-26 Mike Yang <yang@research.att.com>
10708 Mark Mitchell <mark@codesourcery.com>
10709
10710 * dump.c (dump_access): New function.
10711 (cp_dump_tree): Use it. Dump basetype information for class
10712 types.
10713
b850de4f
MM
107142001-03-26 Mark Mitchell <mark@codesourcery.com>
10715
10716 * Makefile.in (optimize.o): Depend on params.h.
10717 (duplicate_decls): Copy DECL_NUM_STMTS, not DECL_FRAME_SIZE.
10718 (init_decl_processing): Set flag_no_inline when doing
10719 inlining-on-trees.
10720 * optimize.c: Include params.h.
10721 (struct inline_data): Improve documentation of FNS. Add
10722 FIRST_INLINED_FN, INLINED_STMTS, and CLONING_P.
10723 (INSNS_PER_STMT): New macro.
10724 (remap_block): Use CLONING_P.
10725 (inlinable_function_p): Don't inline big functions.
10726 (expand_call_inline): Keep track of how much inlining we've done.
10727 (optimize_function): Set FIRST_INLINED_FN.
10728 (maybe_clone_body): Set CLONING_P.
10729 * semantics.c (simplify_aggr_init_exprs_r): Fix typing problems in
10730 tree nodes.
10731 (genrtl_finish_function): Clear DECL_DEFER_OUTPUT before calling
10732 rest_of_compilation. Clear DECL_RTL for local variables
10733 afterwards.
10734 (clear_decl_rtl): New function.
11fe225a 10735
788bf0e3
NS
107362001-03-26 Nathan Sidwell <nathan@codesourcery.com>
10737
10738 Implement DR 209
10739 * cp-tree.h (skip_type_access_control,
10740 reset_type_access_control): Prototype.
10741 * decl.c (grokdeclarator): Access of friends is not checked.
10742 * parse.y (component_decl_list): Reset type access control.
10743 * semantics.c (decl_type_access_control): Clear
10744 current_type_lookups.
10745 (save_type_access_control): Don't save if not deferring.
10746 (skip_type_access_control, reset_type_access_control): New
10747 functions.
10748 (begin_class_definition): Do type access control for basetypes.
10749 Start deferred access control.
10750 (finish_class_definition): Resume immediate access control if
10751 this is a local class.
10752
730e1556
KG
107532001-03-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
10754
10755 * class.c (add_method): Use memcpy/memmove, not bcopy.
10756
10757 * decl.c (duplicate_decls): Likewise.
10758
f1a0345c
JJ
107592001-03-23 Jakub Jelinek <jakub@redhat.com>
10760
10761 * mangle.c (write_discriminator): Use `_0' for discriminator 1,
10762 not `_'.
10763
8e4ce833
JJ
107642001-03-23 Jakub Jelinek <jakub@redhat.com>
10765
10766 * decl.c (local_names): Define.
10767 (push_local_name): New.
10768 (grok_reference_init): Return init if initializing static reference
10769 variable with non-constant instead of emitting it.
10770 Move expand_static_init call to cp_finish_decl.
10771 (layout_var_decl): Call push_local_name.
10772 (maybe_commonize_var): Allow inlining functions even if they have
10773 static local variables, use comdat_linkage for them if flag_weak.
10774 (check_initializer): Call obscure_complex_init if
838dfd8a 10775 grok_reference_init returned nonzero.
8e4ce833
JJ
10776 (save_function_data): Clear x_local_names.
10777 (pop_cp_function_context): Free x_local_names.
10778 (mark_inlined_fns): Remove.
10779 (mark_lang_function): Mark x_local_names.
10780 (lang_mark_tree): Don't mark DECL_ACCESS for DECL_DISCRIMINATOR_P.
10781 Mark inlined_fns as tree, remove call to mark_inlined_fns.
10782 * class.c (alter_access): Ensure DECL_ACCESS is never set if
10783 DECL_DISCRIMINATOR_P.
10784 * cp-tree.h (cp_language_function): Add x_local_names.
10785 (lang_decl_flags): Add discriminator into u2.
10786 (lang_decl_inlined_fns): Remove.
10787 (lang_decl): inlined_fns is now a TREE_VEC.
10788 (DECL_DISCRIMINATOR_P, DECL_DISCRIMINATOR): Define.
10789 * optimize.c (inlinable_function_p): DECL_INLINED_FNS is now a
10790 TREE_VEC, not a custom structure.
10791 (optimize_function): Likewise.
10792 * mangle.c (discriminator_for_local_entity): Discriminate among
10793 VAR_DECL local entities.
10794 * search.c (dfs_access_in_type): If DECL_DISCRIMINATOR_P, DECL_ACCESS
10795 is not valid.
10796
60c87482
BM
107972001-03-22 Bryce McKinlay <bryce@albatross.co.nz>
10798
10799 Add support for Java interface method calls.
10800 * cp-tree.h (struct lang_type): Add java_interface flag.
10801 (TYPE_JAVA_INTERFACE): New macro.
10802 * tree.c (cp_valid_lang_attribute): Handle "java_interface" attribute
10803 by setting TYPE_JAVA_INTERFACE.
10804 * call.c (java_iface_lookup_fn): New static.
11fe225a 10805 (build_over_call): If calling a method declared in a
60c87482
BM
10806 TYPE_JAVA_INTERFACE, call build_java_interface_fn_ref to generate the
10807 expression which resolves the function address.
10808 (build_java_interface_fn_ref): New function.
10809
94c7f30b
RH
108102001-03-22 Richard Henderson <rth@redhat.com>
10811
10812 * Make-lang.in (cp/except.o): Don't depend on insn-flags.h.
10813 * except.c: Don't include it.
10814
fd8b7a0e 108152001-03-22 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
826840d9 10816 based on an idea from Joe Buck <jbuck@synopsys.com>
fd8b7a0e
GP
10817
10818 * parse.y (bad_decl, template_arg_list_ignore, arg_list_ignore):
10819 New nonterminals.
10820 (data_def, component_decl): Add reductions to bad_decl.
10821
a1c2b86d
JJ
108222001-03-22 Jakub Jelinek <jakub@redhat.com>
10823
10824 * method.c (do_build_assign_ref): Don't use build_modify_expr for
10825 anonymous aggregates, since they don't have assignment operator
10826 method.
10827 * decl.c (fixup_anonymous_aggr): Disallow ctors, dtors and copy
10828 assignment operators for anonymous structure fields.
10829
46ccf50a
JM
108302001-03-21 Jason Merrill <jason@redhat.com>
10831
10832 * pt.c (instantiate_decl): Abort if we see a member constant
10833 instantiation that doesn't already have its initializer.
10834 Downgrade explicit instantiation without definition to pedwarn.
10835
10836 * cp-tree.h (DECL_TINFO_FN_P, SET_DECL_TINFO_FN_P): Remove.
10837 * class.c (build_vtable_entry): Don't check DECL_TINFO_FN_P.
10838 (import_export_decl): Check tinfo_decl_p, not DECL_TINFO_FN_P.
10839
10840 * cp-tree.h (CLASSTYPE_VTABLE_NEEDS_WRITING): Remove.
10841 (pending_vtables): Remove.
10842 * decl2.c (pending_vtables): Remove.
10843 (import_export_vtable): Use CLASSTYPE_INTERFACE_ONLY, not
10844 CLASSTYPE_VTABLE_NEEDS_WRITING.
10845 (import_export_class): Likewise.
10846 (init_decl2): Don't mark pending_vtables.
10847 * lex.c (handle_pragma_vtable): Just sorry.
10848 * pt.c (instantiate_class_template): Don't mess with
10849 CLASSTYPE_VTABLE_NEEDS_WRITING.
10850 (mark_class_instantiated): Likewise.
10851 * ptree.c (print_lang_type): Don't print it.
10852 * semantics.c (begin_class_definition): Don't set it.
10853
10854 * pt.c (template_tail): Replace with last_pending_template.
10855 (maybe_templates, maybe_template_tail): Remove.
10856 (add_pending_template): Adjust.
10857 (instantiate_pending_templates): Adjust.
10858
10859 * cp-tree.h (struct saved_scope): Remove lang_stack field.
10860 (current_lang_stack): Remove.
10861 * decl.c (maybe_push_to_top_level): Don't initialize it.
10862 (duplicate_decls): Use current_lang_depth.
10863 (xref_basetypes): Likewise.
10864 * class.c (current_lang_depth): New fn.
10865 (push_lang_context): Use more varray functionality.
10866 (pop_lang_context): Likewise.
64d9c3fe
JM
10867
10868 * error.c (GLOBAL_THING): Always use '__'.
10869
1c06710a
MM
108702001-03-21 Mark Mitchell <mark@codesourcery.com>
10871
71cb9286
MM
10872 * class.c (build_clone): Clear DECL_ASSEMBLER_NAME.
10873
1c06710a
MM
10874 * mangle.c (mangle_decl_string): Mangle the names of overloaded
10875 operators, even when they have `extern "C"' linkage.
10876
92643fea
MM
108772001-03-19 Mark Mitchell <mark@codesourcery.com>
10878
10879 * class.c (get_vtable_decl): Use SET_DECL_ASSEMBLER_NAME,
10880 COPY_DECL_ASSEMBLER_NAME, etc. Don't set DECL_ASSEMBLER_NAME
10881 where it's not necessary.
10882 (add_method): Remove optimization involving comparison of
10883 DECL_ASSEMBLER_NAME.
10884 (build_vtbl_or_vbase_field): Use SET_DECL_ASSEMBLER_NAME,
10885 COPY_DECL_ASSEMBLER_NAME, etc. Don't set DECL_ASSEMBLER_NAME
10886 where it's not necessary.
10887 (check_methods): Likewise.
10888 (build_clone): Likewise.
10889 (built_vtt): Likewise.
10890 * cp-tree.h (DECL_NEEDED_P): Likewise.
10891 * decl.c (pushtag): Likewise.
10892 (duplicate_decls): Likewise.
10893 (pushdecl): Likewise.
10894 (builtin_function): Likewise.
10895 (build_library_fn_1): Set DECL_LANGUAGE for library functions.
10896 (build_cp_library_fn): Likewise.
10897 (maybe_commonize_var): Use SET_DECL_ASSEMBLER_NAME,
10898 COPY_DECL_ASSEMBLER_NAME, etc. Don't set DECL_ASSEMBLER_NAME
10899 where it's not necessary.
10900 (make_rtl_for_nonlocal_decl): Likewise.
10901 (cp_finish_decl): Likewise.
10902 (grokfndecl): Likewise.
10903 (grokvardecl): Likewise.
10904 (grokdeclarator): Likewise.
10905 (start_function): Likewise.
10906 (cp_missing_return_ok_p): Likewise.
10907 * decl2.c (grokclassfn): Likewise.
10908 (check_classfn): Likewise.
10909 (finish_static_data_member_decl): Likewise.
10910 (grokfield): Likewise.
10911 * error.c (GLOBAL_IORD_P): Remove.
10912 (dump_global_iord): Improve output.
10913 (dump_decl): Avoid using DECL_ASSEMBLER_NAME.
10914 * except.c (nothrow_libfn_p): Summarily reject any function not in
10915 namespace-scope.
10916 * init.c (build_java_class_ref): Don't explicitly set
10917 DECL_ASSEMBLER_NAME after calling mangle_decl.
10918 * mangle.c (mangle_decl_string): Handle extern "C" functions.
10919 (mangle_decl): Set the DECL_ASSEMBLER_NAME for the decl.
10920 * method.c (set_mangled_name_for_decl): Don't explicitly set
10921 DECL_ASSEMBLER_NAME after calling mangle_decl.
10922 (make_thunk): Explicitly set the DECL_ASSEMBLER_NAME and
10923 IDENTIFIER_GLOBAL_VALUE for the thunk.
10924 * pt.c (set_mangled_name_for_template_decl): Remove.
10925 (check_explicit_specialization): Don't use it.
10926 (looup_template_class): Don't set DECL_ASSEMBLER_NAME.
10927 (tsubst_friend_function): Likewise.
10928 (tsubst_decl): Likewise.
10929 (regenerate_decl_from_template): Use COPY_DECL_ASSEMBLER_NAME.
10930 * rtti.c (get_tinfo_decl): Use SET_DECL_ASSEMBLER_NAME,
10931 COPY_DECL_ASSEMBLER_NAME, etc. Don't set DECL_ASSEMBLER_NAME
10932 where it's not necessary.
10933 (tinfo_base_init): Likewise.
10934 (create_real_tinfo_var): Likewise.
10935 * search.c (looup_field_1): Likewise.
10936 * semantics.c (finish_named_return_value): Likewise.
10937 * tree.c (init_tree): Set lang_set_decl_assembler_name.
11fe225a 10938
d064d75a
GDR
109392001-03-15 Gabriel Dos Reis <gdr@codesourcery.com>
10940
10941 Correct semantics restrictions checking in throw-expression.
10942 * except.c (is_admissible_throw_operand): New function.
10943 (build_throw): Use it.
10944
a3eab619
MM
109452001-03-14 Mark Mitchell <mark@codesourcery.com>
10946
10947 * decl.c (cp_make_fnname_decl): Set DECL_IGNORED_P on __FUNCTION__
10948 and its ilk.
10949
19e7881c
MM
109502001-03-14 Mark Mitchell <mark@codesourcery.com>
10951
10952 * class.c (build_clone): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc.
10953 * cp-tree.h (DECL_IN_MEMORY_P): Likewise.
10954 * decl.c (duplicate_decls): Likewise.
10955 (builtin_function): Likewise.
10956 (build_library_fn): Likewise.
10957 (build_cp_library_fn): Likewise.
10958 (check_initializer): Likewise.
10959 (cp_finish_decl): Likewise.
10960 * decl2.c (grokfield): Likewise.
10961 (grok_function_init): Remove #if 0'd code.
10962 (finish_anon_union): Use COPY_DECL_RTL, DECL_RTL_SET_P, etc.
10963 * friend.c (do_friend): Likewise.
10964 * init.c (get_temp_regvar): Likewise.
10965 * method.c (make_thunk): Likewise.
10966 * pt.c (tsubst_friend_function): Likewise.
10967 (tsubst_decl): Likewise.
10968 (regenerate_decl_from_template): Likewise.
10969 * semantics.c (genrtl_named_return_value): Likewise.
10970 (expand_body): Likewise.
10971 (genrtl_finish_function): Likewise.
10972 * tree.c (cp_tree_equal): Likewise.
11fe225a 10973
78fe06c2
NS
109742001-03-12 Nathan Sidwell <nathan@codesourcery.com>
10975
10976 * call.c (convert_like_real): Add extra semantics to INNER
10977 parameter. Don't convert to temporary if a user conversion
10978 gives us an lvalue that we're about to bind to a reference.
10979 Set INNER to indicate pending reference binding on recursive
10980 calls.
10981
b3e68a79
NB
109822001-03-10 Neil Booth <neil@daikokuya.demon.co.uk>
10983
10984 * cp/lex.c: Delete duplicate pending_lang_change.
10985
109862001-03-10 Neil Booth <neil@daikokuya.demon.co.uk>
10987
10988 * cp/lex.c (handle_pragma_interface, handle_pragma_implementation):
10989 Similarly.
10990 * cp/repo.c (get_base_filename, open_repo_file): Similarly.
10991 * cp/cp-tree.h: Remove file_name_nondirectory prototype.
10992
11642c3a
ZW
109932001-03-09 Zack Weinberg <zackw@stanford.edu>
10994
10995 * Make-lang.in: Add dependencies on $(TM_P_H) as appropriate.
10996
bb6852eb 109972001-03-08 Stan Shebs <shebs@apple.com>
f7687817
SS
10998
10999 * cp-tree.h (set_identifier_local_value): Remove unused decl.
11000
cc937581
ZW
110012001-03-06 Zack Weinberg <zackw@stanford.edu>
11002
11003 * spew.c: Remove references to CPP_OSTRING.
11004
d1188d91
AH
110052001-03-06 Andrew Haley <aph@redhat.com>
11006
11007 * typeck.c (convert_arguments): Check that we have an fndecl.
11008
4eaf1d5b
AH
110092001-03-05 Andrew Haley <aph@redhat.com>
11010
11011 * typeck.c (convert_arguments): Don't do ellipsis conversion for
11012 __built_in_constant_p.
11013
7eeb553c
NS
110142001-03-02 Nathan Sidwell <nathan@codesourcery.com>
11015
11016 * typeck.c (build_static_cast): Allow enum to enum conversions
11017 as per DR 128.
11018
d282fcb2
NS
110192001-03-02 Nathan Sidwell <nathan@codesourcery.com>
11020
11021 * class.c (check_field_decls): Pointers to member do not a
11022 non-pod struct make, as per DR 148.
11023
f86fdf68
NS
110242001-03-02 Nathan Sidwell <nathan@codesourcery.com>
11025
11026 * call.c (joust): cp_pedwarn when using gnu extension concerning
11027 worst conversion sequences.
11028
d6edb99e
ZW
110292001-03-01 Zack Weinberg <zackw@stanford.edu>
11030
11031 * decl.c: Replace all uses of 'boolean' with 'bool'.
11032
f7143427
ZW
110332001-03-01 Zack Weinberg <zackw@stanford.edu>
11034
11035 * lang-specs.h: Add zero initializer for cpp_spec field to
11036 all array elements that need one. Don't put an #ifdef inside
11037 the initializer list; set a default for CPLUSPLUS_CPP_SPEC and
11038 use it.
11039
fbfe8c9e
NS
110402001-03-01 Nathan Sidwell <nathan@codesourcery.com>
11041
11042 Implement using decls inside template functions.
11043 * decl2.c (validate_nonmember_using_decl): Don't special case
11044 fake_std_node in the global namespace. Don't reject early when
11045 processing a template.
11046 (do_local_using_decl): Add to statement tree. Don't do further
11047 processing when building a template.
11048 * pt.c (tsubst_expr, DECL_STMT case): Deal with USING_DECLs.
11049
4d24a889
NS
110502001-03-01 Nathan Sidwell <nathan@codesourcery.com>
11051
11052 * decl2.c (do_nonmember_using_decl): Don't complain if we find
11053 same function. Do complain about ambiguating extern "C"
11054 declarations.
11055
e5844e6d
NS
110562001-02-28 Nathan Sidwell <nathan@codesourcery.com>
11057
11058 Remove floating point and complex type template constant parms.
11059 * pt.c (convert_nontype_argument): Remove REAL_TYPE and
11060 COMPLEX_TYPE extensions.
11061 (invalid_nontype_parm_type_p): Likewise.
11062
788f238c
JO
110632001-02-27 Jeffrey Oldham <oldham@codesourcery.com>
11064
11065 * except.c (call_eh_info): Revert "match_function"'s type.
11066
73ea87d7
NS
110672001-02-27 Nathan Sidwell <nathan@codesourcery.com>
11068
11069 Fix ctor vtable vcall offsets.
11070 * class.c (struct vtbl_init_data_s): Add rtti_binfo member.
11071 (build_rtt_vtbl_entries): Lose RTTI_BINFO parameter.
11072 (get_matching_base): Remove.
11073 (get_original_base): New function.
11fe225a 11074 (build_vtbl_initializer): Initialize vid.rtti_binfo.
73ea87d7
NS
11075 Use a virtual thunk for a ctor vtable with an index
11076 (add_vcall_offset_vtbl_entries_1): Check if binfo has lost a
11077 primary base within a constructor vtable. Only set
11078 BV_VCALL_INDEX when not a constructor vtable. Adjust vcall offset
11079 when primary base has been lost.
11080 * cp-tree.h (BINFO_VIRTUALS): Remove ambiguity from comment.
11081
fe730161
JO
110822001-02-26 Jeffrey Oldham <oldham@codesourcery.com>
11083
11084 * call.c (joust): Ensure more_specialized()'s argument length
11085 parameter has correct value for constructors.
11086
e5dd4aad
NS
110872001-02-26 Nathan Sidwell <nathan@codesourcery.com>
11088
11089 * except.c (call_eh_info): Cleanup generation of cp_eh_info struct.
11fe225a 11090
e5dd4aad
NS
11091 * decl.c (mark_inlined_fns): Prototype.
11092
25200ab2
MM
110932001-02-22 Mark Mitchell <mark@codesourcery.com>
11094
11095 * spew.c (yylex): Correct handling of friends.
11096
f58c04ac
MM
110972001-02-22 Mark Mitchell <mark@codesourcery.com>
11098
11099 * mangle.c (write_encoding): Pass write_function_type the
11100 FUNCTION_DECL for the function being encoded.
11101 (write_function_type): Pass it along to write_bare_function_type.
11102 (write_bare_function_type): Pass it along to write_method_parms.
11103 (write_method_parms): Don't mangle the compiler-generated
11104 parameters to a constructor or destructor.
11105
9c96f3f8
AJ
111062001-02-22 Andreas Jaeger <aj@suse.de>
11107
11108 * optimize.c: Include toplev.h for
11109 note_deferral_of_defined_inline_function prototype.
11110
b3bae5e2
JJ
111112001-02-22 Jakub Jelinek <jakub@redhat.com>
11112
11113 * cp-tree.h (struct lang_decl_inlined_fns): New.
11114 (struct lang_decls): Add inlined_fns.
11115 (DECL_INLINED_FNS): New macro.
11116 * optimize.c (struct inline_data): Add inlined_fns.
11117 (declare_return_variable): Use VARRAY_ACTIVE_SIZE macro.
11118 (inlinable_function_p): Likewise, fix typo in comment,
11119 function is not inlinable if it already inlined function currently
11120 being optimized.
306ef644 11121 (expand_call_inline): Add fn to inlined_fns if necessary.
b3bae5e2
JJ
11122 (optimize_function): Initialize inlined_fns.
11123 Save inlined_fns into DECL_INLINED_FNS after expanding inlines.
11124 * decl.c (mark_inlined_fns): New function.
11125 (lang_mark_tree): Call it.
11126
5daf7c0a
JM
111272001-02-21 Jason Merrill <jason@redhat.com>
11128
11129 * cp-tree.h (struct lang_decl_flags): Remove uninlinable flag.
11130 (DECL_UNINLINABLE): Move to middle-end.
11131
11132 * class.c (clone_function_decl): Set DECL_ABSTRACT on original fn.
11133 * decl.c (duplicate_decls): Preserve DECL_ABSTRACT.
11134 * class.c (build_clone): Set DECL_ABSTRACT_ORIGIN for the clone.
11135 * optimize.c (maybe_clone_body): Set DECL_ABSTRACT_ORIGIN for the
11136 parms and outer BLOCK. note_deferral_of_defined_inline_function.
11137
11138 * method.c (implicitly_declare_fn): Don't set DECL_ARTIFICIAL on
11139 second parm of op=.
11140
2c0fc02d
MM
111412001-02-19 Mark Mitchell <mark@codesourcery.com>
11142
11143 * decl2.c (set_decl_namespace): Allow explicit instantiations in
11144 any namespace.
11145
612164eb
KL
111462001-02-18 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
11147
11148 * optimize.c (expand_call_inline): Don't walk subtrees of type
11149 nodes.
11150
69a59a49
MM
111512001-02-18 Mark Mitchell <mark@codesourcery.com>
11152
11153 * class.c (add_vcall_offset_vtbl_entries_1): Only add one entry
11154 for a destructor.
11155
e0fff4b3
JM
111562001-02-18 Jason Merrill <jason@redhat.com>
11157
11158 Do put the VTT parameter in DECL_ARGUMENTS.
11159 * cp-tree.h (struct cp_language_function): Add x_vtt_parm.
11160 (current_vtt_parm): New macro.
11161 (struct lang_decl_flags): Add has_vtt_parm_p, remove vtt_parm.
11162 (DECL_HAS_VTT_PARM_P): New macro.
11163 (DECL_VTT_PARM): Remove.
11164 (FUNCTION_FIRST_USER_PARMTYPE, FUNCTION_FIRST_USER_PARM): New macros.
11165 * decl.c (duplicate_decls): Only copy the operator code if
11166 appropriate.
11167 (start_function): Set current_vtt_parm.
11168 (lang_mark_tree): Don't mark vtt_parm.
9c96f3f8 11169 * decl2.c (maybe_retrofit_in_chrg): Do add the VTT parm to
e0fff4b3
JM
11170 DECL_ARGUMENTS. Set DECL_HAS_VTT_PARM_P.
11171 * class.c (build_clone): Maybe remove the VTT parm.
11172 * optimize.c (maybe_clone_body): Set up the VTT parm.
11173 * pt.c (copy_default_args_to_explicit_spec): Preserve the VTT parm.
11174 * call.c (build_over_call): Just allow the VTT arg.
11175 * method.c (make_thunk): Don't set DECL_VTT_PARM.
11176 (do_build_copy_constructor): Use FUNCTION_FIRST_USER_PARM.
11177 (synthesize_method): Use FUNCTION_FIRST_USER_PARMTYPE.
11178 * decl.c (grokdeclarator, copy_args_p, grok_ctor_properties): Likewise.
11179 * error.c (dump_function_decl): Likewise.
11180 * call.c (build_user_type_conversion_1, convert_like_real): Abort
11181 if we try to call a constructor with in-charge or VTT parms.
11182 * method.c (skip_artificial_parms_for): New fn.
11183 * call.c (add_function_candidate, build_over_call): Call it.
11184 * call.c (build_new_method_call): Use current_vtt_parm.
11185 * init.c (expand_virtual_init): Likewise.
11186 * class.c (same_signature_p): No longer static.
11187 * cp-tree.h: Declare it.
11188 * search.c (look_for_overrides_r): Use it.
11189
c750255c
MM
111902001-02-17 Mark Mitchell <mark@codesourcery.com>
11191
8fa33dfa
MM
11192 * cp-tree.h (new_abi_rtti_p): Remove.
11193 (name_mangling_version): Likewise.
11194 (flag_do_squangling): Likewise.
11195 * class.c (build_rtti_vtbl_entries): Remove old ABI support.
11196 * decl.c (grokfndecl): Likewise.
11197 * decl2.c (name_mangling_version): Remove.
11198 (flag_do_squangling): Likewise.
11199 (lang_f_options): Remove `squangle'.
11200 (unsupported_options): Add `squangle'.
11201 (cxx_decode_option): Issue a warning about uses of
11202 -fname-mangling-version.
11203 (finish_file): Remove old ABI support.
11204 * pt.c (check_explicit_specialization): Likewise.
11205 (tsubst_decl): Likewise.
11206 * rtti.c (init_rtti_processing): Likewise.
11207 (build_headof): Likewise.
11208 (get_tinfo_decl_dynamic): Likewise.
11209 (tinfo_from_decl): Likewise.
11210 (build_dynamic_cast_1): Likewise.
11211 (synthesize_tinfo_var): Likewise.
12fa82db
MM
11212 * init.c (build_new): Allow enumeration types for the array-bounds
11213 in a direct-new-declarator.
11214
11215 * semantics.c (finish_typeof): Resolve OFFSET_REFs.
11216
c750255c
MM
11217 * pt.c (check_explicit_specialization): Copy TREE_PRIVATE and
11218 TREE_PROTECTED from the template being specialized.
11219
a714e5c5
JM
112202001-02-17 Jason Merrill <jason@redhat.com>
11221
11222 * decl2.c (build_artificial_parm): Set TREE_READONLY.
11223
9c96f3f8 11224 * decl.c (bad_specifiers): Allow throw specs on things with
a714e5c5
JM
11225 pointer-to-function or -member-function type.
11226 * init.c (build_default_init): Don't use a CONSTRUCTOR to initialize
11227 a pmf.
11228
8084b91e
MM
112292001-02-17 Mark Mitchell <mark@codesourcery.com>
11230
11231 * call.c (check_dtor_name): Handle template names correctly.
11232
48f22ed2
JM
112332001-02-16 Jason Merrill <jason@redhat.com>
11234
11235 * cp-tree.h (DECL_USE_VTT_PARM): Remove.
11236 * decl2.c (maybe_retrofit_in_chrg): Don't create it.
11237 * optimize.c (maybe_clone_body): Don't substitute it.
11238 * call.c (build_new_method_call): Check in_chrg instead.
11239 * init.c (expand_virtual_init): Likewise.
11240
e8186ecf
GDR
112412001-02-16 Gabriel Dos Reis <gdr@codesourcery.com>
11242
11243 * decl.c (check_tag_decl): Make sure a typedef for an anonymous
11244 class-type introduces at least a type-name.
11245
2c1be322
JJ
112462001-02-16 Jakub Jelinek <jakub@redhat.com>
11247
11248 * call.c (convert_like_real): Create a temporary for non-lvalue.
11249
aab8454a
JO
112502001-02-16 Jeffrey Oldham <oldham@codesourcery.com>
11251
11252 * cp-tree.h: Fix typos in comments.
11253
a901fa64
JM
112542001-02-16 Jason Merrill <jason@redhat.com>
11255
11256 * optimize.c (remap_block): If we're compiling a clone, pass the
11257 new block to insert_block.
11258
8853373c
MM
112592001-02-16 Mark Mitchell <mark@codesourcery.com>
11260
11261 * semantics.c (finish_asm_stmt): Robustify.
11262
b60ecc04
MM
112632001-02-15 Mark Mitchell <mark@codesourcery.com>
11264
11265 * pt.c (push_template_decl_real): Don't remangle the name of a
11266 class template.
11267
e658449e
JM
112682001-02-15 Jim Meyering <meyering@lucent.com>
11269
fd48c9b5
DD
11270 * Make-lang.in (c++.install-common): Depend on installdirs.
11271 (c++.install-info): Likewise.
11272 (c++.install-man): Likewise.
e658449e 11273
f1a3f197
MM
112742001-02-15 Mark Mitchell <mark@codesourcery.com>
11275
11276 * typeck2.c (build_m_component_ref): Robustify.
11277
8826b15b
AO
112782001-02-15 Alexandre Oliva <aoliva@redhat.com>
11279
11280 * friend.c (do_friend): Don't take the nested [template] class
11281 into account when deciding whether to warn about the friend
11282 function not referring to a template function.
11283
7161c1a5
JJ
112842001-02-14 Jakub Jelinek <jakub@redhat.com>
11285
11286 * typeck.c (build_unary_op): Clarify error message.
11287
4806765e
AH
112882001-02-08 Aldy Hernandez <aldyh@redhat.com>
11289
a901fa64
JM
11290 * parse.y (component_constructor_declarator): allow optional
11291 parentheses around constructor class name.
4806765e 11292
bfc8e1e2
NS
112932001-02-14 Nathan Sidwell <nathan@codesourcery.com>
11294
11295 * cp-tree.h (setup_vtbl_ptr): Move prototype to semantics.c
11296 section.
11297 * init.c (emit_base_init): Remove incorrect comment about
11298 virtual bases.
11299 * method.c (make_thunk): Fix comment alignment.
11300
394fd776
NS
113012001-02-14 Nathan Sidwell <nathan@codesourcery.com>
11302
11303 Kill remnants of this is variable.
11304 * cp-tree.h (flag_this_is_variable): Remove.
11305 * decl2.c (flag_this_is_variable): Remove.
11306 * class.c (fixed_type_or_null): Add cdtor parm. Adjust.
11307 (build_vbase_path): The path is non-static, even in a cdtor.
11308 (resolves_to_fixed_type_p): Add additional return value.
11309 * search.c (init_vbase_pointers): Adjust.
11310 * tree.c (lvalue_p_1): Adjust.
11311 * typeck.c (mark_addressable): Adjust.
11312
d0ab7624
NS
113132001-02-14 Nathan Sidwell <nathan@codesourcery.com>
11314
11315 * pt.c (unify): Don't check cv quals of array types.
11316
7773899b
NS
113172001-02-14 Nathan Sidwell <nathan@codesourcery.com>
11318
11319 * tree.c (cp_build_qualified_type_real): Use CP_TYPE_QUALS to
11320 check whether we already have the type.
11321
52682a1b
MM
113222001-02-13 Mark Mitchell <mark@codesourcery.com>
11323
11324 * cp-tree.h (CLASSTYPE_DESTRUCTORS): Fix typo in comment.
11325 * call.c (build_op_delete_call): Simplify to remove duplicate
11326 code.
11327 * class.c (clone_function_decl): Don't build the deleting variant
11328 of a non-virtual destructor.
11329 * decl.c (finish_destructor_body): Don't call delete if this is a
11330 non-virtual destructor.
11331 * init.c (build_delete): Explicitly call `operator delete' when
11332 deleting an object with a non-virtual destructor.
9c96f3f8 11333
3b6bd115
JM
113342001-02-13 Jason Merrill <jason@redhat.com>
11335
11336 * lang-specs.h: Add more __EXCEPTIONS.
11337
45abaea8
NS
113382001-02-12 Nathan Sidwell <nathan@codesourcery.com>
11339
11340 * typeck2.c (process_init_constructor): Check
11341 TREE_HAS_CONSTRUCTOR before issuing missing init warning.
11342
996065b4
NS
113432001-02-12 Nathan Sidwell <nathan@codesourcery.com>
11344
11345 * pt.c (maybe_adjust_types_for_deduction, DEDUCE_ORDER case):
11346 Remove spurious information in comment. Allow further
11347 adjustments of REFERENCE_TYPE args.
11348
82c18d5c
NS
113492001-02-12 Nathan Sidwell <nathan@codesourcery.com>
11350
11351 * errfn.c (cp_deprecated): Tweak diagnostic text.
11352 * parse.y (new_initializer): Deprecate initializer lists
11353 extension.
11354
1f84ec23
MM
113552001-02-12 Mark Mitchell <mark@codesourcery.com>
11356
11357 Remove old ABI support.
11358
8c310e3f
MM
113592001-02-11 Mark Mitchell <mark@codesourcery.com>
11360
b1012f1b
MM
11361 * decl2.c (flag_vtable_thunks): Always set it to 1.
11362 (flag_new_abi): Likewise.
11363 * lang-specs.h: Remove conditional on ENABLE_NEW_GXX_ABI.
9c96f3f8 11364
8c310e3f
MM
11365 * Makefile.in (g++spec.o): Fix typo.
11366
3b635dfc
JM
113672001-02-09 Jason Merrill <jason@redhat.com>
11368
11369 * lang-specs.h: Restore definition of __EXCEPTIONS.
11370
bd0d5d4a
JM
113712001-02-08 Jason Merrill <jason@redhat.com>
11372
11373 * search.c (shared_member_p): New function.
11374 (lookup_field_r): Use it.
11375 * cp-tree.h (SHARED_MEMBER_P): Remove.
11376
11377 * method.c (process_overload_item): Handle template-dependent array
11378 bounds.
11379 * pt.c (type_unification_real): If we end up with undeduced nontype
11380 parms, try again.
11381
11382 * decl.c (lookup_name_real): Tweak warning to refer to decls, not
11383 types.
11384
11385 * typeck2.c (friendly_abort): Don't say anything if we have
11386 earlier errors or sorries.
11387
9c96f3f8 11388 * decl.c (check_tag_decl): Notice attempts to redefine bool and
bd0d5d4a
JM
11389 wchar_t. Ignore if in_system_header.
11390
11391 * decl.c (maybe_push_cleanup_level): New fn...
11392 (start_decl_1): ...split out from here.
11393 * cvt.c (build_up_reference): Use it.
11394 * cp-tree.h: Declare it.
11395
a9374841
MM
113962001-02-07 Mark Mitchell <mark@codesourcery.com>
11397
9c96f3f8 11398 * lang-specs.h: Use CPLUSPLUS_CPP_SPEC for the preprocessor
a9374841
MM
11399 spec.
11400
a87b4257
NS
114012001-02-06 Nathan Sidwell <nathan@codesourcery.com>
11402
11403 * pt.c (lookup_template_class): Make sure it's a primary
11404 template or template_template_parm when called from the parser.
11405 (instantiate_template_class): Add assertion.
11406
518fed76
AO
114072001-02-05 Alexandre Oliva <aoliva@redhat.com>
11408
11409 * method.c (build_mangled_name) [old abi]: Protect flush_repeats()
11410 from error_mark_node.
11411
9965d119
NS
114122001-02-05 Nathan Sidwell <nathan@codesourcery.com>
11413
11414 Fix specification and implementation bugs in V3 ABI
11415 construction vtables.
11416 * cp-tree.h (flag_dump_class_layout): New flag.
11417 (BINFO_OVERRIDE_ALONG_VIRTUAL_PATH_P): Remove.
11418 (BINFO_LOST_PRIMARY_P): New flag.
11419 (SET_BINFO_NEW_VTABLE_MARKED): Adjust asserts.
11420 (BINFO_PRIMARY_MARKED_P): Rename to ...
11421 (BINFO_PRIMARY_P): ... here.
11422 (binfo_via_virtual): New prototype.
11423 * decl2.c (flag_dump_class_layout): New flag.
11424 (cxx_decode_option): Set it. Adjust -fdump-translation-unit to
11425 use `=' as a file name separator.
11426 * init.c (dfs_initialize_vtbl_ptrs): Walk into virtual primary
11427 bases.
11428 (build_vtbl_address): If this is a virtual primary base, then
11429 get the vtbl of what it is ultimately primary for.
11430 * search.c (dfs_skip_nonprimary_vbases_unmarkedp): Adjust
11431 for BINFO_PRIMARY_P.
11432 (dfs_skip_nonprimary_vbases_markedp): Likewise.
11433 (get_shared_vbase_if_not_primary): Likewise.
11434 (dfs_get_pure_virtuals): Likewise.
11435 (expand_upcast_fixups): Likewise.
11436 (fixup_virtual_upcast_offsets): Likewise.
11437 (dfs_find_vbase_instance): Likewise.
11438 (find_vbase_instance): Likewise.
11439 (binfo_from_vbase): Adjust comment to reflect reality.
11440 (binfo_via_virtual): New function.
11441 * class.c (VTT_TOP_LEVEL_P, VTT_MARKED_BINFO_P): New macros
11442 for binfo walking during VTT construction.
11443 (dfs_mark_primary_bases): Remove.
11444 (force_canonical_binfo_r): New function.
11445 (force_canonical_binfo): New function.
11446 (mark_primary_virtual_base): New function.
11447 (mark_primary_bases): Walk in inheritance graph order, use
11448 mark_primary_virtual_base.
11449 (determine_primary_base): Use some more intermediate variables.
11450 (dfs_find_final_overrider): Don't check for overriding along a
11451 virtual path.
11452 (dfs_modify_vtables): Walk into primary virtual bases too.
11453 (walk_subobject_offsets): Adjust for BINFO_PRIMARY_P.
11454 (build_base_fields): Likewise.
11455 (dfs_set_offset_for_unshared_vbases): Likewise.
11456 (layout_virtual_bases): Likewise.
11457 (end_of_class): Likewise.
11458 (finish_struct_1): Call dump_class_hierarchy, if requested.
11459 (dfs_get_primary_binfo): Use BINFO_TYPE for binfos.
11460 (dump_class_hierarchy_r): Add stream parameter. Emit more information.
11461 (dump_class_hierarchy): Add file parameter. Append to file, if
11462 required.
11463 (finish_vtbls): Adjust accumulate_vtbl_inits call.
11464 Use canonical base for virtual bases.
11465 (build_vtt): Add more comments. Adjust build_vtt_inits call.
11466 (build_vtt_inits): Remove VIRTUAL_VTTS_P parm.
11467 Only set BINFO_VPTR_INDEX on top level. Use VTT_TOP_LEVEL_P,
11468 VTT_MARKED_BINFO_P for binfo walking. Use canonical vbase for
11469 virtual VTTs.
11470 (dfs_build_secondary_vptr_vtt_inits): Extract VTT_TOP_LEVEL_P
11471 from DATA. We want virtual primary bases and all bases via virtual.
11472 Only set BINFO_VPTR_INDEX for top level. Look up from a primary
11473 virtual base when not a construction vtable.
11474 (dfs_ctor_vtable_bases_queue_p): New DFS predicate.
11475 (build_ctor_vtbl_group): Adjust accumulate_vtbl_inits call.
11476 Use canonical bases when processing virtual bases.
11477 (accumulate_vtbl_inits): We're interested in any base via a
11478 virtual path.
11479 (dfs_accumulate_vtbl_inits): If this is a primary virtual base
11480 within a construction vtable, determine what is being overridden.
11481 (build_vtbl_initializer): Add more comments
11482 (add_vcall_offset_vtbl_entries_1): Adjust comment.
11483 (build_rtti_vtbl_entries): Check if the base has lost its
11484 primary.
11485
39d6f2e8
MM
114862001-02-05 Mark Mitchell <mark@codesourcery.com>
11487
11488 * Makefile.in (g++spec.o): Adjust use of DRIVER_DEFINES.
11489
d2a6f3c0 114902001-02-04 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
400500c4
RK
11491
11492 * decl.c (pushdecl): Call abort instead of fatal.
11493 * except.c (decl_is_java_type): Call fatal_error instead of fatal.
11494 * init.c (build_new_1): Likewise.
11495 (build_java_class_ref): Call internal_error and fatal_error, not fatal.
11496 * decl.c (build_typename_type): hash_table_init now returns void.
11497 decl.c (init_decl_processing): Make an error non-fatal.
11498
97458258
MM
114992001-02-04 Mark Mitchell <mark@codesourcery.com>
11500
11501 * cp-tree.h (CLASSTYPE_INTERFACE_UNKNOWN): Fix formatting.
11502 Document.
11503 (CLASSTYPE_INTERFACE_KNOWN): Likewise.
11504 (SET_CLASSTYPE_INTERFACE_UNKNOWN_X): Likewise.
11505 (SET_CLASSTYPE_INTERFACE_UNKNOWN): Likewise.
11506 (SET_CLASSTYPE_INTERFACE_KNOWN): Likewise.
11507 * decl.c (maybe_commonize_var): Use the new name-mangling where
11508 appropriate.
11509 * decl2.c (comdat_linkage): Enhance comments. Make all
11510 compiler-generated things static, if COMDAT is not available.
11511 (get_tinfo_decl): Do not make typeinfo objects that belong in the
11512 library COMDAT.
11513 (tinfo_base_init): Use the correct mangled name for typeinfo
11514 strings, and push them into the global scope.
11515 (typeinfo_in_lib_p): New function.
11516 (synthesize_tinfo_var): Use it.
11517 (create_real_tinfo_var): Likewise.
9c96f3f8 11518
55de1b66
JJ
115192001-02-03 Jakub Jelinek <jakub@redhat.com>
11520
11521 * decl.c (push_class_binding): Use context_for_name_lookup instead
11522 of CP_DECL_CONTEXT.
11523 * search.c (context_for_name_lookup): Remove static. Check for NULL
11524 context in the loop.
11525 * cp-tree.h (context_for_name_lookup): Add prototype.
11526
e92730aa
JJ
115272001-02-02 Jakub Jelinek <jakub@redhat.com>
11528
11529 * cp-tree.h (build_expr_ptr_wrapper, can_free): Remove.
11530 * tree.c (build_expr_ptr_wrapper, can_free, permanent_obstack):
11531 Remove.
11532 * call.c (convert_class_to_reference, build_user_type_conversion_1,
11533 add_warning): Change build_expr_ptr_wrapper to build_ptr_wrapper.
11534
049f6ec9
MM
115352001-02-02 Mark Mitchell <mark@codesourcery.com>
11536
11537 * Make-lang.in (g++spec.o): Add DRIVER_DEFINES to the list
11538 of macros used when compiling g++spec.c.
11539 * g++spec.c (lang_specific_driver): Link with the shared
11540 libgcc by default.
11541
718b8ea5
JM
115422001-01-29 Joseph S. Myers <jsm28@cam.ac.uk>
11543
11544 * decl2.c (build_expr_from_tree), lex.c (make_pointer_declarator,
11545 make_reference_declarator, make_call_declarator), method.c
11546 (implicitly_declare_fn), parse.y (namespace_using_decl,
11547 notype_unqualified_id, expr_or_declarator, new_type_id,
11548 after_type_declarator, direct_after_type_declarator,
11549 notype_declarator, complex_notype_declarator,
11550 complex_direct_notype_declarator, qualified_id,
11551 notype_qualified_id, overqualified_id, direct_new_declarator,
11552 absdcl, direct_abstract_declarator, conversion_declarator), pt.c
11553 (tsubst), semantics.c (begin_constructor_declarator): Use build_nt
11554 instead of build_parse_node.
11555
f2d1f0ba
KG
115562001-01-28 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11557
11558 * cp-tree.h (cp_tree_index): Delete CPTI_MINUS_ONE.
11559 (minus_one_node): Moved to top level gcc directory. Renamed
11560 to integer_minus_one_node.
11561
11562 * init.c (init_init_processing): Don't set minus_one_node.
11563 (build_vec_init): Use integer_minus_one_node.
11564
11565 * rtti.c (get_tinfo_decl_dynamic): Likewise.
11566
6001735e
JJ
115672001-01-28 Jakub Jelinek <jakub@redhat.com>
11568
11569 * optimize.c (copy_body_r): If MODIFY_EXPR has both arguments
11570 identical and they would be replaced with constant, remove
11571 MODIFY_EXPR from the tree.
11572
c913b6f1
KG
115732001-01-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11574
11575 * Make-lang.in: Remove all dependencies on defaults.h.
11576 * call.c: Don't include defaults.h.
11577 * decl.c: Likewise.
11578 * decl2.c: Likewise.
11579 * except.c: Likewise.
11580 * pt.c: Likewise.
11581 * rtti.c: Likewise.
11582 * tree.c: Likewise.
11583 * typeck.c: Likewise.
11584
324ffb8c
JJ
115852001-01-25 Jakub Jelinek <jakub@redhat.com>
11586
11587 * mangle.c (write_mangled_name, write_encoding): Mangle overloaded
11588 operators even in "C" linkage.
11589 * method.c (set_mangled_name_for_decl): Likewise.
11590 * decl.c (grokfndecl): Call set_mangled_name_for_decl even for
11591 overloaded operators in "C" linkage.
11592
4b2811e9
NS
115932001-01-24 Nathan Sidwell <nathan@codesourcery.com>
11594
11595 * pt.c (tsubst_decl): Remove IN_DECL parameter.
11596 (tsubst_arg_types): Check parameter is not void.
11597 (tsubst): Adjust tsubst_decl call.
11598
d8caf48e
NS
115992001-01-24 Nathan Sidwell <nathan@codesourcery.com>
11600
11601 * call.c (add_builtin_candidate): Quote std properly, from
11602 previous change.
11603
08511114
KL
116042001-01-23 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
11605
11606 * pt.c (check_explicit_specialization): Clone constructors and
11607 destructors.
11608
92ecdfb7
NS
116092001-01-23 Nathan Sidwell <nathan@codesourcery.com>
11610
11611 * decl.c (grokdeclarator): Don't presume DECL_LANG_SPECIFIC
11612 indicates anything special about template depth. Make sure we
11613 only count the user visible template classes.
11614
4cff6abe
NS
116152001-01-23 Nathan Sidwell <nathan@codesourcery.com>
11616
11617 * call.c (build_conv): Typo in comment.
11618 (add_builtin_candidate): Add more explanation.
11619 Remove extra test for ENUMERAL_TYPE in {PRE,POST}INCREMENT_EXPR.
11620 Allow ENUMERAL_TYPEs for relops and eqops. Add both candidates
11621 when we have enumeral types.
11622 (add_builtin_candidates): Add more explanation. Add ENUMERAL_TYPE
11623 candidates for relops and eqops.
11624 (joust): Simplify control flow. Allow a non-template user
11625 function to hide a builtin.
11626
62e4a758
NS
116272001-01-22 Nathan Sidwell <nathan@codesourcery.com>
11628
11629 * cp-tree.h (unification_kind_t): Add DEDUCE_ORDER.
11630 (more_specialized): Add deduction parameter.
11631 * call.c (joust): Adjust more_specialized call.
11632 * pt.c (UNIFY_ALLOW_OUTER_MORE_CV_QUAL,
11633 UNIFY_ALLOW_OUTER_LESS_CV_QUAL): New unify flags.
11634 (get_bindings_order): Remove.
11635 (get_bindings_real): Add DEDUCE parameter.
11636 (maybe_adjust_types_for_deduction): Return extra unify flags. Do
11637 REFERENCE_TYPE jig for DEDUCE_ORDER.
11638 (type_unification_real): Deal with DEDUCE_ORDER. Use result of
11639 maybe_adjust_types_for_deduction.
11640 (more_specialized): Add DEDUCE parameter. Call get_bindings_real
11641 directly.
11642 (try_one_overload): Use result of maybe_adjust_types_for_deduction.
11643 (check_cv_quals_for_unify): Use new unify qualifier flags.
11644 (unify): Clear new unify qualifier flags.
11645 (get_bindings_real): Add DEDUCE parameter.
11646 (get_bindings): Adjust call to get_bindings_real.
11647 (get_bindings_overload): Likewise.
11648 (most_specialized_instantiation): Adjust call to
11649 more_specialized.
11650
2a2a9e5a
JM
116512001-01-19 Jason Merrill <jason@redhat.com>
11652
11653 * decl2.c (flag_vtable_thunks): Also depend on ENABLE_NEW_GXX_ABI.
11654
11655 * decl.c (init_decl_processing): Just force -fvtable-thunks on if
11656 -fnew-abi.
11657
60696c53
JM
116582001-01-19 Ute Pelkmann <scope.muc@t-online.de>
11659
11660 * decl2.c (arg_assoc_class): Fix double iteration logic.
11661
116622001-01-19 Jason Merrill <jason@redhat.com>
11663
11664 * init.c (build_delete): Always call convert_force to strip cv-quals.
11665
11666 * decl2.c (flag_new_abi): Depend on ENABLE_NEW_GXX_ABI.
11667 * lang-specs.h: Default ABI depends on ENABLE_NEW_GXX_ABI.
11668 * g++spec.c: Don't look at ENABLE_NEW_GXX_ABI.
11669
1e00f18c
NS
116702001-01-19 Nathan Sidwell <nathan@codesourcery.com>
11671
11672 * search.c (get_vbase_1): Count only virtual bases.
11673
e13bced2
NS
116742001-01-19 Nathan Sidwell <nathan@codesourcery.com>
11675
11676 * class.c (duplicate_tag_error): Robustify flag clearing.
11677
f9c244b8
NS
116782001-01-19 Nathan Sidwell <nathan@codesourcery.com>
11679
11680 * cp-tree.h (lookup_template_class): Add complain parm.
11681 * decl.c (lookup_namespace_name): Adjust call to
11682 lookup_template_class.
11683 (make_typename_type): Likewise.
11684 * semantics.c (finish_template_type): Likewise.
11685 * pt.c (lookup_template_class): Add complain parm. Adjust.
11686 (tsubst_aggr_type): Pass COMPLAIN down to lookup_template_class.
11687 (tsubst): Likewise.
11688
08c2df0f
NS
116892001-01-19 Nathan Sidwell <nathan@codesourcery.com>
11690
11691 * pt.c (copy_default_args_to_explicit_spec): Preserve
11692 object's CV quals. Reorganize.
11693
f5ceeec8
NS
116942001-01-18 Nathan Sidwell <nathan@codesourcery.com>
11695
11696 * typeck.c (build_modify_expr): Say `initialization' for
11697 INIT_EXPRs.
11698 * init.c (build_default_init): Convert to enumeral type, if
11699 needed.
11700
a1cfa434
JJ
117012001-01-18 Jakub Jelinek <jakub@redhat.com>
11702
11703 * parse.y (nomods_initdcl0): Properly set things up for
11704 initdcl0_innards.
11705
028d1f20
NS
117062001-01-18 Nathan Sidwell <nathan@codesourcery.com>
11707
11708 * pt.c (UNIFY_ALLOW_OUTER_LEVEL): New unify flag.
11709 (type_unification_real): Set it.
11710 (unify): Use it.
11711
9f724b6a
NS
117122001-01-18 Nathan Sidwell <nathan@codesourcery.com>
11713
11714 * decl.c (finish_destructor_body): Convert to vbase pointer here.
11715
522d6614
NS
117162001-01-18 Nathan Sidwell <nathan@codesourcery.com>
11717
11718 * semantics.c (begin_class_definition): Check we're not inside a
11719 template parm list.
11720
7f805b8f
NS
117212001-01-18 Nathan Sidwell <nathan@codesourcery.com>
11722
11723 * tree.c (walk_tree, TREE_LIST): Don't walk the TREE_PURPOSE of
11724 BASELINK_P.
11725
dc3799c1
KL
117262001-01-16 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
11727
11728 * typeck.c (build_function_call_real): Call fold on the CALL_EXPR.
11729 * call.c (build_over_call): Add comment.
11730
bb37c4a5
DB
117312001-01-16 Daniel Berlin <dberlin@redhat.com>
11732
826840d9
RH
11733 * cvt.c (ocp_convert): Handle vector type conversion
11734 * typeck2.c (digest_init): Handle vector type initializations
9c96f3f8 11735
a26e7fb5
PE
117362001-01-16 Phil Edwards <pme@sources.redhat.com>
11737
11738 * g++spec.c: Don't add libraries needlessly if -fsyntax-only
11739 was given.
11740
11b810f1
NS
117412001-01-15 Nathan Sidwell <nathan@codesourcery.com>
11742
11743 * pt.c (check_nontype_parm): Rename to ...
11744 (invalid_nontype_parm_type_p): ... here.
11745 (process_template_parm): Adjust.
11746 (convert_template_argument): Adjust.
11747
db3f4e4e
NS
117482001-01-15 Nathan Sidwell <nathan@codesourcery.com>
11749
11750 * pt.c (check_nontype_parm): New function.
11751 (process_template_parm): Use it.
11752 (convert_template_argument): Use it.
11753 (convert_nontype_argument, RECORD_TYPE): Assert it's a ptr to
11754 member.
11755
ea4f1fce
JO
117562001-01-14 Jeffrey Oldham <oldham@codesourcery.com>
11757
11758 * tree.c: Add defaults.h
11759 (cp_valid_lang_attribute): Incorporate SUPPORTS_INIT_PRIORITY.
11760 * Make-lang.in (cp/tree.o): Add defaults.h.
11761
1312c143
JM
117622001-01-13 Joseph S. Myers <jsm28@cam.ac.uk>
11763
11764 * Make-lang.in (CXX_C_OBJS): Add c-format.o.
11765
4bc1997b
JM
117662001-01-13 Joseph S. Myers <jsm28@cam.ac.uk>
11767
11768 * g++.1: Change to be ".so man1/gcc.1".
11769
23de1fbf
JM
117702001-01-13 Joseph S. Myers <jsm28@cam.ac.uk>
11771
11772 * Make-lang.in (c++.info, c++.install-info): Build and install g++
11773 internals info.
11774 (c++.uninstall, c++.maintainer-clean): Remove g++ internals info.
11775 ($(srcdir)/cp/g++int.info): New target.
11776 * gxxint.texi: Add info directory entry. Use @@ in email address.
11777 * .cvsignore: Update.
11778
0949f723
NS
117792001-01-12 Nathan Sidwell <nathan@codesourcery.com>
11780
11781 * typeck.c (build_c_cast): Do template processing earlier.
11782 Always pedwarn on array casts.
11783
a8641661
NS
117842001-01-12 Nathan Sidwell <nathan@codesourcery.com>
11785
11786 * friend.c (make_friend_class): Make sure a templated class is
11787 actually a template.
11788
844511c8
NS
117892001-01-11 Nathan Sidwell <nathan@codesourcery.com>
11790
11791 * decl2.c (get_guard): Set linkage from guarded decl.
11792
96a1e32d
NS
117932001-01-11 Nathan Sidwell <nathan@codesourcery.com>
11794
11795 * call.c (convert_default_arg): Check for unprocessed
11796 DEFAULT_ARG.
11797 * cp-tree.h (replace_defarg): Move to spew.c.
11798 (maybe_snarf_defarg, add_defarg_fn, do_pending_defargs): Move to
11799 spew.c, which is where they really are.
11800 (done_pending_defargs): Declare.
11801 (unprocessed_defarg_fn): Declare.
11802 * decl.c (replace_defarg): Move to spew.c
11803 * parse.y (structsp): Call done_pending_defargs.
11804 * spew.c (defarg_fns): Rearrange list structure.
11805 (defarg_fnsdone): New static variable.
11806 (defarg_depfns): New static variable.
11807 (init_spew): Adjust.
11808 (add_defarg_fn): Store the type in TREE_TYPE.
11809 (do_pending_defargs): Detect and deal with ordering constraints
11810 and circularity.
11811 (done_pending_defargs): New function.
11812 (unprocessed_defarg_fn): New function.
11813 (replace_defarg): Moved from decl.c. Robustify. Don't save
11814 if circularity detected.
11815
34e225a3
NS
118162001-01-11 Nathan Sidwell <nathan@codesourcery.com>
11817
11818 * pt.c (unify): Check array has a domain, before checking
11819 whether it is variable sized.
11820
98979fe0
NS
118212001-01-11 Nathan Sidwell <nathan@codesourcery.com>
11822
11823 * decl.c (grokparms): Unobfuscate and get correct diagnostic for
11824 parameters with pointers to arrays of unknown bound.
11825
b37bf5bd
NS
118262001-01-11 Nathan Sidwell <nathan@codesourcery.com>
11827
11828 * parse.y (template_parm_header, template_spec_header): New
11829 reductions. Split out from ...
11830 (template_header): ... here. Use them.
11831 (template_template_parm): Use template_parm_header.
11832 * semantics.c (finish_template_template_parm): Add assert.
11833
6c418184
MM
118342001-01-10 Mark Mitchell <mark@codesourcery.com>
11835
792508b5
MM
11836 * mangle.c (write_builtin_type): Fix thinko.
11837
8afa707f
MM
11838 * pt.c (copy_default_args_to_explicit_spec_1): New function.
11839 (copy_default_args_to_explicit_spec): Likewise.
11840 (check_explicit_specialization): Use it.
11841
6c418184
MM
11842 * class.c (finish_struct_1): Remove last argument in call to
11843 make_decl_rtl; use make_function_rtl instead of make_decl_rtl.
11844 * decl.c (builtin_function): Likewise.
11845 (build_cp_library_fn): Likewise.
11846 (check_initializer): Likewise.
11847 (make_rtl_for_nonlocal_decl): Likewise.
11848 (cp_finish_decl): Likewise.
11849 (start_function): Likewise.
11850 * decl2.c (finish_anon_union): Likewise.
11851 * friend.c (do_friend): Likewise.
11852 * init.c (build_java_class_ref): Likewise.
11853 * method.c (make_thunk): Likewise.
11854 * pt.c (tsubst_friend_function): Likewise.
11855 * semantics.c (expand_body): Likewise.
11856
31d95fc6
MM
118572001-01-10 Mark Mitchell <mark@codesourcery.com>
11858
11859 * cp-tree.h (DECL_CLONED_FUNCTION_P): Avoid wild reads by not
11860 looking at DECL_CLONED_FUNCTION for non-functions.
11861
31bb3027
NS
118622001-01-10 Nathan Sidwell <nathan@codesourcery.com>
11863
11864 * error.c (dump_template_parameter): Use parm to determine how
11865 to print default value.
11866
fd3f43e7
NS
118672001-01-10 Nathan Sidwell <nathan@codesourcery.com>
11868
11869 * class.c (duplicate_tag_error): Clear more flags.
11870
042b4c4e
NS
118712001-01-10 Nathan Sidwell <nathan@codesourcery.com>
11872
11873 * call.c (build_new_method_call): Use binfo_for_vbase.
11874
a7537031
JM
118752001-01-10 Joseph S. Myers <jsm28@cam.ac.uk>
11876
11877 * cp-tree.h (flag_cond_mismatch): Don't declare.
11878 * decl2.c (flag_cond_mismatch): Don't define.
11879 (lang_f_options): Remove cond-mismatch.
11880 (unsupported_options): Add cond-mismatch.
11881
186c0fbe
NS
118822001-01-09 Nathan Sidwell <nathan@codesourcery.com>
11883
11884 * class.c (handle_using_decl): Reject using of constructor name
11885 of sourcing class. Allow injecting of a method with same name as
11886 nested class. Fixup error messages.
11887
28ec8d6b
JM
118882001-01-09 Joseph S. Myers <jsm28@cam.ac.uk>
11889
11890 * decl2.c (lang_decode_option): Handle -Wformat=2.
11891
3febd123
NS
118922001-01-08 Nathan Sidwell <nathan@codesourcery.com>
11893
11894 * cp-tree.h (lang_decl_flags): Rename defined_in_class to
11895 initialized_in_class.
11896 (DECL_DEFINED_IN_CLASS_P): Rename to ...
11897 (DECL_INITIALIZED_IN_CLASS_P): ... here, to reflect true meaning.
11898 * decl.c (duplicate_decls): Preseve DECL_INITIALIZED_IN_CLASS_P.
11899 (cp_finish_decl): Adjust for DECL_INITIALIZED_IN_CLASS_P.
11900 * pt.c (check_default_tmpl_args): Adjust for
11901 DECL_INITIALIZED_IN_CLASS_P.
11902 (instantiate_class_template): Likewise.
11903 (instantiate_decl): Check DECL_INITIALIZED_IN_CLASS_P.
9c96f3f8 11904
3febd123
NS
11905 * class.c (finish_struct): Constify saved_filename.
11906
1f0d71c5
NS
119072001-01-08 Nathan Sidwell <nathan@codesourcery.com>
11908
11909 * class.c (duplicate_tag_error): Adjust diagnostic.
11910 (finish_struct): Locally set location to start of struct.
11911 * decl.c (fixup_anonymous_aggr): Use cp_error_at.
11912
5bf15e84 119132001-01-08 Nathan Sidwell <nathan@codesourcery.com>
76191fdd
NS
11914
11915 * decl.c (struct binding_level): Adjust class_shadowed comments
11916 to reflect reality.
aba649ba 11917 (push_class_level_binding): Adjust comments to reflect reality.
76191fdd
NS
11918 Set IDENTIFIER_CLASS_VALUE when replacing an existing binding.
11919 Don't set TREE_VALUE on the class_shadowed list.
11920
23d4e4cc 119212001-01-07 Alexandre Petit-Bianco <apbianco@cygnus.com>
9c96f3f8
AJ
11922
11923 * decl2.c (acceptable_java_type): Allow references too.
23d4e4cc
APB
11924 * init.c (build_java_class_ref): When using the new ABI, search
11925 `class$' and have it mangled with `mangle_decl.'
11926 * mangle.c (write_java_integer_type_codes): New function.
11927 (write_builtin_type): Detect and mangle Java integer and real
11928 types.
9c96f3f8 11929
0c58da3e
MM
119302001-01-07 Mark Mitchell <mark@codesourcery.com>
11931
11932 * decl2.c (grokfield): Don't accept `asm' specifiers for
11933 non-static data members.
11934
45b8ddb4
KG
119352001-01-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
11936
11937 * expr.c (cplus_expand_expr): Don't reset `target'.
11938
96302433
NB
119392001-01-07 Neil Booth <neil@daikokuya.demon.co.uk>
11940
826840d9 11941 * cp/decl2.c (cxx_post_options): Call cpp_post_options.
96302433 11942
220bce48
NS
119432001-01-05 Nathan Sidwell <nathan@codesourcery.com>
11944
11945 * parse.y (template_datadef): Check for error_mark_node.
11946
bfa2cb33
NS
119472001-01-05 Nathan Sidwell <nathan@codesourcery.com>
11948
11949 * cp-tree.def (DEFAULT_ARG): Make `x' class.
11950
eaa7c03f
JM
119512001-01-04 Joseph S. Myers <jsm28@cam.ac.uk>
11952
11953 * decl.c (SIZE_TYPE, PTRDIFF_TYPE, WCHAR_TYPE): Don't define.
11954 (record_builtin_type): Make non-static.
11955 (flag_short_double): Don't declare.
11956 (init_decl_processing): Remove the creation of many tree nodes now
11957 in c_common_nodes_and_builtins.
11958 (build_void_list_node): New function.
11959 * decl2.c (flag_short_double, flag_short_wchar): Don't define.
11960 * cp-tree.h (flag_short_wchar): Don't declare.
11961
3af4c257
MM
119622001-01-04 Mark Mitchell <mark@codesourcery.com>
11963
11964 * call.c (build_conv): Don't use build1 for USER_CONV.
11965 * pt.c (tsubst_copy): Or for PREINCREMENT_EXPR and similar nodes.
11966
03dc0325
JM
119672001-01-03 Joseph S. Myers <jsm28@cam.ac.uk>
11968
11969 * lex.c (lang_init): Call c_common_lang_init.
11970
3c505507
NS
119712001-01-03 Nathan Sidwell <nathan@codesourcery.com>
11972
11973 * search.c (lookup_fnfields_here): Remove.
11974 (look_for_overrides_r): Use lookup_fnfields_1.
11975 Ignore functions from using declarations.
11976
03378143
NS
119772001-01-03 Nathan Sidwell <nathan@codesourcery.com>
11978
11979 Implement exceptions specifiers for implicit member functions.
11980 * cp-tree.h (merge_exceptions_specifiers): Declare new function.
11981 * method.c (synthesize_exception_spec): New function.
11982 (locate_dtor, locate_ctor, locate_copy): New functions.
11983 (implicitly_declare_fn): Generate the exception spec too.
11984 * search.c (check_final_overrider): Check artificial functions
11985 too.
9c96f3f8 11986 * typeck2.c (merge_exception_specifiers): New function.
03378143 11987
f30efcb7
JM
119882001-01-03 Jason Merrill <jason@redhat.com>
11989
11990 * init.c (build_default_init): New fn.
11991 (perform_member_init): Split out from here.
11992 (build_new_1): Use it. Simplify initialization logic.
11993 (build_vec_init): Take an array, rather than a pointer and maxindex.
11994 Speed up simple initializations. Don't clean up if we're assigning.
11995 * cp-tree.h: Adjust.
11996 * decl2.c (do_static_initialization): Remove TREE_VEC case.
11997 * parse.y (new_initializer): Return void_zero_node for ().
11998 * typeck.c (build_modify_expr): Handle getting a CONSTRUCTOR.
11999 * typeck2.c (digest_init): Only complain about user-written
12000 CONSTRUCTORs.
12001
a412bf75
MS
120022000-12-22 Mike Stump <mrs@wrs.com>
12003
12004 * decl2.c: (max_tinst_depth): Increase to 50.
12005
4890c2f4
MM
120062001-01-02 Mark Mitchell <mark@codesourcery.com>
12007
12008 * class.c (invalidate_class_lookup_cache): Zero the
12009 previous_class_values.
12010 * cp-tree.h (TMPL_PARMS_DEPTH): Use TREE_INT_CST_LOW, not
12011 TREE_INT_CST_HIGH.
12012 (CLASSTYPE_TEMPLATE_LEVEL): Likewise.
12013 * decl.c (free_bindings): New variable.
12014 (push_binding): Don't create a new binding if we have one on the
12015 free list.
12016 (pop_binding): Put old bindings on the free list.
12017 (init_decl_processing): Use size_int, not build_int_2.
12018 Register free_bindings as a GC root.
12019 (cp_make_fname_decl): Use size_int, not build_int_2.
12020 (push_inline_template_parms_recursive): Likewise.
12021 (end_template_parm_list): Likewise.
688f6688 12022 (for_each_template_parm): Do not use walk_tree_without_duplicates.
4890c2f4
MM
12023 (tsubst_template_parms): Use size_int, not build_int_2.
12024 (tsubst): Likewise.
12025 * rtti.c (get_vmi_pseudo_type_info): Likewise.
9c96f3f8 12026
4f78b9a8
RH
120272001-01-02 Richard Henderson <rth@redhat.com>
12028
12029 * parse.y (asm): Set ASM_INPUT_P.
12030
3c8c2a0a
JM
120312001-01-02 Jason Merrill <jason@redhat.com>
12032
96d6c610
JM
12033 * tree.c (cp_valid_lang_attribute): Don't set CLASSTYPE_COM_INTERFACE
12034 for v3 ABI.
12035
12036 * typeck.c (cp_truthvalue_conversion): New fn.
12037 * cvt.c (ocp_convert): Use it.
12038
12039 * cp-tree.h: Lose c-common.c decls.
12040
12041 * typeck.c (build_unary_op): Restore old &a.f diagnostic code.
12042 * cvt.c (convert_to_void): Use type_unknown_p.
12043
9c96f3f8 12044 * typeck.c (strip_all_pointer_quals): Also strip quals from
3c8c2a0a
JM
12045 pointer-to-member types.
12046
12047 * Make-lang.in (cp/TAGS): Use --no-globals. Ignore parse.c, and treat
12048 parse.y as C.
12049
12050 * call.c (build_new_method_call): Do evaluate the object parameter
12051 when accessing a static member.
12052 * typeck.c (build_component_ref): Likewise.
12053
d363e7bf
AJ
120542001-01-02 Andreas Jaeger <aj@suse.de>
12055
12056 * decl.c (cp_missing_noreturn_ok_p): New.
12057 (init_decl_processing): Set lang_missing_noreturn_ok_p.
12058
77f5250d
JJ
120592000-12-29 Jakub Jelinek <jakub@redhat.com>
12060
12061 * decl.c (init_decl_processing): Fix sign of wchar_type_node.
12062
31a714f6
MM
120632000-12-29 Mark Mitchell <mark@codesourcery.com>
12064
12065 * class.c (pushclass): Remove #if 0'd code.
12066 * cp-tree.h (overload_template_name): Remove.
12067 * decl.c (store_bindings): Simplify.
12068 (pop_from_top_level): Likewise.
12069 * pt.c (overload_template_name): Remove.
d363e7bf 12070 (instantiate_decl): Don't call push_to_top_level if it's not
31a714f6
MM
12071 needed.
12072
414ea4aa
MM
120732000-12-28 Mark Mitchell <mark@codesourcery.com>
12074
12075 * pt.c (register_local_specialization): Don't return a value.
12076 (lookup_template_class): Use move-to-front heuristic when looking
12077 up template instantiations.
12078 (instantiate_decl): Only push_to_top_level when we're actually
12079 going to instantiate the template.
12080
6f18f7e9
HPN
120812000-12-29 Hans-Peter Nilsson <hp@bitrange.com>
12082
12083 * search.c (binfo_for_vtable): Return least derived class, not
12084 most. Handle secondary vtables.
12085
e5214479
JM
120862000-12-22 Jason Merrill <jason@redhat.com>
12087
3c8c2a0a
JM
12088 * pt.c (more_specialized): Don't optimize len==0.
12089 (fn_type_unification): If we're adding the return type, increase len.
12090
ebb1abc3
JM
12091 * typeck.c (build_binary_op): Fix pmf comparison logic.
12092
c939ca5f
JM
12093 * call.c (joust): Use DECL_NONSTATIC_MEMBER_FUNCTION_P, not
12094 DECL_STATIC_FUNCTION_P.
12095
e6fe680d
JM
12096 * semantics.c (genrtl_finish_function): Don't try to jump to
12097 return_label unless it exists.
12098
e5214479
JM
12099 In partial ordering for a call, ignore parms for which we don't have
12100 a real argument.
12101 * call.c (joust): Pass len to more_specialized.
12102 (add_template_candidate_real): Strip 'this', pass len.
12103 * pt.c (more_specialized): Pass len down. Lose explicit_args parm.
12104 (get_bindings_order): New fn. Pass len down.
12105 (get_bindings_real): Strip 'this', pass len.
12106 (fn_type_unification): Likewise.
12107 (type_unification_real): Succeed after checking 'len' args.
12108 (most_specialized_instantiation): Lose explicit_args parm.
d363e7bf 12109 * class.c (resolve_address_of_overloaded_function): Strip 'this',
e5214479
JM
12110 pass len.
12111
121122000-12-21 Jason Merrill <jason@redhat.com>
477f6664
JM
12113
12114 * pt.c (tsubst_decl): A FUNCTION_DECL has DECL_RESULT, not
12115 DECL_TEMPLATE_RESULT.
12116
12117 * search.c (lookup_field_r): Call lookup_fnfields_1, not
12118 lookup_fnfields_here.
12119
12120 * parse.y (typename_sub2): Return the TYPE_DECL, not the type.
12121
12122 * call.c (build_object_call): Also allow conversions that return
12123 reference to pointer to function.
12124 (add_conv_candidate): Handle totype being ref to ptr to fn.
12125 (build_field_call): Also allow members of type reference to function.
12126 Lose support for calling pointer to METHOD_TYPE fields.
12127
12128 * error.c (dump_expr): Handle *_CAST_EXPR.
12129
12130 * typeck2.c (build_scoped_ref): Always convert to the naming class.
12131
12132 * tree.c (break_out_cleanups): Lose.
12133 * cp-tree.h: Remove prototype.
12134 * typeck.c (build_component_ref): Don't break_out_cleanups.
12135 (build_compound_expr): Likewise.
12136 * semantics.c (finish_expr_stmt): Likewise.
12137
3e4d04a1
RH
121382000-12-20 Richard Henderson <rth@redhat.com>
12139
12140 * cp-tree.h: Update declarations.
12141 * decl.c (finish_case_label): Return the new stmt node.
12142 * semantics.c (finish_goto_stmt): Likewise.
12143 (finish_expr_stmt, finish_return_stmt): Likewise.
12144 (finish_break_stmt, finish_continue_stmt): Likewise.
12145 (finish_asm_stmt): Likewise.
12146 * parse.y (already_scoped_stmt): Set STMT_LINENO.
12147 (compstmt, implicitly_scoped_stmt, stmt): Likewise.
12148 (simple_if, simple_stmt): Return the new stmt node.
12149 (save_lineno): New.
12150
20d380b1
JM
121512000-12-18 Joseph S. Myers <jsm28@cam.ac.uk>
12152
12153 * cp-tree.h: Don't declare warn_long_long.
12154
221c7a7f
KL
121552000-12-15 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
12156
12157 * tree.c (no_linkage_helper): Use CLASS_TYPE_P instead of
12158 IS_AGGR_TYPE.
12159
b429fdf0
KL
121602000-12-15 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
12161
12162 * pt.c (unify): Handle when both ARG and PARM are
12163 BOUND_TEMPLATE_TEMPLATE_PARM.
12164
c2beae77
KL
121652000-12-15 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
12166
12167 * pt.c (reduce_template_parm_level): Set DECL_ARTIFICIAL and
12168 DECL_TEMPLATE_PARM_P.
12169
c3e899c1
JM
121702000-12-15 Jason Merrill <jason@redhat.com>
12171
96790071
JM
12172 * init.c (build_new_1): Reorganize. Now with 100% fewer SAVE_EXPRs!
12173
8d42565b
JM
12174 * init.c (build_new_1): Don't strip quals from type.
12175
fab09a24
JM
12176 * decl.c (pushdecl): Don't check for linkage on a non-decl.
12177
c3e899c1
JM
12178 * call.c (build_op_delete_call): See through ARRAY_TYPEs.
12179
12180 * call.c (build_new_function_call): Lose space before paren in
12181 error message.
12182 (build_new_method_call): Likewise.
12183
12184 * typeck2.c (build_m_component_ref): Propagate quals from datum.
12185
edac124d
KL
121862000-12-14 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
12187
12188 * pt.c (check_explicit_specialization): Propagate default
12189 function arguments to explicit specializations.
12190
31750649 121912000-12-13 DJ Delorie <dj@redhat.com>
8d3b081e
DD
12192
12193 * typeck.c (build_binary_op): Do signed/unsigned warnings for >?
12194 and <? operators.
12195
5e818b93
JM
121962000-12-08 Jason Merrill <jason@redhat.com>
12197
12198 * error.c (dump_function_name): Don't let the user see __comp_ctor.
12199
12200 Clean up copy-initialization in overloading code.
12201 * call.c (build_user_type_conversion_1): Die if we are asked to
12202 convert to the same or a base type.
12203 (implicit_conversion): Avoid doing so. Lose reference binding code.
12204 (convert_like_real): Treat BASE_CONV and RVALUE_CONV as implicit
12205 direct-initialization. Also do direct-init part of copy-init.
12206 (build_user_type_conversion): Don't provide context to convert_like.
12207 * cvt.c (ocp_convert): build_user_type_conversion will now provide
12208 the constructor call for copy-init.
12209
12210 * pt.c (tsubst_decl): Call clone_function_decl here if this is an
12211 instantiation of a member template.
12212 (do_decl_instantiation): Not here.
12213
38da6039
NS
122142000-12-07 Nathan Sidwell <nathan@codesourcery.com>
12215
12216 * class.c (check_field_decls): Don't special case anonymous
12217 fields in error messages.
c9407e4c 12218 (note_name_declared_in_class): Use %D on diagnostic.
d363e7bf 12219
38da6039
NS
12220 * tree.c (pod_type_p): Use strip_array_types.
12221 (cp_valid_lang_attribute): Likewise.
12222 * typeck.c (cp_type_quals): Strip arrays separately, to avoid
12223 multiple evaluations.
d363e7bf 12224 (cp_has_mutable_p): Use strip_array_types.
38da6039 12225
a11d04b5
NS
122262000-12-07 Nathan Sidwell <nathan@codesourcery.com>
12227
12228 * cp-tree.h (sufficient_parms_p): Declare new function.
12229 * call.c (sufficient_parms_p): New function, broken out of ...
12230 (add_function_candidate): ... here. Use it.
12231 (add_conv_candidate): Use it.
12232 * decl.c (grok_ctor_properties): Use it.
12233
5eec2847
JJ
122342000-12-07 Jakub Jelinek <jakub@redhat.com>
12235
12236 * optimize.c (copy_body_r): Set STMT_IS_FULL_EXPR_P on EXPR_STMT.
12237
c907e684
JM
122382000-12-07 Joseph S. Myers <jsm28@cam.ac.uk>
12239
12240 * decl2.c (lang_decode_option): Handle -Wformat-security.
12241
74601d7c
KL
122422000-12-06 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
12243
12244 * pt.c (verify_class_unification): New function.
12245 (get_class_bindings): Use it.
12246 (try_class_unification): Tidy.
12247 (unify): Handle when argument of a template-id is not
12248 template parameter dependent.
12249 (template_args_equal): Handle when TREE_CODE's do not match.
12250
8954e858
AO
122512000-12-06 Alexandre Oliva <aoliva@redhat.com>
12252
12253 * lang-specs.h (c++): When invoking the stand-alone preprocessor
12254 for -save-temps, pass all relevant -Defines to it, and then don't
12255 pass them to cc1plus.
12256
3dc9aec6
WC
122572000-12-05 Will Cohen <wcohen@redhat.com>
12258
12259 * decl.c (finish_case_label): Cleared
12260 more_cleanups_ok in surrounding function scopes.
12261 (define_label): Likewise.
12262
cbb40945
NS
122632000-12-05 Nathan Sidwell <nathan@codesourcery.com>
12264
12265 * cp-tree.h (IDENTIFIER_VIRTUAL_P): Document.
12266 (get_matching_virtual): Remove.
12267 (look_for_overrides): Declare new function.
12268 * decl.c (grokfndecl): Don't set IDENTIFIER_VIRTUAL_P or
12269 DECL_VINDEX here.
12270 * class.c (check_for_override): Move base class iteration code
12271 to look_for_overrides.
12272 * search.c (next_baselink): Remove.
12273 (get_virtuals_named_this): Remove.
12274 (get_virtual_destructor): Remove.
12275 (tree_has_any_destructors_p): Remove.
12276 (struct gvnt_info): Remove.
12277 (check_final_overrider): Remove `virtual' from error messages.
12278 (get_matching_virtuals): Remove. Move functionality to ...
12279 (look_for_overrides): ... here, and ...
12280 (look_for_overrides_r): ... here. Set DECL_VIRTUAL_P, if found
12281 to be overriding.
12282
61402b80
NS
122832000-12-05 Nathan Sidwell <nathan@codesourcery.com>
12284
12285 * typeck.c (get_delta_difference): If via a virtual base,
12286 return zero.
12287 * cvt.c (cp_convert_to_pointer): If via a virtual base, do no
12288 adjustment.
12289
39abc9a6
RH
122902000-12-04 Richard Henderson <rth@redhat.com>
12291
12292 * error.c (dump_tree): Use output_add_string not OB_PUTS.
12293
c00996a3
JM
122942000-12-04 Jason Merrill <jason@redhat.com>
12295
12296 * mangle.c (write_type): Mangle VECTOR_TYPE with "U8__vector".
d363e7bf 12297 (write_builtin_type): Pass intSI_type_node and the like through
c00996a3
JM
12298 type_for_mode.
12299 * method.c (process_overload_item): Mangle VECTOR_TYPEs with 'o'.
12300 Pass intSI_type_node and the like through type_for_mode.
12301 * decl2.c (arg_assoc_type): Handle VECTOR_TYPE like COMPLEX_TYPE.
12302 * pt.c (tsubst, unify): Likewise.
12303 * tree.c (walk_tree): Likewise.
12304 * error.c (dump_type): Likewise.
12305 (dump_type_prefix, dump_type_suffix): Don't bother with VECTOR_TYPE.
d363e7bf 12306
c00996a3
JM
12307 * Make-lang.in: Tweak top comment for emacs.
12308 (cp/TAGS): Restore.
12309
12310 * except.c (expand_throw): Use push_throw_library_fn for _Jv_Throw.
12311
c00996a3
JM
12312 * class.c (clone_function_decl): Robustify.
12313
123142000-12-04 Michael Matz <matzmich@cs.tu-berlin.de>
12315
12316 * decl.c (store_bindings): Only search in the non modified
12317 old_bindings for duplicates.
12318
00bb3dad
NS
123192000-12-04 Nathan Sidwell <nathan@codesourcery.com>
12320
12321 * error.c (dump_function_decl): Use DECL_VIRTUAL_P, not
12322 TYPE_POLYMORPHIC_P.
d363e7bf 12323
00bb3dad
NS
12324 * typeck.c (build_static_cast): Remove unused variable.
12325
dc957d14
KL
123262000-12-01 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
12327
12328 * pt.c: Fix typo in comment.
12329
4d808927
JM
123302000-12-01 Joseph S. Myers <jsm28@cam.ac.uk>
12331
12332 * decl2.c (warn_format): Remove definition.
12333 (lang_decode_option): Handle -Wformat-nonliteral,
12334 -Wno-format-extra-args and -Wno-format-y2k. Use set_Wformat.
12335
5fd8e536
JM
123362000-12-01 Joseph S. Myers <jsm28@cam.ac.uk>
12337
12338 * decl.c (WINT_TYPE, INTMAX_TYPE, UINTMAX_TYPE): Don't define.
12339 (init_decl_processing): Don't create string_type_node,
12340 const_string_type_node, wint_type_node, intmax_type_node,
12341 uintmax_type_node, default_function_type, ptrdiff_type_node and
12342 unsigned_ptrdiff_type_node. Adjust position of call to
12343 c_common_nodes_and_builtins.
12344 (identifier_global_value): New function.
12345
13f9714b
NS
123462000-12-01 Nathan Sidwell <nathan@codesourcery.com>
12347
12348 * call.c (standard_conversion): Reject pointer to member
12349 conversions from ambiguous, inaccessible or virtual bases.
12350 * typeck.c (build_static_cast): Don't check pointers to members
12351 specially.
12352
31b1b957
NS
123532000-11-30 Nathan Sidwell <nathan@codesourcery.com>
12354
12355 * method.c (do_build_copy_constructor): Preserve cv
12356 qualifications when accessing source object members.
12357 (do_build_assign_ref): Likewise. Remove separate diagnostics for
12358 unnamed fields.
12359
717e3f73
NS
123602000-11-30 Nathan Sidwell <nathan@codesourcery.com>
12361
12362 * method.c (do_build_assign_ref): Construct appropriately
12363 CV-qualified base reference. Don't allow const casts in base
12364 conversion.
12365
2c92b94d
NS
123662000-11-30 Nathan Sidwell <nathan@codesourcery.com>
12367
12368 * call.c (build_over_call): Use VOID_TYPE_P. Don't die on
12369 incomplete return type.
12370
bb92901d
NS
123712000-11-28 Nathan Sidwell <nathan@codesourcery.com>
12372
12373 * parse.y (base_class.1): Produce a _TYPE not a _DECL.
12374 * semantics.c (finish_base_specifier): Accept a _TYPE not a
12375 _DECL.
12376
2f3608c3
NS
123772000-11-28 Nathan Sidwell <nathan@codesourcery.com>
12378
12379 * spew.c (yyerror): Cope if yylval.ttype is NULL.
12380
eeb75383
NS
123812000-11-28 Nathan Sidwell <nathan@codesourcery.com>
12382
12383 * decl.c (grokdeclarator): Diagnose undefined template contexts.
12384
5ee4cc26
NS
123852000-11-28 Nathan Sidwell <nathan@codesourcery.com>
12386
12387 * decl.c (grokdeclarator): Do type access control on friend
12388 class.
12389
76e57b45
NS
123902000-11-27 Nathan Sidwell <nathan@codesourcery.com>
12391
12392 * decl.c (grokfndecl): Undo COMPONENT_REF damage caused by
12393 bison parser ickiness.
12394 * pt.c (tsubst_friend_function): Enter namespace scope when
12395 tsubsting the function name.
12396 * cp-tree.h (DECL_TI_TEMPLATE): Update comment to reflect reality.
12397
f9825168
NS
123982000-11-27 Nathan Sidwell <nathan@codesourcery.com>
12399
12400 * cp-tree.h (binfo_from_vbase): Return the virtual base's binfo.
12401 * cvt.c (cp_convert_to_pointer): Add force parameter.
12402 Allow conversions via virtual base if forced.
12403 (convert_to_pointer_force): Adjust call to cp_convert_to_pointer.
12404 (ocp_convert): Likewise.
12405 * search.c (binfo_from_vbase): Return the virtual base's binfo.
12406 * typeck.c (get_delta_difference): Adjust handling of virtual
12407 bases.
12408
9ccb25d5
MM
124092000-11-26 Mark Mitchell <mark@codesourcery.com>
12410
12411 * tree.c (struct list_hash): Remove.
12412 (list_hash_table): Make it be an htab.
12413 (struct list_proxy): New type.
12414 (list_hash_eq): New function.
12415 (list_hash_pieces): Renamed from ...
12416 (list_hash): ... this.
12417 (list_hash_lookup): Remove.
12418 (list_hash_add): Remove.
12419 (hash_tree_cons): Use the generic hashtable.
12420 (mark_list_hash): Remove.
12421 (init_tree): Create the hashtable.
12422
9399bad3
JM
124232000-11-25 Joseph S. Myers <jsm28@cam.ac.uk>
12424
12425 * method.c (build_mangled_C9x_name): Rename to
12426 build_mangled_C99_name. Change C9X references in comments to
12427 refer to C99.
12428
2f401cc8
NS
124292000-11-24 Nathan Sidwell <nathan@codesourcery.com>
12430
12431 * parse.y (unary_expr): Move VA_ARG from here ...
12432 (primary): ... to here.
12433
3d7e9ba4
NS
124342000-11-24 Nathan Sidwell <nathan@codesourcery.com>
12435
12436 * semantics.c (finish_id_expr): If type is error_mark, return
12437 error_mark.
12438
ab097535
NS
124392000-11-23 Nathan Sidwell <nathan@codesourcery.com>
12440
12441 * pt.c (lookup_template_class): Simplify loop exit constructs.
12442 Cope when there is no partial instantiation of a template
12443 template member.
12444
d2a6f3c0 124452000-11-23 J"orn Rennecke <amylaar@redhat.com>
9196ece5
R
12446
12447 * Make-lang.in (g++spec.o, cxxmain.o): Depend on $(CONFIG_H).
12448
cac78ea2
MM
124492000-11-22 Mark Mitchell <mark@codesourcery.com>
12450
6e1b44bc
MM
12451 * mangle.c (mangle_conv_op_name_for_type): Don't use `__op'
12452 prefix.
12453
cac78ea2
MM
12454 * pt.c (do_decl_instantiate): Explicitly clone constructors and
12455 destructors that haven't already been cloned.
12456
3aac38d7
RH
124572000-11-20 Richard Henderson <rth@redhat.com>
12458
12459 * parse.y (yyparse_1): Rename the parser entry point.
12460
124612000-11-20 Alex Samuel <samuel@codesourcery.com>
beac9b93
AS
12462
12463 * mangle.c (write_name): Use <unscoped-name> for names directly in
12464 function scope.
12465 (write_unscoped_name): Accept names directly in function scope.
d363e7bf 12466
447306fa
NS
124672000-11-20 Nathan Sidwell <nathan@codesourcery.com>
12468
12469 * lex.c (rid_to_yy, RID_EXPORT): Make unique keyword.
12470 * parse.y (extdef): Add EXPORT reduction.
12471 * spew.c (yylex): Don't skip export here.
12472
2650255a
MM
124732000-11-19 Mark Mitchell <mark@codesourcery.com>
12474
12475 * decl.c (init_decl_processing): Correct name of pure virtual
12476 function under the new ABI.
12477 * rtti.c (throw_bad_cast): Likewise, for bad cast function.
12478 (throw_bad_typeid): Likewise for bad typeid function.
12479
0657c69c
MM
124802000-11-18 Mark Mitchell <mark@codesourcery.com>
12481
04f3dc2b
MM
12482 * decl.c (grokparms): Don't even function types of `void' type,
12483 either.
12484 * mangle.c (write_type): Don't crash when confronted with the
12485 error_mark_node.
12486
0657c69c
MM
12487 * decl.c (grokparms): Don't create parameters of `void' type.
12488
a8a05998
ZW
124892000-11-17 Zack Weinberg <zack@wolery.stanford.edu>
12490
12491 * lex.c (mark_impl_file_chain): Delete.
12492 (init_parse): Remove call to ggc_add_string_root. No need to
12493 ggc_strdup a string constant. Do not add impl_file_chain to GC
12494 roots.
12495 (handle_pragma_implementation): No need to ggc_strdup main_filename.
12496
35728a80
NS
124972000-11-17 Nathan Sidwell <nathan@codesourcery.com>
12498
12499 * pt.c (tsubst_expr, DECL_STMT): Instantiate decl's type.
12500
5cce22b6
NS
125012000-11-17 Nathan Sidwell <nathan@codesourcery.com>
12502
12503 * cp-tree.h (PARMLIST_ELLIPSIS_P): New macro.
12504 * decl.c (grokdeclarator): Don't reject void parms here.
12505 (require_complete_types_for_parms): Simplify, use
12506 complete_type_or_else.
12507 (grokparms): Remove bitrot. Remove funcdef parm.
12508 Deal with ellipsis parm lists here.
12509 * semantics.c (finish_parmlist): Don't append void_list_node
12510 here. Set PARMLIST_ELLIPSIS_P.
12511
146c8d60
NS
125122000-11-17 Nathan Sidwell <nathan@codesourcery.com>
12513
d30d6e7a 12514 * typeck2.c (incomplete_type_error): Reorganize to avoid
146c8d60
NS
12515 excessive diagnostics.
12516
520a57c8
ZW
125172000-11-16 Zack Weinberg <zack@wolery.stanford.edu>
12518
12519 * lex.c (struct impl_files, internal_filename): Constify a char *.
12520
43048a06
MM
125212000-11-16 Mark Mitchell <mark@codesourcery.com>
12522
12523 * mangle.c (write_special_name_constructor): Don't generate
12524 assembler junk when confronted with an old-style constructor.
12525 (write_special_name_destructor): Likewise.
12526 (mangle_decl_string): Do it here instead.
12527
cdb71673
NS
125282000-11-16 Nathan Sidwell <nathan@codesourcery.com>
12529
12530 * call.c (op_error): Make error messages clearer.
12531
62136084
MM
125322000-11-15 Mark Mitchell <mark@codesourcery.com>
12533
12534 * decl.c (wrapup_globals_for_namespace): Don't mark things
12535 TREE_ASM_WRITTEN when they're not.
12536
ee3400e8
JM
125372000-11-15 Jason Merrill <jason@redhat.com>
12538
12539 * typeck2.c (friendly_abort): Uncount the error before handing
12540 off to fancy_abort.
12541
71631a1f
NS
125422000-11-15 Nathan Sidwell <nathan@codesourcery.com>
12543
12544 * typeck.c (lookup_anon_field): Cope with qv qualifiers.
12545
79cda2d1
MM
125462000-11-14 Mark Mitchell <mark@codesourcery.com>
12547
12548 * class.c (build_vtbl_initializer): Fix typo in comment.
12549 * typeck.c (expr_sizeof): Don't crash on errors.
12550
2567bc56
JW
125512000-11-14 Jim Wilson <wilson@redhat.com>
12552
12553 * lang-specs.h: Add %2 after %(cc1_options).
12554
8422942c
RH
125552000-11-14 Richard Henderson <rth@redhat.com>
12556
12557 * typeck.c (c_sizeof): Be strict about casting result value
12558 back to c_size_type_node.
12559 (expr_sizeof, c_sizeof_nowarn, c_alignof): Likewise.
12560
19552aa5
JM
125612000-11-13 Joseph S. Myers <jsm28@cam.ac.uk>
12562
12563 * typeck.c (build_unary_op): Use boolean_increment from
12564 c-common.c, moving the relevant code there.
12565
d96a6d1a
JM
125662000-11-11 Jason Merrill <jason@redhat.com>
12567
12568 * typeck.c (mark_addressable): Don't call put_var_into_stack.
492cca24
JM
12569
12570 * decl.c (maybe_commonize_var): Set DECL_UNINLINABLE for statics
12571 in inlines.
12572
4e135bdd
KG
125732000-11-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
12574
12575 * decl.c (grokdeclarator, save_function_data): Use memcpy, not bcopy.
12576 * lex.c (copy_lang_decl): Likewise.
12577
0a7394bc
MM
125782000-11-09 Mark Mitchell <mark@codesourcery.com>
12579
13507bd8
MM
12580 * dump.c (cp_dump_tree): Don't dump function bodies here.
12581
0a7394bc
MM
12582 * Make-lang.in (CXX_C_OBJS): Add c-dump.o.
12583 (dump.o): Update dependency list.
12584 * cp-tree.h (DECL_MAYBE_TEMPLATE): Remove.
12585 (flag_dump_translation_unit): Likewise.
12586 (CP_TYPE_QUALS): Adjust definition.
12587 (DECL_C_BIT_FIELD): Remove.
12588 (SET_DECL_C_BIT_FIELD): Likewise.
12589 (CLEAR_DECL_C_BIT_FIELD): Likewise.
12590 (add_maybe_template): Likewise.
12591 (strip_array_types): Likewise.
12592 (dump_node_to_file): Likewise.
12593 (cp_dump_tree): New function.
12594 * decl.c (init_decl_processing): Set lang_dump_tree.
12595 * decl2.c (flag_dump_translation_unit): Remove.
12596 * dump.c: Move most of it to ../c-dump.c.
12597 (cp_dump_tree): New function.
12598 * pt.c (add_maybe_template): Remove.
12599 * typeck.c (strip_array_types): Likewise.
a8a05998 12600
5362b086
EC
126012000-11-07 Eric Christopher <echristo@redhat.com>
12602
492cca24
JM
12603 * decl.c (init_decl_processing): Change definition of
12604 __wchar_t to wchar_t. Remove artificial declaration of
12605 wchar_t.
12606 * lex.c: Change instances of __wchar_t to wchar_t.
5362b086 12607
5361cbb7
NS
126082000-11-09 Nathan Sidwell <nathan@codesourcery.com>
12609
12610 * lex.c (do_identifier): Don't lookup_name for operators.
12611 * parse.y (operator): Save looking_for_typename.
12612 (unoperator): Restore it.
12613 * spew.c (frob_opname): Use nth_token for lookahead.
12614
36791f1e
NS
126152000-11-08 Nathan Sidwell <nathan@codesourcery.com>
12616
12617 * decl.c (grok_op_properties): Always use coerce_new_type and
12618 coerce_delete_type.
12619 * decl2.c (coerce_new_type): Use c_size_type_node. Preserve
12620 exception specification. Tidy up.
12621 (coerce_delete_type): Preserve exception specification. Tidy up.
12622
961192e1
JM
126232000-11-07 Joseph S. Myers <jsm28@cam.ac.uk>
12624
12625 * class.c (duplicate_tag_error, build_vtbl_initializer), decl.c
12626 (push_binding_level), error.c (cp_tree_printer), pt.c
12627 (process_partial_specialization, tsubst_template_arg_vector),
12628 search.c (lookup_member): Use memset () instead of bzero ().
12629
d48ebde1
NS
126302000-11-07 Nathan Sidwell <nathan@codesourcery.com>
12631
12632 * decl.c (build_ptrmemfunc_type): Allow error_mark_node.
12633
436a88a6
JM
126342000-11-05 Joseph S. Myers <jsm28@cam.ac.uk>
12635
12636 * Make-lang.in (c++.distdir): Remove.
12637
7a4e5091
MM
126382000-11-04 Mark Mitchell <mark@codesourcery.com>
12639
12640 * decl2.c (do_nonmember_using_decl): Allow `extern "C"'
12641 declarations from different namespaces to be combined.
12642
0e9295cf
ZW
126432000-11-03 Zack Weinberg <zack@wolery.stanford.edu>
12644
12645 * decl.c: Include tm_p.h.
12646
da61dec9
JM
126472000-11-03 Joseph S. Myers <jsm28@cam.ac.uk>
12648
12649 * tree.c (cp_tree_equal): Use memcmp () instead of bcmp ().
12650
9473c522
JM
126512000-11-02 Joseph S. Myers <jsm28@cam.ac.uk>
12652
12653 * dump.c (dequeue_and_dump), lex.c (interface_strcmp), method.c
12654 (build_overload_value), repo.c (open_repo_file), xref.c
12655 (open_xref_file): Use strchr () and strrchr () instead of index ()
12656 and rindex ().
12657
b0b3afb2
BS
126582000-11-01 Bernd Schmidt <bernds@redhat.co.uk>
12659
12660 * call.c (build_over_call): Call fold on the CALL_EXPR.
12661
faafaee6
GDR
126622000-11-01 Gabriel Dos Reis <gdr@codesourcery.com>
12663
12664 * error.c (dump_template_decl): Separate template hearders with
12665 space not comma.
12666
761f0855
GDR
126672000-10-31 Gabriel Dos Reis <gdr@codesourcery.com>
12668
12669 * error.c: Move TFF_ macros into cp-tree.h. Throughout, replace
12670 TS_* flags with corresponding TFF_*. Adjust prototypes of
12671 functions (which used to take a tree_string_flags) to take an int.
12672
12673 * cp-tree.h (enum tree_string_flags): Remove
12674 (TFF_PLAIN_IDENTIFIER, TFF_NAMESPACE_SCOPE, TFF_CLASS_SCOPE,
12675 TFF_CHASE_NAMESPACE_ALIAS, TFF_CHASE_TYPEDEF, TFF_DECL_SPECIFIERS,
12676 TFF_CLASS_KEY_OR_ENUM, TFF_RETURN_TYPE,
12677 TFF_FUNCTION_DEFAULT_ARGUMENTS, TFF_EXCEPTION_SPECIFICATION,
12678 TFF_TEMPLATE_HEADER, TFF_TEMPLATE_DEFAULT_ARGUMENTS,
12679 TFF_TEMPLATE_NAME, TFF_EXPR_IN_PARENS, TFF_SCOPE): New macros.
12680 (type_as_string, decl_as_string, expr_as_string,
12681 context_as_string): Adjust prototype.
12682
12683 * class.c (dump_class_hierarchy_r): Use TFF_PLAIN_IDENTIFIER
12684 instead of TS_PLAIN.
12685
12686 * pt.c (mangle_class_name_for_template): Use TFF_CHASE_TYPEDEF
12687 instead of TF_CHASE_TYPEDEFS. Use TFF_PLAIN_IDENTIFIER instead of
12688 plain `0'.
12689
ad50e811
MM
126902000-10-30 Mark Mitchell <mark@codesourcery.com>
12691
12692 * cp-tree.h (DECL_EXTERNAL_LINKAGE_P): New macro.
12693 (linkage_kind): New enumeration.
12694 (decl_linkage): New function.
12695 * decl2.c (comdat_linkage): Extend comment.
12696 * error.c (dump_function_decl): Print the arguments used to
12697 instantiate a template, even when not printing the type of the
12698 function.
12699 * pt.c (convert_nontype_argument): Use DECL_EXTERNAL_LINKAGE_P,
12700 not TREE_PUBLIC, to test for external linkage.
12701 * tree.c (decl_linkage): New function.
12702
930cd796
MM
127032000-10-28 Mark Mitchell <mark@codesourcery.com>
12704
12705 * pt.c (instantiate_decl): Always instantiate static data members
12706 initialized in-class.
12707
b8dad04b
ZW
127082000-10-27 Zack Weinberg <zack@wolery.stanford.edu>
12709
12710 * Make-lang.in: Move all build rules here from Makefile.in,
12711 adapt to new context. Wrap all rules that change the current
12712 directory in parentheses. Expunge all references to $(P).
12713 When one command depends on another and they're run all at
12714 once, use && to separate them, not ;. Add OUTPUT_OPTION to
12715 all object-file generation rules. Delete obsolete variables.
12716
12717 * Makefile.in: Delete.
12718 * config-lang.in: Delete outputs= line.
12719
5f9cd837
GDR
127202000-10-26 Gabriel Dos Reis <gdr@codesourcery.com>
12721
12722 * error.c (dump_function_decl): Print no space between
12723 `ptr-operator' the `type-specifier' of the return type.
12724 (dump_type_prefix): Make sure we put space at the appropriate
5362b086 12725 place.
5f9cd837 12726
6c6ed0ef
JM
127272000-10-23 Jason Merrill <jason@redhat.com>
12728
12729 * call.c (equal_functions): Also call decls_match for extern "C" fns.
12730
127312000-10-22 Jason Merrill <jason@redhat.com>
12732
12733 * call.c (build_conditional_expr): Use ocp_convert to force
12734 rvalue conversion.
12735
e36308b0
MM
127362000-10-22 Mark Mitchell <mark@codesourcery.com>
12737
583ca5a0
MM
12738 * call.c (standard_conversion): Use RVALUE_CONVs for all
12739 expressions that satisfy lvalue_p, not just those that satisfy
12740 real_lvalue_p.
12741
f9808f81
MM
12742 * optimize.c (copy_body_r): Don't treat CALL_EXPRs specially.
12743
5362b086 12744 * typeck.c (c_sizeof): Return an expression of `size_t' type,
e36308b0
MM
12745 not one with TYPE_IS_SIZETYPE set.
12746 (dubious_conversion_warnings): Remove special-case code.
12747
3b9ae6f0
GK
127482000-10-21 Geoffrey Keating <geoffk@cygnus.com>
12749
7a0f14e5
GK
12750 * decl2.c (arg_assoc_type): Handle VECTOR_TYPE.
12751 * error.c (dump_type): Handle VECTOR_TYPE like POINTER_TYPE.
12752 (dump_type_prefix): Print vector-of-int as 'int vector'.
12753 (dump_type_suffix): Handle VECTOR_TYPE like POINTER_TYPE.
12754 * tree.c (walk_tree): Handle VECTOR_TYPE.
12755
3b9ae6f0 12756 * decl.c (init_decl_processing): Call MD_INIT_BUILTINS.
5362b086 12757
aca77bd1
JM
127582000-10-21 Jason Merrill <jason@redhat.com>
12759
12760 * parse.y (operator): Set got_object from got_scope.
12761 Set looking_for_typename.
12762 * decl.c (lookup_name_real): Clear val after setting from_obj.
12763 Reorganize diagnostic.
12764
ba523395
JM
127652000-10-20 Jason Merrill <jason@redhat.com>
12766
12767 * tree.c (walk_tree): Don't walk into default args.
12768
12769 * error.c (dump_expr): Use host_integerp.
12770
2e44948d
DE
127712000-10-20 David Edelsohn <edelsohn@gnu.org>
12772
12773 * typeck2.c (abstract_virtuals_error): Use "because" instead of
12774 "since" in error message.
12775
d2a6f3c0 127762000-10-20 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
44475138
RK
12777
12778 * typeck.c (dubious_conversion_warning): Suppress if TYPE_IS_SIZETYPE.
12779
11306230
JO
127802000-10-20 Jeffrey Oldham <oldham@codesourcery.com>
12781
12782 * decl.c (revert_static_member_fn): Fixed typo.
12783
97ba1e3c
MM
127842000-10-19 Mark Mitchell <mark@codesourcery.com>
12785
c20118a8
MM
12786 * class.c (subobject_offset_fn): New type.
12787 (dfs_record_base_offsets): Remove.
12788 (record_base_offsets): Likewise.
12789 (dfs_search_base_offsets): Likewise.
12790 (record_subobject_offset): New function.
12791 (check_subobject_offset): Likewise.
12792 (walk_subobject_offsets): Likewise.
12793 (record_subobject_offsets): Likewise.
12794 (layout_conflict_p): Reimplement.
12795 (layout_nonempty_base_or_field): Correct handling of type
12796 conflicts during layout.
12797 (layout_empty_base): Likewise.
12798 (build_base_field): Adjust to handle new representation of empty
12799 base offset table.
12800 (build_base_fields): Likewise.
12801 (layout_virtual_bases): Likewise.
12802 (splay_tree_compare_integer_csts): New function.
12803 (layout_class_type): Use a splay_tree, rather than a varray, to
12804 represent the offsets of empty bases.
5362b086 12805
97ba1e3c
MM
12806 * cp-tree.h (DECL_ANTICIPATED): Don't require a FUNCTION_DECL.
12807 * decl.c (select_decl): Don't return declarations that are
12808 DECL_ANTICIPATED.
12809
6bcedb4e
MM
128102000-10-18 Mark Mitchell <mark@codesourcery.com>
12811
12812 * cp-tree.h (cp_tree_index): Add CPTI_FAKE_STD.
12813 (fake_std_node): New macro.
12814 * decl.c (in_std): Rename to ...
12815 (in_fake_std): ... this.
12816 (flag_no_builtin): Remove.
12817 (flag_no_nonansi_builtin): Likewise.
12818 (walk_namespaces_r): Use fake_std_node.
12819 (push_namespace): Use std_identifier.
12820 (pop_namespace): Use in_fake_std.
12821 (lookup_name_real): Use fake_std_node.
12822 (init_decl_processing): When -fhonor-std, create the `std'
12823 namespace. Don't create a dummy fake_std_node in that case.
12824 Adjust call to c_common_nodes_and_builtins. Use std_identifier.
12825 (builtin_function): Put builtins whose names don't begin
12826 with `_' in the std namespace.
12827 * decl2.c (flag_no_builtin): Remove.
12828 (flag_no_nonansi_builtin): Likewise.
12829 (set_decl_namespace): Use fake_std_node.
12830 (validate_nonmember_using_decl): Likewise.
12831 (do_using_directive): Likewise.
12832 (handle_class_head): Likewise.
12833 * dump.c (dequeue_and_dump): Likewise.
12834 * except.c (init_exception_processing): Use std_identifier.
12835 * init.c (build_member_call): Use fake_std_node.
12836 * rtti.c (init_rtti_processing): Use std_identifier.
5362b086 12837
67673f5c
MM
128382000-10-17 Mark Mitchell <mark@codesourcery.com>
12839
12840 * cp-tree.h (back_end_hook): Remove declaration.
12841 * decl2.c (back_end_hook): Remove definition.
12842
12843 * dump.c (dequeue_and_dump): Dump TREE_USED.
12844
d2a6f3c0 128452000-10-17 Brad Lucier <lucier@math.purdue.edu>
8fef2e47
BL
12846
12847 * spew.c (snarf_defarg): Cast 2nd arg to obstack_blank to (int).
12848
652469d0
JM
128492000-10-17 Joseph S. Myers <jsm28@cam.ac.uk>
12850
12851 * decl.c (WINT_TYPE): Define.
12852 (init_decl_processing): Create types unsigned_ptrdiff_type_node,
12853 c_size_type_node, signed_size_type_node and wint_type_node.
12854
74ff4629
JM
128552000-10-17 Joseph S. Myers <jsm28@cam.ac.uk>
12856
12857 * decl2.c (warn_missing_format_attribute): New variable.
12858 (lang_decode_option): Decode -Wmissing-format-attribute.
12859
634790f4
MM
128602000-10-16 Mark Mitchell <mark@codesourcery.com>
12861
12862 * typeck.c (qualify_type): Remove.
12863 (composite_pointer_type): Fix handling of conversions to `cv void*'.
12864
bb12da9d
KG
128652000-10-14 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
12866
12867 * Makefile.in (parse.c, parse.h): Fix think-o in last patch.
12868
4b945402
KG
128692000-10-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
12870
12871 * Makefile.in (parse.c, parse.h): Create atomically.
12872
1f8f4a0b
MM
128732000-10-12 Mark Mitchell <mark@codesourcery.com>
12874
12875 * class.c (current_obstack): Remove.
12876 * decl.c (ggc_p): Remove.
12877 (start_decl): Don't use decl_tree_cons.
12878 (grokdeclarator): Don't use build_decl_list.
12879 (start_function): Don't use decl_tree_cons.
12880 (finish_function): Don't mess with obstacks.
12881 * decl2.c (grok_x_components): Don't use build_decl_list.
12882 * lex.c (make_call_declarator): Don't call decl_tree_cons.
12883 (implicitly_declare_fn): Don't call build_decl_list.
12884 * parse.y (frob_specs): Don't call build_decl_list or
12885 decl_tree_cons.
12886 (expr_or_declarator_intern): Don't call decl_tree_cons.
12887 (primary): Don't call build_decl_list.
12888 (fcast_or_absdcl): Likewise.
12889 (typed_declspecs): Don't call decl_tree_cons.
12890 (reserved_declspecs): Don't call build_decl_list.
12891 (declmods): Likewise.
12892 (reserved_typespecquals): Likewise.
12893 (aggr): Likewise.
12894 (new_type_id): Likewise.
12895 (cv_qualifiers): Likewise.
12896 (after_type_declarator_intern): Likewise.
12897 (notype_declarator_intern): Likewise.
12898 (absdcl_intern): Likewise.
12899 (named_parm): Likewise.
12900 * pt.c (most_specialized_class): Likewise.
12901 * repo.c (temporary_obstack): Make it a structure, not a pointer.
12902 (init_repo): Initialize it.
12903 * search.c (current_obstack): Remove.
12904 * typeck2.c (add_exception_specifier): Don't call build_decl_list.
5362b086 12905
8dc54971
RH
129062000-10-09 Richard Henderson <rth@cygnus.com>
12907
12908 * Make-lang.in (CXX_EXTRA_HEADERS): Remove.
12909 (c++ language support bits for libgcc): Remove.
12910 (c++.clean): Remove cplib2.txt cleanup.
12911 * config-lang.in (headers, lib2funcs): Remove.
12912
12913 * exception.cc, new.cc, new1.cc, new2.cc: Remove files.
12914 * tinfo.cc, tinfo.h, tinfo2.cc, vec.cc: Remove files.
12915 * inc/cxxabi.h, inc/exception, inc/new: Remove files.
12916 * inc/new.h, inc/typeinfo: Remove files.
12917
b15ad712
JM
129182000-10-08 Joseph S. Myers <jsm28@cam.ac.uk>
12919
12920 * decl.c (INTMAX_TYPE, UINTMAX_TYPE): Define if not already
12921 defined.
12922 (init_decl_processing): Initialize intmax_type_node and
12923 uintmax_type_node.
12924
156ce211
RH
129252000-10-06 Richard Henderson <rth@cygnus.com>
12926
12927 * cp-tree.h (struct cp_language_function): Remove x_result_rtx.
12928 (original_result_rtx): Remove.
12929 * decl.c (save_function_data): Don't clear x_result_rtx.
12930 (mark_lang_function): Don't mark it either.
12931 * expr.c (fixup_result_decl): Remove.
12932 * semantics.c (genrtl_named_return_value): Frob the return decl
12933 before calling emit_local_var.
12934 (genrtl_finish_function): Don't call fixup_result_decl.
12935 Always emit the jump to return_label.
12936
92777ce4
NS
129372000-10-06 Nathan Sidwell <nathan@codesourcery.com>
12938
12939 * pt.c (lookup_template_class): Set current access for enum.
12940 (tsubst_enum): Set file & line for enum decl.
5362b086 12941
92777ce4
NS
12942 * spew.c (yylex): Remove unused variable.
12943
63c16fc5
RH
129442000-10-05 Richard Henderson <rth@cygnus.com>
12945
12946 * semantics.c (genrtl_finish_function): Don't init or check
12947 can_reach_end; remove noreturn and return value checks.
12948
d1a458c4
TT
129492000-10-05 Tom Tromey <tromey@cygnus.com>
12950
12951 * init.c (build_java_class_ref): Use `build_static_name' with a
12952 suffix, not a prefix, to build the class object's name.
12953
509fc277
NS
129542000-10-05 Nathan Sidwell <nathan@codesourcery.com>
12955
12956 * cp-tree.h (access_kind): Fix comment typo.
12957 * decl2.c (grokfield): Fix diagnostic typo.
12958 * semantics.c (finish_template_type): Fix comment typo.
12959 (finish_qualified_object_call_expr): Likewise.
12960
ce2e5191
NS
129612000-10-05 Nathan Sidwell <nathan@codesourcery.com>
12962
12963 * pt.c (tsubst_expr, DECL_STMT case): Don't process if
5362b086 12964 tsubsting fails.
ce2e5191 12965
79cc5312
NS
129662000-10-05 Nathan Sidwell <nathan@codesourcery.com>
12967
12968 * spew.c (frob_id): New static function.
12969 (frob_opname): Use it.
12970 (yylex): Use it.
12971
f15b9af9
MM
129722000-10-01 Mark Mitchell <mark@codesourcery.com>
12973
12974 * decl.c (lang_mark_false_label_stack): Remove.
12975 * lex.c (cp_mang_lang_type): Use ggc_alloc_cleared.
5362b086 12976
28e6b1c2
JM
129772000-09-30 Joseph S. Myers <jsm28@cam.ac.uk>
12978
12979 * gxxint.texi: Use @email for formatting email addresses.
12980
99885b3f
GDR
129812000-09-29 Gabriel Dos Reis <gdr@codesourcery.com>
12982
12983 * error.c: Remove direct obstack manipulation. Replace with
12984 output_buffer-based formatting. Adjust calls to removed macros.
12985 (obstack_chunk_alloc, obstack_chunk_free): Remove.
12986 (OB_INIT, OB_PUTC, OB_PUTC2, OB_PUTS, OB_PUTID, OB_PUTCP,
12987 OB_FINISH, OB_PUTI, OB_END_TEMPLATE): Likewise.
12988
c06aa51e
MM
129892000-09-24 Mark Mitchell <mark@codesourcery.com>
12990
12991 * ir.texi: Move to ../c-tree.texi.
12992
99fada40
JM
129932000-09-20 Jason Merrill <jason@redhat.com>
12994
12995 * decl2.c (get_guard): Check DECL_FUNCTION_SCOPE_P.
12996
bb20cc46
AJ
129972000-09-21 Andreas Jaeger <aj@suse.de>
12998
12999 * errfn.c: Move declaration of cp_printer and cp_printers to ...
13000 * cp-tree.h: ... here.
13001
13002 * error.c: Remove declaration of cp_printer.
13003
fab701da
MM
130042000-09-20 Mark Mitchell <mark@codesourcery.com>
13005
13006 * tree.c (mark_local_for_remap_r): Handle CASE_LABELs.
13007
0370fea1
HPN
130082000-09-20 Hans-Peter Nilsson <hp@axis.com>
13009
13010 * except.c: Delete #if 0:d EXCEPTION_SECTION_ASM_OP-default and
13011 users.
13012
78c120b5
MM
130132000-09-18 Mark Mitchell <mark@codesourcery.com>
13014
13015 * decl.c (start_function): Robustify.
13016
3f80e6ac
KG
130172000-09-18 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
13018
13019 * cp-tree.h (check_function_format): Accept a `status' parameter.
bb20cc46 13020
3f80e6ac
KG
13021 * call.c, typeck.c: Updates calls to `check_function_format'.
13022
fc928afe
GK
130232000-09-17 Geoffrey Keating <geoffk@cygnus.com>
13024
13025 * decl2.c (handle_class_head): Always push some scope even
13026 in the error case.
13027
8f17b5c5
MM
130282000-09-16 Mark Mitchell <mark@codesourcery.com>
13029
13030 * cp-tree.h (struct cp_language_function): Remove
13031 x_scope_stmt_stack and name_declared.
13032 (current_scope_stmt_stack): Remove.
13033 (function_name_declared_p): New macro.
13034 (struct lang_decl_flags): Use c_lang_decl as a base class.
13035 (context): Remove.
13036 (struct lang_decl): Replace saved_tree with context.
13037 (DECL_FRIEND_CONTEXT): Adjust accordingly.
13038 (SET_DECL_FRIEND_CONTEXT): Likewise.
13039 (DECL_VIRTUAL_CONTEXT): Likewise.
13040 (DECL_SAVED_TREE): Remove.
13041 (C_DECLARED_LABEL_FLAG): Likewise.
13042 (cplus_expand_expr_stmt): Don't declare.
13043 (add_decl_stmt): Likewise.
13044 (add_scope_stmt): Likewise.
13045 * decl.c (mark_stmt_tree): Remove.
13046 (case_compare): Likewise.
13047 (finish_case_label): Use c_add_case_label.
13048 (init_decl_processing): Set more language-specific hooks.
13049 (build_enumerator): Fix typo in comment.
13050 (cplus_expand_expr_stmt): Remove.
13051 (mark_lang_function): Use mark_c_language_function.
13052 (lang_mark_tree): Use c_mark_lang_decl.
13053 * decl2.c: Change order of inclusion.
13054 * except.c: Likewise.
13055 * expr.c (cplus_expand_expr): Remove handling of STMT_EXPR. Fall
13056 back on c_expand_expr.
13057 * friend.c: Include expr.h.
13058 * init.c: Change order of inclusion.
13059 * Makefile.in: Update dependencies.
13060 * lex.h (free_lang_decl_chain): Remove.
13061 * optimize.c (maybe_clone_body): Use function_name_declared_p.
13062 * pt.c (build_template_decl): Don't copy DECL_VIRTUAL_CONTEXT if
13063 it doesn't exist.
13064 (instantiate_decl): Use function_name_declared_p.
13065 * semantics.c (lang_expand_expr_stmt): Remove.
13066 (set_current_function_name_declared): Likewise.
13067 (current_function_name_declared): Likewise.
13068 (begin_compound_stmt): Use function_name_declared_p.
13069 (add_decl_stmt): Remove.
13070 (setup_vtbl_ptr): Use function_name_declared_p.
13071 (add_scope_stmt): Remove.
13072 (current_scope_stmt_stack): New function.
13073 (cp_expand_stmt): Don't handle SCOPE_STMTs.
13074 (expand_body): Use function_name_declared_p.
13075 * tree.c (cp_statement_code_p): Don't include SCOPE_STMT.
13076 * typeck.c: Change order of includes.
13077 (convert_sequence): Remove.
bb20cc46 13078
d9dbd9b1
JM
130792000-09-14 Joseph S. Myers <jsm28@cam.ac.uk>
13080
13081 * lex.c (reswords): Add _Complex.
13082
d2a6f3c0 130832000-09-14 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
9985f210
RK
13084
13085 * Make-lang.in (cplib2.txt): Depend on cp/Makefile.
13086
f903ebb1
DA
130872000-09-13 J. David Anglin <dave@hiauly1.hia.nrc.ca>
13088
13089 * init.c (begin_init_stmts): Don't use // comments.
13090
f2ae0c45
JM
130912000-09-12 Jason Merrill <jason@redhat.com>
13092
13093 * decl.c (maybe_deduce_size_from_array_init): Set do_default for
13094 all non-extern arrays.
13095
13096 * decl.c (grokdeclarator): Complain about 'friend T' for implicit
13097 typenames, too. Downgrade complaint to pedwarn.
13098 (xref_tag): Warn about surprising behavior of 'friend struct T'.
13099 * decl2.c (handle_class_head): Generate a TYPENAME_TYPE for
13100 'class This::Inherited'.
13101
71ad4a16
MM
131022000-09-12 Mark Mitchell <mark@codesourcery.com>
13103
13104 * decl.c (finish_case_label): Given the LABEL_DECL a
13105 DECL_CONTEXT.
13106
c3e76028
GDR
131072000-09-12 Gabriel Dos Reis <gdr@codesourcery.com>
13108
13109 * error.c (TFF_PLAIN_IDENTIFIER, TFF_NAMESPACE_SCOPE,
13110 TFF_CLASS_SCOPE, TFF_CHASE_NAMESPACE_ALIAS, TFF_CHASE_TYPDEF,
13111 TFF_DECL_SPECIFIERS, TFF_CLASS_KEY_OR_ENUM, TFF_RETURN_TYPE,
13112 TFF_FUNCTION_DEFAULT_ARGUMENTS, TFF_EXCEPTION_SPECIFICATION,
13113 TFF_TEMPLATE_HEADER, TFF_TEMPLATE_DEFAULT_ARGUMENTS, TFF_SCOPE):
13114 New macros.
13115 (sorry_for_unsupported_tree, print_scope_operator,
13116 print_left_paren, print_right_paren, print_left_bracket,
13117 print_right_bracket, print_whitespace): Likewise.
13118 (aggr_variety): Rename to class_key_or_enum.
13119 (print_type): Rename to print_type_id.
13120 (print_type_specifier_seq, print_simple_type_specifier,
13121 print_elaborated_type_specifier,
13122 print_rest_of_abstract_declarator,
13123 print_parameter_declaration_clause, print_exception_specification,
13124 print_nested_name_specifier, print_template_id,
13125 typedef_original_name, print_template_argument_list_start,
13126 print_template_argument_list_end): New functions.
13127
eb50138b
GDR
131282000-09-11 Gabriel Dos Reis <gdr@codesourcery.com>
13129
a8a05998 13130 * ir.texi: Add more documentation.
eb50138b 13131
f444e36b
MM
131322000-09-11 Mark Mitchell <mark@codesourcery.com>
13133
13134 * cp-tree.h (struct saved_scope): Remove x_function_parms.
13135 (current_function_parms): Don't define.
13136 (struct cp_language_function): Remove parms_stored.
13137 (current_function_just_assigned_this): Don't define.
13138 (current_function_parms_stored): Likewise.
13139 (static_ctors): Declare.
13140 (static_dtors): Likewise.
13141 (SF_EXPAND): Don't define.
13142 (expand_start_early_try_stmts): Remove declaration.
13143 (store_parm_decls): Likewise.
13144 * decl.c (static_ctors): Don't declare.
13145 (static_dtors): Likewise.
13146 (struct binding_level): Remove this_block.
13147 (poplevel): Remove dead code.
13148 (set_block): Likewise.
13149 (mark_binding_level): Don't mark this_block.
13150 (mark_saved_scope): Don't mark x_function_parms.
13151 (init_decl_processing): Don't add current_function_parms as a GC
13152 root.
13153 (check_function_type): Change prototype.
13154 (start_function): Remove RTL-generation code.
13155 (expand_start_early_try_stmts): Remove.
13156 (store_parm_decls): Give it internal linkage. Remove
13157 RTL-generation code.
13158 (finish_function): Remove RTL-generation code.
13159 * decl2.c (static_ctors): Fix formatting.
13160 (static_dtors): Likewise.
13161 * method.c (use_thunk): Don't call store_parm_decls.
13162 (synthesize_method): Likewise.
13163 * optimize.c (maybe_clone_body): Likewise.
13164 * parse.y (fn.def2): Likewise.
13165 (.set_base_init): Likewise.
13166 (nodecls): Likewise.
13167 * pt.c (instantiate_decl): Likewise.
13168 * rtti.c (synthesize_tinfo_fn): Likewise.
13169 * semantics.c (genrtl_try_block): Simplify.
13170 (expand_body): Use genrtl_start_function and
13171 genrtl_finish_function.
13172 (genrtl_start_function): New function.
13173 (genrtl_finish_function): Likewise.
13174
181d2ba0
NS
131752000-09-11 Nathan Sidwell <nathan@codesourcery.com>
13176
13177 * error.c (cp_tree_printer, case 'P'): Append break.
13178
f2d71db6
NS
131792000-09-11 Nathan Sidwell <nathan@codesourcery.com>
13180
13181 * cp-tree.h (frob_opname): Declare.
13182 * parse.y (saved_scopes): New static variable.
13183 (cp_parse_init): Adjust.
13184 (do_id): If lastiddecl is NULL, do do_identifier.
13185 (operator): Save scope information.
aca77bd1 13186 (unoperator): New reduction. Restore scope information.
f2d71db6
NS
13187 (operator_name): Append unoperator. Call frob_opname.
13188 * spew.c (frob_opname): Define.
13189
d8ea8f28
ZW
131902000-09-10 Zack Weinberg <zack@wolery.cumb.org>
13191
13192 * decl.c, rtti.c: Include defaults.h if not already included.
13193 Don't define the *_TYPE_SIZE macros.
13194
56cb9733
MM
131952000-09-09 Mark Mitchell <mark@codesourcery.com>
13196
13197 * cp-tree.h (push_switch): Change prototype.
13198 (check_cp_case_value): Remove declaration.
13199 (decl_constant_value): Likewise.
13200 * decl.c (struct cp_switch): Add switch_stmt and cases.
13201 (case_compare): New function.
13202 (push_switch): Set switch_stmt. Initialize cases.
13203 (pop_switch): Clean up cases.
13204 (define_case_label): Rename to ...
13205 (finish_case_label): ... this. Do semantic analysis for case
13206 labels here.
13207 (start_function): Correct comment.
13208 * decl2.c (check_cp_case_value): Remove.
13209 * expr.c (do_case): Remove.
13210 * pt.c (tsubst_expr): Adjust call to finish_case_label.
13211 * semantics.c (genrtl_do_poplevel): Remove declaration.
13212 (RECHAIN_STMTS): Remove.
13213 (finish_break_stmt): Use build_break_stmt.
13214 (finish_continue_stmt): Use build_continue_stmt.
13215 (finish_switch_cond): Adjust condition here, rater than in
13216 c_expand_start_case.
13217 (finish_case_label): Remove.
13218 * typeck.c (c_expand_return): Remove.
13219 (c_expand_start_case): Likewise.
bb20cc46 13220
990a9693
GDR
132212000-09-07 Gabriel Dos Reis <gdr@codesourcery.com>
13222
13223 * ir.texi: Document type nodes.
13224
ae499cce
MM
132252000-09-06 Mark Mitchell <mark@codesourcery.com>
13226
54f7877c
MM
13227 * cp-tree.h (init_cp_semantics): Declare.
13228 (genrtl_try_block): Don't declare.
13229 (genrtl_handler): Likewise.
13230 (genrtl_catch_block): Likewise.
13231 (genrtl_ctor_stmt): Likewise.
13232 (genrtl_subobject): Likewise.
13233 (genrtl_do_poplevel): Likewise.
13234 (genrtl_named_return_value): Likewise.
13235 * lex.c (init_parse): Call init_cp_semantics.
13236 * semantics.c (genrtl_try_block): Give it internal linkage.
13237 (genrtl_handler): Likewise.
13238 (genrtl_catch_block): Likewise.
13239 (genrtl_ctor_stmt): Likewise.
13240 (genrtl_subobject): Likewise.
13241 (genrtl_do_poplevel): Likewise.
13242 (genrtl_named_return_value): Likewise.
13243 (lang_expand_stmt): Rename to ...
13244 (cp_expand_stmt): ... this. Only handle C++-specific nodes.
13245 (init_cp_semantics): Define.
13246
3a0d3e1e
MM
13247 * decl.c (initialize_local_var): Remove RTL-generating code.
13248 * semantics.c (genrtl_try_block): Fix formatting.
13249
ae499cce
MM
13250 Move statement-tree facilities from C++ to C front-end.
13251 * cp-tree.h (cp_tree_index): Remove CPTI_VOID_ZERO.
13252 (void_zero_node): Remove.
13253 (stmt_tree): Likewise.
13254 (scope_chain): Adjust.
13255 (language_function): Rename to cp_language_function.
13256 (cp_function_chain): Adjust.
13257 (current_stmt_tree): Remove.
13258 (last_tree): Likewise.
13259 (last_expr_type): Likewise.
13260 (struct lang_decl): Adjust.
13261 (STMT_IS_FULL_EXPR_P): Remove.
13262 (add_tree): Remove.
13263 (begin_stmt_tree): Likewise.
13264 (finish_stmt_tree): Likewise.
13265 (walk_tree_fn): Likewise.
13266 (walk_stmt_tree): Likewise.
13267 * class.c (finish_struct): Replace use of add_tree with add_stmt.
13268 * decl.c (mark_stmt_tree): Adjust type.
13269 (init_decl_processing): Don't build void_zero_node.
13270 (initialize_local_var): Adjust usage of current_stmt_tree.
13271 (finish_enum): Use add_stmt, not add_tree.
13272 (save_function_data): Adjust use of language_function.
13273 (finish_constructor_body): Use add_stmt, not add_tree.
13274 (finish_destructor_body): Likewise.
13275 (push_cp_function_context): Adjust use of language_function.
13276 (pop_cp_function_context): Likewise.
13277 (mark_lang_function): Likewise.
13278 (mark_cp_function_context): Likewise.
13279 * init.c (build_aggr_init): Adjust use of current_stmt_tree.
13280 (build_vec_init): Likewise.
13281 * semantics.c (SET_LAST_STMT): Remove.
13282 (RECHAIN_STMTS): Don't use it.
13283 (stmts_are_full_exprs_p): Adjust use of current_stmt_tree.
13284 (current_stmt_tree): Define.
13285 (add_tree): Remove.
13286 (finish_goto_stmt): Use add_stmt, not add_tree.
13287 (finish_expr_stmt): Likewise.
13288 (begin_if_stmt): Likewise.
13289 (finish_then_clause): Likewise.
13290 (begin_while_stmt): Likewise.
13291 (begin_do_stmt): Likewise.
13292 (finish_return_stmt): Likewise.
13293 (begin_for_stmt): Likewise.
13294 (finish_break_stmt): Likewise.
13295 (finish_continue_stmt): Likewise.
13296 (begin_switch_stmt): Likewise.
13297 (finish_case_label): Likewise.
13298 (begin_try_block): Likewise.
13299 (begin_function_try_block): Likewise.
13300 (begin_handler): Likewise.
13301 (begin_catch_block): Likewise.
13302 (begin_compound_stmt): Likewise.
13303 (begin_asm_stmt): Likewise.
13304 (finish_asm_stmt): Likewise.
13305 (finish_label_stmt): Likewise.
13306 (add_decl_stmt): Likewise.
13307 (finish_subobject): Likewise.
13308 (finish_decl_cleanup): Likewise.
13309 (finish_named_return_value): Likewise.
13310 (setup_vtbl_ptr): Likewise.
13311 (add_scope_stmt): Likewise.
13312 (finish_stmt_expr): Likewise.
13313 (prune_unused_decls): Remove.
13314 (begin_stmt_tree): Likewise.
13315 (finish_stmt_tree): Likewise.
13316 (prep_stmt): Adjust use of current_stmt_tree.
13317 (lang_expand_stmt): Likewise.
13318 * tree.c (statement_code_p): Remove.
13319 (cp_statement_code_p): New function.
13320 (walk_stmt_tree): Remove.
13321 (init_tree): Set lang_statement_code_p.
bb20cc46 13322
0e5921e8
ZW
133232000-09-06 Zack Weinberg <zack@wolery.cumb.org>
13324
13325 Integrated preprocessor.
13326
13327 * Make-lang.in, Makefile.in: Remove all references to input.c,
13328 gxx.gperf, and hash.h. Add ../c-lex.o to C_OBJS.
13329 * gxx.gperf, hash.h, input.c: Delete.
13330 * lang-specs.h: Pass -lang-c++ to cc1plus so cpplib is
13331 initialized properly.
13332
13333 * class.c (fixup_pending_inline): Take a tree, not a
13334 struct pending_inline *. All callers changed.
13335 (init_class_processing): Set RID_PUBLIC, RID_PRIVATE,
13336 RID_PROTECTED entries in ridpointers[] array here.
13337 * decl.c (duplicate_decls): Do not refer to struct
13338 pending_inline.
13339 (record_builtin_type, init_decl_processing): Use RID_MAX not
13340 CP_RID_MAX.
13341 (grokdeclarator): Use C_IS_RESERVED_WORD.
13342 * decl2.c (lang_decode_option): Ignore -lang-c++ for sake of
13343 cpplib.
13344 (grok_x_components): Do not inspect pending_inlines chain.
13345
13346 * cp-tree.h (struct lang_identifier): Add rid_code entry.
13347 (C_IS_RESERVED_WORD, C_RID_CODE, C_RID_YYCODE): New.
13348 (flag_no_gnu_keywords, flag_operator_names, rid_to_yy): Declare.
13349 (DEFARG_LENGTH, struct pending_inline, TIME_IDENTIFIER_TIME,
13350 TIME_IDENTIFIER_FILEINFO): Kill.
13351 Update prototypes.
13352 * lex.h: Expunge cp_rid. Rewrite RIDBIT macros to use just a
13353 single 32-bit word.
13354 * parse.y: Call do_pending_inlines unconditionally.
13355 reinit_parse_for_method is now snarf_method. fn.defpen is no
13356 longer necessary. Remove unnecessary <itype> annotation on
13357 SCOPE. Do not refer to end_of_file or struct pending_inline.
13358 * semantics.c (begin_inline_definitions): Call
13359 do_pending_inlines unconditionally.
13360
13361 * lex.c: Remove all code now shared with C front end.
13362 Initialize cpplib properly if USE_CPPLIB. Put reserved words
13363 into the get_identifier table. Rewrite pragma handling to
13364 work with the registry. Move code to save tokens for later
13365 processing to spew.c.
13366
13367 * spew.c: Rewrite everything in terms of token streams instead
13368 of text. Move routines here from lex.c / input.c as
13369 appropriate. GC-mark trees hanging off the pending inlines
13370 chain.
13371
44835fdd
MM
133722000-09-06 Mark Mitchell <mark@codesourcery.com>
13373
13374 * NEWS: Mention that the named return value extension has been
13375 deprecated.
13376 * cp-tree.h (original_result_rtx): Define.
13377 (TREE_REFERENCE_EXPR): Remove.
13378 (DECL_VPARENT): Likewise.
13379 (pushdecl_nonclass_level): Likewise.
13380 (store_return_init): Likewise.
13381 (reinit_lang_specific): Likewise.
13382 (genrtl_named_return_value): Change prototype.
13383 * decl.c (original_result_rtx): Remove.
13384 (cp_finish_decl): Don't build DECL_STMTs for RESULT_DECLs.
13385 Do not generate RTL for local variables here.
13386 (store_return_init): Remove.
13387 * semantics.c (genrtl_named_return_value): Simplify. Fold in
13388 store_return_init.
13389 (finish_named_return_value): Adjust accordingly. Warn that this
13390 extension is deprecated.
13391 (lang_expand_stmt): Adjust call to genrtl_named_return_value.
13392
d7c4edd0
NS
133932000-09-06 Nathan Sidwell <nathan@codesourcery.com>
13394
13395 * pt.c (type_unification_real): Replace switch with if.
13396 (unify): Tsubst non-type parms before comparing.
13397
46e2747c
NS
133982000-09-06 Nathan Sidwell <nathan@codesourcery.com>
13399
13400 * error.c (dump_typename): New function, broken out of ...
13401 (dump_type): ... here. Use it.
13402 * typeck.c (same_type_p): Use cp_tree_equal for TYPENAME_TYPE.
13403
c833d2be
NS
134042000-09-06 Nathan Sidwell <nathan@codesourcery.com>
13405
13406 * init.c (build_offset_ref): Deal with namespace scoped
13407 TEMPLATE_ID_EXPRs.
13408
b1ce3eb2
NS
134092000-09-06 Nathan Sidwell <nathan@codesourcery.com>
13410
13411 * class.c (resolve_address_of_overloaded_function): Add
13412 explanation message.
13413 * decl.c (define_case_label): Reformat explanation.
13414 * decl2.c (finish_static_data_member_decl): Likewise.
13415 (grokfield): Likewise.
13416 * friend.c (do_friend): Likewise.
13417
11f53b6a
ZW
134182000-09-05 Zack Weinberg <zack@wolery.cumb.org>
13419
13420 * tree.c (walk_tree): Expose tail recursion.
13421 (walk_stmt_tree): New function.
13422 * cp-tree.h: Prototype walk_stmt_tree.
13423 * semantics.c (prune_unused_decls): Operate on SCOPE_STMTs not
13424 the BLOCKs directly. If a BLOCK has no variables after
13425 pruning, discard it.
13426 (finish_stmt_tree): Use walk_stmt_tree. No need to save and
13427 restore the line number.
13428
ee94fce6
MM
134292000-09-05 Mark Mitchell <mark@codesourcery.com>
13430
13431 * Makefile.in (CXX_TREE_H): Add dependency on HTAB_H.
13432 (pt.o): Remove dependency on HTAB_H.
13433 * cp-tree.h: Include hashtab.h.
13434 (walk_tree): Change prototype.
13435 (walk_tree_without_duplicates): New function.
13436 * decl.c (check_default_argument): Use it.
13437 * optimize.c (remap_decl): Adjust calls to walk_tree.
13438 (copy_body): Likewise.
13439 (expand_calls_inline): Likewise.
13440 (calls_setjmp_p): Use walk_tree_without_duplicates.
13441 * pt.c: Don't include hashtab.h.
13442 (for_each_template_parm): Use walk_tree_without_duplicates.
13443 * semantics.c (finish-stmt_tree): Likewise.
13444 (expand_body): Likewise.
13445 * tree.c (walk_tree): Add additional parameter.
13446 (walk_tree_without_duplicates): New function.
13447 (count_trees): Use it.
13448 (verify_stmt_tree): Adjust call to walk_tree.
13449 (find_tree): Use walk_tree_without_duplicates.
13450 (no_linkage_check): Likewise.
13451 (break_out_target_exprs): Adjust call to walk_tree.
13452 (cp_unsave): Likewise.
13453
a1281f45
KL
134542000-09-04 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
13455
13456 * cp-tree.def (BOUND_TEMPLATE_TEMPLATE_PARM): New tree code.
13457 (TEMPLATE_TEMPLATE_PARM): Adjust comment.
13458 * cp-tree.h (TYPE_BINFO): Adjust comment.
13459 (TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO): Likewise.
13460 (TEMPLATE_TYPE_PARM_INDEX): Likewise.
13461 (IS_AGGR_TYPE): Use BOUND_TEMPLATE_TEMPLATE_PARM instead.
13462 (TYPE_TEMPLATE_INFO): Likewise.
13463 (TEMPLATE_TEMPLATE_PARM_TEMPLATE_DECL): Likewise.
13464 * class.c (push_nested_class): Likewise.
13465 * decl.c (lookup_name_real): Likewise.
13466 (grokdeclarator): Likewise.
13467 (grok_op_properties): Likewise.
13468 (xref_tag): Likewise.
13469 (xref_basetypes): Likewise.
13470 * decl2.c (constructor_name_full): Likewise.
13471 (arg_assoc_template_arg): Add TEMPLATE_TEMPLATE_PARM case.
13472 (arg_assoc_type): Use BOUND_TEMPLATE_TEMPLATE_PARM instead.
13473 * error.c (dump_type): Split TEMPLATE_TEMPLATE_PARM case.
13474 (dump_type_prefix): Add BOUND_TEMPLATE_TEMPLATE_PARM.
13475 (dump_type_suffix): Likewise.
13476 * init.c (is_aggr_type): Use BOUND_TEMPLATE_TEMPLATE_PARM
13477 instead.
13478 (get_aggr_from_typedef): Likewise.
13479 * mangle.c (write_type): Split TEMPLATE_TEMPLATE_PARM case.
13480 (write_expression): Add BOUND_TEMPLATE_TEMPLATE_PARM.
13481 (write_template_parm): Likewise.
13482 (write_template_template_parm): Check tree code instead of
13483 using TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO.
0e5921e8 13484 * method.c (build_overload_nested_name): Add
a1281f45
KL
13485 BOUND_TEMPLATE_TEMPLATE_PARM.
13486 (process_overload_item): Split TEMPLATE_TEMPLATE_PARM case.
13487 * parse.y (bad_parm): Add BOUND_TEMPLATE_TEMPLATE_PARM.
13488 * pt.c (convert_template_argument): Check tree code instead of
13489 using TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO.
13490 (for_each_template_parm_r): Split TEMPLATE_TEMPLATE_PARM case.
13491 (for_each_template_parm): Adjust comment.
13492 (tsubst): Add BOUND_TEMPLATE_TEMPLATE_PARM. Reorganize.
13493 (tsubst_copy): Add BOUND_TEMPLATE_TEMPLATE_PARM.
13494 (unify): Add BOUND_TEMPLATE_TEMPLATE_PARM. Reorganize. Use
13495 template_args_equal to compare template template parameter cases.
13496 * ptree.c (print_lang_type): Add BOUND_TEMPLATE_TEMPLATE_PARM.
13497 * search.c (lookup_field_1): Use BOUND_TEMPLATE_TEMPLATE_PARM
13498 instead.
13499 * tree.c (copy_template_template_parm): Decide whether to create
13500 a TEMPLATE_TEMPLATE_PARM or BOUND_TEMPLATE_TEMPLATE_PARM node.
13501 (walk_tree): Add BOUND_TEMPLATE_TEMPLATE_PARM.
13502 (copy_tree_r): Likewise.
13503 * typeck.c (comptypes): Likewise. Check tree code instead of
13504 using TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO.
13505
c9672d45
ME
135062000-09-04 Mark Elbrecht <snowball3@bigfoot.com>
13507
13508 * decl.c (finish_function): Move the code for handling functions
13509 marked with the constructor and destructor attributes inside the
13510 expand_p block.
13511
67804825
NS
135122000-09-04 Nathan Sidwell <nathan@codesourcery.com>
13513
13514 * init.c (resolve_offset_ref): Deal with TEMPLATE_ID_EXPR.
13515
1bc0793e
NS
135162000-09-04 Nathan Sidwell <nathan@codesourcery.com>
13517
13518 * pt.c (lookup_template_class): Remove abort.
13519 * tree.c (get_type_decl): Allow error_mark_node.
13520
3338663b
NS
135212000-09-04 Nathan Sidwell <nathan@codesourcery.com>
13522
13523 * decl2.c (arg_assoc): Deal with COMPONENT_REFs inside
13524 TEMPLATE_ID_EXPRs.
13525
1b84dc37
MM
135262000-09-03 Mark Mitchell <mark@codesourcery.com>
13527
13528 * operators.def (ALIGNOF_EXPR, MAX_EXPR, MIN_EXPR): Change
c9672d45 13529 new ABI mangling.
1b84dc37 13530
9687f8f4
NS
135312000-09-01 Nathan Sidwell <nathan@codesourcery.com>
13532
13533 * parse.y (named_class_head): Check for TYPENAME_TYPE. Simplify
c9672d45 13534 union tag mismatch error reporting.
9687f8f4 13535
4f8025eb
NS
135362000-09-01 Nathan Sidwell <nathan@codesourcery.com>
13537
c9672d45 13538 * call.c (build_scoped_method_call): Check it is not a namespace.
4f8025eb 13539
495d26d6
JM
135402000-08-30 Jason Merrill <jason@redhat.com>
13541
13542 * cp-tree.h (LOCAL_CLASS_P): Use decl_function_context.
13543
13544 * tree.c (bot_manip): Check TREE_CONSTANT rather than
13545 !TREE_SIDE_EFFECTS. Call break_out_target_exprs and
13546 build_target_expr_with_type for the non-AGGR_INIT_EXPR case.
13547
13548 * decl.c (start_function): Always call make_function_rtl.
13549
7efcf466
ZW
135502000-08-29 Zack Weinberg <zack@wolery.cumb.org>
13551
495d26d6 13552 * semantics.c (prune_unused_decls): New function.
7efcf466
ZW
13553 (finish_stmt_tree): Call it via walk_tree.
13554
63ad61ed
ZW
135552000-08-29 Zack Weinberg <zack@wolery.cumb.org>
13556
13557 * class.c (build_secondary_vtable): Constify a char *.
13558 * decl.c (init_decl_processing): Initialize function_id_node,
13559 pretty_function_id_node, and func_id_node.
13560 * input.c (struct input_source): Constify 'str'.
13561 (feed_input): Constify first argument.
13562 * mangle.c (write_identifier): Constify argument.
13563 * pt.c (mangle_class_name_for_template): Constify argument.
13564
4361b41d
MM
135652000-08-29 Mark Mitchell <mark@codesourcery.com>
13566
13567 * typeck.c (mark_addressable): Remove code that pokes around in
13568 RTL.
13569
881c6935
JM
135702000-08-28 Jason Merrill <jason@redhat.com>
13571
13572 * lex.c (file_name_nondirectory): Move to toplev.c.
13573
13574 * cp-tree.h (LOCAL_CLASS_P): New macro.
13575 * class.c (finish_struct_1): Use it.
13576
f0f33848
AS
135772000-08-27 Alex Samuel <samuel@codesourcery.com>
13578
13579 * mangle.c (CLASSTYPE_TEMPLATE_ID_P): Remove unexplained voodoo.
13580 (write_encoding): Pass another argument to write_name.
13581 (write_name): Add ignore_local_scope parameter. Fix handling of
13582 local names.
13583 (write_nested_name): Use write_unqualified_name.
13584 (write_prefix): Likewise. Skip out on FUNCTION_DECLs.
13585 (write_template_prefix): Use write_unqualified_name.
13586 (write_component): Remove.
13587 (write_local_name): Add parameter. Use direct local entity to
13588 discriminator calculation.
0e5921e8 13589 (write_class_enum_type): Pass another argument to write_name.
f0f33848
AS
13590 (write_template_template_arg): Likewise.
13591 (make_guard_variable): Likewise.
0e5921e8 13592
94dfccd1
JM
135932000-08-27 Jason Merrill <jason@redhat.com>
13594
13595 * decl.c (pushdecl): Matching decls for local externs are found in
13596 the current level. Propagate linkage information from previous
13597 declarations.
13598
14fdf4b6
GDR
135992000-08-26 Gabriel Dos Reis <gdr@codesourcery.com>
13600
13601 * ir.texi (Expressions): Fix typo.
13602
b5232c64
GM
136032000-08-25 Greg McGary <greg@mcgary.org>
13604
13605 * tree.c (init_tree): Use ARRAY_SIZE.
13606
22a4158c
GDR
136072000-08-25 Gabriel Dos Reis <gdr@codesourcery.com>
13608
13609 * error.c (cp_tree_printer): Rework.
13610
f22967f3
MM
136112000-08-25 Mark Mitchell <mark@codesourcery.com>
13612
a0c182fe
MM
13613 * Make-lang.in (CXX_LIB2FUNCS): Remove cp-demangle.o and
13614 dyn-string.o.
13615 (CXX_LIB2SRCS): Remove cp-demangle.c and dyn-string.c.
13616 (cp-demangle.o): Remove target.
13617 (dyn-string.o): Likewise.
13618
f22967f3
MM
13619 * decl.c (grokfndecl): Require that `main' return an `int'.
13620 * mangle.c (write_encoding): Don't mangle return types for
13621 conversion functions.
13622
a1066c99
GDR
136232000-08-25 Gabriel Dos Reis <gdr@codesourcery.com>
13624
13625 * error.c (tree_formatting_info): New data type.
13626 (tree_being_formatted): New macro.
13627 (tree_formatting_flags): Likewise.
13628 (put_whitespace): Likewise.
13629 (print_tree_identifier): Likewise.
13630 (print_identifier): Likewise.
13631 (cp_tree_printer, print_function_argument_list, print_declaration,
13632 print_expression, print_function_declaration,
13633 print_function_parameter, print_type, print_cv_qualifier): New
0e5921e8 13634 functions.
a1066c99
GDR
13635 (init_error): Initialize lang_printer.
13636
3f2b640a
JM
136372000-08-24 Jason Merrill <jason@redhat.com>
13638
13639 * typeck.c (build_ptrmemfunc): Just reinterpret if there's no
13640 adjustment necessary.
13641
7ec09bf7
GM
136422000-08-24 Greg McGary <greg@mcgary.org>
13643
13644 * cp-tree.h (MAIN_NAME_P): Remove macro.
13645
2ab99c46
GDR
136462000-08-24 Gabriel Dos Reis <gdr@codesourcery.com>
13647
13648 * error.c (print_instantiation_context): Don't forget to flush the
13649 buffer.
13650
7def1251
JM
136512000-08-23 Jason Merrill <jason@redhat.com>
13652
13653 * typeck.c (build_ptrmemfunc): Save the input pmf.
13654
13655 * method.c (process_modifiers): Use same_type_p.
13656
94350948
MM
136572000-08-23 Mark Mitchell <mark@codesourcery.com>
13658
13659 * cp-tree.h (DECL_CLONED_FUNCTION_P): Check DECL_LANG_SPECIFIC.
13660 * mangle.c (write_function_type): Change prototype.
13661 (write_encoding): Don't mangle return types for
13662 constructors or destructors.
13663 (write_type): Adjust call to write_function_type.
13664 * pt.c (instantiate_template): Instantiate alternate entry points
13665 when instantiating the main function.
0e5921e8 13666
a64e7329
GDR
136672000-08-23 Gabriel Dos Reis <gdr@codesourcery.com>
13668
13669 * error.c (cp_print_error_function): Don't use embedded '\n' in
0e5921e8 13670 output_printf.
a64e7329 13671
a72462a4
GDR
136722000-08-23 Gabriel Dos Reis <gdr@codesourcery.com>
13673
13674 * decl.c (init_decl_processing): Remove bogus initialization.
13675 * error.c (lang_print_error_function): Restore here.
0e5921e8
ZW
13676 (init_error): Initialize print_error_function.
13677
3add6264
TP
136782000-08-22 Theodore Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr>
13679
13680 * decl2.c (arg_assoc): Revert my 2000-08-11 change.
13681
cb753e49
GDR
136822000-08-22 Gabriel Dos Reis <gdr@codesourcery.com>
13683
13684 * Makefile.in (error.o): Depends on diagnostic.h
13685
13686 * cp-tree.h (problematic_instantiation_changed,
13687 record_last_problematic_instantiation, current_instantiation,
13688 print_instantiation_context): Declare.
13689 (maybe_print_template_context): Remove.
13690
13691 * decl.c (init_decl_processing): Set print_error_function to NULL.
13692 (lang_print_error_function): Remove, since we're using a new
13693 machinery.
13694
13695 * error.c: #include diagnostic.h
13696 (function_category): New function.
13697 (cp_diagnostic_starter): Likewise.
13698 (cp_diagnostic_finalizer): Likewise.
13699 (cp_print_error_function): Likewise.
13700 (maybe_print_instantiation_context): Likewise.
13701 (print_instantiation_full_context): Likewise.
13702 (print_instantiation_partial_context): Likewise.
13703 (print_instantiation_context): Define.
13704 (init_error): Initialize diagnostic pager and finalizer.
13705
13706 * pt.c (problematic_instantiation_changed): Define.
13707 (record_last_problematic_instantiation): Likewise.
13708 (current_instantiation): Likewise.
13709 (maybe_print_template_context): Remove.
13710 (print_template_context): Likewise.
13711 (current_tinst_level): Make static to reflect Brendan Kehoe's
13712 change of 1995-04-13.
0e5921e8
ZW
13713 (push_tinst_level): Call print_instantiation_context.
13714
05a3d06e 137152000-08-21 Nix <nix@esperi.demon.co.uk>
0e5921e8 13716
05a3d06e
N
13717 * lang-specs.h: Do not process -o or run the assembler if
13718 -fsyntax-only.
13719
93e2382f
JM
137202000-08-21 Joseph S. Myers <jsm28@cam.ac.uk>
13721
13722 * decl.c (flag_hosted, flag_noniso_default_format_attributes): New
13723 variables.
13724 * decl2.c (lang_decode_option): Disable gettext attributes for
13725 -ansi.
13726
24805e80
GDR
137272000-08-21 Gabriel Dos Reis <gdr@codesourcery.com>
13728
13729 * lex.c (lang_init_options): Default diagnostic message maximum
13730 length to 80, when line-wrapping.
13731
b485e15b
MM
137322000-08-20 Mark Mitchell <mark@codesourcery.com>
13733
13734 * class.c (build_vtbl_initializer): Clear the entire
13735 vtbl_init_data. Start keeping track of the functions for which we
13736 have created vcall offsets here.
13737 (dfs_build_vcall_offset_vtbl_entries): Remove.
13738 (build_vcall_offset_vtbl_entries): Reimplement.
13739 (add_vcall_offset_vtbl_entries_r): New function.
13740 (add_vcall_offset_vtbl_entries_1): Likewise. Tweak logic for
13741 computing when vcall offsets are necessary.
13742
2ae7bada
NS
137432000-08-18 Nathan Sidwell <nathan@codesourcery.com>
13744
13745 * decl.c (member_function_or_else): Use cp_error ... %T.
13746 (grokdeclarator): Likewise.
13747 (start_method): Likewise.
0e5921e8 13748 * friend.c (make_friend_class): Use cp_pedwarn ... %T.
2ae7bada 13749
7a8b1375
NS
137502000-08-18 Nathan Sidwell <nathan@codesourcery.com>
13751
13752 * decl2.c (grokfield): Set CLASSTYPE_GOT_SEMICOLON on class
0e5921e8 13753 TYPE_DECLs.
7a8b1375 13754
19420d00
NS
137552000-08-18 Nathan Sidwell <nathan@codesourcery.com>
13756
13757 * cp-tree.h (PTRMEM_OK_P): New macro.
13758 (itf_ptrmem_ok): New enumeration value.
13759 * class.c (resolve_address_of_overloaded_function): Add PTRMEM
13760 argument. Diagnose implicit pointer to member.
13761 (instantiate_type): Don't diagnose implicit pointer to member
13762 here. Pass itf_ptrmem_ok if ok. Adjust calls to
13763 resolve_address_of_overloaded_function.
13764 * init.c (build_offset_ref): Set PTRMEM_OK_P.
13765 (resolve_offset_ref): Don't diagnose implicit pointer to member here.
13766 * semantics.c (finish_parenthesized_expr): Clear OFFSET_REFs here.
13767 * typeck.c (build_x_unary_op): Calculate PTRMEM_OK_P.
13768 (build_unary_op): Deal with single non-static member in
13769 microsoft-land.
13770
66081283
NS
137712000-08-18 Nathan Sidwell <nathan@codesourcery.com>
13772
13773 * decl2.c (arg_assoc_type): Cope with TYPENAME_TYPE.
13774
fa40aa12
NS
137752000-08-18 Nathan Sidwell <nathan@codesourcery.com>
13776
13777 * cp-tree.h (enum_name_string): Remove prototype.
13778 (report_case_error): Remove prototype.
13779 * cp/typeck2.c (enum_name_string): Remove.
13780 (report_case_error): Remove.
13781 * error.c (dump_expr): Deal with enum values directly.
13782 Correctly negate integer constant.
13783
d13b34e9
NS
137842000-08-17 Nathan Sidwell <nathan@codesourcery.com>
13785
13786 * inc/cxxabi.h (__cxa_vec_new2, __cxa_vec_new3): Declare.
13787 (__cxa_vec_delete2, __cxa_vec_delete3): Declare.
13788 * vec.cc (__cxa_vec_new2, __cxa_vec_new3): Implement.
13789 (__cxa_vec_delete2, __cxa_vec_delete3): Implement.
13790 (__cxa_vec_new): Use __cxa_vec_new2.
13791 (__cxa_vec_delete): Use __cxa_vec_delete2.
13792
2f1b80af
NS
137932000-08-17 Nathan Sidwell <nathan@codesourcery.com>
13794
13795 * vec.cc (__cxa_vec_new): Set "C" linkage.
13796 (__cxa_vec_ctor): Likewise.
13797 (__cxa_vec_cctor): Likewise.
13798 (__cxa_vec_dtor): Likewise.
13799 (__cxa_vec_delete): Likewise.
13800 * inc/cxxabi.h (__cxa_vec_new): Set "C" linkage.
13801 (__cxa_vec_ctor): Likewise.
13802 (__cxa_vec_cctor): Likewise.
13803 (__cxa_vec_dtor): Likewise.
13804 (__cxa_vec_delete): Likewise.
13805
105d8e1f
NS
138062000-08-17 Nathan Sidwell <nathan@codesourcery.com>
13807
13808 * class.c (instantiate_type): Reinstate local variable
13809 deleted in previous change.
0e5921e8 13810
f1819d9a
NS
13811 * cvt.c (cp_convert_to_pointer): Pass itf_complain, not
13812 itf_no_attributes.
105d8e1f 13813
5e76004e
NS
138142000-08-17 Nathan Sidwell <nathan@codesourcery.com>
13815
13816 * cp-tree.h (instantiate_type_flags): New enumeration.
13817 (instantiate_type): Change parameter.
13818 * class.c (instantiate_type): Adjust prototype. Adjust.
13819 * call.c (standard_conversion): Adjust instantiate_type call.
13820 (reference_binding): Likewise.
13821 (build_op_delete_call): Likewise.
13822 (convert_like_real): Likewise.
13823 * cvt.c (cp_convert_to_pointer): Likewise.
13824 (convert_to_reference): Likewise.
13825 * pt.c (convert_nontype_argument): Likewise.
13826 * typeck.c (build_binary_op): Likewise.
13827 (build_ptrmemfunc): Likewise.
13828 (convert_for_assignment): Likewise.
13829
4b054b80
NS
138302000-08-17 Nathan Sidwell <nathan@codesourcery.com>
13831
13832 * cp-tree.h (CPTR_AGGR_TAG): New global tree node.
13833 (current_aggr): Define.
13834 * decl.c (grokdeclarator): Make sure a friend class is an
13835 elaborated type specifier.
13836 * parse.y (current_aggr): Remove static definition.
13837 (cp_parse_init): Adjust.
13838 (structsp): Clear and restore current_aggr.
13839 (component_decl_list): Clear current_aggr.
0e5921e8 13840
4b054b80
NS
13841 * error.c (dump_type, case TYPENAME_TYPE): Don't emit the
13842 aggregate tag on the typename's context.
0e5921e8 13843
321cba97
NS
13844 * pt.c (tsubst_friend_class): Return error_mark_node, if
13845 parms becomes NULL.
13846 (instantiate_class_template): Ignore error_mark_node friend types.
4b054b80 13847
08aead78
NS
138482000-08-14 Nathan Sidwell <nathan@codesourcery.com>
13849
13850 * cvt.c (warn_ref_binding): New static function, broken out of ...
0e5921e8 13851 (convert_to_reference): ... here. Use it.
08aead78 13852
fa1f3ebc
KL
138532000-08-11 Kriang Lerdsuwanakij <lerdsuwa@scf-fs.usc.edu>
13854
13855 * parse.y (template_arg): Add rule for template qualified with
13856 global scope.
13857
9845b52b
TP
138582000-08-11 Theodore Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr>
13859
13860 * decl2.c (add_function): Reorganize.
13861 (arg_assoc): Do not consider function template decls.
13862
e69c8072
JM
138632000-08-11 Jason Merrill <jason@redhat.com>
13864
13865 * decl.c (lookup_name_real): Don't forget the TYPENAME_TYPE we're
13866 looking inside.
13867
5c1e5476
NS
138682000-08-11 Nathan Sidwell <nathan@codesourcery.com>
13869
13870 * cp-tree.h (resolve_scope_to_name): Remove unused prototype.
13871 (lookup_nested_tag): Likewise.
0e5921e8 13872
5c1e5476
NS
13873 * decl2.c (grokfield): Fix comment to reflect many types of _DECLs
13874 can be produced.
13875
5426aa7f
NS
138762000-08-11 Nathan Sidwell <nathan@codesourcery.com>
13877
13878 * parse.y (named_complex_class_head_sans_basetype): Remove
13879 always true if.
13880
fd037e0d
NS
138812000-08-11 Nathan Sidwell <nathan@codesourcery.com>
13882
13883 * decl2.c (build_expr_from_tree, case METHOD_CALL_EXPR): Build
13884 explicit TEMPLATE_ID_EXPR args.
13885 (build_expr_from_tree, case CALL_EXPR): Likewise.
13886
73ae5c34
NS
138872000-08-11 Nathan Sidwell <nathan@codesourcery.com>
13888
13889 * decl.c (check_tag_decl): Diagnose typename's which don't
13890 declare anything.
13891
aa54df09
NS
138922000-08-10 Nathan Sidwell <nathan@codesourcery.com>
13893
13894 * init.c (build_aggr_init): Reject bogus array initializers
13895 early.
13896
7e8dad18
NS
138972000-08-09 Nathan Sidwell <nathan@codesourcery.com>
13898
13899 * rtti.c (build_dynamic_cast_1): Set "C" linkage for new abi
13900 runtime.
13901 * cp/tinfo.cc (__dynamic_cast): Likewise.
0e5921e8 13902 * cp/inc/cxxabi.h (__dynamic_cast): Likewise.
7e8dad18 13903
0f586b9b
NS
139042000-08-09 Nathan Sidwell <nathan@codesourcery.com>
13905
13906 * cvt.c (convert_to_pointer_force): Fix error message when
0e5921e8 13907 attempting to cast from ambiguous base.
0f586b9b 13908
08e72a19
JM
139092000-08-08 Jason Merrill <jason@redhat.com>
13910
13911 * pt.c (tsubst_aggr_type): Bail if creating the argvec fails.
13912 (tsubst_template_arg_vector): Likewise.
13913
13914 * decl2.c (build_anon_union_vars): Choose the largest field; don't
13915 assume that one will be as large as the union.
13916
0811ea8f
KH
139172000-08-07 Kazu Hirata <kazu@hxi.com>
13918
13919 * cp-tree.h (CLASSTYPE_HAS_PRIMARY_BASE_P): Fix a comment typo.
13920 * decl.c (pop_labels): Likewise.
13921
f9fcf62b
JO
139222000-08-04 Jeffrey Oldham <oldham@codesourcery.com>
13923
13924 * inc/cxxabi.h (__pbase_type_info): Changed member names to match
13925 specifications.
13926 (__pointer_to_member_type_info): Likewise.
13927 (__base_class_info): Likewise.
13928 (__class_type_info): Likewise.
13929 (__si_class_type_info): Likewise.
13930 (__vmi_class_type_info): Likewise.
13931 * tinfo.cc (__si_class_type_info::__do_find_public_src):
13932 Changed member names to match specifications.
13933 (__vmi_class_type_info::__do_find_public_src): Likewise.
13934 (__si_class_type_info::__do_dyncast): Likewise.
13935 (__vmi_class_type_info::__do_dyncast): Likewise.
13936 (__si_class_type_info::__do_upcast): Likewise.
13937 (__vmi_class_type_info::__do_upcast): Likewise.
13938 * tinfo2.cc (__pbase_type_info::__do_catch): Likewise.
13939 (__pbase_type_info::__pointer_catch): Likewise.
13940 (__pointer_type_info::__pointer_catch): Likewise.
13941 (__pointer_to_member_type_info::__pointer_catch): Likewise.
13942
a36556a8
ZW
139432000-08-04 Zack Weinberg <zack@wolery.cumb.org>
13944
0e5921e8
ZW
13945 * Make-lang.in (cc1plus): Depend on $(BACKEND), not stamp-objlist.
13946 * Makefile.in: Add C_OBJS, BACKEND; delete OBJS, OBJDEPS.
13947 (cc1plus): Link with $(BACKEND) and $(C_OBJS).
a36556a8 13948
452a394b
MM
139492000-08-04 Mark Mitchell <mark@codesourcery.com>
13950
13951 * cp-tree.h (add_method): Change prototype.
13952 * class.c (add_method): Remove FIELDS parameter. Add ERROR_P.
13953 Don't double the size of the method vector in the error case.
13954 (handle_using_decl): Adjust call to add_method.
13955 (add_implicitly_declared_members): Likewise.
13956 (clone_function_decl): Likewise.
13957 * decl2.c (check_classfn): Likewise.
13958 * semantics.c (finish_member_declaration): Likewise.
0e5921e8 13959
b8458e3e
JM
139602000-08-04 Joseph S. Myers <jsm28@cam.ac.uk>
13961
13962 * decl.c (flag_isoc94): New variable.
13963
a1bcc528
JM
139642000-08-02 Jason Merrill <jason@redhat.com>
13965
13966 * pt.c (do_type_instantiation): Add complain parm; don't complain
13967 if called recursively.
13968 * cp-tree.h, parse.y: Adjust.
13969
50e60bc3
ZW
139702000-08-02 Zack Weinberg <zack@wolery.cumb.org>
13971
eae51189
ZW
13972 * decl2.c: Silently ignore -Wstrict-prototypes; warn about
13973 -Wno-strict-prototypes.
13974
37620334
ZW
13975 * g++spec.c: Adjust type of second argument to
13976 lang_specific_driver, and update code as necessary.
13977
50e60bc3
ZW
13978 * cp-tree.h: Don't prototype min_precision here.
13979 (my_friendly_assert): Cast expression to void.
13980 * semantics.c (do_poplevel): Initialize scope_stmts.
13981
3f954fc3
MM
139822000-08-02 Mark Mitchell <mark@codesourcery.com>
13983
13984 * cp-tree.h (DECL_NEEDED_P): Tweak.
13985
ab4fa7ed
JM
139862000-07-28 Jason Merrill <jason@redhat.com>
13987
13988 * lang-specs.h: Use %i in rule for .ii files.
13989
4871239e
ZW
139902000-07-31 Zack Weinberg <zack@wolery.cumb.org>
13991
13992 * lang-specs.h: Rename cpp to cpp0 and/or tradcpp to tradcpp0.
13993
911a71a7
MM
139942000-07-30 Mark Mitchell <mark@codesourcery.com>
13995
13996 Allow indirect primary bases.
13997 * cp-tree.h (struct lang_type): Remove vfield_parent. Add
13998 primary_base.
13999 (CLASSTYPE_VFIELD_PARENT): Remove.
14000 (CLASSTYPE_PRIMARY_BINFO): Reimplement.
14001 (BINFO_PRIMARY_BINFO): Remove.
14002 (CLASSTYPE_HAS_PRIMARY_BASE_P): Reimplement.
14003 (BINFO_VBASE_PRIMARY_P): Likewise.
14004 (BINFO_PRIMARY_BASE_OF): New macro.
14005 (BINFO_INDIRECT_PRIMARY_P): Likewise.
14006 (get_primary_binfo): New function.
14007 * decl.c (lang_mark_tree): Make lang_type::primary_base.
14008 * class.c (vcall_offset_data_s): Rename to ...
14009 (vtbl_init_data_s): ... this. Rename primary_p to primary_vtbl_p,
14010 and add ctor_vtbl_p.
14011 (get_derived_offset): Use get_primary_binfo.
14012 (dfs_mark_primary_bases): Adjust handling of virtual primary
14013 bases.
14014 (mark_primary_bases): Likewise.
14015 (set_primary_base): Take a binfo, not an integer, as a
14016 representation of the primary base.
14017 (indirect_primary_base_p): Remove.
14018 (determine_primary_base): Adjust for indirect primary bases.
14019 (dfs_find_final_overrider): Fix typo in coment.
14020 (update_vtable_entry_for_fn): Use get_primary_binfo.
14021 (layout_nonempty_base_or_field): Tweak.
14022 (build_base_fields): Adjust for new primary base semantics.
14023 (dfs_propagate_binfo_offsets): Remove.
14024 (propagate_binfo_offsets): Rewrite.
14025 (dfs_set_offset_for_shared_vbases): Remove.
14026 (layout_virtual_bases): Don't use it.
14027 (layout_class_type): Set CLASSTYPE_SIZE correctly under the new
14028 ABI.
14029 (finish_struct_1): Set CLASSTYPE_PRIMARY_BINFO, not
14030 CLASSTYPE_VFIELD_PARENT.
14031 (dfs_get_primary_binfo): New function.
14032 (get_primary_binfo): Likewise.
14033 (dump_class_hierarchy_r): Tweak printing of primary bases.
14034 (build_vtbl_initializer): Fix typo in comments. Use
14035 vtbl_init_data.
14036 (build_vcall_and_vbase_vtbl_entries): Likewise.
14037 (build_vbaes_offset_vtbl_entries): Likewise.
14038 (dfs_build_vcall_offset_vtbl_entries): Adjust setting of
14039 BV_VCALL_INDEX to handle indirect primary bases.
14040 (build_vcall_offset_vtbl_entries): Use vtbl_init_data.
14041 (build_rtti_vtbl_entries): Likewise.
14042 * search.c (get_shared_vbase_if_not_primary): Tweak.
14043 (find_vbase_instance): Likewise.
14044 (binfo_for_vtable): Simplify.
14045 * tree.c (unshare_base_binfos): Clear BINFO_PRIMARY_BASE_OF.
14046 (make_binfo): Make it have 11 entries.
0e5921e8 14047
722bed0f
AS
140482000-07-30 Alex Samuel <samuel@codesourcery.com>
14049
14050 * mangle.c (DECL_TEMPLATE_ID_P): Remove.
14051 (CLASSTYEP_TEMPLATE_ID_P): Check template info, and context when
14052 ascertaining primaryness.
14053 (G): Remove template_args.
14054 (decl_is_template_id): New function.
14055 (write_encoding): Use decl_is_template_id.
14056 (write_name): Likewise. Handle type_decls. Get main variant of
14057 type decls.
14058 (write_nested_name): Likewise.
14059 (write_prefix): Likewise.
14060 (write_template_prefix): Likewise.
14061 (write_special_name_constructor): Remove defunct production from
14062 comment.
14063 (write_bare_function_type): Remove comment about absent parameter.
14064 (write_template_template_arg): Add missing grammar production to
14065 comment.
14066
9076e292
JM
140672000-07-27 Jason Merrill <jason@redhat.com>
14068
14069 * decl.c (duplicate_decls): If common_type produces a non-typedef
14070 type for a typedef, just use the old type.
14071
b2244c65
MM
140722000-07-27 Mark Mitchell <mark@codesourcery.com>
14073
14074 * cp-tree.h (function_depth): Declare.
14075 (verify_stmt_tree): Likewise.
14076 (find_tree): Likewise.
14077 * decl.c (function_depth): Give it external linkage.
14078 * optimize.c (optimize_function): Increment and decrement it.
14079 * tree.c (verify_stmt_tree_r): New function.
14080 (verify_stmt_tree): Likewise.
14081 (find_tree_r): Likewise.
14082 (find_tree): Likewise.
14083
62e3bf54
JM
140842000-07-27 Jason Merrill <jason@redhat.com>
14085
9076e292
JM
14086 * pt.c (for_each_template_parm_r, case RECORD_TYPE): Use
14087 TYPE_PTRMEMFUNC_P.
14088 * cp-tree.h (TYPE_TEMPLATE_INFO): Check for TYPE_LANG_SPECIFIC.
62e3bf54 14089
5a728aca
MM
140902000-07-26 Mark Mitchell <mark@codesourcery.com>
14091
14092 * decl.c (start_cleanup_fn): Mark the function as `inline'.
14093 * decl2.c (get_guard): Call cp_finish_decl, not
14094 rest_of_decl_compilation, for local guards.
14095 * lex.c (do_identifier): Remove unused variable.
14096
d2a6f3c0 140972000-07-26 Marc Espie <espie@cvs.openbsd.org>
6a1fa5f9
ME
14098
14099 * parse.y: Add missing ';'.
14100
0c10a805
MM
141012000-07-26 Mark Mitchell <mark@codesourcery.com>
14102
14103 * parse.y (empty_parms): Use `()', not `(...)', when in the scope
14104 of `extern "C++"'.
14105
8b27e9ef
NS
141062000-07-25 Nathan Sidwell <nathan@codesourcery.com>
14107
14108 Kill strict_prototype. Backwards compatibility only for
14109 non NO_IMPLICIT_EXTERN_C systems.
14110 * cp-tree.h (flag_strict_prototype): Remove.
14111 (strict_prototype): Remove.
14112 (strict_prototypes_lang_c, strict_prototypes_lang_cplusplus): Remove.
14113 * decl.c (maybe_push_to_top_level): Adjust.
14114 (pop_from_top_level): Adjust.
14115 (decls_match): Only allow sloppy parm matching for ancient
14116 system headers.
14117 (init_decl_processing): Adjust.
14118 (grokdeclarator): Adjust.
14119 * decl2.c (flag_strict_prototype): Remove.
14120 (strict_prototype): Remove.
14121 (strict_prototypes_lang_c, strict_prototypes_lang_cplusplus): Remove.
14122 (lang_f_options): Remove "strict-prototype".
14123 (unsupported-options): Add "strict-prototype".
14124 * lex.c (do_identifier): Adjust.
14125 (do_scoped_id): Adjust.
14126 * parse.y (empty_parms): Adjust.
14127 * class.c (push_lang_context): Adjust.
14128 (pop_lang_context): Adjust.
14129 * typeck.c (comp_target_parms): Adjust.
14130
c3783399
NS
141312000-07-25 Nathan Sidwell <nathan@codesourcery.com>
14132
14133 * decl.c (poplevel): Deal with anonymous variables at for scope.
14134 (maybe_inject_for_scope_var): Likewise.
14135
a7023245
ZW
141362000-07-25 Zack Weinberg <zack@wolery.cumb.org>
14137
14138 * decl.c: Remove all signal handling code, now done in toplev.c.
14139
95ee998c
MM
141402000-07-23 Mark Mitchell <mark@codesourcery.com>
14141
14142 * decl.c (make_rtl_for_nonlocal_decl): Rework.
14143
14144 * pt.c (lookup_template_class): Ensure that TYPE_CONTEXT is set
14145 correctly.
14146
1b493b81
ZW
141472000-07-20 Zack Weinberg <zack@wolery.cumb.org>
14148
14149 * cp-tree.h: Use __FUNCTION__ not __PRETTY_FUNCTION__.
14150 Define my_friendly_assert and my_friendly_abort as macros
14151 which may call friendly_abort. Prototype friendly abort, not
14152 my_friendly_abort or my_friendly_assert.
14153 * decl.c (signal_catch): Report the signal caught in the error
14154 message. Call fatal directly.
14155 * typeck2.c (ack, my_friendly_assert): Delete.
14156 (my_friendly_abort): Rename to friendly_abort. Expect file,
14157 line, and function parameters. Report the abort code, then
14158 call fancy_abort. Do not mask an abort if errors have
14159 already occurred.
14160
a306451c
NS
141612000-07-18 Nathan Sidwell <nathan@codesourcery.com>
14162
14163 * typeck.c (comp_target_parms): Remove obsolete parameter.
14164 (comp_target_types): Adjust.
14165
f49fad00
JM
141662000-07-17 Jason Merrill <jason@redhat.com>
14167
14168 * typeck.c (mark_addressable): Never set TREE_USED.
14169 * call.c (build_call): Don't abort on calls to library functions
14170 that have been declared normally.
14171
14172 * typeck.c (build_binary_op): Fix grammar in warning.
14173
14174 * exception.cc (__eh_free): Fix prototype.
14175
14176 * decl2.c (finish_decl_parsing): Handle TEMPLATE_ID_EXPR.
14177
0e5921e8 14178 * decl.c (pushdecl): Handle seeing an OVERLOAD in
f49fad00
JM
14179 IDENTIFIER_NAMESPACE_VALUE.
14180
69690d98
MM
141812000-07-16 Mark Mitchell <mark@codesourcery.com>
14182
14183 * cp-tree.h (THUNK_VCALL_OFFSET): Update documentation.
14184 * method.c (use_thunk): Correct handling of vcall offsets.
14185
bfbbc080
ZW
141862000-07-14 Zack Weinberg <zack@wolery.cumb.org>
14187
14188 * .cvsignore: parse.h and parse.c have no cp- prefix.
14189
83a90717
MM
141902000-07-13 Mark Mitchell <mark@codesourcery.com>
14191
14192 * .cvsignore: New file.
14193
ea414c97
ZW
141942000-07-13 Zack Weinberg <zack@wolery.cumb.org>
14195
14196 * lang-specs.h: Use the new named specs. Remove unnecessary braces.
14197
792abd35
MM
141982000-07-12 Mark Mitchell <mark@codesourcery.com>
14199
14200 * Makefile.in ($(PARSE_H)): Depend directly on parse.y.
14201 * parse.c: Remove.
14202 * parse.h: Likewise.
14203
72a50ab0
MM
142042000-07-11 Mark Mitchell <mark@codesourcery.com>
14205
14206 * class.c (layout_class_type): Add pointers to virtual bases after
14207 base classes under the old ABI.
14208
0dfdeca6
BC
142092000-07-10 Benjamin Chelf <chelf@codesourcery.com>
14210
14211 * semantics.c (finish_for_stmt): Remove call to emit_line_note.
14212 (finish_continue_stmt): Likewise.
14213 (begin_for_stmt): Remove call to note_level_for_for.
14214 (finish_goto_stmt): Change call from build_min_nt
14215 to build_stmt.
14216 (finish_expr_stmt): Likewise.
14217 (begin_if_stmt): Likewise.
14218 (begin_while_stmt): Likewise.
14219 (finish_while_stmt): Likewise.
14220 (finish_return_stmt): Likewise.
14221 (begin_for_stmt): Likewise.
14222 (finish_for_stmt): Likewise.
14223 (finish_break_stmt): Likewise.
14224 (begin_switch_stmt): Likewise.
14225 (finish_case_label): Likewise.
14226 (genrtl_try_block): Likewise.
14227 (begin_try_block): Likewise.
14228 (begin_handler): Likewise.
14229 (begin_compound_stmt): Likewise.
14230 (finish_asm_stmt): Likewise.
14231 (finish_label_stmt): Likewise.
14232 (add_decl_stmt): Likewise.
14233 (finish_subobject): Likewise.
14234 (finish_decl_cleanup): Likewise.
14235 (finish_named_return_value): Likewise.
14236 (setup_vtbl_ptr): Likewise.
14237 (add_scope_stmt): Likewise.
14238 * decl.c (finish_constructor_body): Likewise.
14239 (finish_destructor_body): Likewise.
14240 * optimize.c (copy_body_r): Likewise.
14241 (initialize_inlined_parameters): Likewise.
14242 (declare_return_variable): Likewise.
14243 (expand_call_inline): Likewise.
0e5921e8 14244
f12eef58
JJ
142452000-07-10 Jakub Jelinek <jakub@redhat.com>
14246
14247 * semantics.c (expand_body): Sync interface information
14248 at the end of function body expansion.
14249
2bb5d995
JM
142502000-07-09 Jason Merrill <jason@redhat.com>
14251
14252 * init.c (build_new_1): Bail early if the call to new fails.
14253
0e5921e8 14254 * decl.c (compute_array_index_type): Check specifically for
2bb5d995
JM
14255 an INTEGER_CST, not just TREE_CONSTANT.
14256
0e5921e8 14257 * decl.c (duplicate_decls): Don't call duplicate_decls on
2bb5d995
JM
14258 the DECL_TEMPLATE_RESULT.
14259 (decls_match): Return 0 if the DECL_TEMPLATE_RESULTs have different
14260 codes.
14261
14262 * error.c (dump_template_bindings): Don't crash if we had an
14263 invalid argument list.
14264
14265 * typeck.c (c_expand_start_case): Do narrowing here.
14266 * semantics.c (finish_switch_cond): Not here.
14267
142682000-07-09 Hidvegi Zoli <hzoli@austin.ibm.com>
14269
14270 * parse.y (asm_clobbers): Do string concatenation.
14271
089acd57
MM
142722000-07-09 Mark Mitchell <mark@codesourcery.com>
14273
14274 * decl.c (pushtag): Don't put local classes in template functions
14275 on the local_classes list.
14276
142772000-07-04 Scott Snyder <snyder@fnal.gov>
14278
14279 * decl2.c (get_guard): Add missing return for old ABI local
14280 variable case.
14281
7b019c19
MM
142822000-07-09 Mark Mitchell <mark@codesourcery.com>
14283
14284 * cp-tree.h (char_type_p): New function.
14285 * decl.c (init_decl_processing): Don't initialize
14286 signed_wchar_type_node or unsigned_wchar_type_node.
14287 (complete_array_type): Handle brace-enclosed string-constants.
14288 * rtti.c (emit_support_tinfos): Remove #if 0'd code.
14289 * tree.c (char_type_p): New function.
14290 * typeck2.c (digest_init): Use char_type_p.
14291
a5f1c5f8
NS
142922000-07-06 Nathan Sidwell <nathan@codesourcery.com>
14293
14294 * pt.c (tsubst): Don't layout type, if it's error_mark.
14295
84e5ca0f
NS
142962000-07-06 Nathan Sidwell <nathan@codesourcery.com>
14297
14298 * pt.c (instantiate_pending_templates): Reset template level.
14299
ab785305
JM
143002000-07-05 Jason Merrill <jason@redhat.com>
14301
14302 * call.c (joust): Don't complain about `operator char *()' beating
14303 `operator const char *() const'.
14304
90418208
JM
143052000-07-04 scott snyder <snyder@fnal.gov>
14306 Jason Merrill <jason@redhat.com>
14307
0e5921e8 14308 * repo.c (repo_get_id): Handle the case where a class with virtual
90418208
JM
14309 bases has a null TYPE_BINFO_VTABLE.
14310
143112000-07-04 Kevin Buhr <buhr@stat.wisc.edu>
14312 Jason Merrill <jason@redhat.com>
14313
14314 * parse.y (member_init): Just pass in the type.
14315 * init.c (expand_member_init): Handle getting a type.
14316
14317