OSDN Git Service

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