re PR fortran/56650 (Odd error messages with C_SIZEOF for valid code)
[platform/upstream/gcc.git] / gcc / fortran / ChangeLog
1 2013-03-27  Tobias Burnus  <burnus@net-b.de>
2
3         PR fortran/56650
4         PR fortran/36437
5         * check.c (gfc_check_sizeof, gfc_check_c_sizeof,
6         gfc_check_storage_size): Update checks.
7         * intrinsic.texi (SIZEOF): Correct class.
8         * intrinsic.h (gfc_simplify_sizeof,
9         gfc_simplify_storage_size): New prototypes.
10         * intrinsic.c (add_functions): Use them.
11         * simplify.c (gfc_simplify_sizeof,
12         gfc_simplify_storage_size): New functions.
13
14 2013-03-27  Janne Blomqvist  <jb@gcc.gnu.org>
15
16         PR fortran/25708
17         * module.c (module_locus): Use long for position.
18         (module_content): New variable.
19         (module_pos): Likewise.
20         (prev_character): Remove.
21         (bad_module): Free data instead of closing mod file.
22         (set_module_locus): Use module_pos.
23         (get_module_locus): Likewise.
24         (module_char): use buffer rather than stdio file.
25         (module_unget_char): Likewise.
26         (read_module_to_tmpbuf): New function.
27         (gfc_use_module): Call read_module_to_tmpbuf.
28
29 2013-03-26  Tobias Burnus  <burnus@net-b.de>
30
31         PR fortran/56649
32         * simplify.c (gfc_simplify_merge): Simplify more.
33
34 2013-03-25  Tobias Burnus  <burnus@net-b.de>
35
36         PR fortran/38536
37         PR fortran/38813
38         PR fortran/38894
39         PR fortran/39288
40         PR fortran/40963
41         PR fortran/45824
42         PR fortran/47023
43         PR fortran/47034
44         PR fortran/49023
45         PR fortran/50269
46         PR fortran/50612
47         PR fortran/52426
48         PR fortran/54263
49         PR fortran/55343
50         PR fortran/55444
51         PR fortran/55574
52         PR fortran/56079
53         PR fortran/56378
54         * check.c (gfc_var_strlen): Properly handle 0-sized string.
55         (gfc_check_c_sizeof): Use is_c_interoperable, add checks.
56         (is_c_interoperable, gfc_check_c_associated, gfc_check_c_f_pointer,
57         gfc_check_c_f_procpointer, gfc_check_c_funloc, gfc_check_c_loc): New
58         functions.
59         * expr.c (check_inquiry): Add c_sizeof, compiler_version and
60         compiler_options.
61         (gfc_check_pointer_assign): Refine function result check.
62         gfortran.h (gfc_isym_id): Add GFC_ISYM_C_ASSOCIATED,
63         GFC_ISYM_C_F_POINTER, GFC_ISYM_C_F_PROCPOINTER, GFC_ISYM_C_FUNLOC,
64         GFC_ISYM_C_LOC.
65         (iso_fortran_env_symbol, iso_c_binding_symbol): Handle
66         NAMED_SUBROUTINE.
67         (generate_isocbinding_symbol): Update prototype.
68         (get_iso_c_sym): Remove.
69         (gfc_isym_id_by_intmod, gfc_isym_id_by_intmod_sym): New prototypes.
70         * intrinsic.c (gfc_intrinsic_subroutine_by_id): New function.
71         (gfc_intrinsic_sub_interface): Use it.
72         (add_functions, add_subroutines): Add missing C-binding intrinsics.
73         (gfc_intrinsic_func_interface): Add special case for c_loc.
74         gfc_isym_id_by_intmod, gfc_isym_id_by_intmod_sym): New functions.
75         (gfc_intrinsic_func_interface, gfc_intrinsic_sub_interface): Use them.
76         * intrinsic.h (gfc_check_c_associated, gfc_check_c_f_pointer,
77         gfc_check_c_f_procpointer, gfc_check_c_funloc, gfc_check_c_loc,
78         gfc_resolve_c_loc, gfc_resolve_c_funloc): New prototypes.
79         * iresolve.c (gfc_resolve_c_loc, gfc_resolve_c_funloc): New
80         functions.
81         * iso-c-binding.def: Split PROCEDURE into NAMED_SUBROUTINE and
82         NAMED_FUNCTION.
83         * iso-fortran-env.def: Add NAMED_SUBROUTINE for completeness.
84         * module.c (create_intrinsic_function): Support subroutines and
85         derived-type results.
86         (use_iso_fortran_env_module): Update calls.
87         (import_iso_c_binding_module): Ditto; update calls to
88         generate_isocbinding_symbol.
89         * resolve.c (find_arglists): Skip for intrinsic symbols.
90         (gfc_resolve_intrinsic): Find intrinsic subs via id.
91         (is_scalar_expr_ptr, gfc_iso_c_func_interface,
92         set_name_and_label, gfc_iso_c_sub_interface): Remove.
93         (resolve_function, resolve_specific_s0): Remove calls to those.
94         (resolve_structure_cons): Fix handling.
95         * symbol.c (gen_special_c_interop_ptr): Update c_ptr/c_funptr
96         generation.
97         (gen_cptr_param, gen_fptr_param, gen_shape_param,
98         build_formal_args, get_iso_c_sym): Remove.
99         (std_for_isocbinding_symbol): Handle NAMED_SUBROUTINE.
100         (generate_isocbinding_symbol): Support hidden symbols and
101         using c_ptr/c_funptr symtrees for nullptr defs.
102         * target-memory.c (gfc_target_encode_expr): Fix handling
103         of c_ptr/c_funptr.
104         * trans-expr.c (conv_isocbinding_procedure): Remove.
105         (gfc_conv_procedure_call): Remove call to it.
106         (gfc_trans_subcomponent_assign, gfc_conv_expr): Update handling
107         of c_ptr/c_funptr.
108         * trans-intrinsic.c (conv_isocbinding_function,
109         conv_isocbinding_subroutine): New.
110         (gfc_conv_intrinsic_function, gfc_conv_intrinsic_subroutine):
111         Call them.
112         * trans-io.c (transfer_expr): Fix handling of c_ptr/c_funptr.
113         * trans-types.c (gfc_typenode_for_spec,
114         gfc_get_derived_type): Ditto.
115         (gfc_init_c_interop_kinds): Handle NAMED_SUBROUTINE.
116
117 2013-03-18  Tobias Burnus  <burnus@net-b.de>
118
119         * gfortran.h (gfc_option_t): Remove flag_whole_file.
120         * invoke.texi (-fno-whole-file): Remove.
121         * lang.opt (fwhole-file): Change to Ignore.
122         * options.c (gfc_init_options, gfc_post_options,
123         gfc_handle_option): Remove !flag_whole_file handling
124         * parse.c (resolve_all_program_units, translate_all_program_units,
125         gfc_parse_file): Ditto.
126         * resolve.c (resolve_global_procedure): Ditto.
127         * trans-decl.c (gfc_get_symbol_decl, gfc_get_extern_function_decl,
128         gfc_create_module_variable): Ditto.
129         * trans-types.c (gfc_get_derived_type): Ditto.
130
131 2013-03-15  Tobias Burnus  <burnus@net-b.de>
132
133         PR fortran/56615
134         * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Pack arrays
135         if they are not simply contiguous.
136
137 2013-03-11  Tobias Burnus  <burnus@net-b.de>
138
139         * gfortran.texi (STRUCTURE and RECORD): State more clearly how
140         to convert them into derived types.
141
142 2013-03-10  Paul Thomas  <pault@gcc.gnu.org>
143
144         PR fortran/56575
145         * expr.c (gfc_default_initializer): Check that a class declared
146         type has any components.
147         * resolve.c (resolve_fl_derived0): On failing the test for C437
148         set the type to BT_UNKNOWN to prevent repeat error messages.
149
150 2013-03-03  Mikael Morin  <mikael@gcc.gnu.org>
151
152         PR fortran/56477
153         * expr.c (gfc_check_pointer_assign): Avoid NULL pointer dereference.
154
155 2013-03-03  Mikael Morin  <mikael@gcc.gnu.org>
156
157         PR fortran/54730
158         * array.c (gfc_match_array_constructor): Set a checkpoint before
159         matching a typespec.  Drop it on success, restore it otherwise.
160
161 2013-03-03  Mikael Morin  <mikael@gcc.gnu.org>
162
163         PR fortran/54730
164         * gfortran.h (struct gfc_undo_change_set): New field 'previous'.
165         (gfc_new_undo_checkpoint, gfc_drop_last_undo_checkpoint,
166         gfc_restore_last_undo_checkpoint): New prototypes.
167         * symbol.c (default_undo_chgset_var): Update initialization.
168         (single_undo_checkpoint_p, gfc_new_undo_checkpoint,
169         free_undo_change_set_data, pop_undo_change_set,
170         gfc_drop_last_undo_checkpoint, enforce_single_undo_checkpoint):
171         New functions.
172         (save_symbol_data): Handle multiple change sets.  Make sure old_symbol
173         field's previous value is not overwritten.  Clear gfc_new field.
174         (restore_old_symbol): Restore previous old_symbol field.
175         (gfc_restore_last_undo_checkpoint): New function, using body renamed
176         from gfc_undo_symbols.  Restore the previous change set as current one.
177         (gfc_undo_symbols): New body.
178         (gfc_commit_symbols, gfc_commit_symbol, gfc_enforce_clean_symbol_state):
179         Call enforce_single_undo_checkpoint.
180         (gfc_symbol_done_2): Ditto.  Free change set data.
181
182 2013-03-03  Mikael Morin  <mikael@gcc.gnu.org>
183
184         * symbol.c (restore_old_symbol): Fix thinko.
185
186 2013-03-03  Mikael Morin  <mikael@gcc.gnu.org>
187
188         * symbol.c (gfc_undo_symbols): Move code...
189         (restore_old_symbol): ... here as a new function.
190
191 2013-03-03  Mikael Morin  <mikael@gcc.gnu.org>
192
193         * Make-lang.in (F95_PARSER_OBJS): Add dependency to vec.h.
194         * gfortran.h: Include vec.h.
195         (gfc_undo_change_set): New struct.
196         * symbol.c (tentative_tbp): Remove struct.
197         (changed_syms, tentative_tbp_list): Remove variables.
198         (default_undo_chgset_var, latest_undo_chgset): New variables.
199         (save_symbol_data, gfc_get_sym_tree, gfc_undo_symbols,
200         gfc_commit_symbols, gfc_commit_symbol,
201         gfc_enforce_clean_symbol_state, gfc_get_typebound_proc):
202         Use latest_undo_chgset instead of changed_syms and tentative_tbp_list.
203
204 2013-03-01  Tobias Burnus  <burnus@net-b.de>
205
206         PR fortran/56491
207         * iresolve.c (resolve_bound): Use gfc_get_string instead of xstrdup.
208         * symbol.c (free_components): Free proc-pointer components.
209
210 2013-03-01  Tobias Burnus  <burnus@net-b.de>
211
212         * trans-decl.c (gfc_trans_deferred_vars): Free expr after use.
213         * trans-io.c (build_dt): Ditto.
214
215 2013-02-24  Joseph Myers  <joseph@codesourcery.com>
216
217         * resolve.c (generate_component_assignments): Don't use UTF-8
218         ligature in diagnostic.
219
220 2013-02-21  Janus Weil  <janus@gcc.gnu.org>
221
222         PR fortran/56385
223         * trans-array.c (structure_alloc_comps): Handle procedure-pointer
224         components with allocatable result.
225
226 2012-02-21  Tobias Burnus  <burnus@net-b.de>
227
228         PR fortran/56416
229         * gfortran.texi (Part II: Language Reference, Extensions,
230         Non-Fortran Main Program): Sort @menu to match actual section order.
231         * intrinsic.texi (Intrinsic Procedures): Ditto.
232         (C_F_POINTER, PRECISION): Move to the alphabetically correct place.
233
234 2013-02-15  Tobias Burnus  <burnus@net-b.de>
235             Mikael Morin  <mikael@gcc.gnu.org>
236
237         PR fortran/56318
238         * simplify.c (gfc_simplify_matmul): Fix result shape
239         and matmul result.
240
241 2013-02-15  Tobias Burnus  <burnus@net-b.de>
242
243         PR fortran/53818
244         * resolve.c (apply_default_init_local): Don't create an
245         initializer for a result variable.
246
247 2013-02-14  Thomas Koenig  <tkoenig@gcc.gnu.org>
248
249         PR fortran/56224
250         * gfortran.h (gfc_add_include_path):  Add boolean argument
251         for warn.
252         * scanner.c (gfc_add_include_path):  Pass along warn argument
253         to add_path_to_list.
254         * options.c (gfc_post_options):  Add true warn argument to
255         gfc_add_include_path.
256         (gfc_handle_module_path_options):  Likewise.
257         (gfc_handle_option): Also gfc_add_include_path for intrinsic
258         modules, without warning.
259
260 2013-02-14  Paul Thomas  <pault@gcc.gnu.org>
261             Tobias Burnus  <burnus@net-b.de>
262
263         PR testsuite/56138
264         * trans-decl.c (gfc_get_symbol_decl): Fix deferred-length
265         results for functions without extra result variable.
266
267         Revert:
268         2013-01-30  Tobias Burnus  <burnus@net-b.de>
269
270         PR fortran/56138
271         * trans-decl.c (gfc_trans_deferred_vars): Fix deferred-length
272         results for functions without extra result variable.
273
274 2013-02-12  Janus Weil  <janus@gcc.gnu.org>
275
276         PR fortran/46952
277         * resolve.c (resolve_call): Do not check deferred procedures for
278         recursiveness.
279
280 2013-02-09  Paul Thomas  <pault@gcc.gnu.org>
281
282         PR fortran/55362
283         * check.c (array_check): It is an error if a procedure is
284         passed.
285
286 2013-02-08  Mikael Morin  <mikael@gcc.gnu.org>
287
288         PR fortran/54107
289         * trans-types.c (gfc_get_function_type): Change a NULL backend_decl
290         to error_mark_node on entry.  Detect recursive types.  Build a variadic
291         procedure type if the type is recursive.  Restore the initial
292         backend_decl.
293
294 2013-02-07  Tobias Burnus  <burnus@net-b.de>
295
296         PR fortran/54339
297         * gfortran.texi (Standards): Mention TS29113.
298         (Varying Length Character): Mention deferred-length
299         strings.
300         (Fortran 2003 Status): Add unlimited polymorphic.
301         (TS 29113 Status): Add TYPE(*) and DIMENSION(..).
302         (C Interop): Update the section about TS29113.
303
304 2013-02-06 Paul Thomas  <pault@gcc.gnu.org>
305
306         PR fortran/55789
307         * trans-array.c (trans_array_constructor): Remove condition
308         'dynamic' = true if the loop ubound is a VAR_DECL.
309
310 2013-02-04  Paul Thomas  <pault@gcc.gnu.org>
311
312         PR fortran/56008
313         PR fortran/47517
314         * trans-array.c (gfc_alloc_allocatable_for_assignment): Save
315         the lhs descriptor before it is modified for reallocation. Use
316         it to deallocate allocatable components in the reallocation
317         block.  Nullify allocatable components for newly (re)allocated
318         arrays.
319
320 2013-02-04  Mikael Morin  <mikael@gcc.gnu.org>
321
322         PR fortran/54195
323         * resolve.c (resolve_typebound_procedures): Recurse through
324         resolve_symbol.
325
326 2013-02-04  Mikael Morin  <mikael@gcc.gnu.org>
327
328         PR fortran/54107
329         PR fortran/54195
330         * gfortran.h (struct gfc_symbol): New field 'resolved'.
331         * resolve.c (resolve_fl_var_and_proc): Don't skip result symbols.
332         (resolve_symbol): Skip duplicate calls.  Don't check the current
333         namespace.
334
335 2013-02-02  Thomas Koenig  <tkoenig@gcc.gnu.org>
336
337         PR fortran/50627
338         PR fortran/56054
339         * decl.c (gfc_match_end):  Remove half-ready namespace
340         from parent if the end of a block is missing.
341         * parse.c (parse_module):  Do not put namespace into
342         gsymbol on error.
343
344 2013-01-30  Tobias Burnus  <burnus@net-b.de>
345
346         PR fortran/56138
347         * trans-decl.c (gfc_trans_deferred_vars): Fix deferred-length
348         results for functions without extra result variable.
349
350 2013-01-29  Janus Weil  <janus@gcc.gnu.org>
351             Mikael Morin  <mikael@gcc.gnu.org>
352
353         PR fortran/54107
354         * gfortran.h (gfc_component): Delete members 'formal' and 'formal_ns'.
355         (gfc_copy_formal_args,gfc_copy_formal_args_ppc,gfc_expr_replace_symbols,
356         gfc_expr_replace_comp): Delete.
357         (gfc_sym_get_dummy_args): New prototype.
358         * dependency.c (gfc_check_fncall_dependency): Use
359         'gfc_sym_get_dummy_args'.
360         * expr.c (gfc_is_constant_expr): Ditto.
361         (replace_symbol,gfc_expr_replace_symbols,replace_comp,
362         gfc_expr_replace_comp): Deleted.
363         * frontend-passes.c (doloop_code,do_function): Use
364         'gfc_sym_get_dummy_args'.
365         * interface.c (gfc_check_operator_interface,gfc_compare_interfaces,
366         gfc_procedure_use,gfc_ppc_use,gfc_arglist_matches_symbol,
367         gfc_check_typebound_override): Ditto.
368         * module.c (MOD_VERSION): Bump module version.
369         (mio_component): Do not read/write 'formal' and 'formal_ns'.
370         * resolve.c (resolve_procedure_interface,resolve_fl_derived0): Do not
371         copy formal args, but just keep a pointer to the interface.
372         (resolve_function,resolve_call,resolve_typebound_generic_call,
373         resolve_ppc_call,resolve_expr_ppc,generate_component_assignments,
374         resolve_fl_procedure,gfc_resolve_finalizers,check_generic_tbp_ambiguity,
375         resolve_typebound_procedure,check_uop_procedure): Use
376         'gfc_sym_get_dummy_args'.
377         * symbol.c (free_components): Do not free 'formal' and 'formal_ns'.
378         (gfc_copy_formal_args,gfc_copy_formal_args_ppc): Deleted.
379         (gfc_sym_get_dummy_args): New function.
380         * trans-array.c (get_array_charlen,gfc_walk_elemental_function_args):
381         Use 'gfc_sym_get_dummy_args'.
382         * trans-decl.c (build_function_decl,create_function_arglist,
383         build_entry_thunks,init_intent_out_dt,gfc_trans_deferred_vars,
384         add_argument_checking): Ditto.
385         * trans-expr.c (gfc_map_fcn_formal_to_actual,gfc_conv_procedure_call,
386         gfc_conv_statement_function): Ditto.
387         * trans-stmt.c (gfc_conv_elemental_dependencies): Ditto.
388         * trans-types.c (create_fn_spec,gfc_get_function_type): Ditto.
389
390 2013-01-28  Tobias Burnus  <burnus@net-b.de>
391             Mikael Morin  <mikael@gcc.gnu.org>
392
393         PR fortran/53537
394         * symbol.c (gfc_find_sym_tree): Don't look for the symbol outside an
395         interface block.
396         (gfc_get_ha_symtree): Let gfc_find_sym_tree lookup the parent namespace.
397         * decl.c (gfc_match_data_decl): Ditto.
398         (variable_decl): Remove undeclared type error.
399         (gfc_match_import): Use renamed instead of original name.
400
401 2013-01-27 Paul Thomas  <pault@gcc.gnu.org>
402
403         PR fortran/55984
404         PR fortran/56047
405         * gfortran.h : Add associate_var to symbol_attr.
406         * resolve.c (resolve_assoc_var): Set associate_var attribute.
407         If the target class_ok is set, set it for the associate
408         variable.
409         * check.c (allocatable_check): Associate variables should not
410         have the allocatable attribute even if their symbols do.
411         * class.c (gfc_build_class_symbol): Symbols with associate_var
412         set will always have a good class container.
413
414 2013-01-23  Janus Weil  <janus@gcc.gnu.org>
415
416         PR fortran/56081
417         * resolve.c (resolve_select): Add argument 'select_type', reject
418         non-scalar expressions.
419         (resolve_select_type,resolve_code): Pass new argument to
420         'resolve_select'.
421
422 2013-01-23  Jakub Jelinek  <jakub@redhat.com>
423
424         PR fortran/56052
425         * trans-decl.c (gfc_get_symbol_decl): Set DECL_ARTIFICIAL
426         and DECL_IGNORED_P on select_type_temporary and don't set
427         DECL_BY_REFERENCE.
428
429 2013-01-21  Thomas Koenig  <tkoenig@gcc.gnu.org>
430
431         PR fortran/55919
432         * scanner.c (add_path_to_list): Copy path to temporary and strip
433         trailing directory separators before calling stat().
434
435 2013-01-17  Richard Biener  <rguenther@suse.de>
436
437         * trans-stmt.c (gfc_trans_do): Conditionally compute countm1
438         dependent on sign of step, avoids repeated evaluation of
439         step sign test.  Avoid undefined overflow issues by using unsigned
440         arithmetic.
441
442 2013-01-16  Janus Weil  <janus@gcc.gnu.org>
443
444         PR fortran/55983
445         * class.c (find_typebound_proc_uop): Check for f2k_derived instead of
446         asserting it.
447
448 2013-01-16  Jakub Jelinek  <jakub@redhat.com>
449             Tobias Burnus  <burnus@net-b.de>
450
451         PR driver/55884
452         * lang.opt (fintrinsic-modules-path): Don't accept Joined.
453         (fintrinsic-modules-path=): New.
454         * options.c (gfc_handle_option, gfc_get_option_string,
455         gfc_get_option_string): Handle the latter.
456
457 2013-01-16  Jakub Jelinek  <jakub@redhat.com>
458
459         PR fortran/52865
460         * trans-stmt.c (gfc_trans_do): Put countm1-- before conditional
461         and use value of countm1 before the decrement in the condition.
462
463 2013-01-15  Paul Thomas  <pault@gcc.gnu.org>
464
465         PR fortran/54286
466         * expr.c (gfc_check_pointer_assign): Check for presence of
467         's2' before using it.
468
469 2013-01-14  Thomas Koenig  <tkoenig@gcc.gnu.org>
470
471         PR fortran/55806
472         * frontend-passes.c (optimize_reduction):  New function,
473         including prototype.
474         (callback_reduction):  Likewise.
475         (gfc_run_passes):  Also run optimize_reduction.
476         (copy_walk_reduction_arg):  New function.
477         (dummy_code_callback):  New function.
478
479 2013-01-13  Jakub Jelinek  <jakub@redhat.com>
480
481         PR fortran/55935
482         * trans-expr.c (gfc_conv_structure): Call
483         unshare_expr_without_location on the ctor elements.
484
485 2013-01-13  Paul Thomas  <pault@gcc.gnu.org>
486
487         PR fortran/54286
488         * expr.c (gfc_check_pointer_assign): Ensure that both lvalue
489         and rvalue interfaces are presented to gfc_compare_interfaces.
490         Simplify references to interface names by using the symbols
491         themselves. Call gfc_compare_interfaces with s1 and s2 inter-
492         changed to overcome the asymmetry of this function. Do not
493         repeat the check for the presence of s1 and s2.
494
495 2013-01-12  Janus Weil  <janus@gcc.gnu.org>
496
497         PR fortran/55072
498         * trans-array.c (gfc_conv_array_parameter): No packing was done for
499         full arrays of derived type.
500
501 2013-01-08  Paul Thomas  <pault@gcc.gnu.org>
502
503         PR fortran/55868
504         * class.c (get_unique_type_string): Change $tar to STAR and
505         replace sprintf by strcpy where there is no formatting.
506         * decl.c (gfc_match_decl_type_spec): Change $tar to STAR.
507
508 2013-01-09  Mikael Morin  <mikael@gcc.gnu.org>
509
510         PR fortran/47203
511         * module.c (check_for_ambiguous): Get the current program unit using
512         gfc_current_ns.
513
514 2013-01-09  Tobias Burnus  <burnus@net-b.de>
515
516         PR fortran/55758
517         * resolve.c (resolve_symbol): Reject non-C_Bool logicals
518         in BIND(C) procedures with -std=f*.
519
520 2013-01-08  Paul Thomas  <pault@gcc.gnu.org>
521
522         PR fortran/55618
523         * trans-expr.c (gfc_conv_procedure_call): Dereference scalar
524         character function arguments to elemental procedures in
525         scalarization loops.
526
527 2013-01-07  Tobias Burnus  <burnus@net-b.de>
528
529         PR fortran/55763
530         * gfortran.h (gfc_check_assign_symbol): Update prototype.
531         * decl.c (add_init_expr_to_sym, do_parm): Update call.
532         * expr.c (gfc_check_assign_symbol): Handle BT_CLASS and
533         improve error location; support components.
534         (gfc_check_pointer_assign): Handle component assignments.
535         * resolve.c (resolve_fl_derived0): Call gfc_check_assign_symbol.
536         (resolve_values): Update call.
537         (resolve_structure_cons): Avoid double diagnostic.
538
539 2013-01-07  Tobias Burnus  <burnus@net-b.de>
540             Thomas Koenig  <tkoenig@gcc.gnu.org>
541
542         PR fortran/55852
543         * expr.c (gfc_build_intrinsic_call): Avoid clashes
544         with user's procedures.
545         * gfortran.h (gfc_build_intrinsic_call): Update prototype.
546         * simplify.c (gfc_simplify_size): Update call.
547         * class.c (finalization_scalarizer, finalization_get_offset,
548         finalizer_insert_packed_call, generate_finalization_wrapper):
549         Clean up by using gfc_build_intrinsic_call.
550
551 2013-01-07  Tobias Burnus  <burnus@net-b.de>
552
553         PR fortran/55763
554         * resolve.c (resolve_select_type): Reject intrinsic types for
555         a non-unlimited-polymorphic selector.
556
557 2013-01-06  Paul Thomas  <pault@gcc.gnu.org>
558
559         PR fortran/53876
560         PR fortran/54990
561         PR fortran/54992
562         * trans-array.c (build_array_ref): Check the TYPE_CANONICAL
563         to see if it is GFC_CLASS_TYPE_P.
564         * trans-expr.c (gfc_get_vptr_from_expr): The same.
565         (gfc_conv_class_to_class): If the types are not the same,
566         cast parmese->expr to the type of ctree.
567         * trans-types.c (gfc_get_derived_type): GFC_CLASS_TYPE_P of
568         CLASS components must be set.
569
570 2013-01-06  Mikael Morin  <mikael@gcc.gnu.org>
571
572         PR fortran/42769
573         PR fortran/45836
574         PR fortran/45900
575         * module.c (read_module): Don't reuse local symtree if the associated
576         symbol isn't exactly the one wanted.  Don't reuse local symtree if it is
577         ambiguous.
578         * resolve.c (resolve_call): Use symtree's name instead of symbol's to
579         lookup the symtree.
580
581 2013-01-05  Steven G. Kargl  <kargl@gcc.gnu.org>
582             Mikael Morin  <mikael@gcc.gnu.org>
583
584         PR fortran/55827
585         * class.c (gfc_fix_class_refs): Adapt ts initialization for the case
586         e->symtree == NULL.
587         * trans-expr.c (gfc_conv_function_expr): Init sym earlier. Use it.
588
589 2013-01-05  Tobias Burnus  <burnus@net-b.de>
590
591         * class.c (finalize_component): Used passed offset expr.
592         (finalization_get_offset): New static function.
593         (finalizer_insert_packed_call, generate_finalization_wrapper): Use it
594         to handle noncontiguous arrays.
595
596 2013-01-04  Tobias Burnus  <burnus@net-b.de>
597
598         * trans.c (gfc_build_final_call): New function.
599         * trans.h (gfc_build_final_call, gfc_conv_scalar_to_descriptor):
600         New function prototypes.
601         * trans-expr.c (gfc_conv_scalar_to_descriptor): Renamed from
602         conv_scalar_to_descriptor, removed static attribute.
603         (gfc_conv_procedure_call): Honor renaming.
604
605 2013-01-04  Tobias Burnus  <burnus@net-b.de>
606
607         * intrinsic.c (add_functions): New internal intrinsic
608         function GFC_PREFIX ("stride").
609         * gfortran.h (gfc_isym_id): Add GFC_ISYM_STRIDE.
610         * intrinsic.h (gfc_resolve_stride): New prototypes.
611         * iresolve.c (gfc_resolve_stride): New function.
612         * trans-intrinsic.c (conv_intrinsic_stride): New static
613         function.
614         (gfc_conv_intrinsic_function): Use it.
615
616 2013-01-04  Tobias Burnus  <burnus@net-b.de>
617
618         * class.c (gfc_find_intrinsic_vtab): Add _final
619         component.
620         * decl.c (gfc_match_null): Remove superfluous
621         variadic argument to gfc_match.
622
623 2013-01-04  Paul Thomas  <pault@gcc.gnu.org>
624
625         PR fortran/55172
626         * match.c (copy_ts_from_selector_to_associate): Remove call to
627         gfc_resolve_expr and replace it with explicit setting of the
628         array reference type.
629         * resolve.c (resolve_select_type): It is an error if the
630         selector is coindexed.
631
632 2013-01-04  Tobias Burnus  <burnus@net-b.de>
633
634         PR fortran/55763
635         * decl.c (gfc_match_null): Parse and reject MOLD.
636
637 2013-01-04  Tobias Burnus  <burnus@net-b.de>
638
639         PR fortran/55854
640         PR fortran/55763
641         * class.c (gfc_class_null_initializer): Fix finding the vtab.
642         (gfc_find_intrinsic_vtab): Use BT_VOID for some components.
643
644 2013-01-03  Janus Weil  <janus@gcc.gnu.org>
645
646         PR fortran/55855
647         * expr.c (gfc_check_assign): Use 'gfc_expr_attr' to evaluate attributes
648         of rvalue. Correct hyphenation in error message.
649
650 2013-01-03  Jakub Jelinek  <jakub@redhat.com>
651
652         * gfortranspec.c (lang_specific_driver): Update copyright notice
653         dates.
654 \f
655 Copyright (C) 2013 Free Software Foundation, Inc.
656
657 Copying and distribution of this file, with or without modification,
658 are permitted in any medium without royalty provided the copyright
659 notice and this notice are preserved.