OSDN Git Service

* call.c (build_op_delete_call): Do not forget the placement
[pf3gnuchains/gcc-fork.git] / gcc / cp / ChangeLog
1 2004-03-19  Mark Mitchell  <mark@codesourcery.com>
2
3         * call.c (build_op_delete_call): Do not forget the placement
4         arguments when iterating through mutiple delete operators.
5
6         * cp-tree.h (svaed_scope): Remove last_parms.
7         (NEW_DELETE_OPNAME_P): New macro.
8         (last_function_parms): Remove.
9         (do_friend): Adjust prototype.
10         * decl.c (grokparms): Return the PARM_DECLs directly, rather than
11         using last_function_parms.
12         (grokfndecl): Take the PARM_DECLs as an argument, rather than
13         using last_function_parms.
14         (grokdeclarator): Adjust accordingly.  Do not form METHOD_TYPEs
15         for class-specific operator new and operator delete.
16         (grok_op_properties): Do not look for allocation functions with
17         METHOD_TYPEs.
18         (start_function): Use DECL_ARGUMENTS instead of
19         last_function_parms.
20         * decl.h (last_function_parms): Do not declare.
21         * decl2.c (grokclassfn): Do not use last_function_parms.
22         * friend.c (do_friend): Remove parmdecls parameter.
23         * name-lookup.c (push_to_top_level): Do not save last_function_parms.
24         (pop_from_top_level): Do not restore it.
25         * pt.c (check_explicit_specialization): Do not adjust
26         last_function_parms.
27
28         * name-lookup.c (do_local_using_decl): Create a local binding for
29         types brought in via using declarations.
30
31         * name-lookup.c (lookup_arg_dependent): Handle block-scope
32         function declarations correctly.
33
34         * semantics.c (finish_id_expression): Correct handling of
35         conversion operators to dependent types.
36
37         * typeck.c (lookup_destructor): Allow the use of destructors from
38         base classes.
39         
40 2004-03-19  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
41
42         * cxx-pretty-print.c (pp_cxx_unqualified_id): Use
43         TEMPLATE_TYPE_PARM_INDEX instead of TYPE_FIELDS.
44         * search.c (dfs_unuse_fields): Add two more TREE_CODES that mean
45         the field is named TEMPLATE_TYPE_PARM_INDEX.
46
47 2004-03-19  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
48
49         PR c++/14545
50         * parser.c (cp_parser_functional_cast): A cast to anything
51         but integral or enumaration type is not an integral constant
52         expression.
53         * pt.c (value_dependent_expression_p): Handle cast expressions
54         without operands (such as "int()").
55
56 2004-03-18  Mark Mitchell  <mark@codesourcery.com>
57
58         * semantics.c (finish_pseudo_destructor_expr): Allow differing
59         cv-qualification between the type named by the
60         pseudo-destructor-name and the object-type.
61
62         * search.c (accessible_base_p): Handle non-proper bases.
63
64         * name-lookup.c (do_nonmember_using_decl): If a using declaration
65         refers to a single overloaded function, set the type of the
66         function.
67         * tree.c (lvalue_type): Simplify.
68         * typeck.c (type_unknown_p): Do not assume all OVERLOADs have an
69         unknown type.
70         (build_unary_op): Handle OVERLOADs with known types.
71
72         * decl.c (duplicate_decls): Do not destroy DECL_ARGUMENTS for
73         function templates.
74
75         * parser.c (cp_parser_postfix_expression): Handle the use of
76         "typename" in non-dependent contexts.  Convert appropriately when
77         when using a qualified name after "->" or ".".
78
79         * call.c (conditional_conversion): Honor the requirement that some
80         conversions refer to the original object.
81
82 2004-03-18  Mark Mitchell  <mark@codesourcery.com>
83
84         * call.c (build_conditional_expr): Do not call force_rvalue for
85         operands of void_type when the conditional expression itself has
86         void type.
87         * name-lookup.c (pushdecl): Don't consider a declaration of a
88         function named "main" to be an overload of a type named "main".
89         * parser.c (cp_parser_template_name): Perform name lookup when the
90         template name is proceeded by "template" if the qualifying scope
91         is non-dependent.
92         * typeck.c (composite_pointer_type_r): Correctly handle
93         pointer-to-member types.
94         (build_const_cast): Likewise.
95
96 2004-03-18  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
97
98         * cp-tree.def (TEMPLATE_TYPE_PARM, TYPEOF_TYPE): Update comments.
99         * cp-tree.h (NEW_EXPR_USE_GLOBAL, DELETE_EXPR_USE_GLOBAL): Add check.
100         (DELETE_EXPR_USE_VEC, COMPOUND_EXPR_OVERLOADED): Likewise.
101         (KOENIG_LOOKUP_P, PTRMEM_OK_P, TEMPLATE_TYPE_PARM_INDEX): Likewise.
102         (TYPENAME_TYPE_FULLNAME): Add check and use type.values.
103         (TYPEOF_TYPE_EXPR): New macro.
104         * class.c (finish_struct_bits): Use TYPE_VFIELD and TYPE_METHODS.
105         * error.c (dump_type): Use TYPEOF_TYPE_EXPR.
106         * pt.c (tsubst): Likewise.
107         * semantics.c (finish_typeof): Likewise.
108         * search.c (dfs_unuse_fields): Handle TYPENAME_TYPE, TYPEOF_TYPE,
109         and TEMPLATE_TYPE_PARM.
110         * typeck.c (comptypes): Use TYPE_ORIG_SIZE_TYPE, not TYPE_DOMAIN.
111         (build_array_ref): Use TYPE_DOMAIN, not TYPE_VALUES.
112
113 2004-03-16  Mark Mitchell  <mark@codesourcery.com>
114
115         PR c++/14586
116         * cp-tree.h (build_new_op): Change prototype.
117         (build_x_binary_op): Likewise.
118         * call.c (build_new_op): Add overloaded_p parameter.
119         * decl2.c (grok_array_decl): Adjust call to build_new_op.
120         * parser.c (cp_parser_binary_expression): Note that uses of
121         overloaded operators prevents an expression from being considered
122         an integral constant.
123         * pt.c (tsubst_copy_and_build): Adjust calls to build_new_op and/or
124         build_x_binary_op.
125         * semantics.c (finish_call_expr): Likewise.
126         * typeck.c (rationalize_conditional_expr): Likewise.
127         (build_x_indirect_ref): Likewise.
128         (build_x_binary_op): Likewise.
129         (build_x_unary_op): Likewise.
130         (build_x_compound_expr): Likewise.
131         (build_modify_expr): Likewise.
132         * typeck2.c (build_x_arrow): Likewise.
133
134 2004-03-15  Kazu Hirata  <kazu@cs.umass.edu>
135
136         * cp-lang.c, ptree.c: Update copyright.
137
138 2004-03-13  Mark Mitchell  <mark@codesourcery.com>
139
140         PR c++/14550
141         * parser.c (cp_parser_non_integral_constant_expression): Encode
142         more of the idiom that surrounded calls to this function within
143         the function itself
144         (cp_parser_primary_expression): Adjust accordingly.
145         (cp_parser_postfix_expression): Likewise.
146         (cp_parser_unary_expression): Likewise.
147         (cp_parser_cast_expression): Likewise.
148         (cp_parser_assignment_expression): Likewise.
149         (cp_parser_expression): Likewise.
150         (cp_parser_new_expression): Note that new-expressions are not
151         allowed in integral constant expressions.
152         (cp_parser_delete_expression): Likewise.
153
154 2004-03-12  Matt Austern  <austern@apple.com>
155
156         * decl2.c (maybe_make_one_only): Look at
157         TARGET_EXPLICIT_INSTANTIATION_ONE_ONLY when deciding whether
158         to make an explicit instantiation weak.
159         * method.c (use_thunk): Make sure we call comdat_linkage
160         when appropriate.
161         * pt.c (do_type_instantiation): On systems where weak symbols
162         don't go in a static archive's TOC, explicit instantiation of a
163         class must imply *explicit* instantiation of its memeber.
164         
165 2004-03-11  Kazu Hirata  <kazu@cs.umass.edu>
166
167         * call.c, cp-tree.h, pt.c: Fix comment typos.
168
169 2004-03-10  Mark Mitchell  <mark@codesourcery.com>
170
171         PR c++/14510
172         * decl.c (xref_tag): Disregard non-type declarations when
173         looking up a tagged type. 
174
175 2004-03-09  Nathan Sidwell  <nathan@codesourcery.com>
176
177         PR c++/14397
178         * call.c (convert_like_real): Build a const qualified temporary,
179         when testing ctor access.
180
181 2004-03-09  Mark Mitchell  <mark@codesourcery.com>
182
183         * call.c (initialize_reference): Fix typo.
184
185 2004-03-09  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
186
187         PR c++/14409
188         * pt.c (determine_specialization): For member templates, match also
189         constness.
190
191         PR c++/14448
192         * parser.c (cp_parser_initializer_clause): Fold initializer if it is
193         non-dependent.
194         * pt.c (tsubst_copy_and_build): Handle NOP_EXPRs.
195
196 2004-03-09  Mark Mitchell  <mark@codesourcery.com>
197
198         PR c++/14230
199         * call.c (initialize_reference): Handle initializers that are
200         class-member access expressions applies to rvalues.
201
202 2004-03-09  Mark Mitchell  <mark@codesourcery.com>
203
204         PR c++/14432
205         * name-lookup.c (supplement_binding): Ignore functions that are
206         marked DECL_ANTICIPATED.
207
208 2004-03-08  Mark Mitchell  <mark@codesourcery.com>
209
210         PR c++/14401
211         * class.c (check_field_decls): Complain about non-static data
212         members of reference type in unions.  Propagate
213         CLASSTYPE_REF_FIELDS_NEED_INIT and
214         CLASSTYPE_READONLY_FIELDS_NEED_INIT from the types of non-static
215         data members.
216         * init.c (perform_member_init): Complain about mbmers with const
217         type that are not explicitly initialized.
218
219 2004-03-08  Mark Mitchell  <mark@codesourcery.com>
220
221         * class.c (check_methods): Don't use IDENTIFIER_ERROR_LOCUS.
222         * cp-tree.h (DECL_INVALID_OVERRIDER_P): New macro.
223         (lang_identifier): Remove implicit_decl and error_locus.
224         (IDENTIFIER_IMPLICIT_DECL): Remove.
225         (SET_IDENTIFIER_IMPLICTI_DECL): Likewise.
226         (IDENTIFIER_ERROR_LOCUS): Likewise.
227         (SET_IDENTIFIER_ERROR_LOCUS): Likewise.
228         (TYPE_ASSEMBLER_NAME_STRING): Likewise.
229         (TYPE_ASSEMBLER_NAME_LENGTH): Likewise.
230         (implicitly_declare): Remove.
231         * decl.c (warn_extern_redeclared_static): Remove check of
232         IDENTIFIER_IMPLICIT_DECL.
233         (duplicate_decls): Don't check IDENTIFIER_ERROR_LOCUS.
234         (implicitly_declare): Remove.
235         (grok_ctor_properties): Don't set IDENTIFIER_ERROR_LOCUS.
236         (start_function): Don't check IDENTIFIER_IMPLICIT_DECL.
237         (start_method): Don't check IDENTIFIER_ERROR_LOCUS.
238         * lex.c (unqualified_name_lookup_error): Create a dummy VAR_DECL
239         in the innermost scope, rather than at namespace scope.
240         * name-lookup.c (push_local_binding): Give it external linkage.
241         (pushdecl): Remove dead code.
242         * name-lookup.h (push_local_binding): Declare it.
243         * ptree.c (cxx_print_identifier): Don't print
244         IDENTIFIER_IMPLICIT_DECL or IDENTIFIER_ERROR_LOCUS.
245         * search.c (check_final_overrider): Use DECL_INVALID_OVERRIDER_P,
246         not IDENTIFIER_ERROR_LOCUS.
247         * typeck.c (build_function_call): Remove dead code.
248
249 2004-03-08  Jason Merrill  <jason@redhat.com>
250
251         PR c++/13170
252         * decl.c (xref_tag): Remove attribute handling.
253         * cp-tree.h: Adjust prototype.
254         * decl.c, parser.c, rtti.c: Adjust callers.
255         * parser.c (cp_parser_class_head): Pass back attributes in the
256         class head.
257         (cp_parser_class_specifier): Adjust.
258
259 2004-03-08  Matt Austern  <austern@apple.com>
260
261         PR debug/14079
262         * name-lookup.c (add_decl_to_level): Add extern variables, as well
263         as static, to static_decls array.
264         
265 2004-03-05  Jason Merrill  <jason@redhat.com>
266
267         * tree.c (list_hash_pieces): s/TYPE_HASH/TREE_HASH/.
268
269 2004-03-04  Geoffrey Keating  <geoffk@apple.com>
270
271         * decl.c (grokfndecl): Update old incorrect comment.
272         (grokvardecl): Diagnose C++ variables of type with no linkage.
273
274 2004-03-01  Mark Mitchell  <mark@codesourcery.com>
275
276         PR c++/14369
277         * pt.c (build_non_dependent_expr): Do not create a
278         NON_DEPENDENT_EXPR for a THROW_EXPR.
279
280 2004-03-01  Gabriel Dos Reis  <gdr@integrable-solutions.net>
281
282         PR c++/14369
283         * error.c (dump_expr): Handle THROW_EXPR.
284
285 2004-03-01  Mark Mitchell  <mark@codesourcery.com>
286
287         PR c++/14360
288         * parser.c (cp_parser_postfix_expression): Do not perform Koenig
289         lookup if ordinary name-lookup finds a non-function.
290         * pt.c (tsubst_copy_and_build): Likewise.
291
292         PR c++/14361
293         * parser.c (cp_parser_late_parsing_default_args): Check that there
294         are no extra tokens after the end of the default-argument
295         expression.
296         
297 2004-03-01  Mark Mitchell  <mark@codesourcery.com>
298
299         PR c++/14324
300         * lex.c (retrofit_lang_decl): Treat entities with no linkage as
301         having C++ linkage for name-mangling purposes.
302
303         PR c++/14260
304         * parser.c (cp_parser_direct_declarator): Recognize constructor
305         declarators that use a template-id to name the class being
306         constructed.
307
308         PR c++/14337
309         * pt.c (tsubst_qualified_id): Handle dependent qualifying scopes.
310         (tsubst_expr): Do not call tsubst_copy, even when
311         processing_template_decl.       
312
313 2004-03-01  Jeff Law  <law@redhat.com>
314
315         * init.c (build_vec_delete_1): Convert 2nd argument to NE_EXPR to
316         the proper type.
317
318 2004-02-29  Mark Mitchell  <mark@codesourcery.com>
319
320         PR c++/14138
321         * name-lookup.h (push_scope): Change prototype.
322         * name-lookup.c (push_scope): Do not reenter the current class
323         scope.
324         * decl.c (grokfndecl): Check return code from push_scope before
325         calling pop_scope.
326         * decl2.c (check_classfn): Likewise.
327         * parser.c (cp_parser_conversion_function_id): Likewise.
328         (cp_parser_init_declarator): Likewise.
329         (cp_parser_direct_declarator): Likewise.
330         (cp_parser_class_specifier): Likewise.
331         (cp_parser_class_head): Likewise.
332         (cp_parser_lookup_name): Likewise.
333         (cp_parser_constructor_declarator_p): Likewise.
334         * pt.c (instantiate_class_template): Likewise.
335         (resolve_typename_type): Likewise.
336
337 2004-02-29  Mark Mitchell  <mark@codesourcery.com>
338
339         PR c++/14267
340         * typeck.c (build_modify_expr): Remove more of the cast-as-lvalue
341         extension.
342
343         PR debug/12103
344         * class.c (update_vtable_entry_for_fn): Do not go through
345         covariance machinery if the type returned by an overrider is the
346         same as the original.
347
348 2004-02-29  Kazu Hirata  <kazu@cs.umass.edu>
349
350         * call.c: Fix a comment typo.
351
352 2004-02-27  Ziemowit Laski  <zlaski@apple.com>
353
354         * tree.c (pod_type_p): Treat VECTOR_TYPEs as PODs.
355
356 2004-02-26  Mark Mitchell  <mark@codesourcery.com>
357
358         PR c++/14278
359         * parser.c (cp_parser_parameter_declaration_list): Commit
360         to fewer tentative parses.
361
362 2004-02-26  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
363
364         PR c++/14284
365         * pt.c (dependent_type_p_r): A template template parameter is a
366         dependent type.
367
368 2004-02-26  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
369
370         PR c++/14246
371         * mangle.c (write_template_arg_literal): Don't rely on identity for
372         boolean constants.
373
374 2004-02-24  Jason Merrill  <jason@redhat.com>
375
376         * tree.c (build_exception_variant): Use check_qualified_type.
377
378 2004-02-23  Zack Weinberg  <zack@codesourcery.com>
379             Kazu Hirata  <kazu@cs.umass.edu>
380
381         * decl.c (cxx_init_decl_processing): Don't check
382         flag_writable_strings.
383
384 2004-02-23  Andrew Pinski  <pinskia@physics.uc.edu>
385
386         PR c++/14156
387         * typeck.c (maybe_warn_about_returning_address_of_location):
388         Change check for VAR_DECL to use DECL_P instead.
389
390 2004-02-23  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
391
392         PR c++/14250
393         * cvt.c (build_expr_type_conversion): Type must be complete before
394         looking up for conversions.
395
396 2004-02-23  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
397
398         PR c++/14143
399         * name-lookup.c (arg_assoc_class): Don't look into template 
400         arguments if it is not a primary template.
401
402 2004-02-20  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
403
404         PR c++/12007
405         * method.c (use_thunk): Always clone function argument tree.
406
407 2004-02-20  Mark Mitchell  <mark@codesourcery.com>
408
409         PR c++/14199
410         * pt.c (tsubst_copy): Call mark_used for a PARM_DECL.
411
412         PR c++/14173
413         * semantics.c (begin_class_definition): Set TYPE_PACKED correctly
414         for all type variants.
415
416 2004-02-19  Mark Mitchell  <mark@codesourcery.com>
417
418         PR c++/13927
419         * decl.c (duplicate_decls): Return error_mark_node for invalid
420         redeclarations.
421         * name-lookup.c (push_namespace): Ignore the return value from
422         pushdecl.
423         * pt.c (push_template_decl_real): Robustify.
424
425         PR c++/14186
426         * name-lookup.c (push_class_level_binding): Do not complain about
427         adding a binding for a member whose name is the same as the
428         enclosing class if the member is located in a base class of the
429         current class.
430
431 2004-02-19  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
432
433         PR c++/14181
434         * parser.c (cp_parser_new_expression): Parse an ill-formed 
435         direct-new-declarator after a parenthesized type-id to emit good
436         diagnostic.
437
438 2004-02-18  Kazu Hirata  <kazu@cs.umass.edu>
439
440         * cp-tree.def, cvt.c: Update copyright.
441
442 2004-02-17  Mark Mitchell  <mark@codesourcery.com>
443
444         PR c++/11326
445         * cp-tree.h (abi_version_at_least): Remove.
446         * mangle.c: Include flags.h.
447
448 2004-02-15  Mark Mitchell  <mark@codesourcery.com>
449
450         PR c++/13971
451         * call.c (build_conditional_expr): Handle conversions between
452         class types which result in differently cv-qualified type
453         variants.
454
455         PR c++/14086
456         * class.c (delete_duplicate_fields_1): Remove.
457         (delete_duplicate_fields): Likewise.
458         (finish_struct_anon): Remove check for members with the same name
459         as their enclosing class.
460         (check_field_decls): Do not call duplicate_fields.
461         * decl.c (grokdeclarator): Remove check for static data members
462         with the same name as their enclosing class.
463         * name-lookup.c (push_class_level_binding): Check for members with
464         the same name as their enclosing class.
465
466 2004-02-15  Gabriel Dos Reis  <gdr@integrable-solutions.net>
467
468         PR c++/14085
469         * error.c (dump_decl): Handle TEMPLATE_TYPE_PARM.
470
471 2004-02-14  Kriang Lerdsuwanakij  <lerdsuwa@users.sourceforge.net>
472
473         PR c++/13635
474         * pt.c (push_template_decl_real): Make sure DECL_TI_ARGS of DECL
475         has full set of arguments.
476
477 2004-02-13  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
478
479         PR c++/13927
480         * error.c (dump_decl) <ALIAS_DECL>: Dump as simple declarations.
481
482 2004-02-13  Mark Mitchell  <mark@codesourcery.com>
483
484         PR c++/14122
485         * cp-tree.h (delete_sanity): Change prototype.
486         * decl2.c (delete_sanity): Make doing_vec a bool, not an int.
487         Remove dead code.  Adjust code to warn about deleting an array.
488         * typekc.c (decay_conversion): Use build_address and build_nop.
489
490         PR c++/14108
491         * search.c (accessible_p): Do not check access in thunks.
492
493         PR c++/14083
494         * call.c (build_conditional_expr): Call force_rvalue on the
495         non-void operand in the case that one result is a throw-expression
496         and the other is not.
497
498 2004-02-13  Ian Lance Taylor  <ian@wasabisystems.com>
499
500         PR c++/9851
501         * parser.c (cp_parser_pseudo_destructor_name): Check for errors on
502         the type name and look ahead for ::~, and bail out early with a
503         better error message if the parse is going to fail.
504
505 2004-02-12  Mark Mitchell  <mark@codesourcery.com>
506
507         * call.c (conversion_kind): New type.
508         (conversion_rank): Likewise.
509         (conversion): Likewise.
510         (CONVERSION_RANK): New macro.
511         (conversion_obstack): New variable.
512         (obstack_initialized): Likewise.
513         (z_candidate): Change type of convs and second_conv.
514         (candidate_warning): New type.
515         (IDENTITY_RANK): Remove.
516         (EXACT_RANK): Likewise.
517         (PROMO_RANK): Likewise.
518         (STD_RANK): Likewise.
519         (PBOOL_RANK): Likewise.
520         (USER_RANK): Likewise.
521         (ELLIPSIS_RANK): Likewise.
522         (BAD_RANK): Likewise.
523         (ICS_RANK): Likewise.
524         (ICS_STD_RANK): Likewise.
525         (ICS_USER_FLAG): Likewise.
526         (ICS_ELLIPSIS_FLAG): Likewise.
527         (ICS_THIS_FLAG): Likewise.
528         (ICS_BAD_FLAG): Likewise.
529         (NEED_TEMPORARY_P): Likewise.
530         (CHECK_COPY_CONSTRUCTOR_P): Likewise.
531         (USER_CONV_CAND): Likewise.
532         (USER_CONV_FN): Likewise.
533         (conversion_obstack_alloc): New function.
534         (alloc_conversion): Likewise.
535         (validate_conversion_obstack): Likewise.
536         (alloc_conversions): Likewise.
537         (build_conv): Adjust to deal with new conversion data structures.
538         (build_identity_conv): New function.
539         (build_ambiguous_conv): Likewise.
540         (standard_conversion): Adjust to deal with new conversion data
541         structures.
542         (convert_class_to_reference): Likewise.
543         (direct_reference_binding): Likewise.
544         (reference_binding): Likewise.
545         (implicit_conversion): Likewise.
546         (add_candidate): Likewise.
547         (add_function_candidate): Likewise.
548         (add_conv_candidate): Likewise.
549         (build_builtin_candidate): Likewise.
550         (print_z_candidate): Likewise.
551         (merge_conversion_sequences): Likewise.
552         (build_user_type_conversion_1): Likewise.
553         (build_user_type_conversion): Likewise.
554         (build_new_function_call): Likewise.
555         (build_object_call): Likewise.
556         (conditional_conversion): Likewise.
557         (build_conditional_expr): Likewise.
558         (build_new_op): Likewise.
559         (build_op_delete_call): Likewise.
560         (convert_like_real): Likewise.
561         (build_over_call): Likewise.
562         (build_new_method_call): Likewise.
563         (is_subseq): Likewise.
564         (maybe_handle_implicit_object): Likewise.
565         (maybe_handle_ref_bind): Likewise.
566         (compare_ics): Likewise.
567         (source_type): Likewise.
568         (add_warning): Likewise.
569         (joust): Likewise.
570         (can_convert_arg): Likewise.
571         (can_convert_arg_bad): Likewise.
572         (perform_implicit_conversion): Likewise.
573         (perform_direct_initialization_if_possible): Likewise.
574         (initialize_reference): Likewise.
575         * cp-lang.c (cp_tree_size): Do not handle WRAPPER.
576         * cp-tree.def (WRAPPER): Likewise.
577         (IDENTITY_CONV): Remove.
578         (LVALUE_CONV): Likewise.
579         (QUAL_CONV): Likewise.
580         (STD_CONV): Likewise.
581         (PTR_CONV): Likewise.
582         (PMEM_CONV): Likewise.
583         (BASE_CONV): Likewise.
584         (REF_BIND): Likewise.
585         (USER_CONV): Likewise.
586         (AMBIG_CONV): Likewise.
587         (RVALUE_CONV): Likewise.
588         * cp-tree.h (tree_wrapper): Remove.
589         (WRAPPER_ZC): Remove.
590         (lang_tree_node): Remove wrapper.
591         (LOOKUP_SPECULATIVELY): Remove.
592         (build_op_delete_call): Adjust prototype.
593         (validate_conversion_obstack): Declare.
594         (build_zc_wrapper): Remove.
595         * cvt.c (convert_to_reference): Remove dead code.
596         (ocp_convert): Likewise.
597         * decl.c (redeclaration_error_message): Correct handling of
598         templates.
599         (finish_destructor_body): Do not use LOOKUP_SPECULATIVELY.
600         (cp_tree_node_structure): Remove WRAPPER case.
601         * decl2.c (finish_file): Call validate_conversion_obstack.
602         * init.c (build_new_1): Remove use of LOOKUP_SPECULATIVELY.
603         (build_op_delete_call): Likewise.
604         (build_x_delete): Likewise.
605         (build_delete): Adjust call to build_op_delete_call.
606         * pt.c (tsubst_friend_declaration): Adjust code to determine
607         whether or not a friend template is a definition.
608         (tsubst_decl): Clear DECL_INITIAL for new FUNCTION_DECLs.
609         * tree.c (build_zc_wrapper): Remove.
610         
611 2004-02-12  Zack Weinberg  <zack@codesourcery.com>
612
613         * cp-lang.c: Don't define LANG_HOOKS_BUILTIN_TYPE_DECLS.
614         * cp-tree.h: Don't declare cxx_builtin_type_decls.
615         * decl.c (builtin_type_decls, cxx_builtin_type_decls): Delete.
616         (record_builtin_type): Call debug_hooks->type_decl on the TYPE_DECL.
617
618 2004-02-10  Mark Mitchell  <mark@codesourcery.com>
619
620         * typeck.c (lookup_destructor): Fix typo in error message.
621
622 2004-02-09  Kazu Hirata  <kazu@cs.umass.edu>
623
624         * call.c, parser.c, tree.c: Fix comment typos.
625
626 2004-02-07  Zack Weinberg  <zack@codesourcery.com>
627
628         Bug 13856
629         * optimize.c (maybe_clone_body): Don't update DECL_ESTIMATED_INSNS.
630         * decl.c (duplicate_decls, start_function): Likewise.
631
632 2004-02-07  Zack Weinberg  <zack@codesourcery.com>
633
634         * name-lookup.c (pushdecl): Issue shadow warnings directly.
635         * parser.c (free_parser_stacks): Delete.
636
637 2004-02-07  Kazu Hirata  <kazu@cs.umass.edu>
638
639         * rtti.c: Update copyright.
640
641 2003-02-06  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
642
643         PR c++/14033
644         * decl.c (require_complete_types_for_parms): Do not insert
645         error_mark_node in the parameter list.
646
647 2003-02-06  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
648
649         PR c++/14028
650         * parser.c (cp_parser_enclosed_template_argument_list): Emit straight
651         error when terminator can not be found.
652
653 2004-02-05  Kelley Cook  <kcook@gcc.gnu.org>
654
655         Make-lang.in (po-generated):  Delete.
656
657 2004-02-05  Kazu Hirata  <kazu@cs.umass.edu>
658
659         * call.c (type_passed_as): Replace PROMOTE_PROTOTYPES with
660         targetm.calls.promote_prototypes.
661
662 2004-02-05  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
663
664         PR middle-end/13750
665         Revert:
666         2004-01-15  Geoffrey Keating  <geoffk@apple.com>
667         PR pch/13361
668         * cp/lex.c (handle_pragma_interface): Duplicate string from tree.
669         (handle_pragma_implementation): Likewise.
670
671 2004-02-05  Mark Mitchell  <mark@codesourcery.com>
672
673         PR c++/13714
674         * typeck.c (lookup_destructor): Tweak error message.
675
676 2004-02-05  Jan Hubicka  <jh@suse.cz>
677
678         * tree.c (cp_cannot_inline_tree_fn):  Allow inlining of comdat
679         functions.
680
681 2003-02-05  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
682
683         PR c++/14008
684         * parser.c (cp_parser_diagnose_invalid_typename): Removed parsing
685         code, only emits the diagnostic now. Added lookup of the identifier
686         and support for qualified ids.
687         (cp_parser_parse_and_diagnose_invalid_type_name): New function.
688         Parse an (invalid) type name as id-expression within a declarator.
689         (cp_parser_simple_declaration): Use it.
690         (cp_parser_member_declaration): Likewise.
691         (cp_parser_make_typename_type): New function. Handle errors through
692         cp_parser_diagnose_invalid_typename.
693         (cp_parser_elaborated_type_specifier): Use it.
694
695 2004-02-04  Mark Mitchell  <mark@codesourcery.com>
696
697         PR c++/13932
698         * call.c (convert_like_real): Use "converting" rather than
699         "argument" as the descriptive keyword to
700         dubious_conversion_warnings.
701         * typeck.c (convert_for_assignment): Do not call
702         dubious_conversion_warnings.
703
704 2004-02-04  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
705
706         PR c++/13086
707         * init.c (build_delete): Emit a more informative error message in
708         case of an incomplete type, and on the correct source line.
709
710 2004-02-04  Kazu Hirata  <kazu@cs.umass.edu>
711
712         * error.c, search.c: Update copyright.
713
714 2004-02-04  Mark Mitchell  <mark@codesourcery.com>
715
716         PR c++/9941
717         * rtti.c (tinfo_base_init): Use import_export_tinfo to decide the
718         linkage for the typeinfo name string.
719
720 2004-02-04  Mark Mitchell  <mark@codesourcery.com>
721
722         PR c++/13969
723         * cp-tree.h (fold_non_dependent_expr): New function.
724         * parser.c (cp_parser_fold_non_dependent_expr): Remove.
725         (cp_parser_template_argument): Use fold_non_dependent_expr.
726         (cp_parser_direct_declarator): Likewise.
727         * pt.c (fold_non_dependent_expr): New function.
728         (convert_nontype_argument): Use it.
729         (tsubst_qualified_id): Simplify.
730         (tsubst_copy_and_build): Likewise.
731
732 2004-02-04  Mark Mitchell  <mark@codesourcery.com>
733
734         * decl.c (cxx_push_function_context): Do not set
735         current_function_is_thunk.
736         * method.c (use_thunk): Set CALL_FROM_THUNK on the call to the
737         actual function.
738
739 2003-02-04  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
740
741         PR c++/13997
742         * pt.c (more_specialized_class): Increase processing_template_decl
743         while partial ordering.
744
745 2004-02-03  Mark Mitchell  <mark@codesourcery.com>
746
747         PR c++/13925
748         * decl.c (start_function): Do not call pushdecl for any
749         instantiation or specialization of a primary template.
750
751 2004-02-03  Mark Mitchell  <mark@codesourcery.com>
752
753         PR c++/13950
754         * parser.c (cp_parser_class_name): Robustify.
755
756         PR c++/13970
757         * parser.c (cp_parser_cache_group): Do not consume the EOF token.
758
759         PR c++/14002
760         * semantics.c (finish_id_expression): Do not return an
761         IDENTIFIER_NODE when lookup finds a PARM_DECL.
762
763 2004-02-03  Mark Mitchell  <mark@codesourcery.com>
764
765         PR c++/13978
766         * pt.c (build_non_dependent_expr): Do not build
767         NON_DEPENDENT_EXPRs for FUNCTION_DECLs or TEMPLATE_DECLs.
768
769         PR c++/13968
770         * semantics.c (finish_id_expression): Do not return an
771         IDENTIFIER_NODE when lookup finds a VAR_DECL.
772
773         PR c++/13975
774         * parser.c (cp_parser_simple_declaration): When skipping to the
775         end of the statement swallow the terminating semicolon.
776
777 2004-02-02  Mark Mitchell  <mark@codesourcery.com>
778
779         PR c++/13113
780         * init.c (build_offset_ref): Improve error recovery for invalid
781         uses of non-static member functions.
782
783         PR c++/13854
784         * cp-tree.h (cp_build_type_attribute_variant): New function.
785         * class.c (build_clone): Use cp_build_type_attribute_variant.
786         * decl.c (duplicate_decls): Likewise.
787         * pt.c (copy_default_args_to_explicit_spec): Likewise.
788         (tsubst_function_type): Likewise.
789         * tree.c (build_exception_variant): Check attributes before
790         concluding that two types are the same.
791         (cp_build_type-attribute_variant): New method.
792         * typeck.c (merge_types): Use cp_build_type_attribute_variant.
793
794         PR c++/13907
795         * call.c (convert_class_to_reference): Keep better track of
796         pedantically invalid user-defined conversions.
797
798 2004-02-01  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
799
800         PR c++/13957
801         * pt.c (tsubst_qualified_id): Improved error message when a type
802         is expected but not found.
803
804 2004-01-31  Kazu Hirata  <kazu@cs.umass.edu>
805
806         * class.c: Fix comment typos.
807         * decl.c: Likewise.
808         * error.c: Likewise.
809         * parser.c: Likewise.
810         * pt.c: Likewise.
811         * search.c: Likewise.
812         * typeck.c: Likewise.
813
814 2004-01-30  Richard Henderson  <rth@redhat.com>
815
816         PR c++/13693
817         * method.c (use_thunk): Don't force_target_expr for void thunks.
818         * tree.c (build_target_expr_with_type): Assert non-void type.
819         (force_target_expr): Likewise.
820
821 2004-01-30  Michael Matz  <matz@suse.de>
822
823         * parser.c (cp_parser_labeled_statement): Accept case ranges.
824
825 2004-01-30  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
826
827         DR206
828         PR c++/13813
829         * decl.c (grokdeclarator): Check immediatly type completeness for
830         non-dependent types.
831
832 2004-01-30  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
833
834         PR c++/13683
835         * call.c (convert_arg_to_ellipsis): Don't emit a warning if within
836         a sizeof expression.block
837
838 2004-01-29  Mark Mitchell  <mark@codesourcery.com>
839
840         PR c++/13883
841         * mangle.c (write_encoding): Correct encoding of member template
842         constructors.
843
844 2004-01-28  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
845
846         * parser.c (cp_parser_template_id): Parse tentatively `[:' after a
847         template name as it was `<::' (digraph typo).
848         (cp_parser_nth_token_starts_template_argument_list_p): New function.
849         (cp_parser_id_expression): Use it.
850         (cp_parser_nested_name_specifier_opt): Likewise.
851         (cp_parser_template_name): Likewise.
852         (cp_parser_class_name): Likewise.
853         (cp_lexer_get_preprocessor_token): Use c_lex_with_flags.
854
855 2004-01-28  Mark Mitchell  <mark@codesourcery.com>
856
857         PR c++/13791
858         * typeck.c (merge_types): Do not merge attributes into
859         TYPENAME_TYPEs.
860
861         PR c++/13736
862         * parser.c (cp_parser_direct_declarator): Do not prevent
863         backtracking inside a parenthesized declarator.
864         (cp_parser_parameter_declaration): Fix typo in comment.
865
866 2004-01-28  Jan Hubicka  <jh@suse.cz>
867
868         * semantics.c (expand_body)  Do emit_associated_thunks before
869         expansion.
870
871 2004-01-27  Devang Patel  <dpatel@apple.com>
872
873         * name-lookup.c: Include "debug.h"
874         (do_namespace_alias): Invoke debug_hooks to emit debug info
875         for namespace alias.
876         (do_local_using_decl): Invoke debug_hooks to emit debug info
877         for using decl.
878         (do_class_using_decl): Same.
879         (do_toplevel_using_decl): Same.
880         (do_using_directive): Same.
881         (cp_emit_debug_info_for_using): New function.
882         * Make-lang.in (cp/parser.o): Depend on debug.h
883         (cp/name-lookup.o): Same.
884
885 2004-01-26  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
886
887         * cp-tree.h (language_function, lang_type_header): Use
888         BOOL_BITFIELD.
889         * name-lookup.h (cp_binding_level): Likewise.
890
891 2004-01-26  Mark Mitchell  <mark@codesourcery.com>
892
893         PR c++/13663
894         * semantics.c (finish_for_expr): Check for unresolved overloaded
895         functions.
896
897         * class.c (add_method): Just check processing_template_decl to
898         determine whether or not we are within a template.
899         * decl2.c (maybe_retrofit_in_chrg): Likewise.
900         * init.c (decl_constant_value): Check the type of the declaration,
901         not TREE_READONLY.
902         * name-lookup.c (maybe_push_to_top_level): Rename to ...
903         (push_to_top_level): ... this.
904         * name-lookup.h (maybe_push_to_top_level): Do not declare it.
905         * pt.c (push_template_decl_real): Reorder condition for speed.
906         (convert_template_argument): Use dependency-checking functions in
907         place of uses_template_parms.
908         (lookup_template_class): Avoid calling uses_template_parms more
909         than once.
910         (uses_template_parms): Reimplement, using dependency-checking
911         functions.
912         (instantiate_class_template): Use push_to_top_level, not
913         maybe_push_to_top_level.
914         (type_unification_real): Simplify.
915         (type_dependent_expression_p): Handle OFFSET_REFs and
916         TEMPLATE_DECLs.
917         (any_dependent_template_arguments_p): Handle multiple levels of
918         template argument.
919         * semantics.c (expand_or_defer_fn): Do not check
920         uses_template_parms for template instantiations.
921         * typeck.c (comptypes): Avoid calling cp_type_quals.
922
923 2004-01-25  Mark Mitchell  <mark@codesourcery.com>
924
925         PR c++/13833
926         * call.c (build_over_call): Do not convert arguments when
927         processing a template.
928         * pt.c (build_non_dependent_expr): Do not build a
929         NON_DEPENDENT_EXPR for arithmetic constants.
930
931 2004-01-25  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
932
933         PR c++/13810
934         * parser.c (cp_parser_type_parameter): When cp_parser_id_expression
935         returns a TYPE_DECL. no further lookup is required.
936         * semantics.c (check_template_template_default_arg): A TYPE_DECL
937         is invalid. Rework to give better diagnostics.
938
939 2004-01-25  Kriang Lerdsuwanakij  <lerdsuwa@users.sourceforge.net>
940
941         PR c++/13797
942         * pt.c (instantiate_class_template): Add an error_mark_node
943         check.
944         (tsubst_decl) <TEMPLATE_DECL case>: Likewise.
945
946 2004-01-23  Andrew Pinski  <pinskia@physics.uc.edu>
947
948         PR c++/13701
949         * decl.c (finish_function): Move the call to
950         finish_fname_decls below the call to
951         finish_eh_spec_block.
952
953 2004-01-21  Kazu Hirata  <kazu@cs.umass.edu>
954
955         * optimize.c, typeck2.c: Update copyright.
956
957 2004-01-21  Kazu Hirata  <kazu@cs.umass.edu>
958
959         * Make-lang.in, call.c, class.c, decl2.c, except.c, expr.c,
960         init.c, mangle.c, typeck.c: Update copyright.
961
962 2004-01-21  Zdenek Dvorak  <rakdver@atrey.karlin.mff.cuni.cz>
963
964         * parser.c (cp_parser_class_specifier): Prevent garbage collection.
965
966 2004-01-20  Kelley Cook  <kcook@gcc.gnu.org>
967
968         * Make-lang.in: Replace $(docdir) with doc.
969         (c++.info, c++.srcinfo): Dummy entry.
970         (c++.man, c++.srcman): New rules.
971         (c++.install-man): Revamp rule.
972
973 2004-01-20  Kelley Cook  <kcook@gcc.gnu.org>
974
975         * Make-lang.in (CXX_INSTALL_NAME, GXX_INSTALL_NAME,
976         CXX_TARGET_INSTALL_NAME, GXX_TARGET_INSTALL_NAME): Define via a
977         immediate $(shell) instead of deferred backquote.
978
979 2004-01-19  Mark Mitchell  <mark@codesourcery.com>
980
981         PR c++/13651
982         * parser.c (cp_parser_postfix_expression): When encountering
983         incomplete type on left-hand side of "->" or ".", treat the entire
984         expression as erroneous.
985
986         PR c++/13592
987         * call.c (build_field_call): Remove.
988         (n_build_method_call): Likewise.
989         (build_method_call): Likewise.
990         (build_new_method_call): Do not call build_field_call.
991         * class.c (n_build_method_call): Remove.
992         (print_class_statistics): Do not print it.
993         * cp-tree.h (build_method_call): Remove declaration.
994         (finish_object_call_expr): Likewise.
995         (build_new_1): Do not use build_method_call.
996         * parser.c (cp_parser_postfix_expression): Use finish_call_expr
997         when the function appearing on the right-hand-side of "." or "->"
998         is not actually a function.
999         * pt.c (tsubst_copy_and_build): Likewise.
1000         * semantics.c (finish_object_call_expr): Remove.
1001
1002 2004-01-18  Mark Mitchell  <mark@codesourcery.com>
1003
1004         PR c++/13710
1005         * pt.c (tsubst): Use finish_typeof.
1006
1007 2004-01-18  Jason Merrill  <jason@redhat.com>
1008
1009         PR c++/11725
1010         * except.c (build_throw): In a template, set
1011         current_function_returns_abnormally.
1012
1013 2004-01-17  Fred Fish  <fnf@intrinsity.com>
1014
1015         PR c++/11895
1016         * decl.c (reshape_init): Handle VECTOR_TYPE like ARRAY_TYPE,
1017         except don't call array_type_nelts() with a VECTOR_TYPE.
1018
1019 2004-01-16  Jan Hubicka  <jh@suse.cz>
1020
1021         * mangle.c (write_mangled_name): Remove inline modifier.
1022
1023 2004-01-16  Mark Mitchell  <mark@codesourcery.com>
1024
1025         PR c++/13574
1026         * decl.c (compute_array_index_type): Fix grammar in comment.
1027         * init.c (build_zero_init): Handle zero-sized arrays correctly.
1028
1029         PR c++/13178
1030         * call.c (name_as_c_string): Print conversion operator names
1031         correctly.
1032
1033         PR c++/13478
1034         * call.c (initialize_reference): Pass -1 for inner parameter to
1035         convert_like_real.
1036
1037 2004-01-15  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1038
1039         PR c++/13407
1040         * parser.c (cp_parser_base_specifier): Check for an invalid
1041         keyword `typename' and emit an user-friendly error message.
1042
1043 2004-01-15  Geoffrey Keating  <geoffk@apple.com>
1044
1045         PR pch/13361
1046         * cp/lex.c (handle_pragma_interface): Duplicate string from tree.
1047         (handle_pragma_implementation): Likewise.
1048
1049 2004-01-15  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1050
1051         PR c++/9259
1052         * typeck.c (build_class_member_access_expr): Allow to access members
1053         of the currently open class.
1054         (finish_class_member_access_expr): Likewise.
1055
1056 2004-01-15  Alexandre Oliva  <aoliva@redhat.com>
1057
1058         PR c++/13659
1059         * name-lookup.c (validate_nonmember_using_decl): Take scope and
1060         name by value, instead of computing them.
1061         (do_local_using_decl, do_toplevel_using_decl): Add scope and name
1062         arguments.  Pass them to validate_nonmember_using_decl.
1063         * name-lookup.h (do_local_using_decl): Adjust.
1064         (do_toplevel_using_decl): Likewise.
1065         * parser.c (cp_parser_using_declaration): Likewise.
1066         * pt.c (tsubst_expr): Likewise.
1067
1068 2004-01-15  Alexandre Oliva  <aoliva@redhat.com>
1069
1070         PR c++/13594
1071         PR c++/13658
1072         * name-lookup.c (qualified_lookup_using_namespace): Search
1073         strongly-associated namespaces first, and only then try other
1074         namespaces.
1075
1076 2004-01-15  Kelley Cook  <kcook@gcc.gnu.org>
1077
1078         * Make-lang.in (c++.srcextra): Dummy entry.
1079
1080 2004-01-15  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1081
1082         PR c++/8856
1083         * parser.c (cp_parser_template_name): Don't try to parse a
1084         conversion-function-id, as it cannot be a template-name.
1085         (cp_parser_simple_type_specifier): Check for invalid template-ids
1086         even after a built-in type.
1087
1088 2004-01-14  Jan Hubicka  <jh@suse.cz>
1089
1090         PR c++/12850
1091         * pt.c (instantiate_decl):  Do not increase function_depth.
1092
1093 2004-01-14  Danny Smith  <dannysmith@users,sourceforge.net>
1094
1095         PR c++/9021
1096         PR c++/11005
1097         * parser.c (cp_parser_elaborated_type_specifier): Warn about
1098         attributes and discard.
1099         * decl.c (xref_tag): Don't overwite existing attributes with
1100         NULL_TREE.
1101
1102 2004-01-14  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1103
1104         PR c++/12335
1105         * parser.c (cp_parser_lookup_name): Return error_mark_node if there
1106         is no destructor while looking up a BIT_NOT_EXPR.
1107
1108 2004-01-13  Ian Lance Taylor  <ian@wasabisystems.com>
1109
1110         * cxxfilt.c: Remove unused file.
1111
1112 2004-01-14  Jan Hubicka  <jh@suse.cz>
1113
1114         Partial fix to PR c++/12850
1115         * decl2.c (mark_used): Do not proactively instantiate templates
1116         when compiling in unit-at-a-time or not optimizing.
1117         * optimize.c (maybe_clone_body): Do not increase function depth.
1118
1119 2004-01-13  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1120
1121         PR c++/13474
1122         * pt.c (tsubst) <INTEGER_TYPE>: Remove obsolete array index tweaking.
1123
1124 2003-01-12  Steven Bosscher  <stevenb@suse.de>
1125
1126         PR c++/13558
1127         * parser.c (cp_parser_member_declaration): Any non-type is also
1128         not a class or a function.
1129
1130 2004-01-12  Jason Merrill  <jason@redhat.com>
1131
1132         PR c++/12815
1133         * class.c (build_base_path): Do not mark vtable references as
1134         TREE_CONSTANT.
1135         (build_vtbl_ref_1): Likewise.
1136
1137 2004-01-12  Richard Henderson  <rth@redhat.com>
1138
1139         PR opt/10776
1140         * typeck2.c (split_nonconstant_init_1, split_nonconstant_init): New.
1141         (store_init_value): Use it.
1142         * decl.c (check_initializer): Expect full initialization code
1143         from store_init_value.
1144         * init.c (expand_aggr_init_1): Likewise.
1145         * decl2.c (maybe_emit_vtables): Abort if runtime init needed.
1146
1147 2004-01-12  Mark Mitchell  <mark@codesourcery.com>
1148
1149         * class.c (layout_class_type): For non-POD class types, also copy
1150         the DECL_SIZE and DECL_MODE of fields to the base class type.
1151
1152 2004-01-12  Kriang Lerdsuwanakij  <lerdsuwa@users.sourceforge.net>
1153
1154         PR c++/13289
1155         * pt.c (instantiate_decl): Set DECL_TEMPLATE_INSTANTIATED before
1156         calling regenerate_decl_from_template.
1157
1158 2004-01-12  Scott Brumbaugh  <scottb.lists@verizon.net>
1159
1160         PR c++/4100
1161         * parser.c (cp_parser_decl_specifier_seq): Add check for a friend
1162         decl-specifier occurring along with a class definition.
1163
1164 2004-01-12  Ian Lance Taylor  <ian@wasabisystems.com>
1165
1166         * parser.c (cp_parser_decl_specifier_seq): Add parenthetical
1167         clauses to comments describing declares_class_or_enum.
1168         (cp_parser_type_specifier): Set *declares_class_or_enum to 0, not
1169         false.
1170
1171 2004-01-12  Jan Hubicka  <jh@suse.cz>
1172
1173         * pt.c (for_each_template_parm): Do not check for duplicates.
1174         (for_each_template_parm): Use walk_tree duplicate checking code.
1175
1176 2004-01-11  Ian Lance Taylor  <ian@wasabisystems.com>
1177
1178         PR c++/3478
1179         * parser.c (cp_parser_decl_specifier_seq): If the first decl_spec
1180         is error_mark_node, don't add any more decl_specs.
1181         (cp_parser_init_declarator): After committing to a declaration, if
1182         the decl_specifiers start with error_mark_node, issue an error and
1183         change the type to "int".
1184
1185 2004-01-09  Nathanael Nerode  <neroden@gcc.gnu.org>
1186
1187         PR bootstrap/7817
1188         * Make-lang.in: Copy gcc.1 to g++.1 rather than using .so.
1189
1190 2004-01-10  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1191
1192         DR 337
1193         PR c++/9256
1194         * pt.c (tsubst): Substitution must fail if we are attempting to
1195         create an array with element type that is an abstract class type.
1196         * decl.c (cp_finish_decl): Strip pointers and array types recursively
1197         before calling abstract_virtuals_error.
1198
1199 2004-01-09  Alexandre Oliva  <aoliva@redhat.com>
1200
1201         * name-lookup.c (qualified_lookup_using_namespace): Consider
1202         strong using directives even if we've already found a binding.
1203
1204 2004-01-09  Mark Mitchell  <mark@codesourcery.com>
1205
1206         * cp-tree.h (cxx_expand_expr): Change prototype.
1207         * expr.c (cxx_expand_expr): Add alt_rtl parameter.
1208
1209 2004-01-08  Giovanni Bajo  <giovannibajo@gcc.gnu.org>
1210
1211         PR c++/12573
1212         * pt.c (value_dependent_expression_p): Handle COMPONENT_REFs by
1213         looking into them recursively. They can be there because of the
1214         new __offsetof__ extension.
1215
1216 2004-01-07  Zack Weinberg  <zack@codesourcery.com>
1217
1218         * parser.c (cp_parser_save_member_function_body): Mark the
1219         definition static.
1220
1221 2004-01-05  Mark Mitchell  <mark@codesourcery.com>
1222
1223         PR c++/13057
1224         * class.c (build_clone): Copy type attributes from the original
1225         function to the clone.
1226
1227         PR c++/12815
1228         * class.c (build_vtbl_ref_1): Do not unconditionally mark vtable
1229         references as constant.
1230
1231         PR c++/12132
1232         * parser.c (cp_parser_explicit_instantiation): Improve error
1233         recovery.
1234         (cp_parser_require): Improve indication of the error location.
1235
1236         PR c++/13451
1237         * parser.c (cp_parser_class_head): Reorder logic to check for
1238         invalid qualification.
1239
1240 2004-01-04  Mark Mitchell  <mark@codesourcery.com>
1241
1242         PR c++/13157
1243         * name-lookup.c (lookup_using_namespace): Remove spacesp
1244         parameter.
1245         (unqualified_namespace_lookup): Likewise.
1246         (lookup_qualified_name): Adjust accordingly.
1247         (lookup_name_real): Likewise.
1248         (lookup_arg_dependent): Do not eliminate the namespace of the
1249         functions found by unqualified name lookup unless that is the
1250         current namespace.
1251
1252 2004-01-04  Andrew Pinski  <pinskia@physics.uc.edu>
1253
1254         * semantics.c (push_deferring_access_checks): Fix format.
1255         (resume_deferring_access_checks): Likewise.
1256         (stop_deferring_access_checks): Likewise.
1257         (pop_deferring_access_checks): Likewise.
1258         (get_deferred_access_checks): Likewise.
1259         (pop_to_parent_deferring_access_checks): Likewise.
1260         (perform_deferred_access_checks): Likewise.
1261         (perform_or_defer_access_check): Likewise.
1262
1263 2004-01-04  Richard Henderson  <rth@redhat.com>
1264
1265         * call.c (build_over_call): Don't create a save_expr of an
1266         aggregate, but rather its address.
1267
1268 2004-01-04  Mark Mitchell  <mark@codesourcery.com>
1269
1270         PR c++/13529
1271         * parser.c (cp_parser_postfix_expression): Allow "." to appear in
1272         an offsetof expression.
1273
1274         * parser.c (cp_parser_parameter_declaration): Fix comment.
1275
1276         PR c++/12226
1277         * call.c (CHECK_COPY_CONSTRUCTOR_P): New macro.
1278         (reference_binding): Set it when appropriate.
1279         (build_temp): New function, split out from ...
1280         (convert_like_real): ... here.  Honor CHECK_COPY_CONSTRUCTOR_P.
1281         (initialize_reference): Likewise.
1282
1283         PR c++/13536
1284         * parser.c (cp_parser): Add in_type_id_in_expr_p.
1285         (cp_parser_new): Initialize it.
1286         (cp_parser_postfix_expression): Set it.
1287         (cp_parser_sizeof_operand): Likewise.
1288         (cp_parser_parameteR_declaration): Do not commit early to tenative
1289         parsers when in_type_id_in_expr_p is set.
1290
1291 2004-01-03  Kriang Lerdsuwanakij  <lerdsuwa@users.sourceforge.net>
1292
1293         PR c++/13094
1294         * parser.c (cp_parser_template_argument): Don't call
1295         make_unbound_class_template directly.
1296         (cp_parser_lookup_name): Don't extract TEMPLATE_DECL from
1297         UNBOUND_CLASS_TEMPLATE tree node.
1298
1299 2004-01-02  Richard Sandiford  <rsandifo@redhat.com>
1300
1301         PR target/12729
1302         * method.c (use_thunk): Pass the CALL_EXPR through force_target_expr.
1303
1304 2004-01-02  Kriang Lerdsuwanakij  <lerdsuwa@users.sourceforge.net>
1305
1306         PR c++/13520
1307         * cp-tree.h (DECL_UNBOUND_CLASS_TEMPLATE_P): New macro.
1308         (DECL_FUNCTION_TEMPLATE_P): Use it.
1309         (DECL_CLASS_TEMPLATE_P): Likewise.
1310         * parser.c (cp_parser_lookup_name): Add is_template parameter.
1311         (cp_parser_type_parameter): Adjust call to cp_parser_lookup_name.
1312         (cp_parser_template_name): Likewise.
1313         (cp_parser_elaborated_type_specifier): Likewise.
1314         (cp_parser_namespace_name): Likewise.
1315         (cp_parser_class_name): Likewise.
1316         (cp_parser_lookup_name_simple): Likewise.
1317
1318 See ChangeLog.3 for earlier changes.