OSDN Git Service

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