]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/fortran/ChangeLog
Makefile.in (LLINKER): New variable.
[thirdparty/gcc.git] / gcc / fortran / ChangeLog
1 2013-05-16 Jason Merrill <jason@redhat.com>
2
3 * Make-lang.in (f951$(exeext)): Use link mutex.
4
5 2013-05-05 Tobias Burnus <burnus@net-b.de>
6
7 * resolve.c (conformable_arrays): Avoid segfault
8 when ar.start[i] == NULL.
9
10 2013-05-05 Tobias Burnus <burnus@net-b.de>
11
12 PR fortran/57141
13 * decl.c (gfc_match_null): Permit use-associated
14 NULL intrinsic.
15
16 2013-05-04 Tobias Burnus <burnus@net-b.de>
17
18 * decl.c (gfc_verify_c_interop_param): Permit allocatable
19 and pointer with -std=f2008ts.
20
21 2013-05-02 Tobias Burnus <burnus@net-b.de>
22
23 PR fortran/57142
24 * simplify.c (gfc_simplify_size): Renamed from
25 simplify_size; fix kind=8 handling.
26 (gfc_simplify_size): New function.
27 (gfc_simplify_shape): Add range check.
28 * resolve.c (resolve_function): Fix handling
29 for ISYM_SIZE.
30
31 2013-05-01 Thomas Koenig <tkoenig@gcc.gnu.org>
32
33 * frontend-passes.c (optimize_power): Fix typo
34 in comment.
35
36 2013-04-30 Thomas Koenig <tkoenig@gcc.gnu.org>
37
38 PR fortran/57071
39 * frontend-passes.c (optimize_power): Simplify
40 1**k to 1.
41
42 2013-04-28 Tobias Burnus <burnus@net-b.de>
43
44 PR fortran/57114
45 * intrinsic.texi (RANK): Correct syntax description and
46 expected result.
47
48 2013-04-28 Tobias Burnus <burnus@net-b.de>
49
50 PR fortran/57093
51 * trans-types.c (gfc_get_element_type): Fix handling
52 of scalar coarrays of type character.
53 * intrinsic.texi (PACK): Add missing ")".
54
55 2013-04-28 Thomas Koenig <tkoenig@gcc.gnu.org>
56
57 PR fortran/57071
58 * frontend-passes (optimize_power): New function.
59 (optimize_op): Use it.
60
61 2013-04-25 Janne Blomqvist <jb@gcc.gnu.org>
62
63 PR bootstrap/57028
64 * Make-lang.in (f951): Link in ZLIB.
65 (CFLAGS-fortran/module.o): Add zlib include directory.
66
67 2013-04-22 Janus Weil <janus@gcc.gnu.org>
68
69 PR fortran/53685
70 PR fortran/57022
71 * check.c (gfc_calculate_transfer_sizes): Fix for array-valued SOURCE
72 expressions.
73 * simplify.c (gfc_simplify_sizeof,gfc_simplify_storage_size): Get rid
74 of special treatment for EXPR_ARRAY.
75 * target-memory.h (gfc_element_size): New prototype.
76 * target-memory.c (size_array): Remove.
77 (gfc_element_size): New function.
78 (gfc_target_expr_size): Modified to always return the full size of the
79 expression.
80
81 2013-04-20 Tobias Burnus <burnus@net-b.de>
82
83 PR fortran/56907
84 * trans-intrinsic.c (conv_isocbinding_function): Don't pack array
85 passed to C_LOC
86
87 2013-04-19 Thomas Koenig <tkoenig@gcc.gnu.org>
88 Mikael Morin <mikael@gcc.gnu.org>
89
90 PR fortran/56872
91 * frontend-passes.c (copy_walk_reduction_arg): Change argument type
92 to gfc_constructor. If it has an iterator, wrap the copy of its
93 expression in an array constructor with that iterator. Don't special
94 case function expressions.
95 (callback_reduction): Update caller. Don't return early if there is
96 an iterator.
97
98 2013-04-18 Tobias Burnus <burnus@net-b.de>
99
100 * expr.c (find_array_element): Don't copy expr.
101 * data.c (create_character_initializer): Free expr.
102 * frontend-passes.c (combine_array_constructor): Ditto.
103 * match.c (match_typebound_call, gfc_match_select_type): Ditto.
104 * resolve.c (resolve_typebound_function): Free gfc_ref.
105
106 2013-04-18 Tobias Burnus <burnus@net-b.de>
107
108 PR fortran/56994
109 * invoke.texi (NEAREST): S argument is not optional.
110
111 2013-04-17 Janus Weil <janus@gcc.gnu.org>
112
113 PR fortran/56814
114 * interface.c (check_result_characteristics): Get result from interface
115 if present.
116
117 2013-04-17 Janne Blomqvist <jb@gcc.gnu.org>
118
119 PR fortran/40958
120 * scanner.h: New file.
121 * Make-lang.in: Dependencies on scanner.h.
122 * scanner.c (gfc_directorylist): Move to scanner.h.
123 * module.c: Don't include md5.h, include scanner.h and zlib.h.
124 (MOD_VERSION): Add comment about backwards compatibility.
125 (module_fp): Change type to gzFile.
126 (ctx): Remove.
127 (gzopen_included_file_1): New function.
128 (gzopen_included_file): New function.
129 (gzopen_intrinsic_module): New function.
130 (write_char): Use gzputc.
131 (read_crc32_from_module_file): New function.
132 (read_md5_from_module_file): Remove.
133 (gfc_dump_module): Use gz* functions instead of stdio, check gzip
134 crc32 instead of md5.
135 (read_module_to_tmpbuf): Use gz* functions instead of stdio.
136 (gfc_use_module): Use gz* functions.
137
138 2013-04-16 Tobias Burnus <burnus@net-b.de>
139
140 PR fortran/39505
141 * decl.c (ext_attr_list): Add EXT_ATTR_NO_ARG_CHECK.
142 * gfortran.h (ext_attr_id_t): Ditto.
143 * gfortran.texi (GNU Fortran Compiler Directives):
144 Document it.
145 * interface.c (compare_type_rank): Ignore rank for NO_ARG_CHECK.
146 (compare_parameter): Ditto - and regard as unlimited polymorphic.
147 * resolve.c (resolve_symbol, resolve_variable): Add same constraint
148 checks as for TYPE(*); turn dummy to TYPE(*),dimension(*).
149 (gfc_explicit_interface_required): Require explicit interface
150 for NO_ARG_CHECK.
151
152 2013-04-16 Janus Weil <janus@gcc.gnu.org>
153
154 PR fortran/56968
155 * expr.c (gfc_check_pointer_assign): Handle generic functions returning
156 procedure pointers.
157
158 2013-04-16 Tobias Burnus <burnus@net-b.de>
159
160 PR fortran/56969
161 * intrinsic.c (gfc_intrinsic_func_interface): Don't set
162 module name to "(intrinsic)" for intrinsics from intrinsic
163 modules.
164
165 2013-04-15 Tobias Burnus <burnus@net-b.de>
166
167 * intrinsic.texi (SYSTEM_CLOCK): Recommend kind=8.
168
169 2013-04-15 Janne Blomqvist <jb@gcc.gnu.org>
170
171 PR fortran/56919
172 * intrinsics.texi (SYSTEM_CLOCK): Update documentation.
173
174 2013-04-15 Tobias Burnus <burnus@net-b.de>
175
176 * class.c (gfc_find_intrinsic_vtab): Removed unused var.
177 * dependency.c (check_data_pointer_types): Fix check.
178 * frontend-passes.c (check_data_pointer_types): Remove
179 superfluous statement.
180 * parse.c (decode_omp_directive): Add missing break.
181 * resolve.c (resolve_typebound_subroutine: Free variable.
182 * trans-decl.c (create_function_arglist): Correct condition.
183
184 2013-04-14 Mikael Morin <mikael@gcc.gnu.org>
185
186 PR fortran/56816
187 * match.c (gfc_match_select_type): Add syntax error. Move namespace
188 allocation and cleanup...
189 * parse.c (decode_statement): ... here.
190
191 2013-04-13 Janus Weil <janus@gcc.gnu.org>
192
193 PR fortran/55959
194 * expr.c (gfc_simplify_expr): Branch is not unreachable.
195
196 2013-04-12 Janus Weil <janus@gcc.gnu.org>
197
198 PR fortran/56266
199 * primary.c (gfc_match_varspec): Turn gcc_assert into MATCH_ERROR.
200
201 2013-04-12 Tobias Burnus <burnus@net-b.de>
202
203 PR fortran/56929
204 * trans-array.c (duplicate_allocatable): Fix handling
205 of scalar coarrays.
206
207 2013-04-12 Janus Weil <janus@gcc.gnu.org>
208
209 PR fortran/56261
210 * gfortran.h (gfc_explicit_interface_required): New prototype.
211 * expr.c (gfc_check_pointer_assign): Check if an explicit interface is
212 required in a proc-ptr assignment.
213 * interface.c (check_result_characteristics): Extra check.
214 * resolve.c (gfc_explicit_interface_required): New function.
215 (resolve_global_procedure): Use new function
216 'gfc_explicit_interface_required'. Do a full interface check.
217
218 2013-04-12 Tobias Burnus <burnus@net-b.de>
219
220 PR fortran/56845
221 * trans-decl.c (gfc_trans_deferred_vars): Restrict
222 static CLASS init to SAVE and -fno-automatic.
223
224 2013-04-12 Tobias Burnus <burnus@net-b.de>
225
226 PR fortran/56845
227 * trans-decl.c (gfc_trans_deferred_vars): Set _vptr for
228 allocatable static BT_CLASS.
229 * trans-expr.c (gfc_class_set_static_fields): New function.
230 * trans.h (gfc_class_set_static_fields): New prototype.
231
232 2013-04-11 Janne Blomqvist <jb@gcc.gnu.org>
233
234 * gfortran.h: Remove enum gfc_try, replace gfc_try with bool type.
235 * arith.c: Replace gfc_try with bool type.
236 * array.c: Likewise.
237 * check.c: Likewise.
238 * class.c: Likewise.
239 * cpp.c: Likewise.
240 * cpp.h: Likewise.
241 * data.c: Likewise.
242 * data.h: Likewise.
243 * decl.c: Likewise.
244 * error.c: Likewise.
245 * expr.c: Likewise.
246 * f95-lang.c: Likewise.
247 * interface.c: Likewise.
248 * intrinsic.c: Likewise.
249 * intrinsic.h: Likewise.
250 * io.c: Likewise.
251 * match.c: Likewise.
252 * match.h: Likewise.
253 * module.c: Likewise.
254 * openmp.c: Likewise.
255 * parse.c: Likewise.
256 * parse.h: Likewise.
257 * primary.c: Likewise.
258 * resolve.c: Likewise.
259 * scanner.c: Likewise.
260 * simplify.c: Likewise.
261 * symbol.c: Likewise.
262 * trans-intrinsic.c: Likewise.
263 * trans-openmp.c: Likewise.
264 * trans-stmt.c: Likewise.
265 * trans-types.c: Likewise.
266
267 2013-04-09 Tobias Burnus <burnus@net-b.de>
268
269 * gfortran.texi (KIND Type Parameters,
270 Internal representation of LOGICAL variables): Add crossrefs.
271 (Intrinsic Types): Mention issues with _Bool interop.
272 (Naming and argument-passing conventions): New section.
273
274 2013-04-08 Thomas Koenig <tkoenig@gcc.gnu.org>
275
276 PR fortran/56782
277 * frontend-passes.c (callback_reduction): Dont't do
278 any simplification if there is only a single element
279 which has an iterator.
280
281 2013-04-07 Tobias Burnus <burnus@net-b.de>
282
283 PR fortran/56849
284 * iresolve.c (gfc_resolve_reshape): Set shape also
285 with order=.
286
287 2013-04-04 Janus Weil <janus@gcc.gnu.org>
288
289 PR fortran/40881
290 * match.c (gfc_match_return): Remove standard notification.
291 * primary.c (gfc_match_actual_arglist): Add standard notification.
292
293 2013-04-04 Tobias Burnus <burnus@net-b.de>
294
295 PR fortran/50269
296 * gcc/fortran/check.c (is_c_interoperable,
297 gfc_check_c_loc): Correct c_loc array checking
298 for Fortran 2003 and Fortran 2008.
299
300 2013-04-03 Janus Weil <janus@gcc.gnu.org>
301
302 PR fortran/56284
303 PR fortran/40881
304 * decl.c (gfc_match_formal_arglist): Warn about alternate-return
305 arguments.
306 * interface.c (check_dummy_characteristics): Return if symbols are NULL.
307
308 2013-04-01 Janus Weil <janus@gcc.gnu.org>
309
310 PR fortran/56500
311 * symbol.c (gfc_set_default_type): Build class container for
312 IMPLICIT CLASS.
313
314 2013-03-31 Tobias Burnus <burnus@net-b.de>
315
316 * class.c (finalization_scalarizer, finalizer_insert_packed_call,
317 generate_finalization_wrapper): Avoid segfault with absent SIZE=
318 argment to TRANSFER and use correct result kind for SIZE.
319 * intrinsic.c (gfc_isym_id_by_intmod): Also handle ids of
320 nonmodules.
321 * trans.c (gfc_build_final_call): Handle coarrays.
322
323 2013-03-30 Thomas Koenig <tkoenig@gcc.gnu.org>
324
325 * trans-expr.c (build_memcmp_call): New function.
326 (gfc_build_compare_string): If the strings
327 compared have constant and equal lengths and
328 the strings are kind=1, or, for kind=4 strings,
329 the test is for (in)equality, use memcmp().
330
331 2013-03-29 Tobias Burnus <burnus@net-b.de>
332
333 PR fortran/35203
334 * trans-decl.c (create_function_arglist): Pass hidden argument
335 for passed-by-value optional+value dummies.
336 * trans-expr.c (gfc_conv_expr_present,
337 gfc_conv_procedure_call): Handle those.
338
339 2013-03-28 Thomas Koenig <tkoenig@gcc.gnu.org>
340
341 PR fortran/45159
342 * gfortran.h (gfc_dep_difference): Add prototype.
343 * dependency.c (discard_nops): New function.
344 (gfc_dep_difference): New function.
345 (check_section_vs_section): Use gfc_dep_difference
346 to calculate the difference of starting indices.
347 * trans-expr.c (gfc_conv_substring): Use
348 gfc_dep_difference to calculate the length of
349 substrings where possible.
350
351 2013-03-28 Thomas Koenig <tkoenig@gcc.gnu.org>
352
353 PR fortran/55806
354 * frontend-passes.c (optimize_code): Keep track of
355 current code to make code insertion possible.
356 (combine_array_constructor): New function.
357 (optimize_op): Call it.
358
359 2013-03-27 Tobias Burnus <burnus@net-b.de>
360
361 PR fortran/56650
362 PR fortran/36437
363 * check.c (gfc_check_sizeof, gfc_check_c_sizeof,
364 gfc_check_storage_size): Update checks.
365 * intrinsic.texi (SIZEOF): Correct class.
366 * intrinsic.h (gfc_simplify_sizeof,
367 gfc_simplify_storage_size): New prototypes.
368 * intrinsic.c (add_functions): Use them.
369 * simplify.c (gfc_simplify_sizeof,
370 gfc_simplify_storage_size): New functions.
371
372 2013-03-27 Janne Blomqvist <jb@gcc.gnu.org>
373
374 PR fortran/25708
375 * module.c (module_locus): Use long for position.
376 (module_content): New variable.
377 (module_pos): Likewise.
378 (prev_character): Remove.
379 (bad_module): Free data instead of closing mod file.
380 (set_module_locus): Use module_pos.
381 (get_module_locus): Likewise.
382 (module_char): use buffer rather than stdio file.
383 (module_unget_char): Likewise.
384 (read_module_to_tmpbuf): New function.
385 (gfc_use_module): Call read_module_to_tmpbuf.
386
387 2013-03-26 Tobias Burnus <burnus@net-b.de>
388
389 PR fortran/56649
390 * simplify.c (gfc_simplify_merge): Simplify more.
391
392 2013-03-25 Tobias Burnus <burnus@net-b.de>
393
394 PR fortran/38536
395 PR fortran/38813
396 PR fortran/38894
397 PR fortran/39288
398 PR fortran/40963
399 PR fortran/45824
400 PR fortran/47023
401 PR fortran/47034
402 PR fortran/49023
403 PR fortran/50269
404 PR fortran/50612
405 PR fortran/52426
406 PR fortran/54263
407 PR fortran/55343
408 PR fortran/55444
409 PR fortran/55574
410 PR fortran/56079
411 PR fortran/56378
412 * check.c (gfc_var_strlen): Properly handle 0-sized string.
413 (gfc_check_c_sizeof): Use is_c_interoperable, add checks.
414 (is_c_interoperable, gfc_check_c_associated, gfc_check_c_f_pointer,
415 gfc_check_c_f_procpointer, gfc_check_c_funloc, gfc_check_c_loc): New
416 functions.
417 * expr.c (check_inquiry): Add c_sizeof, compiler_version and
418 compiler_options.
419 (gfc_check_pointer_assign): Refine function result check.
420 gfortran.h (gfc_isym_id): Add GFC_ISYM_C_ASSOCIATED,
421 GFC_ISYM_C_F_POINTER, GFC_ISYM_C_F_PROCPOINTER, GFC_ISYM_C_FUNLOC,
422 GFC_ISYM_C_LOC.
423 (iso_fortran_env_symbol, iso_c_binding_symbol): Handle
424 NAMED_SUBROUTINE.
425 (generate_isocbinding_symbol): Update prototype.
426 (get_iso_c_sym): Remove.
427 (gfc_isym_id_by_intmod, gfc_isym_id_by_intmod_sym): New prototypes.
428 * intrinsic.c (gfc_intrinsic_subroutine_by_id): New function.
429 (gfc_intrinsic_sub_interface): Use it.
430 (add_functions, add_subroutines): Add missing C-binding intrinsics.
431 (gfc_intrinsic_func_interface): Add special case for c_loc.
432 gfc_isym_id_by_intmod, gfc_isym_id_by_intmod_sym): New functions.
433 (gfc_intrinsic_func_interface, gfc_intrinsic_sub_interface): Use them.
434 * intrinsic.h (gfc_check_c_associated, gfc_check_c_f_pointer,
435 gfc_check_c_f_procpointer, gfc_check_c_funloc, gfc_check_c_loc,
436 gfc_resolve_c_loc, gfc_resolve_c_funloc): New prototypes.
437 * iresolve.c (gfc_resolve_c_loc, gfc_resolve_c_funloc): New
438 functions.
439 * iso-c-binding.def: Split PROCEDURE into NAMED_SUBROUTINE and
440 NAMED_FUNCTION.
441 * iso-fortran-env.def: Add NAMED_SUBROUTINE for completeness.
442 * module.c (create_intrinsic_function): Support subroutines and
443 derived-type results.
444 (use_iso_fortran_env_module): Update calls.
445 (import_iso_c_binding_module): Ditto; update calls to
446 generate_isocbinding_symbol.
447 * resolve.c (find_arglists): Skip for intrinsic symbols.
448 (gfc_resolve_intrinsic): Find intrinsic subs via id.
449 (is_scalar_expr_ptr, gfc_iso_c_func_interface,
450 set_name_and_label, gfc_iso_c_sub_interface): Remove.
451 (resolve_function, resolve_specific_s0): Remove calls to those.
452 (resolve_structure_cons): Fix handling.
453 * symbol.c (gen_special_c_interop_ptr): Update c_ptr/c_funptr
454 generation.
455 (gen_cptr_param, gen_fptr_param, gen_shape_param,
456 build_formal_args, get_iso_c_sym): Remove.
457 (std_for_isocbinding_symbol): Handle NAMED_SUBROUTINE.
458 (generate_isocbinding_symbol): Support hidden symbols and
459 using c_ptr/c_funptr symtrees for nullptr defs.
460 * target-memory.c (gfc_target_encode_expr): Fix handling
461 of c_ptr/c_funptr.
462 * trans-expr.c (conv_isocbinding_procedure): Remove.
463 (gfc_conv_procedure_call): Remove call to it.
464 (gfc_trans_subcomponent_assign, gfc_conv_expr): Update handling
465 of c_ptr/c_funptr.
466 * trans-intrinsic.c (conv_isocbinding_function,
467 conv_isocbinding_subroutine): New.
468 (gfc_conv_intrinsic_function, gfc_conv_intrinsic_subroutine):
469 Call them.
470 * trans-io.c (transfer_expr): Fix handling of c_ptr/c_funptr.
471 * trans-types.c (gfc_typenode_for_spec,
472 gfc_get_derived_type): Ditto.
473 (gfc_init_c_interop_kinds): Handle NAMED_SUBROUTINE.
474
475 2013-03-18 Tobias Burnus <burnus@net-b.de>
476
477 * gfortran.h (gfc_option_t): Remove flag_whole_file.
478 * invoke.texi (-fno-whole-file): Remove.
479 * lang.opt (fwhole-file): Change to Ignore.
480 * options.c (gfc_init_options, gfc_post_options,
481 gfc_handle_option): Remove !flag_whole_file handling
482 * parse.c (resolve_all_program_units, translate_all_program_units,
483 gfc_parse_file): Ditto.
484 * resolve.c (resolve_global_procedure): Ditto.
485 * trans-decl.c (gfc_get_symbol_decl, gfc_get_extern_function_decl,
486 gfc_create_module_variable): Ditto.
487 * trans-types.c (gfc_get_derived_type): Ditto.
488
489 2013-03-15 Tobias Burnus <burnus@net-b.de>
490
491 PR fortran/56615
492 * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Pack arrays
493 if they are not simply contiguous.
494
495 2013-03-11 Tobias Burnus <burnus@net-b.de>
496
497 * gfortran.texi (STRUCTURE and RECORD): State more clearly how
498 to convert them into derived types.
499
500 2013-03-10 Paul Thomas <pault@gcc.gnu.org>
501
502 PR fortran/56575
503 * expr.c (gfc_default_initializer): Check that a class declared
504 type has any components.
505 * resolve.c (resolve_fl_derived0): On failing the test for C437
506 set the type to BT_UNKNOWN to prevent repeat error messages.
507
508 2013-03-03 Mikael Morin <mikael@gcc.gnu.org>
509
510 PR fortran/56477
511 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer dereference.
512
513 2013-03-03 Mikael Morin <mikael@gcc.gnu.org>
514
515 PR fortran/54730
516 * array.c (gfc_match_array_constructor): Set a checkpoint before
517 matching a typespec. Drop it on success, restore it otherwise.
518
519 2013-03-03 Mikael Morin <mikael@gcc.gnu.org>
520
521 PR fortran/54730
522 * gfortran.h (struct gfc_undo_change_set): New field 'previous'.
523 (gfc_new_undo_checkpoint, gfc_drop_last_undo_checkpoint,
524 gfc_restore_last_undo_checkpoint): New prototypes.
525 * symbol.c (default_undo_chgset_var): Update initialization.
526 (single_undo_checkpoint_p, gfc_new_undo_checkpoint,
527 free_undo_change_set_data, pop_undo_change_set,
528 gfc_drop_last_undo_checkpoint, enforce_single_undo_checkpoint):
529 New functions.
530 (save_symbol_data): Handle multiple change sets. Make sure old_symbol
531 field's previous value is not overwritten. Clear gfc_new field.
532 (restore_old_symbol): Restore previous old_symbol field.
533 (gfc_restore_last_undo_checkpoint): New function, using body renamed
534 from gfc_undo_symbols. Restore the previous change set as current one.
535 (gfc_undo_symbols): New body.
536 (gfc_commit_symbols, gfc_commit_symbol, gfc_enforce_clean_symbol_state):
537 Call enforce_single_undo_checkpoint.
538 (gfc_symbol_done_2): Ditto. Free change set data.
539
540 2013-03-03 Mikael Morin <mikael@gcc.gnu.org>
541
542 * symbol.c (restore_old_symbol): Fix thinko.
543
544 2013-03-03 Mikael Morin <mikael@gcc.gnu.org>
545
546 * symbol.c (gfc_undo_symbols): Move code...
547 (restore_old_symbol): ... here as a new function.
548
549 2013-03-03 Mikael Morin <mikael@gcc.gnu.org>
550
551 * Make-lang.in (F95_PARSER_OBJS): Add dependency to vec.h.
552 * gfortran.h: Include vec.h.
553 (gfc_undo_change_set): New struct.
554 * symbol.c (tentative_tbp): Remove struct.
555 (changed_syms, tentative_tbp_list): Remove variables.
556 (default_undo_chgset_var, latest_undo_chgset): New variables.
557 (save_symbol_data, gfc_get_sym_tree, gfc_undo_symbols,
558 gfc_commit_symbols, gfc_commit_symbol,
559 gfc_enforce_clean_symbol_state, gfc_get_typebound_proc):
560 Use latest_undo_chgset instead of changed_syms and tentative_tbp_list.
561
562 2013-03-01 Tobias Burnus <burnus@net-b.de>
563
564 PR fortran/56491
565 * iresolve.c (resolve_bound): Use gfc_get_string instead of xstrdup.
566 * symbol.c (free_components): Free proc-pointer components.
567
568 2013-03-01 Tobias Burnus <burnus@net-b.de>
569
570 * trans-decl.c (gfc_trans_deferred_vars): Free expr after use.
571 * trans-io.c (build_dt): Ditto.
572
573 2013-02-24 Joseph Myers <joseph@codesourcery.com>
574
575 * resolve.c (generate_component_assignments): Don't use UTF-8
576 ligature in diagnostic.
577
578 2013-02-21 Janus Weil <janus@gcc.gnu.org>
579
580 PR fortran/56385
581 * trans-array.c (structure_alloc_comps): Handle procedure-pointer
582 components with allocatable result.
583
584 2013-02-21 Tobias Burnus <burnus@net-b.de>
585
586 PR fortran/56416
587 * gfortran.texi (Part II: Language Reference, Extensions,
588 Non-Fortran Main Program): Sort @menu to match actual section order.
589 * intrinsic.texi (Intrinsic Procedures): Ditto.
590 (C_F_POINTER, PRECISION): Move to the alphabetically correct place.
591
592 2013-02-15 Tobias Burnus <burnus@net-b.de>
593 Mikael Morin <mikael@gcc.gnu.org>
594
595 PR fortran/56318
596 * simplify.c (gfc_simplify_matmul): Fix result shape
597 and matmul result.
598
599 2013-02-15 Tobias Burnus <burnus@net-b.de>
600
601 PR fortran/53818
602 * resolve.c (apply_default_init_local): Don't create an
603 initializer for a result variable.
604
605 2013-02-14 Thomas Koenig <tkoenig@gcc.gnu.org>
606
607 PR fortran/56224
608 * gfortran.h (gfc_add_include_path): Add boolean argument
609 for warn.
610 * scanner.c (gfc_add_include_path): Pass along warn argument
611 to add_path_to_list.
612 * options.c (gfc_post_options): Add true warn argument to
613 gfc_add_include_path.
614 (gfc_handle_module_path_options): Likewise.
615 (gfc_handle_option): Also gfc_add_include_path for intrinsic
616 modules, without warning.
617
618 2013-02-14 Paul Thomas <pault@gcc.gnu.org>
619 Tobias Burnus <burnus@net-b.de>
620
621 PR testsuite/56138
622 * trans-decl.c (gfc_get_symbol_decl): Fix deferred-length
623 results for functions without extra result variable.
624
625 Revert:
626 2013-01-30 Tobias Burnus <burnus@net-b.de>
627
628 PR fortran/56138
629 * trans-decl.c (gfc_trans_deferred_vars): Fix deferred-length
630 results for functions without extra result variable.
631
632 2013-02-12 Janus Weil <janus@gcc.gnu.org>
633
634 PR fortran/46952
635 * resolve.c (resolve_call): Do not check deferred procedures for
636 recursiveness.
637
638 2013-02-09 Paul Thomas <pault@gcc.gnu.org>
639
640 PR fortran/55362
641 * check.c (array_check): It is an error if a procedure is
642 passed.
643
644 2013-02-08 Mikael Morin <mikael@gcc.gnu.org>
645
646 PR fortran/54107
647 * trans-types.c (gfc_get_function_type): Change a NULL backend_decl
648 to error_mark_node on entry. Detect recursive types. Build a variadic
649 procedure type if the type is recursive. Restore the initial
650 backend_decl.
651
652 2013-02-07 Tobias Burnus <burnus@net-b.de>
653
654 PR fortran/54339
655 * gfortran.texi (Standards): Mention TS29113.
656 (Varying Length Character): Mention deferred-length
657 strings.
658 (Fortran 2003 Status): Add unlimited polymorphic.
659 (TS 29113 Status): Add TYPE(*) and DIMENSION(..).
660 (C Interop): Update the section about TS29113.
661
662 2013-02-06 Paul Thomas <pault@gcc.gnu.org>
663
664 PR fortran/55789
665 * trans-array.c (trans_array_constructor): Remove condition
666 'dynamic' = true if the loop ubound is a VAR_DECL.
667
668 2013-02-04 Paul Thomas <pault@gcc.gnu.org>
669
670 PR fortran/56008
671 PR fortran/47517
672 * trans-array.c (gfc_alloc_allocatable_for_assignment): Save
673 the lhs descriptor before it is modified for reallocation. Use
674 it to deallocate allocatable components in the reallocation
675 block. Nullify allocatable components for newly (re)allocated
676 arrays.
677
678 2013-02-04 Mikael Morin <mikael@gcc.gnu.org>
679
680 PR fortran/54195
681 * resolve.c (resolve_typebound_procedures): Recurse through
682 resolve_symbol.
683
684 2013-02-04 Mikael Morin <mikael@gcc.gnu.org>
685
686 PR fortran/54107
687 PR fortran/54195
688 * gfortran.h (struct gfc_symbol): New field 'resolved'.
689 * resolve.c (resolve_fl_var_and_proc): Don't skip result symbols.
690 (resolve_symbol): Skip duplicate calls. Don't check the current
691 namespace.
692
693 2013-02-02 Thomas Koenig <tkoenig@gcc.gnu.org>
694
695 PR fortran/50627
696 PR fortran/56054
697 * decl.c (gfc_match_end): Remove half-ready namespace
698 from parent if the end of a block is missing.
699 * parse.c (parse_module): Do not put namespace into
700 gsymbol on error.
701
702 2013-01-30 Tobias Burnus <burnus@net-b.de>
703
704 PR fortran/56138
705 * trans-decl.c (gfc_trans_deferred_vars): Fix deferred-length
706 results for functions without extra result variable.
707
708 2013-01-29 Janus Weil <janus@gcc.gnu.org>
709 Mikael Morin <mikael@gcc.gnu.org>
710
711 PR fortran/54107
712 * gfortran.h (gfc_component): Delete members 'formal' and 'formal_ns'.
713 (gfc_copy_formal_args,gfc_copy_formal_args_ppc,gfc_expr_replace_symbols,
714 gfc_expr_replace_comp): Delete.
715 (gfc_sym_get_dummy_args): New prototype.
716 * dependency.c (gfc_check_fncall_dependency): Use
717 'gfc_sym_get_dummy_args'.
718 * expr.c (gfc_is_constant_expr): Ditto.
719 (replace_symbol,gfc_expr_replace_symbols,replace_comp,
720 gfc_expr_replace_comp): Deleted.
721 * frontend-passes.c (doloop_code,do_function): Use
722 'gfc_sym_get_dummy_args'.
723 * interface.c (gfc_check_operator_interface,gfc_compare_interfaces,
724 gfc_procedure_use,gfc_ppc_use,gfc_arglist_matches_symbol,
725 gfc_check_typebound_override): Ditto.
726 * module.c (MOD_VERSION): Bump module version.
727 (mio_component): Do not read/write 'formal' and 'formal_ns'.
728 * resolve.c (resolve_procedure_interface,resolve_fl_derived0): Do not
729 copy formal args, but just keep a pointer to the interface.
730 (resolve_function,resolve_call,resolve_typebound_generic_call,
731 resolve_ppc_call,resolve_expr_ppc,generate_component_assignments,
732 resolve_fl_procedure,gfc_resolve_finalizers,check_generic_tbp_ambiguity,
733 resolve_typebound_procedure,check_uop_procedure): Use
734 'gfc_sym_get_dummy_args'.
735 * symbol.c (free_components): Do not free 'formal' and 'formal_ns'.
736 (gfc_copy_formal_args,gfc_copy_formal_args_ppc): Deleted.
737 (gfc_sym_get_dummy_args): New function.
738 * trans-array.c (get_array_charlen,gfc_walk_elemental_function_args):
739 Use 'gfc_sym_get_dummy_args'.
740 * trans-decl.c (build_function_decl,create_function_arglist,
741 build_entry_thunks,init_intent_out_dt,gfc_trans_deferred_vars,
742 add_argument_checking): Ditto.
743 * trans-expr.c (gfc_map_fcn_formal_to_actual,gfc_conv_procedure_call,
744 gfc_conv_statement_function): Ditto.
745 * trans-stmt.c (gfc_conv_elemental_dependencies): Ditto.
746 * trans-types.c (create_fn_spec,gfc_get_function_type): Ditto.
747
748 2013-01-28 Tobias Burnus <burnus@net-b.de>
749 Mikael Morin <mikael@gcc.gnu.org>
750
751 PR fortran/53537
752 * symbol.c (gfc_find_sym_tree): Don't look for the symbol outside an
753 interface block.
754 (gfc_get_ha_symtree): Let gfc_find_sym_tree lookup the parent namespace.
755 * decl.c (gfc_match_data_decl): Ditto.
756 (variable_decl): Remove undeclared type error.
757 (gfc_match_import): Use renamed instead of original name.
758
759 2013-01-27 Paul Thomas <pault@gcc.gnu.org>
760
761 PR fortran/55984
762 PR fortran/56047
763 * gfortran.h : Add associate_var to symbol_attr.
764 * resolve.c (resolve_assoc_var): Set associate_var attribute.
765 If the target class_ok is set, set it for the associate
766 variable.
767 * check.c (allocatable_check): Associate variables should not
768 have the allocatable attribute even if their symbols do.
769 * class.c (gfc_build_class_symbol): Symbols with associate_var
770 set will always have a good class container.
771
772 2013-01-23 Janus Weil <janus@gcc.gnu.org>
773
774 PR fortran/56081
775 * resolve.c (resolve_select): Add argument 'select_type', reject
776 non-scalar expressions.
777 (resolve_select_type,resolve_code): Pass new argument to
778 'resolve_select'.
779
780 2013-01-23 Jakub Jelinek <jakub@redhat.com>
781
782 PR fortran/56052
783 * trans-decl.c (gfc_get_symbol_decl): Set DECL_ARTIFICIAL
784 and DECL_IGNORED_P on select_type_temporary and don't set
785 DECL_BY_REFERENCE.
786
787 2013-01-21 Thomas Koenig <tkoenig@gcc.gnu.org>
788
789 PR fortran/55919
790 * scanner.c (add_path_to_list): Copy path to temporary and strip
791 trailing directory separators before calling stat().
792
793 2013-01-17 Richard Biener <rguenther@suse.de>
794
795 * trans-stmt.c (gfc_trans_do): Conditionally compute countm1
796 dependent on sign of step, avoids repeated evaluation of
797 step sign test. Avoid undefined overflow issues by using unsigned
798 arithmetic.
799
800 2013-01-16 Janus Weil <janus@gcc.gnu.org>
801
802 PR fortran/55983
803 * class.c (find_typebound_proc_uop): Check for f2k_derived instead of
804 asserting it.
805
806 2013-01-16 Jakub Jelinek <jakub@redhat.com>
807 Tobias Burnus <burnus@net-b.de>
808
809 PR driver/55884
810 * lang.opt (fintrinsic-modules-path): Don't accept Joined.
811 (fintrinsic-modules-path=): New.
812 * options.c (gfc_handle_option, gfc_get_option_string,
813 gfc_get_option_string): Handle the latter.
814
815 2013-01-16 Jakub Jelinek <jakub@redhat.com>
816
817 PR fortran/52865
818 * trans-stmt.c (gfc_trans_do): Put countm1-- before conditional
819 and use value of countm1 before the decrement in the condition.
820
821 2013-01-15 Paul Thomas <pault@gcc.gnu.org>
822
823 PR fortran/54286
824 * expr.c (gfc_check_pointer_assign): Check for presence of
825 's2' before using it.
826
827 2013-01-14 Thomas Koenig <tkoenig@gcc.gnu.org>
828
829 PR fortran/55806
830 * frontend-passes.c (optimize_reduction): New function,
831 including prototype.
832 (callback_reduction): Likewise.
833 (gfc_run_passes): Also run optimize_reduction.
834 (copy_walk_reduction_arg): New function.
835 (dummy_code_callback): New function.
836
837 2013-01-13 Jakub Jelinek <jakub@redhat.com>
838
839 PR fortran/55935
840 * trans-expr.c (gfc_conv_structure): Call
841 unshare_expr_without_location on the ctor elements.
842
843 2013-01-13 Paul Thomas <pault@gcc.gnu.org>
844
845 PR fortran/54286
846 * expr.c (gfc_check_pointer_assign): Ensure that both lvalue
847 and rvalue interfaces are presented to gfc_compare_interfaces.
848 Simplify references to interface names by using the symbols
849 themselves. Call gfc_compare_interfaces with s1 and s2 inter-
850 changed to overcome the asymmetry of this function. Do not
851 repeat the check for the presence of s1 and s2.
852
853 2013-01-12 Janus Weil <janus@gcc.gnu.org>
854
855 PR fortran/55072
856 * trans-array.c (gfc_conv_array_parameter): No packing was done for
857 full arrays of derived type.
858
859 2013-01-08 Paul Thomas <pault@gcc.gnu.org>
860
861 PR fortran/55868
862 * class.c (get_unique_type_string): Change $tar to STAR and
863 replace sprintf by strcpy where there is no formatting.
864 * decl.c (gfc_match_decl_type_spec): Change $tar to STAR.
865
866 2013-01-09 Mikael Morin <mikael@gcc.gnu.org>
867
868 PR fortran/47203
869 * module.c (check_for_ambiguous): Get the current program unit using
870 gfc_current_ns.
871
872 2013-01-09 Tobias Burnus <burnus@net-b.de>
873
874 PR fortran/55758
875 * resolve.c (resolve_symbol): Reject non-C_Bool logicals
876 in BIND(C) procedures with -std=f*.
877
878 2013-01-08 Paul Thomas <pault@gcc.gnu.org>
879
880 PR fortran/55618
881 * trans-expr.c (gfc_conv_procedure_call): Dereference scalar
882 character function arguments to elemental procedures in
883 scalarization loops.
884
885 2013-01-07 Tobias Burnus <burnus@net-b.de>
886
887 PR fortran/55763
888 * gfortran.h (gfc_check_assign_symbol): Update prototype.
889 * decl.c (add_init_expr_to_sym, do_parm): Update call.
890 * expr.c (gfc_check_assign_symbol): Handle BT_CLASS and
891 improve error location; support components.
892 (gfc_check_pointer_assign): Handle component assignments.
893 * resolve.c (resolve_fl_derived0): Call gfc_check_assign_symbol.
894 (resolve_values): Update call.
895 (resolve_structure_cons): Avoid double diagnostic.
896
897 2013-01-07 Tobias Burnus <burnus@net-b.de>
898 Thomas Koenig <tkoenig@gcc.gnu.org>
899
900 PR fortran/55852
901 * expr.c (gfc_build_intrinsic_call): Avoid clashes
902 with user's procedures.
903 * gfortran.h (gfc_build_intrinsic_call): Update prototype.
904 * simplify.c (gfc_simplify_size): Update call.
905 * class.c (finalization_scalarizer, finalization_get_offset,
906 finalizer_insert_packed_call, generate_finalization_wrapper):
907 Clean up by using gfc_build_intrinsic_call.
908
909 2013-01-07 Tobias Burnus <burnus@net-b.de>
910
911 PR fortran/55763
912 * resolve.c (resolve_select_type): Reject intrinsic types for
913 a non-unlimited-polymorphic selector.
914
915 2013-01-06 Paul Thomas <pault@gcc.gnu.org>
916
917 PR fortran/53876
918 PR fortran/54990
919 PR fortran/54992
920 * trans-array.c (build_array_ref): Check the TYPE_CANONICAL
921 to see if it is GFC_CLASS_TYPE_P.
922 * trans-expr.c (gfc_get_vptr_from_expr): The same.
923 (gfc_conv_class_to_class): If the types are not the same,
924 cast parmese->expr to the type of ctree.
925 * trans-types.c (gfc_get_derived_type): GFC_CLASS_TYPE_P of
926 CLASS components must be set.
927
928 2013-01-06 Mikael Morin <mikael@gcc.gnu.org>
929
930 PR fortran/42769
931 PR fortran/45836
932 PR fortran/45900
933 * module.c (read_module): Don't reuse local symtree if the associated
934 symbol isn't exactly the one wanted. Don't reuse local symtree if it is
935 ambiguous.
936 * resolve.c (resolve_call): Use symtree's name instead of symbol's to
937 lookup the symtree.
938
939 2013-01-05 Steven G. Kargl <kargl@gcc.gnu.org>
940 Mikael Morin <mikael@gcc.gnu.org>
941
942 PR fortran/55827
943 * class.c (gfc_fix_class_refs): Adapt ts initialization for the case
944 e->symtree == NULL.
945 * trans-expr.c (gfc_conv_function_expr): Init sym earlier. Use it.
946
947 2013-01-05 Tobias Burnus <burnus@net-b.de>
948
949 * class.c (finalize_component): Used passed offset expr.
950 (finalization_get_offset): New static function.
951 (finalizer_insert_packed_call, generate_finalization_wrapper): Use it
952 to handle noncontiguous arrays.
953
954 2013-01-04 Tobias Burnus <burnus@net-b.de>
955
956 * trans.c (gfc_build_final_call): New function.
957 * trans.h (gfc_build_final_call, gfc_conv_scalar_to_descriptor):
958 New function prototypes.
959 * trans-expr.c (gfc_conv_scalar_to_descriptor): Renamed from
960 conv_scalar_to_descriptor, removed static attribute.
961 (gfc_conv_procedure_call): Honor renaming.
962
963 2013-01-04 Tobias Burnus <burnus@net-b.de>
964
965 * intrinsic.c (add_functions): New internal intrinsic
966 function GFC_PREFIX ("stride").
967 * gfortran.h (gfc_isym_id): Add GFC_ISYM_STRIDE.
968 * intrinsic.h (gfc_resolve_stride): New prototypes.
969 * iresolve.c (gfc_resolve_stride): New function.
970 * trans-intrinsic.c (conv_intrinsic_stride): New static
971 function.
972 (gfc_conv_intrinsic_function): Use it.
973
974 2013-01-04 Tobias Burnus <burnus@net-b.de>
975
976 * class.c (gfc_find_intrinsic_vtab): Add _final
977 component.
978 * decl.c (gfc_match_null): Remove superfluous
979 variadic argument to gfc_match.
980
981 2013-01-04 Paul Thomas <pault@gcc.gnu.org>
982
983 PR fortran/55172
984 * match.c (copy_ts_from_selector_to_associate): Remove call to
985 gfc_resolve_expr and replace it with explicit setting of the
986 array reference type.
987 * resolve.c (resolve_select_type): It is an error if the
988 selector is coindexed.
989
990 2013-01-04 Tobias Burnus <burnus@net-b.de>
991
992 PR fortran/55763
993 * decl.c (gfc_match_null): Parse and reject MOLD.
994
995 2013-01-04 Tobias Burnus <burnus@net-b.de>
996
997 PR fortran/55854
998 PR fortran/55763
999 * class.c (gfc_class_null_initializer): Fix finding the vtab.
1000 (gfc_find_intrinsic_vtab): Use BT_VOID for some components.
1001
1002 2013-01-03 Janus Weil <janus@gcc.gnu.org>
1003
1004 PR fortran/55855
1005 * expr.c (gfc_check_assign): Use 'gfc_expr_attr' to evaluate attributes
1006 of rvalue. Correct hyphenation in error message.
1007
1008 2013-01-03 Jakub Jelinek <jakub@redhat.com>
1009
1010 * gfortranspec.c (lang_specific_driver): Update copyright notice
1011 dates.
1012 \f
1013 Copyright (C) 2013 Free Software Foundation, Inc.
1014
1015 Copying and distribution of this file, with or without modification,
1016 are permitted in any medium without royalty provided the copyright
1017 notice and this notice are preserved.