re PR fortran/35059 (Seg fault when max constructor limit reached)
[gcc.git] / gcc / fortran / ChangeLog
1 2008-02-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2
3 PR fortran/35059
4 * expr.c (find_array_element): Modify traversing the constructor to
5 avoid trying to access NULL memory pointed to by next for the
6 last element. (find_array_section): Exit while loop if cons->next is
7 NULL.
8 * trans-expr.c (gfc_conv_scalar_char_value): Initialize gfc_typespec.
9 (gfc_conv_function_call): Same.
10 * decl.c (gfc_match_implicit): Same.
11 * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Same.
12
13 2008-02-28 Daniel Franke <franke.daniel@gmail.com>
14
15 PR fortran/31463
16 PR fortran/33950
17 PR fortran/34296
18 * lang.opt: Added -Wreturn-type.
19 * options.c (gfc_handle_option): Recognize -Wreturn-type.
20 * trans-decl.c (gfc_trans_deferred_vars): Emit warnings for funtions
21 where the result value is not set.
22 (gfc_generate_function_code): Likewise.
23 (generate_local_decl): Emit warnings for funtions whose RESULT
24 variable is not set.
25
26 2008-02-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
27
28 PR fortran/34868
29 * trans-expr.c (gfc_conv_variable): Don't build indirect
30 references when explicit interface is mandated.
31 * resolve.c (resolve_formal_arglist): Set attr.always_explicit
32 on the result symbol as well as the procedure symbol.
33
34 2008-02-27 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
35
36 PR fortran/33387
37 * trans.h: Remove prototypes for gfor_fndecl_math_exponent4,
38 gfor_fndecl_math_exponent8, gfor_fndecl_math_exponent10 and
39 gfor_fndecl_math_exponent16.
40 * f95-lang.c (build_builtin_fntypes): Add new function types.
41 (gfc_init_builtin_functions): Add new builtins for nextafter,
42 frexp, ldexp, fabs, scalbn and inf.
43 * iresolve.c (gfc_resolve_rrspacing): Don't add hidden arguments.
44 (gfc_resolve_scale): Don't convert type of second argument.
45 (gfc_resolve_set_exponent): Likewise.
46 (gfc_resolve_size): Don't add hidden arguments.
47 * trans-decl.c: Remove gfor_fndecl_math_exponent4,
48 gfor_fndecl_math_exponent8, gfor_fndecl_math_exponent10 and
49 gfor_fndecl_math_exponent16.
50 * trans-intrinsic.c (gfc_intrinsic_map): Remove intrinsics
51 for scalbn, fraction, nearest, rrspacing, set_exponent and
52 spacing.
53 (gfc_conv_intrinsic_exponent): Directly call frexp.
54 (gfc_conv_intrinsic_fraction, gfc_conv_intrinsic_nearest,
55 gfc_conv_intrinsic_spacing, gfc_conv_intrinsic_rrspacing,
56 gfc_conv_intrinsic_scale, gfc_conv_intrinsic_set_exponent): New
57 functions.
58 (gfc_conv_intrinsic_function): Use the new functions above.
59
60 2008-02-26 Tobias Burnus <burnus@net-b.de>
61
62 PR fortran/35033
63 * interface.c (check_operator_interface): Show better line for error
64 messages; fix constrains for user-defined assignment operators.
65 (gfc_extend_assign): Fix constrains for user-defined assignment
66 operators.
67
68 2008-02-26 Tom Tromey <tromey@redhat.com>
69
70 * trans-io.c (set_error_locus): Remove old location code.
71 * trans-decl.c (gfc_set_decl_location): Remove old location code.
72 * f95-lang.c (gfc_init): Remove test of USE_MAPPED_LOCATION.
73 * scanner.c (gfc_gobble_whitespace): Remove old location code.
74 (get_file): Likewise.
75 (preprocessor_line): Likewise.
76 (load_file): Likewise.
77 (gfc_new_file): Likewise.
78 * trans.c (gfc_trans_runtime_check): Remove old location code.
79 (gfc_get_backend_locus): Likewise.
80 (gfc_set_backend_locus): Likewise.
81 * data.c (gfc_assign_data_value): Remove old location code.
82 * error.c (show_locus): Remove old location code.
83 * gfortran.h (gfc_linebuf): Remove old location code.
84 (gfc_linebuf_linenum): Remove old-location variant.
85
86 2008-02-25 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
87
88 PR fortran/34729
89 * trans-const.c (gfc_build_string_const): Don't call gettext.
90 (gfc_build_localized_string_const): New function.
91 * trans-const.h (gfc_build_localized_string_const): New prototype.
92 * trans.c (gfc_trans_runtime_check): Use
93 gfc_build_localized_string_const instead of gfc_build_string_const.
94 (gfc_call_malloc): Likewise.
95 (gfc_allocate_with_status): Likewise.
96 (gfc_allocate_array_with_status): Likewise.
97 (gfc_deallocate_with_status): Likewise.
98 (gfc_call_realloc): Likewise.
99 * trans-io.c (gfc_trans_io_runtime_check): Likewise.
100
101 2008-02-24 Tobias Schlüter <tobi@gcc.gnu.org>
102
103 * arith.c: Update copyright years.
104 * arith.h: Likewise.
105 * array.c: Likewise.
106 * bbt.c: Likewise.
107 * check.c: Likewise.
108 * data.c: Likewise.
109 * data.h: Likewise.
110 * decl.c: Likewise.
111 * dependency.c: Likewise.
112 * dependency.h: Likewise.
113 * dump-parse-tree.c: Likewise.
114 * error.c: Likewise.
115 * expr.c: Likewise.
116 * gfc-internals.texi: Likewise.
117 * gfortran.h: Likewise.
118 * gfortran.texi: Likewise.
119 * gfortranspec.c: Likewise.
120 * interface.c: Likewise.
121 * intrinsic.c: Likewise.
122 * intrinsic.h: Likewise.
123 * intrinsic.texi: Likewise.
124 * invoke.texi: Likewise.
125 * io.c: Likewise.
126 * iresolve.c: Likewise.
127 * iso-c-binding.def: Likewise.
128 * iso-fortran-env.def: Likewise.
129 * lang-specs.h: Likewise.
130 * lang.opt: Likewise.
131 * libgfortran.h: Likewise.
132 * match.c: Likewise.
133 * match.h: Likewise.
134 * matchexp.c: Likewise.
135 * misc.c: Likewise.
136 * module.c: Likewise.
137 * openmp.c: Likewise.
138 * options.c: Likewise.
139 * parse.c: Likewise.
140 * parse.h: Likewise.
141 * primary.c: Likewise.
142 * resolve.c: Likewise.
143 * scanner.c: Likewise.
144 * simplify.c: Likewise.
145 * st.c: Likewise.
146 * symbol.c: Likewise.
147 * target-memory.c: Likewise.
148 * target-memory.h: Likewise.
149 * trans-array.h: Likewise.
150 * trans-const.h: Likewise.
151 * trans-stmt.h: Likewise.
152 * trans-types.c: Likewise.
153 * trans-types.h: Likewise.
154 * types.def: Likewise.
155
156 2008-02-24 Jerry DeLisle <jvdelisle@gcc.gnu.org>
157
158 PR fortran/35223
159 * simplify.c (gfc_simplify_ibclr), (gfc_simplify_ibits),
160 (gfc_simplify_ibset): Remove call to range_check.
161 (simplify_cmplx), (gfc_simplify_dble), (gfc_simplify_float)
162 (gfc_simplify_real): Add call gfc_clear_ts to initialize the
163 temporary gfc_typspec variable.
164
165 2008-02-24 Tobias Schlüter <tobi@gcc.gnu.org>
166
167 * trans-array.c (gfc_conv_descriptor_data_get,
168 gfc_conv_descriptor_data_set_internal,
169 gfc_conv_descriptor_data_addr, gfc_conv_descriptor_offset,
170 gfc_conv_descriptor_dtype, gfc_conv_descriptor_dimension,
171 gfc_conv_descriptor_stride, gfc_conv_descriptor_lbound,
172 gfc_conv_descriptor_ubound, gfc_trans_create_temp_array,
173 gfc_conv_array_transpose, gfc_grow_array,
174 gfc_trans_array_constructor_subarray,
175 gfc_trans_array_constructor_value, gfc_trans_scalarized_loop_end,
176 gfc_array_init_size, gfc_array_allocate, gfc_array_deallocate,
177 gfc_conv_array_initializer, gfc_trans_array_bounds,
178 gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias,
179 gfc_get_dataptr_offset, gfc_conv_array_parameter,
180 gfc_trans_dealloc_allocated, get_full_array_size,
181 gfc_duplicate_allocatable, structure_alloc_comps): Use fold_buildN
182 instead of buildN.
183 * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
184 gfc_conv_component_ref, gfc_conv_cst_int_power,
185 gfc_conv_function_call, gfc_trans_structur_assign): Likewise.
186 * trans-common.c (create_common): Likewise.
187 * trans-openmp.c (gfc_trans_omp_atomic, gfc_trans_omp_do):
188 Likewise.
189 * trans-const.c (gfc_conv_constant_to_tree): Likewise.
190 * trans-stmt.c (gfc_trans_goto, gfc_trans_return, gfc_trans_do,
191 gfc_trans_integer_select, gfc_trans_character_select,
192 gfc_trans_forall_loop, compute_overall_iter_number,
193 gfc_trans_forall_1, gfc_evaluate_where_mask, gfc_trans_allocate,
194 gfc_trans_deallocate): Likewise.
195 * trans.c (gfc_build_addr_expr, gfc_trans_runtime_check,
196 gfc_allocate_with_status, gfc_allocate_array_with_status,
197 gfc_deallocate_with_status): Likewise.
198 * f95-lang.c (gfc_truthvalue_conversion): Likewise.
199 * trans-io.c (set_parameter_const, set_parameter_value,
200 set_parameter_ref, set_string, set_internal_unit, io_result,
201 set_error_locus, nml_get_addr_expr, transfer_expr): Likewise.
202 * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
203 gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
204 gfc_generate_function_code): Likewise.
205 * convert.c (convert): Likewise.
206 * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
207 build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
208 gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
209 gfc_conv_intrinsic_conjg, gfc_conv_intrinsic_abs,
210 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
211 gfc_conv_intrinsic_dim, gfc_conv_intrinsic_dprod,
212 gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
213 gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
214 gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_count,
215 gfc_conv_intrinsic_arith, gfc_conv_intrinsic_dot_product,
216 gfc_conv_intrinsic_minmaxloc, gfc_conv_intrinsic_minmaxval,
217 gfc_conv_intrinsic_btest, gfc_conv_intrinsic_not,
218 gfc_conv_intrinsic_ibits, gfc_conv_intrinsic_ishft,
219 gfc_conv_intrinsic_ichar, gfc_conv_intrinsic_size,
220 gfc_conv_intrinsic_array_transfer, gfc_conv_intrinsic_transfer,
221 gfc_conv_allocated, gfc_conv_associated, gfc_conv_intrinsic_trim,
222 gfc_conv_intrinsic_repeat): Likewise.
223
224 2008-02-23 Francois-Xavier Coudert <coudert@clipper.ens.fr>
225
226 PR target/25477
227 * trans-expr.c (gfc_conv_power_op): Use BUILT_IN_CPOW{F,,L}.
228 * f95-lang.c (gfc_init_builtin_functions): Define BUILT_IN_CPOW{F,,L}.
229 * trans.h (gfor_fndecl_math_cpow, gfor_fndecl_math_cpowf,
230 gfor_fndecl_math_cpowl10, gfor_fndecl_math_cpowl16): Remove.
231 * trans-decl.c: Likewise.
232
233 2008-02-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
234
235 PR fortran/35059
236 * expr.c (find_array_element): Modify traversing the constructor to
237 avoid trying to access NULL memory pointed to by next for the
238 last element. (find_array_section): Exit while loop if cons->next is
239 NULL.
240
241 2008-02-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
242
243 PR fortran/34907
244 * iresolve.c (resolve_mask_arg): Add gfc_clear_ts to initialize
245 structure.
246 (gfc_resolve_aint): Likewise.
247 (gfc_resolve_anint): Likewise.
248 (gfc_resolve_besn): Likewise.
249 (gfc_resolve_cshift): Likewise.
250 (gfc_resolve_ctime): Likewise.
251 (gfc_resolve_eoshift): Likewise.
252 (gfc_resolve_index_func): Likewise.
253 (gfc_resolve_isatty): Likewise.
254 (gfc_resolve_malloc): Likewise.
255 (gfc_resolve_rrspacing): Likewise.
256 (gfc_resolve_scale): Likewise.
257 (gfc_resolve_set_exponent): Likewise.
258 (gfc_resolve_spacing): Likewise.
259 (gfc_resolve_spacing): Likewise.
260 (gfc_resolve_fgetc): Likewise.
261 (gfc_resolve_fputc): Likewise.
262 (gfc_resolve_ftell): Likewise.
263 (gfc_resolve_ttynam): Likewise.
264 (gfc_resolve_alarm_sub): Likewise.
265 (gfc_resolve_mvbits): Likewise.
266 (gfc_resolve_getarg): Likewise.
267 (gfc_resolve_signal_sub): Likewise.
268 (gfc_resolve_exit): Likewise.
269 (gfc_resolve_flush): Likewise.
270 (gfc_resolve_free): Likewise.
271 (gfc_resolve_ctime_sub): Likewise.
272 (gfc_resolve_fgetc_sub): Likewise.
273 (gfc_resolve_fputc_sub): Likewise.
274 (gfc_resolve_fseek_sub): Likewise.
275 (gfc_resolve_ftell_sub): Likewise.
276 (gfc_resolve_ttynam_sub): Likewise.
277
278 2008-02-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
279
280 * gfc-internals.texi: Fix typos and markup nits.
281 * gfortran.texi: Likewise.
282 * intrinsic.texi: Likewise.
283
284 2008-02-21 Richard Guenther <rguenther@suse.de>
285
286 * trans-expr.c (gfc_conv_expr_op): Expand INTRINSIC_PARENTHESES
287 as unary PAREN_EXPR for real and complex typed expressions.
288 (gfc_conv_unary_op): Fold the built tree.
289
290 2008-02-20 Tobias Burnus <burnus@net-b.de>
291
292 PR fortran/34997
293 * match.c (gfc_match_name): Improve error message for '$'.
294
295 2008-02-19 Daniel Franke <franke.daniel@gmail.com>
296
297 PR fortran/35030
298 * expr.c (gfc_check_pointer_assign): Add type and kind information
299 to type-mismatch message.
300 (gfc_check_assign): Unify error messages.
301
302 2008-02-16 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
303
304 PR fortran/34952
305 * gfortran.texi: Create new section for unimplemented extensions.
306 Add "STRUCTURE and RECORD" and "ENCODE and DECODE statements".
307 Remove "smaller projects" list. Fix a few typos.
308
309 2008-02-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
310
311 * intrinsic.texi: Rename INDEX node to avoid clashing with
312 index.html on case-insensitive systems.
313
314 2008-02-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
315
316 PR fortran/35150
317 * trans-expr.c (gfc_conv_function_call): Force evaluation of
318 se->expr.
319
320 2008-02-10 Daniel Franke <franke.daniel@gmail.com>
321
322 PR fortran/35019
323 * lang.opt: Allow '-J<dir>' next to '-J <dir>',
324 likewise '-I <dir>' and '-I<dir>'.
325
326 2008-02-06 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
327
328 PR other/35107
329 * Make-lang.in (f951): Add $(GMPLIBS).
330
331 2008-02-05 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
332
333 PR fortran/35037
334 * trans-common.c (build_field): Mark fields as volatile when needed.
335
336 2008-02-05 Tobias Burnus <burnus@net-b.de>
337
338 PR fortran/35093
339 * data.c (gfc_assign_data_value): Only free "size" if
340 it has not already been freed.
341
342 2008-02-05 Paul Thomas <pault@gcc.gnu.org>
343
344 PR fortran/34945
345 * array.c (match_array_element_spec): Remove check for negative
346 array size.
347 (gfc_resolve_array_spec): Add check for negative size.
348
349 2008-02-05 Paul Thomas <pault@gcc.gnu.org>
350
351 PR fortran/32315
352 * data.c (gfc_assign_data_value): Add bounds check for array
353 references.
354
355 2008-02-04 Daniel Franke <franke.daniel@gmail.com>
356
357 * resolve.c (resolve_where): Fix typo.
358 (gfc_resolve_where_code_in_forall): Likewise.
359
360 2008-02-03 Paul Thomas <pault@gcc.gnu.org>
361
362 PR fortran/32760
363 * resolve.c (resolve_allocate_deallocate): New function.
364 (resolve_code): Call it for allocate and deallocate.
365 * match.c (gfc_match_allocate, gfc_match_deallocate) : Remove
366 the checking of the STAT tag and put in above new function.
367 * primary,c (match_variable): Do not fix flavor of host
368 associated symbols yet if the type is not known.
369
370 2008-01-31 Paul Thomas <pault@gcc.gnu.org>
371
372 PR fortran/34910
373 * expr.c (gfc_check_assign): It is an error to assign
374 to a sibling procedure.
375
376 2008-01-30 Paul Thomas <pault@gcc.gnu.org>
377
378 PR fortran/34975
379 * symbol.c (gfc_delete_symtree, gfc_undo_symbols): Rename
380 delete_symtree to gfc_delete_symtree.
381 * gfortran.h : Add prototype for gfc_delete_symtree.
382 * module.c (load_generic_interfaces): Transfer symbol to a
383 unique symtree and delete old symtree, instead of renaming.
384 (read_module): The rsym and the found symbol are the same, so
385 the found symtree can be deleted.
386
387 PR fortran/34429
388 * decl.c (match_char_spec): Remove the constraint on deferred
389 matching of functions and free the length expression.
390 delete_symtree to gfc_delete_symtree.
391 (gfc_match_type_spec): Whitespace.
392 (gfc_match_function_decl): Defer characteristic association for
393 all types except BT_UNKNOWN.
394 * parse.c (decode_specification_statement): Only derived type
395 function matching is delayed to the end of specification.
396
397 2008-01-28 Tobias Burnus <burnus@net-b.de>
398
399 PR libfortran/34980
400 * simplify.c (gfc_simplify_shape): Simplify rank zero arrays.
401
402 2008-01-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
403
404 PR fortran/34990
405 * array.c (gfc_check_constructor_type): Revert clearing the expression.
406
407 2008-01-26 Tobias Burnus <burnus@net-b.de>
408
409 PR fortran/34848
410 * trans-expr.c (gfc_conv_function_call): Don't call
411 gfc_add_interface_mapping if the expression is NULL.
412
413 2008-01-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
414
415 PR fortran/31610
416 * trans-array.c (gfc_trans_create_temp_array): Remove call to
417 gcc_assert (integer_zerop (loop->from[n])).
418
419 2008-01-25 Daniel Franke <franke.daniel@gmail.com>
420
421 PR fortran/34661
422 * resolve.c (resolve_where): Added check if user-defined assignment
423 operator is an elemental subroutine.
424 (gfc_resolve_where_code_in_forall): Likewise.
425
426 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
427
428 PR fortran/33375
429 PR fortran/34858
430 * gfortran.h: Revert changes from 2008-01-17.
431 * match.c: Likewise.
432 * symbol.c: Likewise.
433 (gfc_undo_symbols): Undo namespace changes related to common blocks.
434
435 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
436
437 PR fortran/34202
438 * data.c (formalize_structure_cons): Skip formalization on
439 empty structures.
440
441 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
442
443 * gfortran.texi (OpenMP): Extended existing documentation.
444 (contributors): Added major contributors of 2008 that were
445 not listed yet.
446 (proposed extensions): Removed implemented items.
447
448 2008-01-24 Paul Thomas <pault@gcc.gnu.org>
449
450 PR fortran/34872
451 * parse.c (next_statement) : If ST_GET_FCN_CHARACTERISTICS is
452 seen, check for a statement label and, if present, delete it
453 and set the locus to the start of the statement.
454
455 2008-01-22 Paul Thomas <pault@gcc.gnu.org>
456
457 PR fortran/34875
458 * trans-io.c (gfc_trans_transfer): If the array reference in a
459 read has a vector subscript, use gfc_conv_subref_array_arg to
460 copy back the temporary.
461
462 2008-01-22 Tobias Burnus <burnus@net-b.de>
463
464 PR fortran/34848
465 * interface.c (compare_actual_formal): Fix adding type
466 to missing_arg_type for absent optional arguments.
467
468 2008-01-22 Tobias Burnus <burnus@net-b.de>
469
470 PR fortran/34907
471 * parse.c (parse_spec): Change = into ==.
472
473 2008-01-22 Daniel Franke <franke.daniel@gmail.com>
474
475 PR fortran/34915
476 * expr.c (check_elemental): Fix check for valid data types.
477
478 2008-01-22 Tobias Burnus <burnus@net-b.de>
479
480 PR fortran/34899
481 * scanner.c (load_line): Support <tab><digit> continuation lines.
482 * invoke.texi (-Wtabs): Document this.
483
484 2008-01-22 Paul Thomas <pault@gcc.gnu.org>
485
486 PR fortran/34896
487 * module.c (read_module): Set use_rename attribute.
488
489 2007-01-21 Tobias Burnus <burnus@net-b.de>
490
491 PR fortran/34901
492 * interface.c (compare_parameter): Improved error message
493 for arguments of same type and mismatched kinds.
494
495 2008-01-20 Paul Thomas <pault@gcc.gnu.org>
496
497 PR fortran/34861
498 * resolve.c (resolve_entries): Do not do an array bounds check
499 if the result symbols are the same.
500
501 PR fortran/34854
502 * module.c (read_module) : Hide the symtree of the previous
503 version of the symbol if this symbol is renamed.
504
505 2008-01-20 Paul Thomas <pault@gcc.gnu.org>
506
507 PR fortran/34784
508 * array.c (gfc_check_constructor_type): Clear the expression ts
509 so that the checking starts from the deepest level of array
510 constructor.
511 * primary.c (match_varspec): If an unknown type is changed to
512 default character and the attempt to match a substring fails,
513 change it back to unknown.
514
515 PR fortran/34785
516 * trans-array.c (gfc_add_loop_ss_code) : If ss->string_length is
517 NULL for an array constructor, use the cl.length expression to
518 build it.
519 (gfc_conv_array_parameter): Change call to gfc_evaluate_now to
520 a tree assignment.
521
522 2008-01-19 Thomas Koenig <tkoenig@gcc.gnu.org>
523
524 PR fortran/34817
525 PR fortran/34838
526 * iresolve.c (gfc_resolve_all): Remove conversion of mask
527 argument to kind=1 by removing call to resolve_mask_arg().
528 (gfc_resolve_any): Likewise.
529
530 2008-01-19 Tobias Burnus <burnus@net-b.de>
531
532 PR fortran/34760
533 * primary.c (match_variable): Handle FL_UNKNOWN without
534 uneducated guessing.
535 (match_variable): Improve error message.
536
537 2008-01-18 Tobias Burnus <burnus@net-b.de>
538
539 PR fortran/32616
540 * interface.c (get_expr_storage_size): Return storage size
541 for array element designators.
542 (compare_actual_formal): Reject unequal string sizes for
543 assumed-shape dummy arguments. And fix error message for
544 array-sections with vector subscripts.
545
546 2008-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
547
548 PR fortran/34556
549 * simplify.c (is_constant_array_expr): New static function that returns
550 true if the given expression is an array and is constant.
551 (gfc_simplify_reshape): Use new function.
552
553 2008-01-17 H.J. Lu <hongjiu.lu@intel.com>
554
555 PR fortran/33375
556 * symbol.c (free_common_tree): Renamed to ...
557 (gfc_free_common_tree): This. Remove static.
558 (gfc_free_namespace): Updated.
559
560 * gfortran.h (gfc_free_common_tree): New.
561
562 * match.c (gfc_match_common): Call gfc_free_common_tree () with
563 gfc_current_ns->common_root and set gfc_current_ns->common_root
564 to NULL on syntax error.
565
566 2008-01-18 Richard Sandiford <rsandifo@nildram.co.uk>
567
568 PR fortran/34686
569 * trans-expr.c (gfc_conv_function_call): Use proper
570 type for returned character pointers.
571
572 2008-01-17 Paul Thomas <pault@gcc.gnu.org>
573
574 PR fortran/34429
575 PR fortran/34431
576 PR fortran/34471
577 * decl.c : Remove gfc_function_kind_locus and
578 gfc_function_type_locus. Add gfc_matching_function.
579 (match_char_length): If matching a function and the length
580 does not match, return MATCH_YES and try again later.
581 (gfc_match_kind_spec): The same.
582 (match_char_kind): The same.
583 (gfc_match_type_spec): The same for numeric and derived types.
584 (match_prefix): Rename as gfc_match_prefix.
585 (gfc_match_function_decl): Except for function valued character
586 lengths, defer applying kind, type and charlen info until the
587 end of specification block.
588 gfortran.h (gfc_statement): Add ST_GET_FCN_CHARACTERISTICS.
589 parse.c (decode_specification_statement): New function.
590 (decode_statement): Call it when a function has kind = -1. Set
591 and reset gfc_matching function, as function statement is being
592 matched.
593 (match_deferred_characteristics): Simplify with a single call
594 to gfc_match_prefix. Do appropriate error handling. In any
595 case, make sure that kind = -1 is reset or corrected.
596 (parse_spec): Call above on seeing ST_GET_FCN_CHARACTERISTICS.
597 Throw an error if kind = -1 after last specification statement.
598 parse.h : Prototype for gfc_match_prefix.
599
600 2008-01-16 Tobias Burnus <burnus@net-b.de>
601
602 PR fortran/34796
603 * interface.c (compare_parameter): Allow AS_DEFERRED array
604 elements and reject attr.pointer array elemenents.
605 (get_expr_storage_size): Return storage size of elements of
606 assumed-shape and pointer arrays.
607
608 2008-01-15 Sebastian Pop <sebastian.pop@amd.com>
609
610 * f95-lang.c (gfc_init_builtin_functions): Initialize GOMP builtins
611 for flag_tree_parallelize_loops.
612
613 2008-01-15 Thomas Koenig <tkoenig@gcc.gnu.org>
614
615 PR libfortran/34671
616 * iresolve.c (gfc_resolve_all): Call resolve_mask_arg.
617 (gfc_resolve_any): Likewise.
618 (gfc_resolve_count): Likewise. Don't append kind of
619 argument to function name.
620
621 2008-01-13 Tobias Burnus <burnus@net-b.de>
622
623 PR fortran/34665
624 * resolve.c (resolve_actual_arglist): For expressions,
625 also check for assume-sized arrays.
626 * interface.c (compare_parameter): Move F2003 character checks
627 here, print error messages here, reject elements of
628 assumed-shape array as argument to dummy arrays.
629 (compare_actual_formal): Update for the changes above.
630
631 2008-01-13 Tobias Burnus <burnus@net-b.de>
632
633 PR fortran/34763
634 * decl.c (contained_procedure): Only check directly preceeding state.
635
636 2008-01-13 Tobias Burnus <burnus@net-b.de>
637
638 PR fortran/34759
639 * check.c (gfc_check_shape): Accept array ranges of
640 assumed-size arrays.
641
642 2008-01-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
643
644 PR fortran/34432
645 * match.c (gfc_match_name): Don't error if leading character is a '(',
646 just return MATCH_NO.
647
648 2008-01-11 Jerry DeLisle <jvdelisle@gcc.gnu.org>
649
650 PR fortran/34722
651 * trans-io.c (create_dummy_iostat): Commit the symbol.
652
653 2008-01-11 Paul Thomas <pault@gcc.gnu.org>
654
655 PR fortran/34537
656 * simplify.c (gfc_simplify_transfer): Return NULL if the size
657 of the element is unavailable and only assign character length
658 to the result, if 'mold' is constant.
659
660 2008-01-10 Paul Thomas <pault@gcc.gnu.org>
661
662 PR fortran/34396
663 * trans-array.c (gfc_trans_array_ctor_element): Use gfc_trans_string_copy
664 to assign strings and perform bounds checks on the string length.
665 (get_array_ctor_strlen): Remove bounds checking.
666 (gfc_trans_array_constructor): Initialize string length checking.
667 * trans-array.h : Add prototype for gfc_trans_string_copy.
668
669 2008-01-08 Richard Guenther <rguenther@suse.de>
670
671 PR fortran/34706
672 PR tree-optimization/34683
673 * trans-types.c (gfc_get_array_type_bounds): Use an array type
674 with known size for accesses if that is known.
675
676 2008-01-08 Paul Thomas <pault@gcc.gnu.org>
677
678 PR fortran/34476
679 * expr.c (find_array_element): Check that the array bounds are
680 constant before using them. Use lower, as well as upper bound.
681 (check_restricted): Allow implied index variable.
682
683 2008-01-08 Paul Thomas <pault@gcc.gnu.org>
684
685 PR fortran/34681
686 * trans_array.c (gfc_trans_deferred_array): Do not null the
687 data pointer on entering scope, nor deallocate it on leaving
688 scope, if the symbol has the 'save' attribute.
689
690 PR fortran/34704
691 * trans_decl.c (gfc_finish_var_decl): Derived types with
692 allocatable components and an initializer must be TREE_STATIC.
693
694 2008-01-07 Paul Thomas <pault@gcc.gnu.org>
695
696 PR fortran/34672
697 * module.c (write_generic): Rewrite completely.
698 (write_module): Change call to write_generic.
699
700 2008-01-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
701
702 PR fortran/34659
703 * scanner.c (load_line): Do not count ' ' as printable when checking for
704 continuations.
705
706 2008-01-06 Paul Thomas <pault@gcc.gnu.org>
707
708 PR fortran/34545
709 * module.c (load_needed): If the namespace has no proc_name
710 give it the module symbol.
711
712 2008-01-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
713
714 PR fortran/34387
715 * trans-expr.c (gfc_conv_missing_dummy): Use a temporary to type convert
716 the dummy variable expression, test for NULL, and pass the variable
717 address to the called function.
718
719 2007-01-06 Tobias Burnus <burnus@net-b.de>
720
721 PR fortran/34658
722 * match.c (gfc_match_common): Remove blank common in
723 DATA BLOCK warning.
724 * resolve.c (resolve_common_vars): New function.
725 (resolve_common_blocks): Move checks to resolve_common_vars
726 and invoke that function.
727 (resolve_types): Call resolve_common_vars for blank commons.
728
729 2008-01-06 Tobias Burnus <burnus@net-b.de>
730
731 PR fortran/34655
732 * resolve.c (resolve_equivalence_derived): Reject derived types with
733 default initialization if equivalenced with COMMON variable.
734
735 2008-01-06 Tobias Burnus <burnus@net-b.de>
736
737 PR fortran/34654
738 * io.c (check_io_constraints): Disallow unformatted I/O for
739 internal units.
740
741 2008-01-06 Tobias Burnus <burnus@net-b.de>
742
743 PR fortran/34660
744 * resolve.c (resolve_formal_arglist): Reject dummy procedure in
745 ELEMENTAL functions.
746
747 2008-01-06 Tobias Burnus <burnus@net-b.de>
748
749 PR fortran/34662
750 * interface.c (compare_actual_formal): Reject parameter
751 actual to intent(out) dummy.
752
753 2008-01-04 Tobias Burnus <burnus@net-b.de>
754
755 PR fortran/34557
756 * primary.c (match_varspec): Gobble whitespace before
757 checking for '('.