OSDN Git Service

2007-09-20 Tobias Burnus <burnus@net-b.de>
[pf3gnuchains/gcc-fork.git] / gcc / fortran / ChangeLog
1 2007-09-20  Tobias Burnus  <burnus@net-b.de>
2
3         PR fortran/33325
4         * intrinsic.text: Add documentation of the intrinsic modules.
5         * gfortran.texi: Link to intrinsic-modules section and to
6         the GOMP manual.
7
8 2007-09-18  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
9
10         PR fortran/31119
11         * trans-array.c (gfc_conv_ss_startstride): Only perform bounds
12         checking for optional args when they are present.
13
14 2007-09-18  Tobias Burnus  <burnus@net-b.de>
15
16         PR fortran/33231
17         * resolve.c (resolve_elemental_actual): Check for conformance
18         of intent out/inout dummies.
19
20 2007-09-17  Tobias Burnus  <burnus@net-b.de>
21
22         PR fortran/33106
23         * resolve.c (resolve_symbol): Reject public variable of
24         private derived-types for Fortran 95.
25
26 2007-09-17  Tobias Burnus  <burnus@net-b.de>
27
28         * resolve.c (resolve_fl_procedure): Allow private dummies
29         for Fortran 2003.
30
31 2007-09-17  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
32
33         * trans-types.c (gfc_get_desc_dim_type): Do not to try
34         emit debug info.
35         (gfc_get_array_descriptor_base): Likewise.
36         (gfc_get_mixed_entry_union): Likewise
37         (gfc_get_derived_type): Set decl location for fields and
38         derived type itself.
39
40 2007-09-16  Paul Thomas  <pault@gcc.gnu.org>
41
42         PR fortran/29396
43         PR fortran/29606
44         PR fortran/30625
45         PR fortran/30871
46         * trans.h : Add extra argument to gfc_build_array_ref. Rename
47         gfc_conv_aliased_arg to gfc_conv_subref_array_arg.  Move
48         prototype of is_aliased_array to gfortran.h and rename it
49         gfc_is_subref_array.  Add field span to lang_decl, add a new
50         decl lang specific flag accessed by GFC_DECL_SUBREF_ARRAY_P
51         and a new type flag GFC_DECL_SUBREF_ARRAY_P.
52         * trans.c (gfc_build_array_ref): Add the new argument, decl.
53         If this is a subreference array pointer, use the lang_decl
54         field 'span' to calculate the offset in bytes and use pointer
55         arithmetic to address the element.
56         * trans-array.c (gfc_conv_scalarized_array_ref,
57         gfc_conv_array_ref): Add the backend declaration as the third
58         field, if it is likely to be a subreference array pointer.
59         (gfc_conv_descriptor_dimension, gfc_trans_array_ctor_element,
60         gfc_trans_array_constructor_element, structure_alloc_comps,
61         gfc_conv_array_index_offset): For all other references to
62         gfc_build_array_ref, set the third argument to NULL.
63         (gfc_get_dataptr_offset): New function.
64         (gfc_conv_expr_descriptor): If the rhs of a pointer assignment
65         is a subreference array, then calculate the offset to the
66         subreference of the first element and set the descriptor data
67         pointer to this, using gfc_get_dataptr_offset.
68         trans-expr.c (gfc_get_expr_charlen): Use the expression for the
69         character length for a character subreference.
70         (gfc_conv_substring, gfc_conv_subref_array_arg): Add NULL for
71         third argument in call to gfc_build_array_ref.
72         (gfc_conv_aliased_arg): Rename to gfc_conv_subref_array_arg.
73         (is_aliased_array): Remove.
74         (gfc_conv_function_call): Change reference to is_aliased_array
75         to gfc_is_subref_array and reference to gfc_conv_aliased_arg to
76         gfc_conv_subref_array_arg.
77         (gfc_trans_pointer_assignment): Add the array element length to
78         the lang_decl 'span' field.
79         * gfortran.h : Add subref_array_pointer to symbol_attribute and
80         add the prototype for gfc_is_subref_array.
81         * trans-stmt.c : Add NULL for third argument in all references
82         to gfc_build_array_ref.
83         * expr.c (gfc_is_subref_array): Renamed is_aliased_array.
84         If this is a subreference array pointer, return true.
85         (gfc_check_pointer_assign): If the rhs is a subreference array,
86         set the lhs subreference_array_pointer attribute.
87         * trans-decl.c (gfc_get_symbol_decl): Allocate the lang_decl
88         field if the symbol is a subreference array pointer and set an
89         initial value of zero for the 'span' field.
90         * trans-io.c (set_internal_unit): Refer to is_subref_array and
91         gfc_conv_subref_array_arg.
92         (nml_get_addr_expr): Add NULL third argument to
93         gfc_build_array_ref. 
94         (gfc_trans_transfer): Use the scalarizer for a subreference
95         array.
96
97 2007-09-13  Thomas Koenig  <tkoenig@gcc.gnu.org>
98
99         * iresolve.c (resolve_mask_arg): If a mask is an array
100         expression, convert it to kind=1.
101
102 2007-09-13  Tobias Burnus  <burnus@net-b.de>
103
104         PR fortran/33343
105         * expr.c (gfc_check_conformance): Print ranks in the error message.
106         * resolve.c (resolve_elemental_actual): Check also conformance of
107         the actual arguments for elemental functions.
108
109 2007-09-13  Tobias Burnus  <burnus@net-b.de>
110
111         * symbol.c (gfc_add_elemental,gfc_add_pure,gfc_add_recursive):
112         Allow prefixes only to be specified once.
113
114 2007-09-13  Tobias Burnus  <burnus@net-b.de>
115
116         PR fortran/33412
117         * symbol.c (check_conflict): Add conflict of ELEMENTAL with Bind(C).
118
119 2007-09-12  Tobias Burnus  <burnus@net-b.de>
120
121         PR fortran/33297
122         * check.c (scalar_check): Move up in the file.
123         (kind_check): Call scalar_check.
124         (dim_check): If optional, do not call nonoptional_check; use
125         bool for optional.
126         (gfc_check_all_any,gfc_check_count,gfc_check_cshift,gfc_check_eoshift,
127         gfc_check_lbound,gfc_check_minloc_maxloc,check_reduction,
128         gfc_check_spread,gfc_check_ubound): Use true/false instead of 0/1
129         for dim_check; honor changed meaning of optional.
130         (gfc_check_int): Replace checks by kind_check.
131         (gfc_check_size): Replace checks by dim_check.
132
133 2007-09-12  Tobias Burnus  <burnus@net-b.de>
134
135         PR fortran/33284
136         PR fortran/33310
137         * symbol.c (check_conflict): Add conflict between INTRINSIC and ENTRY
138         and between BIND(C) and PARAMETER.
139
140 2007-09-12  Tobias Burnus  <burnus@net-b.de>
141
142         * trans-expr.c (gfc_conv_initializer): Fix expr == NULL check.
143
144 2007-09-12  Jan Hubicka  <jh@suse.cz>
145
146         * f95-lang.c (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Kill.
147
148 2007-09-12  Christopher D. Rickett  <crickett@lanl.gov>
149
150         PR fortran/33395
151         * trans-expr.c (gfc_conv_initializer): Remove unnecessary test for
152         intmod_sym_id and use derived symbol to set new kind of C_NULL_PTR
153         and C_NULL_FUNPTR expressions.
154
155 2007-09-11  Christopher D. Rickett  <crickett@lanl.gov>
156
157         PR fortran/33040
158         * trans-expr.c (gfc_trans_structure_assign): Convert component
159         C_NULL_PTR and C_NULL_FUNPTR component initializers to (void *).
160         * trans-types.c (gfc_get_derived_type): Create a backend_decl for
161         the c_address field of C_PTR and C_FUNPTR and ensure initializer
162         is of proper type/kind for (void *).
163
164 2007-09-11  Jan Hubicka <jh@suse.cz>
165
166         * f95-lang.c (gfc_expand_function): Kill.
167         (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Kill.
168
169 2007-09-08  Tobias Burnus  <burnus@net-b.de>
170
171         PR fortran/31547
172         * gfortran.texi: Document when CPP is called.
173
174         * intrinsic.texi (IOR): Fix typos.
175
176 2007-09-10  Paul Thomas  <pault@gcc.gnu.org>
177
178         PR fortran/33370
179         * trans-expr.c (copyable_array_p):  Add tests that expression
180         is a variable, that it has no subreferences and that it is a
181         full array.
182         (gfc_trans_assignment): Change conditions to suit modifications
183         to copyable_array_p.
184
185 2007-09-06  Tom Tromey  <tromey@redhat.com>
186
187         * scanner.c (get_file): Update.
188         (load_file): Update.
189         (gfc_next_char_literal): Use gfc_linebuf_linenum.
190         * f95-lang.c (gfc_init): Update.
191         * gfortran.h (gfc_linebuf_linenum): New macro.
192
193 2007-09-05  Sandra Loosemore  <sandra@codesourcery.com>
194
195         * trans-decl.c (build_entry_thunks): Use set_cfun.
196         (gfc_generate_function_code): Likewise.
197
198 2007-09-05  Paul Thomas  <pault@gcc.gnu.org>
199
200         PR fortran/31564
201         * primary.c (gfc_match_rvalue): Make expressions that refer
202         to derived type parameters that have array references into
203         variable expressions.  Remove references to use association
204         from the symbol.
205
206         PR fortran/33241
207         * decl.c (add_init_expr_to_sym): Provide assumed character
208         length parameters with the length of the initialization
209         expression, if a constant, or that of the first element of
210         an array.
211
212 2007-09-04  Janus Weil  <jaydub66@gmail.com>
213             Paul Thomas  <pault@gcc.gnu.org>
214
215         * decl.c (match_procedure_decl,match_procedure_in_interface,
216         gfc_match_procedure): Handle PROCEDURE statements.
217         * gfortran.h (struct gfc_symbol): New member "gfc_symbol *interface".
218         (enum gfc_statement): New element "ST_PROCEDURE".
219         (strcut symbol_attribute): New member "unsigned procedure".
220         * interface.c (check_interface0): Extended error checking.
221         * match.h: Add gfc_match_procedure prototype.
222         * parse.c (decode_statement,next_statement,gfc_ascii_statement,
223         parse_derived,parse_interface): Implement PROCEDURE statements.
224         * resolve.c (resolve_symbol): Ditto.
225         * symbol.c (check_conflict): Ditto.
226         (gfc_add_proc): New function for setting the procedure attribute.
227         (copy_formal_args): New function for copying formal argument lists.
228
229 2007-09-03  Daniel Jacobowitz  <dan@codesourcery.com>
230
231         * Make-lang.in (gfortranspec.o): Remove SHLIB_MULTILIB.
232
233 2007-09-03  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
234
235         * gfortranspec.c (lang_specific_driver): Use CONST_CAST2.
236         * options.c (gfc_post_options): Supply a TYPE for CONST_CAST.
237         * parse.c (parse_omp_structured_block): Likewise,
238         * st.c (gfc_free_statement): Likewise,
239
240 2007-09-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
241
242         PR fortran/31675
243         * libgfortran.h: New file.
244         * iso-fortran-env.def: Use macros in the new header instead of
245         hardcoded integer constants.
246         * Make-lang.in (F95_PARSER_OBJS, GFORTRAN_TRANS_DEPS): Add
247         fortran/libgfortran.h.
248         * gfortran.h (GFC_STD_*, GFC_FPE_*, options_convert,
249         ioerror_codes): Remove.
250         * trans.c (ERROR_ALLOCATION): Remove.
251         (gfc_call_malloc, gfc_allocate_with_status,
252         gfc_allocate_array_with_status): Use LIBERROR_ALLOCATION.
253         * trans-types.h (GFC_DTYPE_*): Remove.
254         * trans-decl.c (gfc_generate_function_code): Use
255         GFC_CONVERT_NATIVE instead of CONVERT_NATIVE.
256         * trans-io.c (set_parameter_value, set_parameter_ref): Use
257         LIBERROR_* macros instead of IOERROR_ macros.
258         * trans-intrinsic.c (gfc_conv_intrinsic_function): Use
259         LIBERROR_END and LIBERROR_EOR instead of hardcoded constants.
260         * options.c (gfc_init_options): Use GFC_CONVERT_NATIVE instead of
261         CONVERT_NATIVE.
262         (gfc_handle_option): Use GFC_CONVERT_* macros instead of CONVERT_*.
263
264 2007-09-02  Steven G. Kargl  <kargl@gcc.gnu.org>
265
266         * invoke.texi: Fix the -frange-checking option entry.
267
268 2007-09-02  Roger Sayle  <roger@eyesopen.com>
269
270         * decl.c (match_string_p): New helper function to explicitly match
271         a string of characters.
272         (match_attr_spec): Remove no longer needed DECL_COLON from decl_types.
273         Delete decls array and peek_char.  Rewrite decl attribute parser to
274         avoid calling gfc_match_strings.
275         * match.c (gfc_match_strings): Delete unused function.
276         * match.h (gfc_match_strings): Delete prototype.
277
278 2007-09-02  Tobias Schlüuter  <tobi@gcc.gnu.org>
279
280         * dump-parse-tree.c (show_char_const): New function.
281         (gfc_show_expr): Use it.
282         * expr.c (find_substring_ref): Rework to not keep characters
283         dangling beyond end of string.
284
285 2007-09-02  H.J. Lu  <hongjiu.lu@intel.com>
286
287         PR fortran/33276
288         * array.c (expand_iterator): Initialize frame.prev.
289
290 2007-08-31  Tobias Burnus  <burnus@net-b.de>
291
292         PR fortran/33232
293         * io.c (match_io): Also diagnose extra comma for READ.
294
295 2007-08-31  Joseph Myers  <joseph@codesourcery.com>
296
297         * intrinsic.texi (LGAMMA): Remove empty @cindex line.
298
299 2007-08-31  Paul Thomas  <pault@gcc.gnu.org>
300
301         PR fortran/31879
302         PR fortran/31197
303         PR fortran/31258
304         PR fortran/32703
305         * gfortran.h : Add prototype for gfc_resolve_substring_charlen.
306         * resolve.c (gfc_resolve_substring_charlen): New function.
307         (resolve_ref): Call gfc_resolve_substring_charlen.
308         (gfc_resolve_character_operator): New function.
309         (gfc_resolve_expr): Call the new functions in cases where the
310         character length is missing.
311         * iresolve.c (cshift, eoshift, merge, pack, reshape, spread,
312         transpose, unpack): Call gfc_resolve_substring_charlen for
313         source expressions that are character and have a reference.
314         * trans.h (gfc_trans_init_string_length) Change name to
315         gfc_conv_string_length; modify references in trans-expr.c,
316         trans-array.c and trans-decl.c.
317         * trans-expr.c (gfc_trans_string_length): Handle case of no
318         backend_decl.
319         (gfc_conv_aliased_arg): Remove code for treating substrings
320         and replace with call to gfc_trans_string_length.
321         * trans-array.c (gfc_conv_expr_descriptor): Remove code for
322         treating strings and call gfc_trans_string_length instead.
323
324 2007-08-30  Tobias Burnus  <burnus@net-b.de>
325
326         PR fortran/33228
327         * interface.c (check_interface0): Improve error for external procs.
328         (check_sym_interfaces): Fix checking of module procedures.
329
330 2007-08-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
331
332         PR fortran/32989
333         * iresolve.c (gfc_resolve_getarg): Handle non-default integer
334         kinds.
335         * check.c (gfc_check_getarg): New function
336         * intrinsic.h: Add prototype for gfc_check_getarg.
337         * intrinsic.c (add_subroutines): Add reference to gfc_check_getarg.
338         * intrinsic.texi (GETARG): Adjust documentation.
339
340 2007-08-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
341             Tobias Burnus  <burnus@gcc.gnu.org>
342
343         PR fortran/33105
344         * intrinsic.c (add_functions): Add IS_IOSTAT_END and
345         IS_IOSTAT_EOR intrinsics.
346         * gfortran.h (gfc_isym_id): Add GFC_ISYM_IS_IOSTAT_END and
347         GFC_ISYM_IS_IOSTAT_EOR.
348         * trans-intrinsic.c (gfc_conv_has_intvalue): New function.
349         (gfc_conv_intrinsic_function): Call gfc_conv_has_intvalue for
350         GFC_ISYM_IS_IOSTAT_END and GFC_ISYM_IS_IOSTAT_EOR.
351         * intrinsic.texi: Add IS_IOSTAT_END and IS_IOSTAT_EOR.
352
353 2007-08-28  Christopher D. Rickett  <crickett@lanl.gov>
354
355         PR fortran/33215
356         * decl.c (build_sym): Pass number of identifiers on line to
357         set_binding_label.
358         (set_binding_label): Verify that only one identifier given if
359         NAME= specified, even if the given binding label has zero length.
360         (gfc_match_bind_c): Remove declaration for has_name_equals because
361         it hides the static global one that is needed.
362
363 2007-08-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
364
365         * trans-array.c (gfc_grow_array): Use gfc_call_realloc.
366         (gfc_array_allocate): Use gfc_allocate_with_status and
367         gfc_allocate_array_with_status.
368         (gfc_array_deallocate): Use gfc_deallocate_with_status.
369         (gfc_trans_dealloc_allocated): Use gfc_deallocate_with_status.
370         * trans-stmt.c (gfc_trans_allocate): Use gfc_allocate_with_status.
371         (gfc_trans_deallocate): Use gfc_deallocate_with_status.
372         * trans.c (gfc_allocate_with_status, gfc_allocate_array_with_status,
373         gfc_deallocate_with_status, gfc_call_realloc): New functions.
374         * trans.h (gfc_allocate_with_status, gfc_allocate_array_with_status,
375         gfc_deallocate_with_status, gfc_call_realloc): New prototypes.
376         (gfor_fndecl_internal_realloc, gfor_fndecl_allocate,
377         gfor_fndecl_allocate_array, gfor_fndecl_deallocate): Remove.
378         * f95-lang.c (gfc_init_builtin_functions): Create decl for
379         BUILT_IN_REALLOC.
380         * trans-decl.c (gfor_fndecl_internal_realloc,
381         gfor_fndecl_allocate, gfor_fndecl_allocate_array,
382         gfor_fndecl_deallocate): Remove function decls.
383         (gfc_build_builtin_function_decls): Likewise.
384
385 2007-08-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
386
387         PR fortran/33055
388         Revert previous patch.
389
390 2007-08-28  Jakub Jelinek  <jakub@redhat.com>
391
392         PR fortran/22244
393         * Make-lang.in (fortran/trans-types.o): Depend on $(FLAGS_H).
394         * trans-types.c: Include flags.h.
395         (gfc_get_nodesc_array_type): Add TYPE_DECL TYPE_NAME with
396         correct bounds and dimensions for packed arrays.
397
398 2007-08-27  Tobias Burnus  <burnus@net-b.de>
399
400         * simplify.c (gfc_simplify_lgamma): Fix mpfr_lgamma call.
401
402 2007-08-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
403
404         PR fortran/33055
405         * trans-io.c (create_dummy_iostat): New function to create a unique
406         dummy variable expression to use with IOSTAT.
407         (gfc_trans_inquire): Use the new function to pass unit number error info
408         to run-time library if a regular IOSTAT variable was not given.
409
410 2007-08-26  H.J. Lu  <hongjiu.lu@intel.com>
411
412         * gfortran.h (gfc_isym_id): Add GFC_ISYM_GAMMA and
413         GFC_ISYM_LGAMMA.
414
415 2007-08-26  Asher Langton  <langton2@llnl.gov>
416             Tobias Burnus  <burnus@net-b.de>
417
418         * gfortran.h (gfc_option_t): Add flag_recursive.
419         * lang.opt: Add -frecursive option and update -fopenmp.
420         * invoke.texi (-frecursive): Document new option.
421         (-fopenmp,-fno-automatic,-fmax-stack-var-size): Update.
422         * options.c (gfc_init_options, gfc_post_options,
423         gfc_handle_option): Add -frecursive and modify -fopenmp.
424         (gfc_post_options): Add warning for conflicting flags.
425
426 2007-08-26  Tobias Burnus  <burnus@net-b.de>
427
428         PR fortran/31298
429         * module.c (mio_symbol_ref,mio_interface_rest):  Return pointer_info.
430         (load_operator_interfaces): Support multible loading of an operator.
431
432 2007-08-26  Tobias Burnus  <burnus@net-b.de>
433
434         PR fortran/32985
435         * match.c (gfc_match_common): Remove SEQUENCE diagnostics.
436         * resolve.c (resolve_common_blocks): Add SEQUENCE diagnostics;
437         fix walking through the tree.
438
439 2007-08-26  Tobias Burnus  <burnus@net-b.de>
440
441         PR fortran/32980
442         * intrinsic.h (gfc_simplify_gamma,gfc_simplify_lgamma,
443         gfc_resolve_gamma,gfc_resolve_lgamma): New function declations.
444         * mathbuiltins.def: Define GAMMA and LGAMMA.
445         * intrinsic.c (add_functions): Add GAMMA, DGAMMA, LGAMMA, ALGAMA
446         and DLGAMA.
447         * simplify.c (gfc_simplify_gamma,gfc_simplify_lgamma): New functions.
448         * iresolve.c (gfc_resolve_gamma,gfc_resolve_lgamma): New functions.
449         * intrinsic.texi: Add documentation for GAMMA and LGAMMA.
450
451 2007-08-26  Tobias Burnus  <burnus@net-b.de>
452
453         PR fortran/33188
454         * parse.c (parse_derived): Support empty derived type
455         definitions for Fortran 2003.
456
457 2007-08-25  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
458
459         * trans-openmp.c (gfc_omp_privatize_by_reference): Constify.
460         * trans.h (gfc_omp_privatize_by_reference): Likewise.
461
462 2007-08-24  Tobias Burnus  <burnus@net-b.de>
463
464         PR fortran/33178
465         * intrinsic.c (gfc_intrinsic_func_interface): Fix initialization
466         expression check.
467
468 2007-08-24  Thomas Koenig  <tkoenig@gcc.gnu.org>
469
470         PR fortran/32972
471         * iresolve.c:  Don't convert array masks.
472
473 2007-08-24  Tobias Burnus  <burnus@net-b.de>
474
475         PR fortran/33139
476         * trans-array.c (gfc_conv_expr_descriptor): Copy bounds for
477         whole-array pointer assignments.
478
479 2007-08-23  Jakub Jelinek  <jakub@redhat.com>
480
481         * decl.c (variable_decl): Don't share charlen structs if
482         length == NULL.
483         * trans-decl.c (create_function_arglist): Assert
484         f->sym->ts.cl->backend_decl is NULL instead of unsharing
485         charlen struct here.
486
487 2007-08-23  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
488
489         PR fortran/33095
490         * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Remove
491         runtime error checking.
492
493 2007-08-22  Roger Sayle  <roger@eyesopen.com>
494             Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
495
496         * match.c (intrinsic_operators): Delete.
497         (gfc_match_intrinsic_op): Rewrite matcher to avoid calling
498         gfc_match_strings.
499
500 2007-08-22  Christopher D. Rickett  <crickett@lanl.gov>
501
502         PR fortran/33020
503         * resolve.c (gfc_iso_c_sub_interface): Remove setting of type and
504         kind for optional SHAPE parameter of C_F_POINTER.
505
506 2007-08-22  Janus Weil  <jaydub66@gmail.com>
507
508         * decl.c (match_attr_spec): Pass on errors from gfc_match_bind_c.
509         (gfc_match_bind_c): Bugfix in check for NAME= with abstract interfaces.
510         (gfc_match_mopdproc): Bugfix to reject module procedures in
511         abstract interfaces.
512
513 2007-08-22  Kai Tietz  <kai.tietz@onevision.com>
514
515         * f95-lang.c: (gfc_init_decl_processing): Choose sizetype by using
516         Pmode.
517
518 2007-08-21  Paul Brook  <paul@codesourcery.com>
519             Nathan Sidwell  <nathan@codesourcery.com>
520             Mark Mitchell  <mark@codesourcery.com>
521             Joseph Myers  <joseph@codesourcery.com>
522
523         * gfortranspec.c (lang_specific_driver): Use pkgversion_string.
524         * Make-lang.in (gfortran.pod): Define BUGURL.
525         * invoke.texi: Use BUGURL for bug-reporting instructions.
526
527 2007-08-19  Roger Sayle  <roger@eyesopen.com>
528
529         * match.c (intrinsic_operators): Make static.
530         (gfc_op2string): New function for converting a gfc_intrinsic_op to
531         to a "const char*", replacing the macro of the same name.
532         * gfortran.h (intrinsic_operators): Delete prototype.
533         (gfc_op2string): Replace macro with function prototype.
534
535 2007-08-18  Tobias Burnus  <burnus@net-b.de>
536
537         * gfortran.h (gfc_is_intrinsic_typename): Add declaration.
538         * symbol.c (gfc_is_intrinsic_typename): New function.
539         * parse.c (decode_statement): Check for space in ABSTRACT INTERFACE.
540         (parse_interface): Use gfc_is_intrinsic_typename.
541         * decl.c (gfc_match_derived_decl): Ditto.
542         * module.c (gfc_match_use): Use gcc_unreachable() for
543         INTERFACE_ABSTRACT in switch().
544
545 2007-08-18  Roger Sayle  <roger@eyesopen.com>
546
547         * primary.c (match_logical_constant_string): New function to match
548         a ".true." or a ".false.".
549         (match_logical_constant): Use it instead of gfc_match_strings.
550
551 2007-08-18  Paul Thomas  <pault@gcc.gnu.org>
552             Janus Weil  <jaydub66@gmail.com>
553
554         * interface.c (gfc_match_interface,gfc_match_abstract_interface,
555         gfc_match_end_interface,gfc_add_interface): Add abstract interface.
556         * dump-parse-tree.c (gfc_show_attr): Ditto.
557         * gfortran.h (interface_type,symbol_attribute): Ditto.
558         * module.c (gfc_match_use,ab_attribute,attr_bits,
559         mio_symbol_attribute): Ditto.
560         * resolve.c (resolve_function): Ditto.
561         * match.h: Ditto.
562         * parse.c (decode_statement): Ditto.
563         (parse_interface): Ditto, check for C1203 (name of abstract interface
564         cannot be the same as an intrinsic type).
565         * decl.c (gfc_match_bind_c): Check for NAME= with abstract interfaces.
566         (access_attr_decl): Handle Abstract interfaces.
567
568 2007-08-18  Paul Thomas  <pault@gcc.gnu.org>
569
570         PR fortran/32881
571         * expr.c (gfc_check_pointer_assign): If the rhs is the
572         initialization expression for the rhs, there is no error.
573
574 2007-08-18  Paul Thomas  <pault@gcc.gnu.org>
575
576         PR fortran/32875
577         * trans-array.c (get_array_ctor_strlen): Set the character
578         length of a zero length array to zero.
579
580 2007-08-16  Tobias Burnus  <burnus@net-b.de>
581
582         PR fortran/33072
583         * module.c (gfc_match_use): Mark user operators as such.
584         (find_use_name_n): Distinguish between operators and other symbols.
585         (find_use_name,number_use_names,mio_namelist,
586          load_operator_interfaces,load_generic_interfaces,read_module,
587          write_generic): Update find_use_name_n calls.
588
589 2007-08-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
590
591         PR fortran/29459
592         * trans.c (gfc_create_var_np): Do not emit warnings for
593         anonymous variables.
594
595 2007-08-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
596
597         PR fortran/33066
598         * decl.c (gfc_get_type_attr_spec): Fix whitespace.
599         (gfc_match_derived_decl): Fix logic.
600
601 2007-08-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
602
603         PR fortran/33073
604         * trans-intrinsic.c (build_fixbound_expr): Convert to result type
605         in all cases.
606
607 2007-08-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
608
609         PR fortran/32594
610         * trans-expr.c (gfc_conv_substring_expr): Only call
611         gfc_conv_substring if expr->ref is not NULL.
612         * expr.c (gfc_is_constant_expr): If e->ref is NULL, the substring
613         expression might be a constant.
614         (gfc_simplify_expr): Handle missing start and end, as well as
615         missing ref.
616
617 2007-08-13  Paul Thomas  <pault@gcc.gnu.org>
618
619         PR fortran/32926
620         * match.c (gfc_match_call): Do not create a new symtree in the
621         case where the existing symbol is external and not referenced.
622
623 2007-08-13  Paul Thomas  <pault@gcc.gnu.org>
624
625         PR fortran/32827
626         * decl.c (variable_decl): Check for an imported symbol
627         by looking for its symtree and testing for the imported
628         attribute.
629         (gfc_match_import): Remove change of symbol's namespace
630         and set the attribute imported instead.
631         * symbol.c (gfc_get_sym_tree): It is not an error if a
632         symbol is imported.
633         * gfortran.h : Add the 'imported' to symbol_attribute.
634
635 2007-08-13  Paul Thomas  <pault@gcc.gnu.org>
636
637         PR fortran/32962
638         * trans-array.c (gfc_conv_array_transpose): Set the offset
639         of the destination to zero if the loop is zero based.
640
641 2007-08-12  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
642
643         PR fortran/29600
644         * intrinsic.c (add_functions): Add optional KIND argument to ACHAR.
645         * iresolve.c (gfc_resolve_achar): Handle the KIND argument.
646         * check.c (gfc_check_achar): Check for the optional KIND argument.
647         * simplify.c (gfc_simplify_achar): Use KIND argument.
648         * intrinsic.h (gfc_check_achar, gfc_simplify_achar,
649         gfc_resolve_achar): Adjust prototypes.
650
651 2007-08-12  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
652
653         PR fortran/30964
654         PR fortran/33054
655         * trans-expr.c (gfc_conv_function_call): When no formal argument
656         list is available, we still substitute missing optional arguments.
657         * check.c (gfc_check_random_seed): Correct the check on the
658         number of arguments to RANDOM_SEED.
659         * intrinsic.c (add_subroutines): Add a resolution function to
660         RANDOM_SEED.
661         * iresolve.c (gfc_resolve_random_seed): New function.
662         * intrinsic.h (gfc_resolve_random_seed): New prototype.
663
664 2007-08-12  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
665
666         PR fortran/32860
667         * error.c (error_uinteger): New function.
668         (error_integer): Call error_uinteger.
669         (error_print): Handle %u, %lu, %li and %ld format specifiers.
670         * interface.c (compare_actual_formal): Use the new %lu specifier.
671
672 2007-08-12  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
673
674         PR fortran/31629
675         * lang.opt (-fmodule-private): New option.
676         * gfortran.h (gfc_option_t): Add flag_module_private member.
677         * invoke.texi (-fmodule-private): Document the new option.
678         * module.c (gfc_check_access): Allow the -fmodule-private option
679         to modify the default behaviour.
680         * options.c (gfc_init_options): Initialize flag_module_private.
681         (gfc_handle_option): Handle -fmodule-private.
682
683 2007-08-12  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
684
685         PR fortran/29600
686         * intrinsic.c (add_functions): Add KIND arguments to COUNT,
687         IACHAR, ICHAR, INDEX, LBOUND, LEN, LEN_TRIM, SCAN, SIZE, UBOUND
688         and VERIFY.
689         * iresolve.c (gfc_resolve_count): Add kind argument.
690         (gfc_resolve_iachar): New function.
691         (gfc_resolve_ichar): Add kind argument.
692         (gfc_resolve_index_func): Likewise.
693         (gfc_resolve_lbound): Likewise.
694         (gfc_resolve_len): Likewise.
695         (gfc_resolve_len_trim): Likewise.
696         (gfc_resolve_scan): Likewise.
697         (gfc_resolve_size): New function.
698         (gfc_resolve_ubound): Add kind argument.
699         (gfc_resolve_verify): Likewise.
700         * trans-decl.c (gfc_get_extern_function_decl): Allow specific
701         intrinsics to have 4 arguments.
702         * check.c (gfc_check_count): Add kind argument.
703         (gfc_check_ichar_iachar): Likewise.
704         (gfc_check_index): Likewise.
705         (gfc_check_lbound): Likewise.
706         (gfc_check_len_lentrim): New function.
707         (gfc_check_scan): Add kind argument.
708         (gfc_check_size): Likewise.
709         (gfc_check_ubound): Likewise.
710         (gfc_check_verify): Likewise.
711         * intrinsic.texi: Update documentation for COUNT, IACHAR, ICHAR,
712         INDEX, LBOUND, LEN, LEN_TRIM, SCAN, SIZE, UBOUND and VERIFY.
713         * simplify.c (get_kind): Whitespace fix.
714         (int_expr_with_kind): New function.
715         (gfc_simplify_iachar): Add kind argument.
716         (gfc_simplify_iachar): Likewise.
717         (gfc_simplify_ichar): Likewise.
718         (gfc_simplify_index): Likewise.
719         (simplify_bound_dim): Likewise.
720         (simplify_bound): Likewise.
721         (gfc_simplify_lbound): Likewise.
722         (gfc_simplify_len): Likewise.
723         (gfc_simplify_len_trim): Likewise.
724         (gfc_simplify_scan): Likewise.
725         (gfc_simplify_shape): Pass NULL as kind argument to gfc_simplify_size.
726         (gfc_simplify_size): Add kind argument.
727         (gfc_simplify_ubound): Likewise.
728         (gfc_simplify_verify): Likewise.
729         * intrinsic.h: Update prototypes and add new ones.
730         * trans-intrinsic.c (gfc_conv_intrinsic_index): Rename into
731         gfc_conv_intrinsic_index_scan_verify.
732         (gfc_conv_intrinsic_scan, gfc_conv_intrinsic_verify): Remove.
733         (gfc_conv_intrinsic_function): Call
734         gfc_conv_intrinsic_index_scan_verify to translate the INDEX,
735         SCAN and VERIFY intrinsics.
736
737 2007-08-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
738
739         PR fortran/31189
740         * invoke.texi (-fbacktrace): Document the new behaviour.
741
742 2007-08-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
743
744         PR fortran/32937
745         * trans-array.c (gfc_conv_expr_descriptor): Use
746         gfc_conv_const_charlen to generate backend_decl of right type.
747         * trans-expr.c (gfc_conv_expr_op): Use correct return type.
748         (gfc_build_compare_string): Use int type instead of default
749         integer kind for single character comparison.
750         (gfc_conv_aliased_arg): Give backend_decl the right type.
751         * trans-decl.c (gfc_build_intrinsic_function_decls): Make
752         compare_string return an int.
753
754 2007-08-11  Ian Lance Taylor  <iant@google.com>
755
756         * f95-lang.c (gfc_get_alias_set): Change return type to
757         alias_set_type.
758
759 2007-08-10  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
760
761         PR fortran/31270
762         * trans.c (gfc_trans_runtime_check): Reorder arguments and
763         add extra variable arguments. Hand them to the library function.
764         * trans.h (gfc_trans_runtime_check): Update prototype.
765         * trans-array.c (gfc_trans_array_bound_check): Issue more
766         detailled error messages.
767         (gfc_conv_array_ref): Likewise.
768         (gfc_conv_ss_startstride): Likewise.
769         (gfc_trans_dummy_array_bias): Reorder arguments to
770         gfc_trans_runtime_check.
771         * trans-expr.c (gfc_conv_substring): Issue more detailled
772         error messages.
773         (gfc_conv_function_call): Reorder arguments to gfc_trans_runtime_check.
774         * trans-stmt.c (gfc_trans_goto): Likewise.
775         * trans-io.c (set_string): Reorder arguments to
776         gfc_trans_runtime_check and issue a more detailled error message.
777         * trans-decl.c (gfc_build_builtin_function_decls): Make
778         runtime_error and runtime_error_at handle a variable number of
779         arguments.
780         * trans-intrinsic.c (gfc_conv_intrinsic_bound): Reorder arguments
781         to gfc_trans_runtime_check.
782         (gfc_conv_intrinsic_minmax): Likewise.
783         (gfc_conv_intrinsic_repeat): Issue more detailled error messages.
784
785 2007-08-10  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
786
787         * gfortranspec.c (lang_specific_driver): Use CONST_CAST.
788         * options.c (gfc_post_options): Likewise.
789         * parse.c (parse_omp_structured_block): Likewise.
790         * st.c (gfc_free_statement): Likewise.
791
792 2007-08-10  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
793
794         PR fortran/32933
795         * trans-decl.c (gfc_build_builtin_function_decls): Change
796         prototype for associated.
797         * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Convert the
798         result of __builtin_isnan into a boolean.
799         (gfc_conv_intrinsic_strcmp): Cleanup.
800         (gfc_conv_associated): Convert the result of the associated
801         function into a boolean.
802
803 2007-08-09  Tobias Burnus  <burnus@net-b.de>
804
805         PR fortran/32987
806         * io.c (format_token): Add FMT_ERROR.
807         (next_char_not_space): Print error/warning when
808         '\t' are used in format specifications.
809         (format_lex): Propagate error.
810         (check_format): Ditto.
811
812 2007-08-09  Tobias Burnus  <burnus@net-b.de>
813
814         PR fortran/33001
815         * arith.c (arith_error): Point in the error message
816         to -fno-range-check.
817
818 2007-08-09  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
819
820         PR fortran/32902
821         * intrinsic.texi (SIZEOF): Add mention to C_SIZE_T.
822
823 2007-08-06  Christopher D. Rickett  <crickett@lanl.gov>
824
825         PR fortran/32732
826         * trans-expr.c (gfc_conv_scalar_char_value): Convert the tree and
827         actual arg expressions for scalar characters passed by-value to
828         bind(c) routines.
829         (gfc_conv_function_call): Call gfc_conv_scalar_char_value.
830         * trans.h: Add prototype for gfc_conv_scalar_char_value.
831         * trans-decl.c (generate_local_decl): Convert by-value character
832         dummy args of bind(c) procedures using
833         gfc_conv_scalar_char_value.
834
835 2007-08-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
836
837         PR fortran/30947
838         * iresolve.c (gfc_resolve_alarm_sub): Suffix the subroutine name
839         with the kind of the STATUS argument.
840
841 2007-08-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
842
843         PR fortran/30948
844         * intrinsic.c (add_functions): Fix name of argument to CHDIR.
845
846 2007-08-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
847
848         PR fortran/30933
849         * iresolve.c (gfc_resolve_exit): Convert argument to default
850         integer kind.
851
852 2007-08-06  Daniel Franke  <franke.daniel@gmail.com>
853
854         * resolve.c (derived_pointer): Removed, replaced callers by access 
855         to appropiate attribute bit.
856         (derived_inaccessable): Shortcut recursion depth.
857         (resolve_fl_namelist): Fixed checks for private components in namelists.
858
859 2007-08-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
860
861         PR fortran/29828
862         * trans.h (gfor_fndecl_string_minmax): New prototype.
863         * trans-decl.c (gfor_fndecl_string_minmax): New variable.
864         (gfc_build_intrinsic_function_decls): Create gfor_fndecl_string_minmax.
865         * check.c (gfc_check_min_max): Allow for character arguments.
866         * trans-intrinsic.c (gfc_conv_intrinsic_minmax_char): New function.
867         (gfc_conv_intrinsic_function): Add special case for MIN and MAX
868         intrinsics with character arguments.
869         * simplify.c (simplify_min_max): Add simplification for character
870         arguments.
871
872 2007-08-06  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
873
874         PR fortran/31612
875         * invoke.texi: Adjust documentation for option -fsyntax-only.
876
877 2007-08-05  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
878             Tobias Burnus  <burnus@gcc.gnu.org>
879
880         PR fortran/32979
881         * intrinsic.h (gfc_check_isnan): Add prototype.
882         * gfortran.h (gfc_isym_id): Add GFC_ISYM_ISNAN.
883         * intrinsic.c (add_functions): Add ISNAN intrinsic.
884         * check.c (gfc_check_isnan): New function.
885         * trans-intrinsic.c (gfc_conv_intrinsic_isnan): New function.
886         (gfc_conv_intrinsic_function): Call gfc_conv_intrinsic_isnan
887         to translate ISNAN.
888         * intrinsic.texi: Document ISNAN.
889
890 2007-08-04  Paul Thomas  <pault@gcc.gnu.org>
891
892         PR fortran/31214
893         * symbol.c (get_unique_symtree): Moved from module.c.
894         * module.c (get_unique_symtree): Moved to symbol.c.
895         * decl.c (get_proc_name): Transfer the typespec from the local
896         symbol to the module symbol, in the case that an entry is also
897         a module procedure.  Ensure the local symbol is cleaned up by
898         pointing to it with a unique symtree.
899
900         * dump_parse_tree (gfc_show_code_node): Add EXEC_ASSIGN_CALL.
901
902 2008-08-04  Steven G. Kargl  <kargl@gcc.gnu.org>
903
904         PR fortran/32969
905         * iresolve.c (gfc_resolve_rrspacing): Convert argument(s) to
906         expected KIND.
907         (gfc_resolve_scale): Ditto.
908         (gfc_resolve_set_exponent): Ditto.
909         (gfc_resolve_spacing): Ditto.
910  
911         PR fortran/32968
912         * trans-intrinsic.c (gfc_conv_intrinsic_si_kind,
913         gfc_conv_intrinsic_sr_kind): Convert the argument(s) to the
914         expected KIND, and fold the result to the expected KIND.
915
916 2007-08-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
917
918         PR fortran/31202
919         * f95-lang.c (gfc_init_builtin_functions): Defin builtins for 
920         lround{f,,l} and llround{f,,l}.
921         * trans-intrinsic.c (build_fix_expr): Generate calls to the
922         {l,}round{f,,l} functions.
923
924 2007-08-01  Thomas Koenig  <tkoenig@gcc.gnu.org>
925
926         PR libfortran/32954
927         * intrinsic.c (resolve_mask_arg):  New function.
928         (gfc_resolve_maxloc):  Use resolve_mask_arg for mask resolution.
929         (gfc_resolve_maxval):  Likewise.
930         (gfc_resolve_minloc):  Likewise.
931         (gfc_resolve_minval):  Likewise.
932         (gfc_resolve_pack):  Likewise.
933         (gfc_resolve_product):  Likewise.
934         (gfc_resolve_sum):  Likewise.
935         (gfc_resolve_unpack):  Likewise.
936
937 2007-08-01  Tobias Burnus  <burnus@net-b.de>
938
939         PR fortran/32936
940         * match.c (gfc_match_allocate): Better check that STAT is
941         a variable.
942
943         * check.c (gfc_check_allocated): Reorder checks to improve
944         error message.
945
946 2007-08-01  Nick Clifton  <nickc@redhat.com>
947
948         * arith.c: Change copyright header to refer to version 3 of the
949         GNU General Public License and to point readers at the COPYING3
950         file and the FSF's license web page.
951         * openmp.c, interface.c, intrinsic.c, trans-array.c, trans-expr.c,
952         symbol.c, iso-fortran-env.def, intrinsic.h, decl.c, trans-array.h,
953         matchexp.c, dump-parse-tree.c, trans-common.c, array.c,
954         Make-lang.in, trans-openmp.c, gfortran.h, error.c,
955         iso-c-binding.def, lang.opt, data.c, trans-const.c, trans-stmt.c,
956         expr.c, trans-const.h, trans-stmt.h, module.c, trans.c, scanner.c,
957         trans-types.c, trans.h, gfortranspec.c, trans-types.h,
958         lang-specs.h, io.c, bbt.c, resolve.c, f95-lang.c, st.c,
959         iresolve.c, match.c, trans-decl.c, trans-io.c, target-memory.c,
960         match.h, target-memory.h, parse.c, arith.h, check.c, dependency.c,
961         parse.h, types.def, convert.c, dependency.h, primary.c,
962         trans-intrinsic.c, options.c, misc.c, simplify.c: Likewise.
963
964 2007-08-01  Daniel Franke  <franke.daniel@gmail.com>
965
966         * trans-decl.c (generate_local_decl): Emit warning on unused parameter
967         on "-Wall -Wextra" or "-Wunused-parameter" but not on "-Wall", changed
968         messages that start with lower case to upper case.
969         * invoke.texi (-Wparameter-unused): Document differences between gcc
970         and gfortran regarding this option.
971
972 2007-08-01  Daniel Franke  <franke.daniel@gmail.com>
973
974         PR fortran/32945
975         * expr.c (check_specification_function): Skip check if no symtree 
976         is available.
977
978 2007-08-01  Paul Thomas  <pault@gcc.gnu.org>
979
980         PR fortran/31609
981         * resolve.c (resolve_entries): Entries declared to be module
982         procedures must point to the function namespace.
983
984 2007-07-31  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
985
986         PR fortran/32938
987         * trans-stmt.c (gfc_trans_return): Convert to correct type.
988
989 2007-07-31  Steven G. Kargl  <kargl@gcc.gnu.org>
990
991         PR fortran/32942
992         * trans-intrinsic.c (gfc_conv_intrinsic_exponent): Convert to correct
993         type.
994
995 2007-07-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
996
997         * invoke.texi: Document -fsign-zero flag.
998
999 2007-07-29  Paul Thomas  <pault@gcc.gnu.org>
1000
1001         PR fortran/31211
1002         * trans-expr.c (gfc_conv_expr_reference): Add block for case of
1003         scalar pointer functions so that NULL result is correctly
1004         handled.
1005
1006         PR fortran/32682
1007         * trans-array.c (gfc_trans_array_constructor): On detecting a
1008         multi-dimensional parameter array, set the loop limits.
1009
1010 2007-07-29  Daniel Franke  <franke.daniel@gmail.com>
1011
1012         PR fortran/32906
1013         * resolve.c (resolve_fl_parameter): Check for constant shape arrays,
1014         adjusted error message.
1015
1016 2007-07-29  Daniel Franke  <franke.daniel@gmail.com>
1017
1018         * invoke.texi: Removed -w from option summary.
1019
1020 2007-07-29  Daniel Franke  <franke.daniel@gmail.com>
1021
1022         PR fortran/32879
1023         * intrinsic.texi (IRAND, RAND, RANDOM_NUMBER): Document algorithm
1024         used for random number generator.
1025
1026 2007-07-28  Kazu Hirata  <kazu@codesourcery.com>
1027
1028         * gfortran.h, interface.c, resolve.c, symbol.c: Fix comment
1029         typos.
1030         * intrinsic.texi, invoke.texi: Fix typos.
1031
1032 2007-07-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1033
1034         PR fortran/31609
1035         * resolve.c (generic_sym): Check for a same symbol and if so, return to
1036         avoid infinite recursion.
1037
1038 2007-07-28  Daniel Franke  <franke.daniel@gmail.com>
1039
1040         PR fortran/31818
1041         PR fortran/32876
1042         PR fortran/32905
1043         * gfortran.h (symbol_attribute): Added bits for pointer_comp, 
1044         private_comp.
1045         * parse.c (parse_derived): Set pointer_comp/private_comp bits if 
1046         the derived type ultimately contains pointer components or private 
1047         components.
1048         * module.c (ab_attribute): New values AB_POINTER_COMP, AB_PRIVATE_COMP.
1049         (attr_bits): Added names for new ab_attributes.
1050         (mio_symbol_attribute): Save/restore new attribute bits in modules.
1051         * match.c (gfc_match_namelist): Removed check for namelist objects
1052         of assumed shape.
1053         * resolve.c (resolve_fl_namelist): Added check for pointer or
1054         private components in nested types. Added check for namelist objects
1055         of assumed shape.
1056
1057 2007-07-28  Paul Thomas  <pault@gcc.gnu.org>
1058
1059         PR fortran/32880
1060         * trans-expr.c (gfc_trans_scalar_assign): Revert to fixed order
1061         for lse and rse pre expressions, for derived types with
1062         allocatable components.  Instead, assign the lhs to a temporary
1063         and deallocate after the assignment.
1064
1065 2007-07-28  Janne Blomqvist  <jb@gcc.gnu.org>
1066
1067         PR fortran/32909
1068         * trans-stmt.c (gfc_trans_character_select): Replace occurrences
1069         of gfc_c_int_type_node with integer_type_node.
1070         * trans-decl.c (gfc_build_intrinsic_function_decls): Likewise.
1071         (gfc_build_builtin_function_decls): Likewise.
1072         (gfc_generate_function_code): Likewise.
1073         * trans-io.c (gfc_build_io_library_fndecls): Likewise.
1074
1075 2007-07-27  Janne Blomqvist  <jb@gcc.gnu.org>
1076
1077         * trans-decl.c (gfc_build_builtin_function_decls): Use existing
1078         gfc_array_index_type rather than creating another typenode for
1079         gfc_index_integer_kind.
1080
1081 2007-07-27  Janne Blomqvist  <jb@gcc.gnu.org>
1082
1083         * trans-io.c (gfc_build_io_library_fndecls): Change to use
1084         gfc_array_index_type for array descriptor triplets instead of
1085         gfc_int4_type_node.
1086
1087 2007-07-26  Steven G. Kargl  <kargl@gcc.gnu.org>
1088
1089         PR fortran/32899
1090         * resolve.c (resolve_operator): Add INTRINSIC_EQ_OS comparison.
1091
1092 2007-07-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1093             Daniel Franke  <franke.daniel@gmail.com>
1094
1095         PR fortran/32760
1096         * primary.c (match_variable): Do not call gfc_add_flavor if symbol has
1097         attribute of ACCESS_PUBLIC or ACCESS_PRIVATE already marked.
1098
1099 2007-07-27  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1100
1101         PR fortran/32035
1102         * trans-stmt.c (gfc_trans_character_select): Replace the
1103         mechanism with labels by a SWITCH_EXPR.
1104         * trans-decl.c (gfc_build_builtin_function_decls): Change
1105         return type for select_string.
1106
1107 2007-07-27  Paul Thomas  <pault@gcc.gnu.org>
1108
1109         PR fortran/32903
1110         * trans-decl.c (gfc_trans_deferred_vars): Set intent(out)
1111         derived types as referenced, if they have the the default
1112         initializer set.
1113
1114 2007-07-25  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
1115
1116         * gfortran.h (generate_isocbinding_symbol): Constify.
1117         * symbol.c (gen_special_c_interop_ptr, gen_cptr_param,
1118         generate_isocbinding_symbol): Likewise.
1119
1120 2007-07-24  Paul Thomas  <pault@gcc.gnu.org>
1121
1122         PR fortran/31205
1123         PR fortran/32842
1124         * trans-expr.c (gfc_conv_function_call): Remove the default
1125         initialization of intent(out) derived types.
1126         * symbol.c (gfc_lval_expr_from_sym): New function.
1127         * matchexp.c (gfc_get_parentheses): Return argument, if it is
1128         character and posseses a ref.
1129         * gfortran.h : Add prototype for gfc_lval_expr_from_sym.
1130         * resolve.c (has_default_initializer): Move higher up in file.
1131         (resolve_code): On detecting an interface assignment, check
1132         if the rhs and the lhs are the same symbol.  If this is so,
1133         enclose the rhs in parenetheses to generate a temporary and
1134         prevent any possible aliasing.
1135         (apply_default_init): Remove code making the lval and call
1136         gfc_lval_expr_from_sym instead.
1137         (resolve_operator): Give a parentheses expression a type-
1138         spec if it has no type.
1139         * trans-decl.c (gfc_trans_deferred_vars): Apply the a default
1140         initializer, if any, to an intent(out) derived type, using
1141         gfc_lval_expr_from_sym and gfc_trans_assignment.  Check if
1142         the dummy is present.
1143
1144 2007-07-24  Daniel Franke  <franke.daniel@gmail.com>
1145
1146         PR fortran/32867
1147         * expr.c (check_init_expr): Simplify matched functions.
1148
1149 2007-07-24  Daniel Franke  <franke.daniel@gmail.com>
1150
1151         PR fortran/32778
1152         * intrinsic.c (add_sym): Do not exclude any symbols, even if not part
1153         of the selected standard.
1154         (make generic): Likewise.
1155         (make alias): Likewise, set standard the alias belongs to.
1156         (add_subroutines): Call make_noreturn unconditionally.
1157         (check_intrinsic_standard): Change return value to try.
1158         (gfc_intrinsic_func_interface): Check return value of above function.
1159         (gfc_intrinsic_sub_interface): Likewise.
1160
1161 2007-07-24  Thomas Koenig  <tkoenig@gcc.gnu.org>
1162
1163         PR fortran/30814
1164         * trans-decl.c (generate_function_code):  Add argument
1165         for flag_bounds_check to the array for set_options.
1166         * invoke.texi (-fbounds-check): Document new libarary run-time
1167         behaviour.
1168
1169 2007-07-23  Daniel Franke  <franke.daniel@gmail.com>
1170
1171         PR fortran/25104
1172         PR fortran/31639
1173         * expr.c (check_transformational): Reject valid transformational
1174         intrinsics to avoid ICE.
1175         (check_inquiry): Report error for assumed character lengths for
1176         all supported standards.
1177         (check_init_expr): Whitespace fix.
1178
1179 2007-07-23  Christopher D. Rickett  <crickett@lanl.gov>
1180
1181         PR fortran/32797
1182         PR fortran/32800
1183         * decl.c (verify_bind_c_sym): Use the result symbol for functions
1184         with a result clause.  Warn if implicitly typed.  Verify the type
1185         and rank of the SHAPE argument, if given.
1186         * resolve.c (gfc_iso_c_sub_interface): Use gfc_procedure_use to
1187         check the actual args against the formal, sorting them if
1188         necessary.
1189         * symbol.c (gen_shape_param): Initialize type of SHAPE param to
1190         BT_VOID.
1191
1192 2007-07-23  Christopher D. Rickett  <crickett@lanl.gov>
1193
1194         PR fortran/32732
1195         * trans-decl.c (generate_local_decl): Convert the TREE_TYPE for by
1196         value character dummy args of BIND(C) procedures.
1197         * trans-expr.c (gfc_conv_variable): Do not build address
1198         expression for BT_CHARACTER dummy args.
1199
1200 2007-07-23  Christopher D. Rickett  <crickett@lanl.gov>
1201             Tobias Burnus  <burnus@net-b.de>
1202
1203         PR fortran/32600
1204         * trans-expr.c (gfc_conv_function_call): Handle c_funloc.
1205         * trans-types.c: Add pfunc_type_node.
1206         (gfc_init_types,gfc_typenode_for_spec): Use it.
1207         * resolve.c (gfc_iso_c_func_interface): Fix whitespace and
1208         improve error message.
1209
1210 2007-07-22  Daniel Franke  <franke.daniel@gmail.com>
1211
1212         PR fortran/32710
1213         * parse.c (gfc_fixup_sibling_symbols): No replacement of symbols if
1214         the current is a namelist.
1215
1216 2007-07-22  Daniel Franke  <franke.daniel@gmail.com>
1217
1218         PR fortran/29962
1219         PR fortran/31253
1220         PR fortran/31265
1221         PR fortran/31639
1222         * gfortran.h (gfc_intrinsic_sym): Changed members elemental, pure,
1223         generic, specific, actual_ok, noreturn into bits of a bitfield, 
1224         added bits for inquiry, transformational, conversion.
1225         * check.c (non_init_transformational): Removed, removed all callers.
1226         * intrinsic.c (enum class): New.
1227         (add_sym*): Replaced argument elemetal by enum class. Changed all
1228         callers.
1229         (add_functions): Assign appropriate classes to intrinsic functions.
1230         (add_subroutines): Assign appropriate classes to intrinsic subroutines.
1231         (add_conv): Set conversion attribute.
1232         (gfc_init_expr_extensions): Removed, removed all callers.
1233         (gfc_intrinsic_func_interface): Reimplemented check for non-standard
1234         initializatione expressions.
1235         * expr.c (check_specification_function): New.
1236         (gfc_is_constant_expr): Added check for specification functions.
1237         (check_init_expr_arguments): New.
1238         (check_inquiry): Changed return value to MATCH, added checks for
1239         inquiry functions defined by F2003.
1240         (check_transformational): New.
1241         (check_null): New.
1242         (check_elemental): New.
1243         (check_conversion): New.
1244         (check_init_expr): Call new check functions, add more specific error
1245         messages.
1246
1247 2007-07-21  Christopher D. Rickett  <crickett@lanl.gov>
1248
1249         PR fortran/32627
1250         * resolve.c (set_name_and_label): Set kind number for character
1251         version of c_f_pointer.
1252         (gfc_iso_c_sub_interface): Set the kind of the SHAPE formal arg to
1253         that of the actual SHAPE arg.
1254         * symbol.c (gen_shape_param): Initialize kind for SHAPE arg.
1255
1256 2007-07-21  Christopher D. Rickett  <crickett@lanl.gov>
1257
1258         PR fortran/32801
1259         * symbol.c (generate_isocbinding_symbol): Remove unnecessary
1260         conditional.
1261
1262         PR fortran/32804
1263         * resolve.c (gfc_iso_c_func_interface): Reject assumed-shape and
1264         deferred-shape arrays as args to C_LOC.  Fix bug in testing
1265         character args to C_LOC.
1266
1267 2007-07-21  Lee Millward  <lee.millward@gmail.com>
1268
1269         PR fortran/32823
1270         * trans-intrinsic.c (gfc_conv_intrinsic_int): Evaluate all
1271         arguments passed, not just the first one. Adjust code to 
1272         refer to "args[0]" instead of "arg" as a result.
1273         
1274 2007-07-19  Christopher D. Rickett  <crickett@lanl.gov>
1275
1276         PR fortran/32600
1277         * trans-expr.c (gfc_conv_function_call): Inline C_LOC.
1278
1279 2007-07-18  Christopher D. Rickett  <crickett@lanl.gov>
1280
1281         PR fortran/32801
1282         * symbol.c (generate_isocbinding_symbol): Fix bug where
1283         ISOCBINDING_FUNPTR was generated for C_LOC instead of the needed
1284         ISOCBINDING_PTR.
1285
1286 2007-07-17  Janus Weil  <jaydub66@gmail.com> 
1287
1288         PR fortran/32535
1289         * resolve.c (resolve_fl_namelist): Check for namelist private 
1290         components in contained subprograms.
1291
1292 2007-07-17  Paul Thomas  <pault@gcc.gnu.org>
1293
1294         PR fortran/31320
1295         PR fortran/32665
1296         * trans-expr.c (gfc_trans_subcomponent_assign): Ensure that
1297         renormalization unity base is done independently of existing
1298         lbound value.
1299         (gfc_trans_scalar_assign): If rhs is not a variable, put
1300         lse->pre after rse->pre to ensure that de-allocation of lhs
1301         occurs after evaluation of rhs.
1302
1303 2007-07-16  Lee Millward  <lee.millward@gmail.com>
1304
1305         PR fortran/32222
1306         PR fortran/32238
1307         PR fortran/32242        
1308         * trans-intrinsic.c (gfc_conv_intrinsic_function_args): Adjust
1309         to operate on a stack allocated array for the intrinsic arguments
1310         instead of creating a TREE_LIST. Add two new parameters for the
1311         array and the number of elements. Update all callers to allocate
1312         an array of the correct length to pass in. Update comment.
1313         (gfc_intrinsic_argument_list_length): New function.
1314         (gfc_conv_intrinsic_conversion): Call it.
1315         (gfc_conv_intrinsic_mnimax): Likewise.
1316         (gfc_conv_intrinsic_merge): Likewise.
1317         (gfc_conv_intrinsic_lib_function): Call it. Use new CALL_EXPR
1318         constructors.
1319         (gfc_conv_intrinsic_cmplx): Likewise.
1320         (gfc_conv_intrinsic_ctime): Likewise.
1321         (gfc_covn_intrinsic_fdate): Likewise.
1322         (gfc_conv_intrinsic_ttynam): Likewise.
1323         (gfc_conv_intrinsic_ishftc): Likewise.
1324         (gfc_conv_intrinsic_index): Likewise.
1325         (gfc_conv_intrinsic_scan): Likewise.
1326         (gfc_conv_intrinsic_verify): Likewise.
1327         (gfc_conv_intrinsic_trim): Likewise.
1328         (gfc_conv_intrinsic_aint): Use new CALL_EXPR constructors.
1329         (gfc_conv_intrinsic_exponent): Likewise.
1330         (gfc_conv_intrinsic_bound): Likewise.
1331         (gfc_conv_intrinsic_abs): Likewise.
1332         (gfc_conv_intrinsic_mod): Likewise.
1333         (gfc_conv_intrinsic_sign): Likewise.
1334         (gfc_conv_intrinsic_len): Likewise.
1335         (gfc_conv_intrinsic_adjust): Likewise.
1336         (gfc_conv_intrinsic_si_kind): Likewise. 
1337         
1338 2007-07-16  Janne Blomqvist  <jb@gcc.gnu.org>
1339
1340         PR fortran/32748
1341         * trans-decl.c (gfc_build_builtin_function_decls): Remove
1342         DECL_IS_MALLOC attribute from internal_realloc, thus reverting
1343         part of my 2007-07-03 patch.
1344
1345 2007-07-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1346             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1347
1348         PR fortran/32611
1349         * gfortran.h (gfc_option_t): Add flag_sign_zero field.
1350         * lang.opt (-fsign-zero): New option.
1351         * trans.h: Rename gfor_fndecl_set_std into gfor_fndecl_set_options.
1352         * trans-decl.c (gfc_build_builtin_function_decls): Build the function
1353         declaration to pass an array containing the options to be used by the
1354         runtime library. (gfc_generate_function_code): Build an array that
1355         contains option values to be passed to the runtime library and the call
1356         to the function. 
1357         * options.c (gfc_init_options): Initialize the flag_sign_zero field.
1358         (gfc_handle_option): Handle the -fsign-zero option.
1359
1360 2007-07-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1361
1362         PR fortran/32036
1363         * trans-array.c (gfc_conv_array_ref): Only evaluate index once.
1364
1365 2007-07-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1366
1367         PR fortran/32357
1368         * iresolve.c (gfc_resolve_mvbits): Convert FROMPOS, LEN and TOPOS
1369         to C int.
1370
1371 2007-07-14  Thomas Koenig  <tkoenig@gcc.gnu.org>
1372
1373         PR libfortran/32731
1374         * iresolve.c(gfc_resolve_pack):  A scalar mask has
1375         to be kind=4, an array mask with kind<4 is converted
1376         to gfc_default_logical_kind automatically.
1377         (gfc_resolve_unpack):  Convert mask to gfc_default_lotical_kind
1378         if it has a kind<4.
1379
1380 2007-07-14  Paul Thomas  <pault@gcc.gnu.org>
1381
1382         PR fortran/32724
1383         * parse.c (parse_spec): Emit error on unexpected statement
1384         function.
1385
1386 2007-07-13  Daniel Franke  <franke.daniel@gmail.com>
1387
1388         * invoke.texi: Unified upper- and lower-case in menus.
1389         (-w, -W): Removed, documented by gcc.
1390         * intrinsic.texi: Unified Class-section entries, added
1391         subroutine/function warning where appropiate.
1392
1393 2007-07-12  Daniel Franke  <franke.daniel@gmail.com>
1394
1395         PR fortran/31639
1396         * decl.c (gfc_match_suffix): Removed surplus general error that hides
1397         a more specific message.
1398         * resolve.c (resolve_fl_variable): Reject illegal initializiers only
1399         if not already done.
1400         (resolve_fl_procedure): Added check for initializers of functions.
1401
1402 2007-07-12  Daniel Franke  <franke.daniel@gmail.com>
1403
1404         PR fortran/32704
1405         * invoke.texi (-static-libgfortran): Document new option.
1406
1407 2007-07-12  Paul Thomas  <pault@gcc.gnu.org>
1408
1409         PR fortran/32634
1410         PR fortran/32727
1411         * module.c (write_generic): Restore patch of 2007-07-10 and use
1412         symbol name if there are no use names. 
1413
1414 2007-07-12  Christopher D. Rickett  <crickett@lanl.gov>
1415
1416         PR fortran/32599
1417         * decl.c (verify_c_interop_param): Require character string dummy
1418         args to BIND(C) procedures to have length 1.
1419         * resolve.c (resolve_fl_procedure): Modify parameter checking for
1420         BIND(C) procedures.
1421
1422         PR fortran/32601
1423         * resolve.c (gfc_iso_c_func_interface): Verify that a valid
1424         expression is given as an argument to C_LOC and C_ASSOCIATED.
1425         * trans-io.c (transfer_expr): Add argument for code block.  Add
1426         standards check to determine if an error message should be
1427         reported for printing C_PTR or C_FUNPTR.
1428         (transfer_array_component): Update arguments to transfer_expr.
1429         (gfc_trans_transfer): Ditto.
1430
1431         * symbol.c (gen_cptr_param): Fix whitespace.
1432
1433 2007-07-12  Jakub Jelinek  <jakub@redhat.com>
1434
1435         PR fortran/32550
1436         * trans.h (GFC_POINTER_TYPE_P): Define.
1437         * trans-types.c (gfc_sym_type): Set it for types on attr->sym.pointer.
1438         * trans-openmp.c (gfc_omp_privatize_by_reference): Return false
1439         if GFC_POINTER_TYPE_P is set on the type.
1440
1441 2007-07-12  Richard Guenther  <rguenther@suse.de>
1442
1443         * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Convert
1444         arguments to gfc_charlen_type_node.
1445         * trans-io.c (gfc_convert_array_to_string): Convert type
1446         size to gfc_array_index_type.
1447
1448 2007-07-12  Daniel Franke  <franke.daniel@gmail.com>
1449
1450         PR fortran/32634
1451         PR fortran/32727
1452         * module.c: Reverted Paul's patch from 2007-07-10.
1453
1454 2007-07-11  Richard Guenther  <rguenther@suse.de>
1455
1456         * trans-array.c (gfc_conv_array_parameter): Use correct
1457         types for comparison.
1458         * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Use
1459         correct types for POINTER_PLUS_EXPR.
1460         * trans-stmt.c (gfc_trans_forall_loop): Use correct type
1461         for integer one constant.
1462
1463 2007-07-10  Paul Thomas  <pault@gcc.gnu.org>
1464
1465         PR fortran/32157
1466         * resolve.c (is_external_proc): New function.  Adds test that
1467         the symbol is not an intrinsic procedure.
1468         * (resolve_function, resolve_call): Replace logical statements
1469         with call to is_external_proc.
1470
1471         PR fortran/32689
1472         * simplify.c (gfc_simplify_transfer): If mold has rank, the
1473         result is an array.
1474
1475         PR fortran/32634
1476         * module.c (write_generic): Write the local name of the
1477         interface. 
1478
1479 2007-07-09  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1480
1481         PR fortran/29459
1482         * trans-array.c (gfc_trans_array_constructor): Mark offset field
1483         with TREE_NO_WARNING.
1484         * trans-decl.c (gfc_build_qualified_array): Mark lbound, ubound,
1485         stride and size variables with TREE_NO_WARNING.
1486
1487 2007-07-09  Steven G. Kargl  <kargl@gcc.gnu.org>
1488
1489         * trans-decl.c (set_tree_decl_type_code): Remove function.
1490         (generate_local_decl): Remove reference to set_tree_decl_type_code.
1491
1492 2007-07-09  Daniel Franke  <franke.daniel@gmail.com>
1493
1494         PR fortran/31129
1495         * trans-decl.c (generate_local_decl) Emit a warning if an unused
1496         parameter is found.
1497
1498 2007-07-08  Daniel Franke  <franke.daniel@gmail.com>
1499
1500         PR fortran/29876
1501         * module.c (gfc_match_use): Do not set an non-existant 
1502         intrinsic operator if a user-defined operator is found.
1503
1504 2007-07-08  Daniel Franke  <franke.daniel@gmail.com>
1505
1506         PR fortran/24784
1507         PR fortran/28004
1508         * trans-decl.c (generate_local_decl): Adjusted warning on unused 
1509         dummy arguments, tell middle-end not to emit additional warnings.
1510
1511 2007-07-08  Daniel Franke  <franke.daniel@gmail.com>
1512             Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
1513
1514         PR fortran/17711
1515         * gfortran.h (gfc_intrinsic_op): Added INTRINSIC_EQ_OS,
1516         INTRINSIC_NE_OS, INTRINSIC_GT_OS, INTRINSIC_GE_OS, 
1517         INTRINSIC_LT_OS and INTRINSIC_LE_OS.
1518         * arith.c (eval_intrinsic, eval_type_intrinsic0): Likewise.
1519         * arith.h (gfc_eq, gfc_ne, gfc_gt, gfc_ge, gfc_lt, gfc_le):
1520         Added gfc_intrinsic_op as third argument type.
1521         * dump-parse-tree.c (gfc_show_expr): Account for new enum values.
1522         * expr.c (simplify_intrinsic_op, check_intrinsic_op): Likewise.
1523         * interface.c (check_operator_interface): Likewise.
1524         (gfc_check_interfaces): Added cross-checks for FORTRAN 77 and 
1525         Fortran 90 style operators using new enum values.
1526         (gfc_extend_expr): Likewise.
1527         (gfc_add_interface): Likewise.
1528         * match.c (intrinsic_operators): Distinguish FORTRAN 77 style
1529         operators from Fortran 90 style operators using new enum values.
1530         * matchexp.c (match_level_4): Account for new enum values.
1531         * module.c (mio_expr): Likewise.
1532         * resolve.c (resolve_operator): Deal with new enum values, fix
1533         inconsistent error messages.
1534         * trans-expr.c (gfc_conv_expr_op): Account for new enum values.
1535
1536 2007-07-08  Tobias Burnus  <burnus@net-b.de>
1537
1538         PR fortran/32669
1539         * interface.c (get_expr_storage_size): Properly obtain lower bound.
1540         (compare_actual_formal): Add space before parenthesis.
1541
1542 2007-07-08  Daniel Franke  <franke.daniel@gmail.com>
1543
1544         PR fortran/25094
1545         * resolve.c (resolve_fl_procedure): Added check for PRIVATE types 
1546         in PUBLIC interfaces.
1547
1548 2007-07-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1549
1550         PR fortran/32644
1551         * decl.c (match_attr_spec): Don't return MATCH_ERROR if comma found and
1552         gfc_match_bind_c does not return MATCH_YES.
1553
1554 2007-07-07  Kazu Hirata  <kazu@codesourcery.com>
1555
1556         * decl.c, gfortran.h, interface.c, module.c, resolve.c,
1557         trans-array.c, trans-decl.c: Fix comment typos.  Follow
1558         spelling conventions.
1559         * intrinsic.texi: Fix typos.  Follow spelling conventions.
1560
1561 2007-05-06  Daniel Franke  <franke.daniel@gmail.com>
1562
1563         PR fortran/32633
1564         * symbol.c (save_status): New.
1565         * gfortran.h (save_status): Added external declaration.
1566         (check_conflict): Check for conflicting explicite SAVE statements
1567         only.
1568         (gen_special_c_interop_ptr): Use SAVE_EXPLICIT constant.
1569         * module.c (ab_attribute, attr_bits): Removed enumerator value 
1570         AB_SAVE for save attribute.
1571         (mio_symbol_attribute): Import/export the full SAVE status, 
1572         removed usage of AB_SAVE.
1573         * dump-parse-tree.c (gfc_show_attr): Dump full SAVE status.
1574         * decl.c (add_init_expr_to_sym): Set SAVE_IMPLICIT only if not
1575         already explicit.
1576
1577 2007-07-05  Daniel Franke  <franke.daniel@gmail.com>
1578             Tobias Burnus  <burnus@net-b.de>
1579
1580         PR fortran/32359
1581         * gfortran.h (symbol_attribute): Change save attribute into an enum.
1582         * decl.c (add_init_expr_to_sym): Set it to SAVE_IMPLICIT.
1583         * symbol.c (gfc_add_save): Check for SAVE_EXPLICIT.
1584         * resolve.c (resolve_fl_variable): Check for SAVE_EXPLICIT.
1585         (resolve_symbol): Allow OMP threadprivate with
1586         initialization SAVEd and save_all variable.
1587         * trans-decl.c (gfc_finish_var_decl): Remove obsolete sym->value check.
1588
1589 2007-07-05  Paul Thomas  <pault@gcc.gnu.org>
1590
1591         PR fortran/32526
1592         * match.c (gfc_match_call): Check, in all cases, that a symbol
1593         is neither generic nor a subroutine before trying to add it as
1594         a subroutine.
1595
1596         PR fortran/32613
1597         * match.c (gfc_match_do): Reset the implied_index attribute.
1598
1599 2007-07-04  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
1600
1601         PR fortran/31198
1602         * trans-intrinsic.c (trans-intrinsic.c): Handle optional
1603         arguments correctly for MIN and MAX intrinsics.
1604
1605 2007-07-03  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1606
1607         PR fortran/32545
1608         * io.c (check_format): Always call gfc_error for errors.
1609         (check_format_string): Change type of this function to try and
1610         return the result of check_format.
1611         (check_io_constraints): Return MATCH_ERROR if check_format_string
1612         returns FAILURE.
1613
1614 2007-07-03  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1615
1616         PR fortran/32612
1617         * decl.c (get_proc_name): Include attr->mod_proc in check for error.
1618
1619 2007-07-03  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1620
1621         PR fortran/32432
1622         * gfortran.h: Change type of gfc_assign_data_value from void to try.
1623         * data.c (gfc_assign_data_value): Return FAILURE if error found.
1624         * resolve.c (check_data_variable): If gfc_assign_data_value returns
1625         failure, break out of loop and return failure.
1626
1627 2007-07-03  Christopher D. Rickett  <crickett@lanl.gov>
1628
1629         PR fortran/32579
1630         * symbol.c (gen_cptr_param): Generate C_PTR and C_FUNPTR if necessary.
1631         (build_formal_args): Pass intrinsic module symbol id to
1632         gen_cptr_param.
1633
1634 2007-07-03  Tobias Burnus  <burnus@net-b.de>
1635
1636         PR fortran/25062
1637         * resolve.c (resolve_common_blocks): New check function.
1638         (resolve_types): Use it.
1639
1640 2007-07-03  Tobias Burnus  <burnus@net-b.de>
1641
1642         PR fortran/30940
1643         * interface.c (get_sym_storage_size): New function.
1644         (get_sym_storage_size): New function.
1645         (compare_actual_formal): Enhance sequence association
1646         support and improve checking.
1647
1648 2007-07-03  Janne Blomqvist  <jb@gcc.gnu.org>
1649
1650         * trans-decl.c (gfc_build_builtin_function_decls): Mark
1651         internal_realloc as a malloc function.
1652
1653 2007-07-03  Tobias Burnus  <burnus@net-b.de>
1654
1655         PR fortran/20888
1656         * resolve.c (resolve_operator): Check for NULL as operand.
1657
1658 2007-07-02  Tobias Burnus  <burnus@net-b.de>
1659
1660         * gfortran.texi (Fortran 2003): Add ISO Bind C.
1661         * intrinsic.texi (C_ASSOCIATED,C_F_POINTER,C_F_PROCPOINTER,
1662         C_FUNLOC,C_LOC): Document new ISO Bind C intrinsics.
1663
1664 2007-07-01  Christopher D. Rickett  <crickett@lanl.gov>
1665
1666         * interface.c (gfc_compare_derived_types): Special case for comparing
1667         derived types across namespaces.
1668         (gfc_compare_types): Deal with BT_VOID.
1669         (compare_parameter): Use BT_VOID to accept ISO C Binding pointers.
1670         * trans-expr.c (gfc_conv_function_call): Remove setting parm_kind
1671         to SCALAR
1672         (gfc_conv_initializer): Deal with ISO C Binding NULL_PTR and 
1673         NULL_FUNPTR.
1674         (gfc_conv_expr): Convert expressions for ISO C Binding derived types.
1675         * symbol.c (gfc_set_default_type): BIND(C) variables should not be
1676         Implicitly declared.
1677         (check_conflict): Add BIND(C) and check for conflicts.
1678         (gfc_add_explicit_interface): Whitespace.       
1679         (gfc_add_is_bind_c): New function.  
1680         (gfc_copy_attr): Use it.
1681         (gfc_new_symbol): Initialize ISO C Binding objects.
1682         (get_iso_c_binding_dt):  New function.
1683         (verify_bind_c_derived_type): Ditto.
1684         (gen_special_c_interop_ptr): Ditto.
1685         (add_formal_arg): Ditto.
1686         (gen_cptr_param): Ditto.
1687         (gen_fptr_param): Ditto.
1688         (gen_shape_param): Ditto.
1689         (add_proc_interface): Ditto.
1690         (build_formal_args): Ditto.
1691         (generate_isocbinding_symbol):  Ditto.
1692         (get_iso_c_sym):  Ditto.
1693         * decl.c (num_idents_on_line, has_name_equals): New variables.
1694         (verify_c_interop_param): New function.
1695         (build_sym): Finish binding labels and deal with COMMON blocks.
1696         (add_init_expr_to_sym): Check if the initialized expression is
1697         an iso_c_binding named constants
1698         (variable_decl): Set ISO C Binding type_spec components.
1699         (gfc_match_kind_spec): Check match for C interoperable kind.
1700         (match_char_spec): Fix comment. Chnage gfc_match_small_int
1701         to gfc_match_small_int_expr.  Check for C interoperable kind.
1702         (match_type_spec): Clear the current binding label.
1703         (match_attr_spec): Add DECL_IS_BIND_C.  If BIND(C) is found, use it
1704         to set attributes.
1705         (set_binding_label): New function.
1706         (set_com_block_bind_c): Ditto.
1707         (verify_c_interop): Ditto.
1708         (verify_com_block_vars_c_interop): Ditto.
1709         (verify_bind_c_sym): Ditto.
1710         (set_verify_bind_c_sym): Ditto.
1711         (set_verify_bind_c_com_block): Ditto.
1712         (get_bind_c_idents): Ditto.
1713         (gfc_match_bind_c_stmt): Ditto.
1714         (gfc_match_data_decl): Use num_idents_on_line.
1715         (match_result): Deal with right paren in BIND(C).
1716         (gfc_match_suffix): New function.
1717         (gfc_match_function_decl): Use it.  Code is re-arranged to deal with
1718         ISO C Binding result clauses.
1719         (gfc_match_subroutine):  Deal with BIND(C).
1720         (gfc_match_bind_c): New function.
1721         (gfc_get_type_attr_spec): New function.  Code is re-arranged in and
1722         taken from gfc_match_derived_decl.
1723         (gfc_match_derived_decl): Add check for BIND(C).
1724         * trans-common.c: Forward declare gfc_get_common.
1725         (gfc_sym_mangled_common_id): Change arg from 'const char *name' to
1726         'gfc_common_head *com'.  Check for ISO C Binding of the common block.
1727         (build_common_decl): 'com->name' to 'com in SET_DECL_ASSEMBLER_NAME.
1728         * gfortran.h: Add GFC_MAX_BINDING_LABEL_LEN
1729         (bt): Add BT_VOID
1730         (sym_flavor): Add FL_VOID.
1731         (iso_fortran_env_symbol, iso_c_binding_symbol, intmod_id): New enum
1732         (CInteropKind_t): New struct.
1733         (c_interop_kinds_table): Use it.  Declare an array of structs.
1734         (symbol_attribute): Add is_bind_c, is_c_interop, and is_iso_c
1735         bitfields.
1736         (gfc_typespec): Add is_c_interop; is_iso_c, and f90_type members.
1737         (gfc_symbol): Add from_intmod, intmod_sym_id, binding_label, and
1738         common_block members.
1739         (gfc_common_head): Add binding_label and is_bind_c members.
1740         (gfc_gsymbol): Add sym_name, mod_name, and binding_label members.
1741         Add prototypes for get_c_kind, gfc_validate_c_kind, 
1742         gfc_check_any_c_kind, gfc_add_is_bind_c, gfc_add_value,
1743         verify_c_interop, verify_c_interop_param, verify_bind_c_sym,
1744         verify_bind_c_derived_type, verify_com_block_vars_c_interop,
1745         generate_isocbinding_symbol, get_iso_c_sym, gfc_iso_c_sub_interface
1746         * iso-c-binding.def: New file. This file contains the definitions
1747         of the types provided by the Fortran 2003 ISO_C_BINDING intrinsic
1748         module.
1749         * trans-const.c (gfc_conv_constant_to_tree): Deal with C_NULL_PTR
1750          or C_NULL_FUNPTR expressions.
1751         * expr.c (gfc_copy_expr): Add BT_VOID case.  For BT_CHARACTER, the
1752         ISO C Binding requires a minimum string length of 1 for '\0'.  
1753         * module.c (intmod_sym): New struct.
1754         (pointer_info): Add binding_label member.
1755         (write_atom): Set len to 0 for NULL pointers. Check for NULL p and *p.
1756         (ab_attribute): Add AB_IS_BIND_C, AB_IS_C_INTEROP and AB_IS_ISO_C.
1757         (attr_bits): Add "IS_BIND_C", "IS_C_INTEROP", and "IS_ISO_C".
1758         (mio_symbol_attribute): Deal with ISO C Binding attributes.
1759         (bt_types): Add "VOID".
1760         (mio_typespec): Deal with ISO C Binding components.
1761         (mio_namespace_ref): Add intmod variable. 
1762         (mio_symbol): Check for symbols from an intrinsic module.
1763         (load_commons): Check for BIND(C) common block.
1764         (read_module): Read binding_label and use it.
1765         (write_common): Add label.  Write BIND(C) info.
1766         (write_blank_common): Blank commons are not BIND(C).  Explicitly
1767         set is_bind_c=0.
1768         (write_symbol): Deal with binding_label.
1769         (sort_iso_c_rename_list): New function.
1770         (import_iso_c_binding_module): Ditto.
1771         (create_int_parameter): Add to args.
1772         (use_iso_fortran_env_module): Adjust to deal with iso_c_binding
1773         intrinsic module.
1774         * trans-types.c (c_interop_kinds_table): new array of structs. 
1775         (gfc_validate_c_kind): New function.
1776         (gfc_check_any_c_kind): Ditto.
1777         (get_real_kind_from_node): Ditto.
1778         (get_int_kind_from_node): Ditto.
1779         (get_int_kind_from_width): Ditto.
1780         (get_int_kind_from_minimal_width): Ditto.
1781         (init_c_interop_kinds): Ditto.
1782         (gfc_init_kinds): call init_c_interop_kinds.
1783         (gfc_typenode_for_spec): Adjust for BT_VOID and ISO C Binding pointers.
1784         Adjust handling of BT_DERIVED.
1785         (gfc_sym_type): Whitespace.
1786         (gfc_get_derived_type):  Account for iso_c_binding derived types
1787         * resolve.c (is_scalar_expr_ptr): New function.
1788         (gfc_iso_c_func_interface): Ditto.
1789         (resolve_function): Use gfc_iso_c_func_interface. 
1790         (set_name_and_label): New function.
1791         (gfc_iso_c_sub_interface): Ditto.
1792         (resolve_specific_s0): Use gfc_iso_c_sub_interface.
1793         (resolve_bind_c_comms): New function.
1794         (resolve_bind_c_derived_types): Ditto.
1795         (gfc_verify_binding_labels): Ditto.
1796         (resolve_fl_procedure): Check for ISO C interoperability.
1797         (resolve_symbol): Check C interoperability.
1798         (resolve_types): Walk the namespace.  Check COMMON blocks.
1799         * trans-decl.c (gfc_sym_mangled_identifier):  Prevent the mangling
1800         of identifiers that have an assigned binding label.
1801         (gfc_sym_mangled_function_id): Use the binding label rather than
1802         the mangled name.
1803         (gfc_finish_var_decl): Put variables that are BIND(C) into a common
1804         segment of the object file, because this is what C would do.
1805         (gfc_create_module_variable): Conver to proper types
1806         (set_tree_decl_type_code): New function.
1807         (generate_local_decl): Check dummy variables and derived types for
1808         ISO C Binding attributes.
1809         * match.c (gfc_match_small_int_expr): New function.
1810         (gfc_match_name_C): Ditto.
1811         (match_common_name): Deal with ISO C Binding in COMMON blocks
1812         * trans-io.c (transfer_expr):  Deal with C_NULL_PTR or C_NULL_FUNPTR
1813         expressions
1814         * match.h: Add prototypes for gfc_match_small_int_expr,
1815         gfc_match_name_C, match_common_name, set_com_block_bind_c,
1816         set_binding_label, set_verify_bind_c_sym,
1817         set_verify_bind_c_com_block, get_bind_c_idents,
1818         gfc_match_bind_c_stmt, gfc_match_suffix, gfc_match_bind_c,
1819         gfc_get_type_attr_spec
1820         * parse.c (decode_statement): Use gfc_match_bind_c_stmt
1821         (parse_derived): Init *derived_sym = NULL, and gfc_current_block
1822         later for valiadation.
1823         * primary.c (got_delim): Set ISO C Binding components of ts.
1824         (match_logical_constant): Ditto.
1825         (match_complex_constant): Ditto.
1826         (match_complex_constant): Ditto.
1827         (gfc_match_rvalue): Check for existence of at least one arg for
1828         C_LOC, C_FUNLOC, and C_ASSOCIATED.
1829         * misc.c (gfc_clear_ts): Clear ISO C Bindoing components in ts.
1830         (get_c_kind): New function.
1831
1832 2007-07-01  Janne Blomqvist  <jb@gcc.gnu.org>
1833
1834         PR fortran/32239
1835         * trans-expr.c (gfc_conv_power_op): Use builtin_powi for
1836         real**int4 powers.
1837         * f95-lang.c (gfc_init_builtin_functions): Add builtin_powi to the
1838         builtins table.
1839
1840 2007-07-01  Janne Blomqvist  <jb@gcc.gnu.org>
1841
1842         * trans.h: Remove decls for 64-bit allocation functions.
1843         * trans-array.c (gfc_grow_array): Always pick the standard realloc
1844         function decl.
1845         (gfc_array_allocate): Likewise.
1846         * trans-decl.c: Remove trees for 64-bit allocation functions.
1847         (gfc_build_builtin_function_decls): Don't build fndecls for 64-bit
1848         allocations functions, use index_int_type for normal allocation
1849         functions.
1850
1851 2007-06-30  Daniel Franke  <franke.daniel@gmail.com>
1852
1853         PR fortran/20373
1854         * intrinsic.c (add_functions): Additional function types.
1855         (gfc_convert_type_warn): Remove intrinsic-flag from
1856         conversion functions.
1857         * resolve.c (resolve_symbol): Added type checks to 
1858         explicitly defined intrinsics.
1859
1860 2007-06-30  Tobias Burnus  <burnus@net-b.de>
1861
1862         PR fortran/32555
1863         * io.c (check_format): Allow zero to precede the
1864         P edit descriptor.
1865
1866 2007-06-30  Paul Thomas  <pault@gcc.gnu.org>
1867
1868         PR fortran/32472
1869         * simplify.c (gfc_simplify_repeat): Add handling of character
1870         literal for first argument.
1871
1872 2007-06-29  Daniel Franke  <franke.daniel@gmail.com>
1873
1874         * resolve.c (resolve_operator): Added check whether a user
1875         defined operator is available.
1876
1877 2007-06-29  Daniel Franke <franke.daniel@gmail.com>
1878
1879         * openmp.c (resolve_omp_clauses): Adjust error message to
1880         better reflect the actual requirement.
1881
1882 2007-06-29  Tobias Burnus  <burnus@net-b.de>
1883
1884         PR fortran/32483
1885         * io.c (format_lex): Fix FMT_ZERO.
1886         (check_format,check_format_string,gfc_match_format,
1887         check_io_constraints) Additional checking for READ.
1888
1889 2007-06-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1890
1891         PR other/31400
1892         * lang.opt (static-libgfortran): New option.
1893         * gfortranspec.c (ADD_ARG_LIBGFORTRAN): New macro.
1894         (Option): Add OPTION_static and OPTION_static_libgfortran.
1895         (lookup_option): Handle the new -static-libgfortran option.
1896         (lang_specific_driver): Check whether -static is passed.
1897         Handle the new -static-libgfortran option.
1898         * options.c (gfc_handle_option): If -static-libgfortran is
1899         passed and isn't supported on this configuration, error out.
1900
1901 2007-06-27  Daniel Franke  <franke.daniel@gmail.com>
1902
1903         PR fortran/32467
1904         * openmp.c (resolve_omp_clauses): Emit error on allocatable
1905         components in COPYIN, COPYPRIVATE, FIRSTPRIVATE and LASTPRIVATE
1906         clauses.
1907
1908 2007-06-25  Paul Thomas  <pault@gcc.gnu.org>
1909
1910         PR fortran/32464
1911         * resolve.c (check_host_association): Return if the old symbol
1912         is use associated.  Introduce retval to reduce the number of
1913         evaluations of the first-order return value.
1914
1915         PR fortran/31494
1916         * match.c (gfc_match_call): If a host associated symbol is not
1917         a subroutine, build a new symtree/symbol in the current name
1918         space.
1919
1920 2007-06-24  Tobias Burnus  <burnus@net-de>
1921
1922         PR fortran/32460
1923         * interface.c (gfc_compare_derived_types): Add access check.
1924         * symbol.c (gfc_find_component): Ditto.
1925         (gfc_set_component_attr,gfc_get_component_attr) Copy access state.
1926         * dump-parse-tree.c (gfc_show_components): Dump access state.
1927         * gfortran.h (struct gfc_component): Add gfc_access.
1928         * module.c (mio_component): Add access state.
1929         * (gfc_match_structure_constructor): Check for private access state.
1930
1931 2007-06-24  Paul Thomas  <pault@gcc.gnu.org>
1932
1933         PR fortran/32298
1934         PR fortran/31726
1935         * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc): Calculate
1936         the offset between the loop counter and the position as
1937         defined. Add the offset within the loop so that the mask acts
1938         correctly.  Do not advance the location on the basis that it
1939         is zero.
1940
1941 2007-06-22  Daniel Franke  <franke.daniel@gmail.com>
1942
1943         PR fortran/31473
1944         * symbol.c (gfc_copy_attr): Emit errors for duplicate 
1945         EXTERNAL/INTRINSIC statements.
1946
1947 2007-06-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1948
1949         PR fortran/32360
1950         * expr.c (gfc_check_assign): If the rvalue expression type is NULL_EXPR,
1951         check to see if the lvalue has attribute pointer and data.  
1952
1953 2007-06-21  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1954
1955         PR fortran/31162
1956         * resolve.c (gfc_resolve_iterator_expr): Add check for REAL using
1957         gfc_notify_standard. (gfc_resolve_iterator): Remove check.
1958         (resolve_branch): Change "Obsolete" to "Deleted feature".
1959         * io.c (resolve_tag): Ditto.
1960         * match.c (gfc_match_pause, gfc_match_assign, gfc_match_goto): Ditto.
1961
1962 2007-06-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1963
1964         PR fortran/32361
1965         * match.c (gfc_match_common): If the symbol value expression type is
1966         NULL_EXPR, don't error if previously initialized.
1967
1968 2007-06-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1969
1970         PR fortran/25061
1971         * decl.c (get_proc_name) Check symbol for generic interface
1972         and issue an error.
1973
1974 2007-06-20  Andrew Pinski  <andrew_pinski@playstation.sony.com>
1975         Richard Guenther  <rguenther@suse.de>
1976
1977         PR fortran/32140
1978         * trans.c (gfc_build_addr_expr): Use the correct types.
1979
1980 2007-06-19  Paul Thomas  <pault@gcc.gnu.org>
1981
1982         PR fortran/20863
1983         PR fortran/20882
1984         * resolve.c (resolve_code): Use gfc_impure_variable as a
1985         condition for rejecting derived types with pointers, in pure
1986         procedures.
1987         (gfc_impure_variable): Add test for dummy arguments of pure
1988         procedures; any for functions and INTENT_IN for subroutines.
1989
1990         PR fortran/32236
1991         * data.c (gfc_assign_data_value): Change the ICE on an array
1992         reference initializer not being an array into an error and
1993         clear init to prevent a repetition of the error.
1994
1995 2007-06-17  Janne Blomqvist  <jb@gcc.gnu.org>
1996
1997         * gfortran.texi: Add documentation for GFORTRAN_UNBUFFERED_n
1998         environment variables. Fix documentation for
1999         GFORTRAN_UNBUFFERED_ALL environment variable.
2000
2001 2007-06-15  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2002
2003         * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Use
2004         POINTER_PLUS_EXPR instead of PLUS_EXPR for pointer addition.
2005         * trans-expr.c (gfc_trans_string_copy): Create
2006         POINTER_PLUS_EXPR instead of a PLUS_EXPR
2007         for pointer types.
2008
2009 2007-06-14  Paul Thomas  <pault@gcc.gnu.org>
2010
2011         PR fortran/32302
2012         * trans-common.c (build_common_decl): If resizing of common
2013         decl is needed, update the TREE_TYPE.
2014
2015 2007-06-13  Tobias Burnus  <burnus@net-b.de>
2016
2017         PR fortran/32323
2018         * interface.c (has_vector_section): New.
2019         (compare_actual_formal): Check for array sections with vector subscript.
2020
2021 2007-06-12  Dirk Mueller  <dmueller@suse.de>
2022
2023         * trans-stmt.c (gfc_trans_call): fix gcc_assert to
2024         a comparison, not an assignment.
2025
2026 2007-06-12  Paul Thomas  <pault@gcc.gnu.org>
2027
2028         * trans-common.c (create_common): Initialize 'field_init'.
2029
2030 2007-06-12  Paul Thomas  <pault@gcc.gnu.org>
2031
2032         PR fortran/29786
2033         PR fortran/30875
2034         * trans-common.c (get_init_field): New function.
2035         (create_common): Call get_init_field for overlapping
2036         initializers in equivalence blocks.
2037         * resolve.c (resolve_equivalence_derived, resolve_equivalence):
2038         Remove constraints on initializers in equivalence blocks.
2039         * target-memory.c (expr_to_char, gfc_merge_initializers):
2040         New functions.
2041         (encode_derived): Add the bit offset to the byte offset to get
2042         the total offset to the field.
2043         * target-memory.h : Add prototype for gfc_merge_initializers.
2044
2045 2007-06-11  Rafael Avila de Espindola  <espindola@google.com>
2046
2047         * trans-types.c (gfc_signed_type): Remove.
2048         * trans-types.h (gfc_signed_type): Remove.
2049         * f95-lang.c (LANG_HOOKS_SIGNED_TYPE): Remove.
2050
2051 2007-06-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2052
2053         * trans-intrinsic.c: Revert Lee's 2007-06-04 patch.
2054
2055 2007-06-07  Steven G. Kargl  <kargl@gcc.gnu.org>
2056             Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2057
2058         PR fortran/32223
2059         * match.c (gfc_match_special_char): New function.  Match special char.
2060         Add handling '\0'.
2061         * match.h: Add prototype.
2062         * io.c (next_char): Use it.
2063         * primary.c (next_string_char): Ditto.
2064
2065 2007-06-06  Steven G. Kargl  <kargl@gcc.gnu.org>
2066
2067         * decl.c: Miscellaneous whitespace fixes.
2068         * expr.c: Likewise.
2069         * gfortran.h: Likewise.
2070         * interface.c : Likewise.
2071         * io.c: Likewise.
2072         * match.c: Likewise.
2073         * match.h: Likewise.
2074         * module.c: Likewise.
2075         * parse.c: Likewise.
2076         * resolve.c: Likewise.
2077         * symbol.c: Likewise.
2078         * trans-array.c: Likewise.
2079         * trans-common.c: Likewise.
2080         * trans-decl.c: Likewise.
2081         * trans-intrinsic.c: Likewise.
2082         * trans-io.c: Likewise.
2083         * trans-stmt.c: Likewise.
2084         * trans-types.c: Likewise.
2085
2086 2007-06-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2087
2088         PR fortran/18923
2089         * parse.c (decode_statement): Don't call gfc_undo_symbols on MATCH_ERROR
2090         for ST_FUNCTION since it is called in reject_statement.
2091         (parse_contained): If error, loop back after reject_statement and try
2092         again.  Free the namespace if an error occured.
2093
2094 2007-06-04 Lee Millward <lee.millward@codesourcery.com>
2095
2096         * trans-intrinsic.c (gfc_conv_intrinsic_function_args): Adjust
2097         to operate on a stack allocated array for the intrinsic arguments
2098         instead of creating a TREE_LIST. Add two new parameters for the
2099         array and the number of elements. Update all callers to allocate
2100         an array of the correct length to pass in. Update comment.
2101         (gfc_intrinsic_argument_list_length): New function.
2102         (gfc_conv_intrinsic_mnimax): Call it.
2103         (gfc_conv_intrinsic_merge): Likewise.
2104         (gfc_conv_intrinsic_lib_function): Call it. Use new CALL_EXPR
2105         constructors.
2106         (gfc_conv_intrinsic_cmplx): Likewise.
2107         (gfc_conv_intrinsic_ctime): Likewise.
2108         (gfc_covn_intrinsic_fdate): Likewise.
2109         (gfc_conv_intrinsic_ttynam): Likewise.
2110         (gfc_conv_intrinsic_ishftc): Likewise.
2111         (gfc_conv_intrinsic_index): Likewise.
2112         (gfc_conv_intrinsic_scan): Likewise.
2113         (gfc_conv_intrinsic_verify): Likewise.
2114         (gfc_conv_intrinsic_trim): Likewise.
2115         (gfc_conv_intrinsic_aint): Use new CALL_EXPR constructors.
2116         (gfc_conv_intrinsic_exponent): Likewise.
2117         (gfc_conv_intrinsic_bound): Likewise.
2118         (gfc_conv_intrinsic_abs): Likewise.
2119         (gfc_conv_intrinsic_mod): Likewise.
2120         (gfc_conv_intrinsic_sign): Likewise.
2121         (gfc_conv_intrinsic_len): Likewise.
2122         (gfc_conv_intrinsic_adjust): Likewise.
2123         (gfc_conv_intrinsic_si_kind): Likewise.
2124
2125 2007-06-04  Steve Ellcey  <sje@cup.hp.com>
2126
2127         * trans-array.c (gfc_conv_array_parameter): Initialize tmp.
2128
2129 2007-05-31  Richard Guenther  <rguenther@suse.de>
2130
2131         * trans-expr.c (gfc_conv_expr_op): Use zero constant
2132         that matches the lse type.
2133         (gfc_trans_string_copy): Use sizetype zero constant.
2134         * intrinsic.c (add_functions): The sizeof intrinsic has
2135         index type result.
2136         * trans-types.c (gfc_get_dtype): Convert size to index
2137         type before shifting.
2138         * trans-array.c (gfc_trans_array_constructor_value): Use
2139         index type for offset computation.
2140         * trans-intrinsic.c (gfc_conv_associated): Use correct type
2141         for zero constant.
2142
2143 2007-05-31  Paul Thomas  <pault@gcc.gnu.org>
2144
2145         PR fortran/32156
2146         * trans-array.c (gfc_trans_array_constructor): Treat the case
2147         where the ss expression charlen is missing.
2148
2149 22007-05-31  Paul Thomas  <pault@gcc.gnu.org>
2150
2151         PR fortran/32103
2152         * module.c (mio_symtree_ref): If an equivalence group member
2153         is not used, give it a hidden symbol and set the pointer_info.
2154         (load_equiv): Only free the equivalence if none of the members
2155         are used.
2156
2157 2007-05-29  Daniel Franke  <franke.daniel@gmail.com>
2158
2159         * gfortran.h: Renamed 'enum gfc_generic_isym_id' to 'enum gfc_isym_id',
2160         added missing GFC_ISYM_* enumerators, ordered alphabetically.
2161         (struct gfc_intrinsic_sym): Renamed 'generic_id' to 'id'.
2162         (gfc_find_subroutine): New prototype.
2163         * intrinsic.c (add_sym, add_sym_*): Added argument 'id' and changed all callers.
2164         (find_subroutine): Renamed to 'gfc_find_subroutine', removed static.  
2165         * dependency.c: Changed usage of isym->generic_id to isym->id.  
2166         * openmp.c: Likewise.  
2167         * resolve.c: Likewise.  
2168         * trans-array.c: Likewise.  
2169         * trans-expr.c: Likewise.  
2170         * trans-intrinsic.c: Likewise.  
2171         * trans-openmp.c: Likewise.
2172
2173 2007-05-28  Tobias Schlüter  <tobi@gcc.gnu.org>
2174
2175         * gfortran.h (gfc_generic_isym_id): Add GFC_ISYM_SIZEOF.
2176         * intrinsic.c (add_functions): Add stuff for SIZEOF intrinsic.
2177         * intrinsic.h (gfc_check_sizeof): Add prototype of ...
2178         * check.c (gfc_check_sizeof): .. new function.
2179         * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): New function.
2180         (gfc_conv_intrinsic_strcmp): Whitespace fix.
2181         (gfc_conv_intrinsic_array_transfer): Remove double initialization,
2182         use fold_build. where appropriate.
2183         (gfc_conv_intrinsic_function): Add case for SIZEOF.
2184         * intrinsic.texi: Add documentation for SIZEOF.
2185
2186 2007-05-28  Brooks Moses  <brooks.moses@codesourcery.com>
2187
2188         * trans-array.c (gfc_conv_expr_descriptor): Edit comment.
2189
2190 2007-05-28  Brooks Moses  <brooks.moses@codesourcery.com>
2191
2192         PR fortran/31972
2193         * target-memory.c (gfc_target_expr_size): Add handling
2194         for size of BT_HOLLERITH variables.
2195         * check.c (gfc_check_transfer): Reject BT_HOLLERITH
2196         variables in MOLD argument of TRANSFER.
2197
2198 2007-05-28  Brooks Moses  <brooks.moses@codesourcery.com>
2199
2200         * gfortran.h (gfc_expr): Remove from_H, add "representation"
2201         struct.
2202         * primary.c (match_hollerith_constant): Store the representation
2203         of the Hollerith in representation, not in value.character.
2204         * arith.c: Add dependency on target-memory.h.
2205         (eval_intrinsic): Remove check for from_H.
2206         (hollerith2representation): New function.
2207         (gfc_hollerith2int): Determine value of the new constant.
2208         (gfc_hollerith2real): Likewise.
2209         (gfc_hollerith2complex): Likewise.
2210         (gfc_hollerith2logical): Likewise.
2211         (gfc_hollerith2character): Point both representation.string and
2212         value.character.string at the value string.
2213         * data.c (create_character_initializer): For BT_HOLLERITH
2214         rvalues, get the value from the representation rather than
2215         value.character.
2216         * expr.c (free_expr0): Update handling of BT_HOLLERITH values
2217         and values with representation.string.
2218         (gfc_copy_expr): Likewise.
2219         * intrinsic.c (do_simplify): Remove special treatement of
2220         variables resulting from Hollerith constants.
2221         * dump-parse-trees.c (gfc_show_expr): Update handling of
2222         Holleriths.
2223         * trans-const.c (gfc_conv_constant_to_tree): Replace from_H
2224         check with check for representation.string; get Hollerith
2225         representation from representation.string, not value.character.
2226         * trans-expr.c (is_zero_initializer_p): Replace from_H check
2227         with check for representation.string.
2228         * trans-stmt.c (gfc_trans_integer_select): Use
2229         gfc_conv_mpz_to_tree for case values, so as to avoid picking up
2230         the memory representation if the case is given by a transfer
2231         expression.
2232         * target-memory.c (gfc_target_encode_expr): Use the known memory
2233         representation rather than the value, if it exists.
2234         (gfc_target_interpret_expr): Store the memory representation of
2235         the interpreted expression as well as its value.
2236         (interpret_integer): Move to gfc_interpret_integer, make
2237         non-static.
2238         (interpret_float): Move to gfc_interpret_float, make non-static.
2239         (interpret_complex): Move to gfc_interpret_complex, make
2240         non-static.
2241         (interpret_logical): Move to gfc_interpret_logical, make
2242         non-static.
2243         (interpret_character): Move to gfc_interpret_character, make
2244         non-static.
2245         (interpret_derived): Move to gfc_interpret_derived, make
2246         non-static.
2247         * target-memory.h: Add prototypes for newly-exported
2248         gfc_interpret_* functions.
2249
2250 2007-05-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2251
2252         PR fortran/31812
2253         * parse.c (next_statement): Warn for truncated lines if source is free
2254         form.
2255
2256 2007-05-27 Paul Thomas  <pault@gcc.gnu.org>
2257            Tobias Burnus  <burnus@net-b.de>
2258
2259         PR fortran/32088
2260         * symbol.c (gfc_check_function_type): Copy dimensions of
2261           result variable.
2262         * resolve.c (resolve_contained_fntype): Improve symbol output in
2263           the error message.
2264
2265 2007-05-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2266
2267         PR fortran/31813
2268         * io.c (check_format): Add warning for H specifier in format.
2269         
2270 2007-05-26  Tobias Burnus  <burnus@net-b.de>
2271
2272         * gfortran.texi: Document the GFORTRAN_ERROR_DUMPCORE and
2273         GFORTRAN_ERROR_BACKTRACE environment variables.
2274
2275 2007-05-26  Paul Thomas  <pault@gcc.gnu.org>
2276
2277         PR fortran/31219
2278         * trans.h : Add no_function_call bitfield to gfc_se structure.
2279         Add stmtblock_t argument to prototype of get_array_ctor_strlen.
2280         * trans-array.c (get_array_ctor_all_strlen): New function.
2281         (get_array_ctor_strlen): Add new stmtblock_t argument and call
2282         new function for character elements that are not constants,
2283         arrays or variables.
2284         (gfc_conv_array_parameter): Call get_array_ctor_strlen to get
2285         good string length.
2286         * trans-intrinsic (gfc_conv_intrinsic_len): Add new argument
2287         to call of get_array_ctor_strlen.
2288
2289 2007-05-25  Kazu Hirata  <kazu@codesourcery.com>
2290
2291         * intrinsic.texi: Fix typos.
2292
2293 2007-05-25  Paul Thomas  <pault@gcc.gnu.org>
2294
2295         PR fortran/32047
2296         * trans-expr.c (gfc_apply_interface_mapping_to_expr): Change
2297         order in logic under EXPR_FUNCTION to handle functions with
2298         no arguments.
2299
2300 2007-05-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2301
2302         PR fortran/31716
2303         * array.c (spec_dimen_size): Test for correct BT_INTEGER type. 
2304
2305 2007-05-23  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2306
2307         PR fortran/32046
2308         * trans-expr.c (gfc_trans_zero_assign): Convert the result of
2309         TYPE_SIZE_UNIT into a signed type.
2310         (gfc_trans_array_copy):  Likewise.
2311         (gfc_trans_array_constructor_copy): Likewise.
2312         * trans-array.c (gfc_trans_create_temp_array): Likewise.
2313         (gfc_grow_array): Likewise.
2314         (gfc_array_init_size): Likewise.
2315         (gfc_duplicate_allocatable): Likewise.
2316         * trans-stmt.c (allocate_temp_for_forall_nest_1): Likewise.
2317
2318 2007-05-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2319
2320         PR fortran/18923
2321         * resolve.c (resolve_function): Don't call resolve_global_procedure if
2322         there is no name. Delete duplicated statement in ELSE clause.
2323
2324 2007-05-22 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2325
2326         PR fortran/31627
2327         * trans-array.c (gfc_trans_array_bound_check): Take extra argument to
2328         indicate whether we should check the upper bound in that dimension.
2329         (gfc_conv_array_index_offset): Check only the lower bound of the
2330         last dimension for assumed-size arrays.
2331         (gfc_conv_array_ref): Likewise.
2332         (gfc_conv_ss_startstride): Likewise.
2333
2334 2007-05-21  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2335             Daniel Franke  <franke.daniel@gmail.com>
2336
2337         PR fortran/32002
2338         * resolve.c (resolve_actual_arglist): Resolve actual argument after
2339         being identified as variable.
2340
2341 2007-05-21  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2342
2343         PR fortran/32027
2344         * trans-stmt.c (gfc_trans_do): Fix the value of loop variable
2345         when the loop ends.
2346
2347 2007-05-21  H.J. Lu  <hongjiu.lu@intel.com>
2348
2349         * trans-stmt.c (gfc_trans_do): Fix a typo in comment.
2350
2351 2007-05-21  Paul Thomas  <pault@gcc.gnu.org>
2352
2353         PR fortran/31867
2354         PR fortran/31994
2355         * trans-array.c (gfc_conv_expr_descriptor): Obtain the stored
2356         offset for non-descriptor, source arrays and correct for stride
2357         not equal to one before writing to field of output descriptor.
2358
2359 2007-05-20  Daniel Franke  <franke.daniel@gmail.com>
2360
2361         PR fortran/32001
2362         * check.c (check_rest): Improved argument conformance check and 
2363         fixed error message generation.
2364
2365 2007-05-19  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2366
2367         PR fortran/30820
2368         * Make-lang.in: Remove use of -Wno-error for expr.o, resolve.o,
2369         simplify.o and trans-common.o.
2370
2371 2007-05-19  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2372
2373         PR fortran/31974
2374         * trans-array.c (gfc_trans_auto_array_allocation): Avoid
2375         multiplication of mismatched types.
2376
2377 2007-05-18  Daniel Franke  <franke.daniel@gmail.com>
2378
2379         PR fortran/24633
2380         * symbol.c (gfc_add_flavor): Add the NAME to error message if
2381         available.
2382
2383 2007-05-15  Daniel Franke  <franke.daniel@gmail.com>
2384
2385         PR fortran/31919
2386         PR fortran/31929
2387         PR fortran/31930
2388         * intrinsic.c (check_specific): Check elemental intrinsics for
2389         rank and shape.
2390         (add_functions): Fixed dummy argument names of BESJN and BESYN.
2391         Fixed elemental status of MCLOCK and MCLOCK8.
2392         * check.c (check_rest): Added check for array conformance.
2393         (gfc_check_merge): Removed check for array conformance.
2394         (gfc_check_besn): Removed check for scalarity.
2395         * intrinsic.texi (CSHIFT, EOSHIFT): Fixed typos.
2396         (BESJN, BESYN): Clarified documentation.
2397
2398 2007-05-17  Tobias Burnus  <burnus@net-b.de>
2399
2400         * gfortran.texi (GFORTRAN_CONVERT_UNIT): Improve documentation.
2401
2402 2007-05-16  Brooks Moses  <brooks.moses@codesourcery.com>
2403
2404         PR fortran/18769
2405         PR fortran/30881
2406         PR fortran/31194
2407         PR fortran/31216
2408         PR fortran/31427
2409         * target-memory.c: New file.
2410         * target-memory.h: New file.
2411         * simplify.c: Add #include "target-memory.h".
2412         (gfc_simplify_transfer): Implement constant-
2413         folding for TRANSFER intrinsic.
2414         * Make-lang.in: Add dependencies on new target-memory.* files.
2415
2416 2007-05-15  Paul Brook  <paul@codesourcery.com>
2417
2418         * trans-types.c (gfc_type_for_size): Handle signed TImode.
2419
2420 2007-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2421
2422         PR fortran/30723
2423         * trans.h (gfor_fndecl_internal_malloc, gfor_fndecl_internal_malloc64,
2424         gfor_fndecl_internal_free): Remove prototypes.
2425         (gfor_fndecl_os_error, gfc_call_free, gfc_call_malloc): Add prototypes.
2426         * trans.c (gfc_call_malloc, gfc_call_free): New functions.
2427         * f95-lang.c (gfc_init_builtin_functions): Add __builtin_free
2428         and __builtin_malloc builtins.
2429         * trans-decl.c (gfor_fndecl_internal_malloc,
2430         gfor_fndecl_internal_malloc64, gfor_fndecl_internal_free): Remove.
2431         (gfor_fndecl_os_error): Add.
2432         (gfc_build_builtin_function_decls): Don't create internal_malloc,
2433         internal_malloc64 and internal_free library function declaration.
2434         Create os_error library call function declaration.
2435         * trans-array.c (gfc_trans_allocate_array_storage,
2436         gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias,
2437         gfc_conv_array_parameter, gfc_duplicate_allocatable): Use
2438         gfc_call_malloc and gfc_call_free instead of building calls to
2439         internal_malloc and internal_free.
2440         * trans-expr.c (gfc_conv_string_tmp): Likewise.
2441         * trans-stmt.c (gfc_do_allocate, gfc_trans_assign_need_temp,
2442         gfc_trans_pointer_assign_need_temp, gfc_trans_forall_1,
2443         gfc_trans_where_2: Likewise.
2444         * trans-intrinsic.c (gfc_conv_intrinsic_ctime,
2445         gfc_conv_intrinsic_fdate, gfc_conv_intrinsic_ttynam,
2446         gfc_conv_intrinsic_array_transfer, gfc_conv_intrinsic_trim): Likewise.
2447
2448 2007-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2449
2450         PR fortran/31725
2451         * trans-expr.c (gfc_conv_substring): Evaluate substring bounds
2452         only once.
2453
2454 2007-05-14  Rafael Avila de Espindola  <espindola@google.com>
2455
2456         * f95-lang.c (LANG_HOOKS_UNSIGNED_TYPE): Remove.
2457         * trans-intrinsic.c (gfc_conv_intrinsic_ishft): Use unsigned_type_for
2458         instead of gfc_unsigned_type.
2459         * trans-stmt.c (gfc_trans_do): Use unsigned_type_for instead of
2460         gfc_unsigned_type.
2461         * trans-types.c (gfc_unsigned_type): Remove.
2462         * trans-types.h (gfc_unsigned_type): Remove.
2463
2464 2007-05-12  Paul Thomas  <pault@gcc.gnu.org>
2465
2466         PR fortran/30746
2467         * resolve.c (check_host_association): New function that detects
2468         incorrect host association and corrects it.
2469         (gfc_resolve_expr): Call the new function for variables and
2470         functions.
2471         * match.h : Remove prototype for gfc_match_rvalue.
2472         * gfortran.h : Add prototype for gfc_match_rvalue.
2473
2474 2007-05-11 Paul Thomas <pault@gcc.gnu.org>
2475
2476         PR fortran/30876
2477         * trans-expr.c (gfc_conv_function_call): Reduce indirection for
2478         direct assignments of recursive array valued functions.
2479         * primary.c (gfc_match_rvalue): Correct error for recursive
2480         function calls such that directly recursive calls of scalar
2481         function without an explicit result are disallowed.
2482
2483 2007-05-11 Paul Thomas <pault@gcc.gnu.org>
2484
2485         PR fortran/30878
2486         * resolve.c (resolve_fl_namelist): It is not an error if the
2487         namelist element is the result variable of the enclosing
2488         function.  Search for the symbol in current and all parent
2489         namespaces for a potential conflict.
2490         * symbol.c (check_conflict): Remove the conflict between
2491         'in_namelist' and 'FL_PROCEDURE' because the symbol info
2492         is not available to exclude function result variables.
2493         * trans-io.c (nml_get_addr_expr): Use the fake result decl
2494         if the symbol is an implicit result variable.
2495
2496 2007-05-11  Paul Thomas  <pault@gcc.gnu.org>
2497
2498         PR fortran/31474
2499         * decl.c (get_proc_name): If an entry has already been declared
2500         as a module procedure, pick up the symbol and the symtree and
2501         use them for the entry.
2502
2503 2007-05-08  Paul Thomas  <pault@gcc.gnu.org>
2504
2505         PR fortran/31630
2506         * resolve.c (resolve_symbol): Remove the flagging mechanism from the
2507         formal namespace resolution and instead check that the formal
2508         namespace is not the current namespace.
2509
2510 2007-05-08  Paul Thomas  <pault@gcc.gnu.org>
2511
2512         PR fortran/31692
2513         * trans-array.c (gfc_conv_array_parameter): Convert full array
2514         references to the result of the procedure enclusing the call.
2515
2516 2007-05-08  Paul Thomas  <pault@gcc.gnu.org>
2517
2518         PR fortran/29397
2519         PR fortran/29400
2520         * decl.c (add_init_expr_to_sym): Expand a scalar initializer
2521         for a parameter array into an array expression with the right
2522         shape.
2523         * array.c (spec_dimen_size): Remove static attribute.
2524         * gfortran.h : Prototype for spec_dimen_size.
2525
2526 2007-05-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2527
2528         PR fortran/31399
2529         * trans-stmt.c (gfc_trans_do): Handle large loop counts.
2530
2531 2007-05-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2532
2533         PR fortran/31764
2534         * simplify.c (gfc_simplify_new_line): NEW_LINE can be simplified
2535         even for non constant arguments.
2536
2537 2007-05-06  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2538             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2539
2540         PR fortran/31201
2541         * gfortran.h: Add runtime error codes from libgfortran.h. Define
2542         MAX_UNIT_NUMBER.
2543         * trans.c (gfc_trans_runtime_check): Update the format of runtime error
2544         messages to match library runtime errors.  Use call to new library
2545         function runtime_error_at().
2546         * trans.h: Add prototype for new function gfc_trans_io_runtime_check.
2547         Add declaration for library functions runtime_error_at and
2548         generate_error.
2549         * trans_io.c (gfc_trans_io_runtime_check): New function.
2550         (set_parameter_value): Add error checking for UNIT numbers.
2551         (set_parameter_ref): Initialize the users variable to zero. 
2552         (gfc_trans_open): Move setting of unit number to after setting of common
2553         flags so that runtime error trapping can be detected.
2554         (gfc_trans_close): Likewise. (build_filepos): Likewise.
2555         (gfc_trans_inquire): Likewise. (build_dt): Likewise.
2556         * trans-decl.c: Add declarations for runtime_error_at and
2557         generate_error. (gfc_build_builtin_function_decls): Build function
2558         declarations for runtime_error_at and generate_error.
2559
2560 2007-05-06  Paul Thomas  <pault@gcc.gnu.org>
2561
2562         PR fortran/31540
2563         * resolve.c (resolve_fl_procedure): Resolve constant character
2564         lengths.
2565
2566 2007-05-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2567
2568         PR fortran/31251
2569         * decl.c (match_char_spec): Add check for invalid character lengths.
2570
2571 2007-05-04  Brooks Moses  <brooks.moses@codesourcery.com>
2572
2573         * intrinsic.texi (CMPLX): Document result kind.
2574         (COMPLEX): Add documentation.
2575
2576 2007-05-04  Daniel Franke  <franke.daniel@gmail.com>
2577
2578         PR fortran/31760
2579         * intrinsic.c (add_functions): Replaced calls to gfc_check_g77_math1
2580         by gfc_check_fn_r to avoid checks for scalarity.
2581         * check.c (gfc_check_besn): Removed check for scalarity.
2582         (gfc_check_g77_math1): Removed.
2583         * intrinsic.h (gfc_check_g77_math1): Removed.
2584
2585 2007-05-04  Daniel Franke  <franke.daniel@gmail.com>
2586
2587         * check.c (gfc_check_fseek_sub): Fixed typo.
2588
2589 2007-05-04  Daniel Franke  <franke.daniel@gmail.com>
2590
2591         PR fortran/22359
2592         * intrinsic.c (add_subroutines): Added FSEEK.
2593         * intrinsic.h (gfc_resolve_fseek_sub, gfc_check_fseek_sub): New.
2594         * iresolve.c (gfc_resolve_fseek_sub): New.
2595         * check.c (gfc_check_fseek_sub): New.
2596         * intrinsic.texi (FSEEK): Updated.
2597
2598 2007-05-04  Tobias Burnus  <burnus@net-b.de>
2599
2600         PR fortran/31803
2601         * expr.c (gfc_check_pointer_assign): Check for NULL pointer.
2602
2603 2007-05-04  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2604
2605         PR fortran/31251
2606         * simplify.c (gfc_simplify_len): Only simplify integer lengths.
2607
2608 2007-05-04  Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2609
2610         PR fortran/31781
2611         * simplify.c (gfc_simplify_repeat): Don't put function call with
2612         side effect in a gcc_assert().
2613
2614 2007-05-04  Tobias Burnus  <burnus@net-b.de>
2615
2616         PR fortran/25071
2617         * interface.c (compare_actual_formal): Check character length.
2618
2619 2007-05-01  Thomas Koenig  <tkoenig@gcc.gnu.org>
2620
2621         PR fortran/31732
2622         * dependency.c (gfc_full_array_ref_p):  If the reference is
2623         to a single element, check that the array has a single
2624         element and that the correct element is referenced.
2625
2626 2007-05-01  Daniel Franke  <franke.daniel@gmail.com>
2627
2628         * intrinsic.c (add_functions): Fixed ELEMENTAL specifications.
2629         (add_subroutines): Replaced magic numbers in function calls by
2630         ELEMENTAL and NOT_ELEMENTAL respectively.
2631         * intrinsic.texi (MVBITS): Changed class to elemental subroutine.
2632         (RANDOM_NUMBER): Changed class to subroutine.
2633         (HUGE, TINY): Changed class to inquiry function.
2634
2635 2007-04-30  Brooks Moses  <brooks.moses@codesourcery.com>
2636
2637         * trans-const.c (gfc_conv_mpz_to_tree): Use mpz_get_double_int.
2638         (gfc_conv_tree_to_mpz): New function.
2639         (gfc_conv_mpfr_to_tree): Use real_from_mpfr.
2640         (gfc_conv_tree_to_mpfr): New function.
2641         * trans-const.h: (gfc_conv_tree_to_mpz): New prototype.
2642         (gfc_conv_tree_to_mpfr): New prototype.
2643
2644 2007-04-30  Daniel Franke  <franke.daniel@gmail.com>
2645
2646         * intrinsic.texi (IERRNO): Changed class to non-elemental function.
2647         (LOG10): Removed COMPLEX as accepted argument type.
2648         (NEW_LINE): Changed class from elemental to inquiry function.
2649         (SIGN): Removed requirement of scalar arguments.
2650         (SNGL): Changed class to elemental function.
2651
2652 2007-04-29  Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2653
2654         PR fortran/31591
2655         * simplify.c (simplify_bound_dim): New function.
2656         (simplify_bound): Use the above. Perform simplification of LBOUND
2657         and UBOUND when DIM argument is not present.
2658
2659 2007-04-29  Daniel Franke  <franke.daniel@gmail.com>
2660
2661         * gfortran.texi: Cleaned up keyword index.
2662         * invoke.texi: Likewise.
2663         * intrinsic.texi: Likewise.
2664                         
2665 2007-04-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2666
2667         PR fortran/31645
2668         * scanner.c (load_file): Discard the byte order mark if one is
2669         found on the first non-preprocessor line of a file.
2670
2671 2007-04-29  Paul Thomas  <pault@gcc.gnu.org>
2672
2673         PR fortran/31711
2674         * trans-array.c (gfc_conv_resolve_dependencies): Create a temp
2675         whenever a dependency is found.
2676
2677 2007-04-28  Tobias Schlüter  <tobi@gcc.gnu.org>
2678
2679         * options.c (gfc_handle_option): Ensure requested free form line
2680         length is not too small.
2681
2682 2007-04-27  Brooks Moses  <brooks.moses@codesourcery.com>
2683
2684         * intrinsic.texi (Transfer): Improve documentation.
2685
2686 2007-04-27  Brooks Moses  <brooks.moses@codesourcery.com>
2687
2688         * gfortran.texi (Option Index): Add @samp as needed.
2689
2690 2007-04-27  Daniel Franke  <franke.daniel@gmail.com>
2691
2692         * gfortran.texi: Added node and menu entry for an option index.
2693         * invoke.texi: Moved command line option related entries of the concept 
2694         index to the option index.
2695
2696 2007-04-27  Daniel Franke  <franke.daniel@gmail.com>
2697
2698         * intrinsic.texi (AND, FPUT, FPUTC, MODULO, OR, SET_EXPONENT,
2699         XOR): Fixed examples.
2700
2701 2007-04-27  Daniel Franke  <franke.daniel@gmail.com>
2702
2703         * intrinsic.texi (PRODUCT, RESHAPE, SPACING, SPREAD, SUM, 
2704         SYSTEM_CLOCK, TRANSFER, UNPACK): New.
2705         (DATE_AND_TIME, CPU_TIME, RRSPACING): Added cross references.
2706
2707 2007-04-26  Daniel Franke  <franke.daniel@gmail.com>
2708
2709         * intrinsic.texi (NULL, PACK, PRESENT, REPEAT, SCAN, SHAPE, 
2710         SIZE, TRANSPOSE, TRIM, VERIFY): New.
2711         (ADJUSTL, ADJUSTR, INDEX): Added cross references.
2712         (INT, INT2, INT8, LONG): Enabled section header.
2713
2714 2007-04-25  Janne Blomqvist  <jb@gcc.gnu.org>
2715
2716         * module.c (module_char): Replace fgetc() with
2717         getc(). 
2718         (write_char): Replace fputc() with putc().
2719         * scanner.c (load_line): Replace fgetc() with getc().
2720         (gfc_read_orig_filename): Likewise.
2721
2722 2007-04-25  Tobias Burnus  <burnus@net-b.de>
2723
2724         PR fortran/31668
2725         * error.c (error_print): Fix %% support.
2726         * intrinsic.c (sort_actual): Improve error message.
2727         * resolve.c (resolve_actual_arglist): Allow %VAL for
2728         interfaces defined in the module declaration part.
2729
2730 2007-04-25  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2731
2732         PR libfortran/31299
2733         * intrinsic.texi (GETLOG): Update documentation to reflect
2734         library changes.
2735
2736 2007-04-24  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2737
2738         PR fortran/31587
2739         * module.c (write_char): Add character to the MD5 buffer.
2740         (read_md5_from_module_file): New function.
2741         (gfc_dump_module): Compute MD5 for new module file. Call
2742         read_md5_from_module_file. Only overwrite old module file
2743         if the new MD5 is different.
2744
2745 2007-04-23  Paul Thomas  <pault@gcc.gnu.org>
2746
2747         PR fortran/31630
2748         * resolve.c (resolve_symbol): Allow resolution of formal
2749         namespaces nested within formal namespaces coming from modules.
2750
2751         PR fortran/31620
2752         * trans-expr.c (gfc_trans_assignment): Make the call to
2753         gfc_trans_zero_assign conditional on the lhs array ref being
2754         the only reference.
2755
2756 2007-04-23  Tobias Burnus  <burnus@net-b.de>
2757
2758         * primary.c (match_integer_constant): Mention -fno-range-check
2759         in the error message.
2760
2761 2007-04-21  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2762
2763         PR fortran/31495
2764         * scanner.c (load_line):  Remove check for comment after ampersand and
2765         adjust tracking of ampersand.
2766
2767 2007-04-21  Andrew Pinski  <andrew_pinski@playstation.sony.com>
2768
2769         * f95-lang.c (lang_tree_node): Use GENERIC_NEXT
2770         instead of checking GIMPLE_STMT_P in chain_next.
2771
2772 2007-04-17  Tobias Schlüter  <tobi@gcc.gnu.org>
2773
2774         * trans-types.h (gfc_packed): New enum.
2775         (gfc_get_nodesc_array_type): Change prototype to use new enum.
2776         * trans-types.c (gfc_get_nodesc_array): Use gfc_packed for
2777         argument packed.  Adapt all references to values accordingly.
2778         (gfc_sym_type): Use enum values in call to gfc_get_nodesc_array.
2779         (gfc_get_derived_type): Likewise.
2780         * trans-array.c (gfc_build_constant_array_constructor): Likewise.
2781         * trans-expr.c (gfc_get_interface_mapping_charlen): Changed packed
2782         argument to type gfc_packed.
2783         (gfc_add_interface_mapping): Use enum values in call to
2784         gfc_get_interface_mapping.
2785         * trans-decl.c (gfc_build_dummy_array_decl): Adapt to use enum
2786         values when determining packing.
2787
2788         * trans-decl.c (gfc_finish_decl): Remove unused second argument
2789         'init'.  Simplify code accordingly.  Remove calls to
2790         gfc_fatal_error in favor of gcc_assert.
2791         (create_function_arglist): Remove second argument from calls to
2792         gfc_finish-decl.
2793         (gfc_trans_dummy_character): Likewise.
2794
2795         * arith.h: Update copyright years.
2796         * dependency.h: Likewise.
2797         * gfortran.h: Likewise.
2798         * lang-specs.h: Likewise.
2799         * parse.h: Likewise.
2800         * symbol.c: Likewise.
2801         * trans.h: Likewise.
2802         * trans.c: Likewise.
2803         * trans-array.c: Likewise.
2804         * trans-common.c: Likewise.
2805         * trans-const.h: Likewise.
2806         * trans-const.c: Likewise.
2807         * trans-decl.c: Likewise.
2808         * trans-expr.c: Likewise.
2809         * trans-io.c: Likewise.
2810         * trans-openmp.c: Likewise.
2811         * trans-types.h: Likewise.
2812         * types.def: Likewise.
2813
2814 2007-04-17  Tobias Schlüter  <tobi@gcc.gnu.org>
2815
2816         PR fortran/31144
2817         * decl.c (gfc_sym_mangled_identifier): Use capital letters in name
2818         mangling.
2819         (gfc_sym_mangled_function_id): Likewise.
2820
2821 2007-04-15  Paul Thomas  <pault@gcc.gnu.org>
2822
2823         PR fortran/31204
2824         * primary.c (check_for_implicit_index): New function to check
2825         that a host associated variable is not an undeclared implied
2826         do loop index.
2827         (gfc_match_rvalue, match_variable): Use it and reset the
2828         implied_index attribute.
2829         * gfortran.h : Add the implied_index field to symbol_attribute.
2830         * match.c (gfc_match_iterator): Mark the iterator variable
2831         with the new attribute.
2832         * decl.c (build_sym): Reset the new attribute.
2833
2834 2007-04-15  Kazu Hirata  <kazu@codesourcery.com>
2835
2836         * gfc-internals.texi: Fix typos.
2837         * simplify.c: Fix a comment typo.
2838
2839 2007-04-14  Bernhard Fischer  <aldot@gcc.gnu.org>
2840
2841         * primary.c: Commentary typo fix; Add question about redundant (?)
2842         set.
2843
2844 2007-04-14  Paul Thomas  <pault@gcc.gnu.org>
2845
2846         PR fortran/29507
2847         PR fortran/31404
2848         * expr.c (scalarize_intrinsic_call): New function to
2849         scalarize elemental intrinsic functions in initialization
2850         expressions.
2851         (check_init_expr): Detect elemental intrinsic functions
2852         in initalization expressions and call previous.
2853
2854 2007-04-13  Tobias Burnus  <burnus@net-b.de>
2855
2856         PR fortran/31559
2857         * primary.c (match_variable): External functions
2858         are no variables.
2859
2860 2007-04-13  Paul Thomas  <pault@gcc.gnu.org>
2861
2862         PR fortran/31550
2863         * trans-types.c (copy_dt_decls_ifequal): Do not get pointer
2864         derived type components.
2865
2866 2007-04-13  Tobias Schlüter  <tobi@gcc.gnu.org>
2867
2868         PR fortran/18937
2869         * resolve.c: Include obstack.h and bitmap.h.  New variable
2870         labels_obstack.
2871         (code_stack): Add tail and reachable_labels fields.
2872         (reachable_labels): New function.
2873         (resolve_branch): Rework to use new fields in code_stack.
2874         (resolve_code): Call reachable_labels.
2875         (resolve_codes): Allocate and free labels_obstack.
2876
2877 2007-04-12  Tobias Schlüter  <tobi@gcc.gnu.org>
2878
2879         PR fortran/31250
2880         * decl.c (match_char_spec): Move check for negative CHARACTER
2881         length ...
2882         * resolve.c (resolve_charlen): ... here.
2883         (resolve_types): Resolve CHARACTER lengths earlier.
2884
2885 2007-04-12  Daniel Franke  <franke.daniel@gmail.com>
2886
2887         PR fortran/31234
2888         * intrinsic.texi (RANDOM_SEED, RANDOM_NUMBER): New.
2889
2890 2007-04-12  Tobias Schlüter  <tobi@gcc.gnu.org>
2891
2892         PR fortran/31266
2893         * primary.c (gfc_variable_attr): Don't copy string length if it
2894         doesn't make sense.
2895         * resolve.c (resolve_code): Clarify error message.
2896
2897         PR fortran/31471
2898         * decl.c (gfc_match_end): Also check for construct name in END
2899         FORALL and END WERE statements.
2900         * match.c (match_case_eos): Use uppercase for statement name in
2901         error message.
2902         (match_elsewhere): Construct name may appear iff construct has a
2903         name.
2904
2905         * trans-types.c: Update copyright years.  Reformat long comment
2906         explaining array descriptor format.  Remove obsolete mention of
2907         TYPE_SET.
2908
2909         * arith.c (gfc_arith_uplus): Rename to ...
2910         (gfc_arith_identity): ... this.
2911         (gfc_parentheses): New function.
2912         (gfc_uplus): Adapt to renamed function.
2913         * arith.h (gfc_parentheses): Add prototype.
2914         * expr.c (gfc_copy_expr): Deal with INTRINSIC_PARENTHESES.
2915         (simplifiy_intrinsic_op): Treat INTRINSIC_UPLUS separately from
2916         INTRINSIC_PARENTHESES.
2917
2918 2007-04-12  Tobias Burnus  <burnus@net-b.de>
2919
2920         PR fortran/31472
2921         * decl.c (match_attr_spec): Allow PRIVATE/PUBLIC
2922         attribute in type definitions.
2923         (gfc_match_private): Allow PRIVATE statement only
2924         in specification part of modules.
2925         (gfc_match_public): Ditto for PUBLIC.
2926         (gfc_match_derived_decl): Allow PRIVATE/PUBLIC attribute only in
2927         specificification part of modules.
2928
2929 2007-04-07  Paul Thomas  <pault@gcc.gnu.org>
2930
2931         PR fortran/31257
2932         * intrinsic.c (add_functions): Add ref. to gfc_resolve_achar.
2933         * intrinsic.h : Add prototype for gfc_resolve_achar.
2934         * iresolve.c (gfc_resolve_achar): New function.
2935
2936 2007-04-07  Paul Thomas  <pault@gcc.gnu.org>
2937
2938         PR fortran/30880
2939         * resolve.c (resolve_fl_variable): Set flag to 2 for automatic
2940         arrays.  Make condition for automatic array error explicit.
2941         If a dummy, no error on an INTENT(OUT) derived type.
2942
2943 2007-04-07  Paul Thomas  <pault@gcc.gnu.org>
2944
2945         PR fortran/30872
2946         * expr.c (find_array_element): Correct arithmetic for rank > 1.
2947
2948 2007-04-07  Paul Thomas  <pault@gcc.gnu.org>
2949
2950         PR fortran/31222
2951         * check.c (numeric_check): If an expresson has not got a type,
2952         see if it is a symbol for which a default type applies.
2953
2954 2007-04-07  Paul Thomas  <pault@gcc.gnu.org>
2955
2956         PR fortran/31214
2957         * trans-decl.c (gfc_get_symbol_decl): Allow unreferenced use
2958         associated symbols.
2959
2960 2007-04-07  Paul Thomas  <pault@gcc.gnu.org>
2961
2962         PR fortran/31293
2963         * symbol.c (gfc_check_function_type): New function.
2964         * gfortran.h : Add prototype for previous.
2965         * parse.c (parse_progunit): Call it after parsing specification
2966         statements.
2967
2968 2007-04-05  Paul Thomas  <pault@gcc.gnu.org>
2969
2970         PR fortran/31483
2971         * trans-expr.c (gfc_conv_function_call): Give a dummy
2972         procedure the correct type if it has alternate returns.
2973
2974 2007-04-05  Paul Thomas  <pault@gcc.gnu.org>
2975
2976         PR fortran/31292
2977         * decl.c (gfc_match_modproc): Go up to the top of the namespace
2978         tree to find the module namespace for gfc_get_symbol.
2979
2980 2007-04-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2981
2982         PR fortran/31304
2983         * fortran/gfortran.h (gfc_charlen_int_kind): New prototype.
2984         * fortran/trans-types.c (gfc_charlen_int_kind): New variable.
2985         (gfc_init_types): Define gfc_charlen_int_kind. 
2986         * fortran/trans.h (gfor_fndecl_string_repeat): Remove prototype.
2987         * fortran/trans-decl.c (gfor_fndecl_string_repeat): Delete.
2988         (gfc_build_intrinsic_function_decls): Don't set
2989         gfor_fndecl_string_repeat.
2990         * fortran/trans-intrinsic.c (gfc_conv_intrinsic_repeat): Rewrite
2991         so that we don't have to call a library function.
2992         * fortran/simplify.c (gfc_simplify_repeat): Perform the necessary
2993         checks on the NCOPIES argument, and work with arbitrary size
2994         arguments.
2995
2996 2007-03-31  Tobias Burnus  <burnus@net-b.de>
2997
2998         * intrinsic.c (add_functions): Fix name of dummy argument
2999           for new_line and exit intrinsic.
3000
3001 2007-03-31  Paul Thomas  <pault@gcc.gnu.org>
3002
3003         PR fortran/31160
3004         * gfortran.texi: Add a section for the %VAL, %REF and %LOC
3005         extensions.
3006
3007 2007-03-30  Rafael Avila de Espindola  <espindola@google.com>
3008
3009         * trans-types.c (gfc_signed_or_unsigned_type): Remove.
3010         (gfc_unsigned_type): Use get_signed_or_unsigned_type instead of
3011         gfc_signed_or_unsigned_type.
3012         (gfc_signed_type): Ditto.
3013         * trans-types.h (gfc_signed_or_unsigned_type): Remove.
3014         * f95-lang.c (LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): Remove.
3015
3016 2007-03-30  Tobias Schlüter  <tobi@gcc.gnu.org>
3017
3018         * symbol.c (gfc_find_gsymbol): Simplify, don't unconditionally
3019         descend into all branches.
3020
3021 2007-03-29  Tobias Schlüter  <tobi@gcc.gnu.org>
3022
3023         * intrinsic.c (conv_name): Let gfc_get_string handle the format.
3024         (find_conv): Compare pointers instead of calling strcmp.
3025         (find_sym): Likewise, but ensure that the compared pointer is in
3026         the global string table.
3027
3028 2007-03-28  Tobias Schlüter  <tobi@gcc.gnu.org>
3029
3030         * gfc-internals.texi: Fix output filename.  Merge type index into
3031         concept index.  Start documentation of gfc_code structure.
3032
3033 2007-03-26  Brooks Moses  <brooks.moses@codesourcery.com>
3034
3035         * gfc-internals.texi: New file,
3036         * Make-lang.in: Add rules to convert it to dvi, pdf, and info.
3037
3038 2007-03-26  Brooks Moses  <brooks.moses@codesourcery.com>
3039  
3040         * error.c (show_locus): Remove always-false test.
3041
3042 2007-03-26  Brooks Moses  <brooks.moses@codesourcery.com>
3043
3044         * lang.opt: Minor edits to descriptions.
3045
3046 2007-03-25  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3047
3048         PR fortran/30877
3049         * fortran/interface.c (check_operator_interface): Implement
3050         the standard checks on user operators extending intrinsic operators.
3051         * fortran/resolve.c (resolve_operator): If the ranks of operators
3052         don't match, don't error out but try the user-defined ones first.
3053
3054 2007-03-24  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3055
3056         PR fortran/30655
3057         * expr.c (check_dimension): Fix logic of comparisons.
3058
3059 2007-03-24  Paul Thomas  <pault@gcc.gnu.org>
3060
3061         PR fortran/31215
3062         * trans-expr.c (gfc_apply_interface_mapping_to_expr): Return
3063         int result that is non-zero if the expression is the function
3064         result.  Only the characteristics of the result expression
3065         can be used in a procedure interface, so simplify LEN in situ
3066         using its character length.
3067
3068         PR fortran/31209
3069         PR fortran/31200
3070         * trans-expr.c (gfc_conv_function_call): Do not use
3071         gfc_conv_expr_reference for actual pointer function with formal
3072         target because a temporary is created that does not transfer
3073         the reference correctly.  Do not indirect formal pointer
3074         functions since it is the function reference that is needed.
3075
3076 2007-03-24  Brooks Moses  <brooks.moses@codesourcery.com>
3077
3078         * gfortran.h: Edit comments on GFC_STD_*.
3079
3080 2007-03-23  Brooks Moses  <brooks.moses@codesourcery.com>
3081
3082         * invoke.texi: Misc. small typo fixes.
3083         (-Wcharacter-truncation): Add.
3084         (-Wnonstd-intrinsics): Correct spelling.
3085         (-std=): Edit.
3086         (-fintrinsic-modules-path): Add.
3087
3088 2007-03-23  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3089
3090         PR fortran/30834
3091         * arith.c (complex_pow): Rewrite to handle large power.
3092         (gfc_arith_power): Handle large power in the real and integer
3093         cases.
3094
3095 2007-03-22  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3096
3097         PR fortran/31262
3098         * trans-const.c (gfc_conv_mpz_to_tree): Allow integer constants
3099         larger than twice the width of a HOST_WIDE_INT.
3100
3101 2006-03-22  Paul Thomas  <pault@gcc.gnu.org>
3102
3103         PR fortran/31193
3104         * trans-intrinsic.c (gfc_size_in_bytes): Remove function.
3105         (gfc_conv_intrinsic_array_transfer): Remove calls to previous.
3106         Explicitly extract TREE_TYPEs for source and mold.  Use these
3107         to calculate length of source and mold, except for characters,
3108         where the se string_length is used.  For mold, the TREE_TYPE is
3109         recalculated using gfc_get_character_type_len so that the
3110         result is correctly cast for character literals and substrings.
3111         Do not use gfc_typenode_for_spec for the final cast.
3112
3113 2007-03-22  Tobias Schlüter  <tobi@gcc.gnu.org>
3114
3115         PR fortran/20897
3116         * decl.c (gfc_match_derived_decl): Reliably reject
3117         'doubleprecision' and 'doublecomplex' as type names.
3118
3119 2007-03-19  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3120
3121         PR fortran/31203
3122         * trans-expr.c (gfc_trans_init_string_length): Length should
3123         never be negative.
3124         (gfc_conv_function_call): Likewise.
3125
3126 2007-03-18  Paul Thomas  <pault@gcc.gnu.org>
3127
3128         PR fortran/30531
3129         PR fortran/31086
3130         * symbo.c : Add gfc_derived_types.
3131         (gfc_free_dt_list): Free derived type list gfc_derived_types.
3132         (gfc_free_namespace): Remove call to gfc_free_dt_list.
3133         (gfc_symbol_done_2): Call  gfc_free_dt_list.
3134         * gfortran.h : Declare gfc_derived_types to be external. Remove
3135         derived types field from gfc_namespace.
3136         * resolve.c (resolve_fl_derived): Refer to gfc_derived types
3137         rather than namespace derived_types.
3138         (resolve_fntype): Remove special treatment for module
3139         derived type functions.
3140         * trans-types.c (gfc_get_derived_type): Remove search for like
3141         derived types.  Finish by copying back end declaration to like
3142         derived types in the derived type list gfc_derived_types.
3143
3144         2007-03-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3145
3146         PR fortran/31120
3147         * trans-expr.c (gfc_conv_powi): Make n argument unsigned hwi.
3148         (gfc_conv_cst_int_power): Handle integer exponent with care,
3149         since it might be too large for us.
3150
3151 2007-03-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3152
3153         PR fortran/31184
3154         * invoke.texi: Fix typo.
3155
3156 2007-03-16  Tobias Burnus  <burnus@net-b.de>
3157
3158         * trans-decl.c (gfc_generate_function_code): Use all arguments of
3159           set_std.
3160
3161 2007-03-15  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3162
3163         * gfortran.h (gfc_option_t): Add flag_backtrace field.
3164         * lang.opt: Add -fbacktrace option.
3165         * invoke.texi: Document the new option.
3166         * trans-decl.c (gfc_build_builtin_function_decls): Add new
3167         option to the call to set_std.
3168         * options.c (gfc_init_options, gfc_handle_option): Handle the
3169         new option.
3170
3171 2007-03-15  Tobias Burnus  <burnus@gcc.gnu.org>
3172             Paul Thomas  <pault@gcc.gnu.org>
3173
3174         PR fortran/30922
3175         * decl.c (gfc_match_import): If the parent of the current name-
3176         space is null, try looking for an imported symbol in the parent
3177         of the proc_name interface.
3178         * resolve.c (resolve_fl_variable): Do not check for blocking of
3179         host association by a same symbol, if the symbol is in an
3180         interface body.
3181
3182 2007-03-15  Paul Thomas  <pault@gcc.gnu.org>
3183
3184         PR fortran/30879
3185         * decl.c (match_data_constant): Before going on to try to match
3186         a name, try to match a structure component.
3187
3188
3189         PR fortran/30870
3190         * resolve.c (resolve_actual_arglist): Do not reject a generic
3191         actual argument if it has a same name specific interface.
3192
3193         PR fortran/31163
3194         * trans-array.c (parse_interface): Do not nullify allocatable
3195         components if the symbol has the saved attribute.
3196
3197 2007-03-14  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3198
3199         * trans-array.c (gfc_trans_auto_array_allocation): Replace
3200         fold(convert()) by fold_convert().
3201         (gfc_duplicate_allocatable): Likewise.
3202         * trans-intrinsic.c (gfc_conv_intrinsic_dot_product): Use
3203         build_int_cst instead of converting an integer_zero_node
3204         to the final type.
3205
3206 2007-03-14  Jakub Jelinek  <jakub@redhat.com>
3207
3208         * module.c (mio_typespec): Don't look at ts->cl if not BT_CHARACTER.
3209
3210 2007-03-13  Brooks Moses  <brooks.moses@codesourcery.com>
3211
3212         PR fortran/30933
3213         PR fortran/30948
3214         PR fortran/30953
3215         * intrinsics.texi (CHDIR): Fix argument names, note
3216         that STATUS must be a default integer.
3217         (CTIME): Fix argument names, note that RESULT must
3218         be a default integer.
3219         (EXIT): Note that STATUS must be a default integer.
3220
3221 2007-03-13  Brooks Moses  <brooks.moses@codesourcery.com>
3222
3223         PR fortran/28068
3224         * intrinsic.texi: General whitespace cleanup, remove
3225         comment about missing intrinsics.
3226         (menu): Add lines for new entries listed below.
3227         (ACOSH): Mention specific function DACOSH, correct
3228         description phrasing.
3229         (ASINH): Mention specific function DASINH, correct
3230         description phrasing.
3231         (ATANH): Mention specific function DATANH, correct
3232         description phrasing.
3233         (COS): Add index entry for CCOS.
3234         (CPU_TIME): Correct "REAL" to "REAL(*)".
3235         (EXP): Add index entry for CEXP.
3236         (INT): Correct argument name to "A".
3237         (INT2): New entry.
3238         (INT8): New entry.
3239         (LONG): New entry.
3240         (MAX): Add index entries for specific variants.
3241         (MCLOCK): New entry.
3242         (MCLOCK8): New entry.
3243         (SECNDS): Adjust to a more standard form.
3244         (SECOND): New entry.
3245         (TIME): Add cross-reference to MCLOCK.
3246         (TIME8): Add cross-reference to MCLOCK8.
3247
3248 2007-03-11  Paul Thomas  <pault@gcc.gnu.org>
3249
3250         PR fortran/30883
3251         * parse.c (parse_interface): Use the default types from the
3252         formal namespace if a function or its result do not have a type
3253         after parsing the specification statements.
3254
3255 2007-03-08  Brooks Moses  <brooks.moses@codesourcery.com>
3256
3257         * intrinsic.texi: (ICHAR) Improve internal I/O note.
3258         (ACHAR): Reference it.
3259         (CHAR): Reference it.
3260         (IACHAR): Reference it.
3261
3262 2007-03-08  Brooks Moses  <brooks.moses@codesourcery.com>
3263
3264         * intrinsic.texi: (LINK) Document function form.
3265         (RENAME): Likewise.
3266         (SYMLNK): Likewise.
3267         (SYSTEM): Likewise.
3268         (UNLINK): Likewise.
3269
3270 2007-03-08  Brooks Moses  <brooks.moses@codesourcery.com>
3271
3272         * intrinsic.texi: minor typo fixes, removed prologue.
3273         (FSEEK): moved to correct place in alphabetical order.
3274
3275 2007-03-08  Daniel Franke  <franke.daniel@gmail.com>
3276
3277         PR fortran/30947
3278         * check.c (gfc_check_alarm_sub): Added check for default integer 
3279         kind of status argument.
3280         * iresolve.c (gfc_resolve_alarm_sub): Removed conversion of 
3281         status argument.
3282         * intrinsic.texi (ALARM): Extended documentation.
3283
3284 2007-03-08  Daniel Franke  <franke.daniel@gmail.com>
3285
3286         * intrinsic.texi (GERROR, ISATTY, TTYNAM): New.
3287         (ABORT, FLUSH, FNUM, IRAND, MALLOC, SIGNAL, SRAND): Fixed typo.
3288         * intrinsic.c (add_subroutines): Adjusted dummy argument names 
3289         of GERROR and TTYNAM.
3290
3291 2007-07-08  Tobias Burnus  <burnus@net-b.de>
3292
3293         * module.c (gfc_match_use): Support renaming of operators
3294         in USE statements.
3295         * gfortran.texi (Fortran 2003 Status): Document support of
3296         renaming of operators.
3297
3298 2007-07-08  Tobias Burnus  <burnus@net-b.de>
3299
3300         PR fortran/30973
3301         * module.c (read_module): Always import module name as symbol.
3302         (gfc_match_use): Disallow module name in the only clause of
3303         a use statement.
3304
3305 2007-03-08  Paul Thomas  <pault@gcc.gnu.org>
3306
3307         PR fortran/31011
3308         * expr.c (find_array_section): Correct arithmetic for section
3309         size.
3310
3311 2007-03-07  Brooks Moses  <brooks.moses@codesourcery.com>
3312
3313         * iresolve.c (gfc_resolve_ishftc): Correct s_kind value.
3314
3315 2007-03-06  Daniel Franke  <franke.daniel@gmail.com>
3316
3317         PR documentation/30950
3318         * intrinsic.texi (AND, CPU_TIME): Fix dummy argument names.
3319         (FREE): Fix call syntax.
3320
3321 2007-03-06  Brooks Moses  <brooks.moses@codesourcery.com>
3322
3323         * intrinsic.texi: Limit column widths to a total of .85.
3324
3325 2007-03-05  Brooks Moses  <brooks.moses@codesourcery.com>
3326
3327         * gfortran.texi (GFortran and G77): Rewrite completely.
3328
3329 2007-03-05  Brooks Moses  <brooks.moses@codesourcery.com>
3330
3331         * match.c (gfc_match_name): Expanded comment.
3332
3333 2007-03-05  Brooks Moses  <brooks.moses@codesourcery.com>
3334
3335         * gfortran.texi (Old-style kind specifications): Document
3336         special handling of old-style kind specifiers for COMPLEX.
3337         * decl.c (gfc_match_old_kind_spec): Document kind/bytesize
3338         assumptions for COMPLEX in comment.
3339
3340 2007-03-05  Brooks Moses  <brooks.moses@codesourcery.com>
3341
3342         PR 31050
3343         * gfortranspec.c (lang_specific_driver): Update program
3344         name and copyright date.
3345
3346 2007-03-03  Paul Thomas  <pault@gcc.gnu.org>
3347
3348         PR fortran/30882
3349         * check.c (dim_rank_check): The shape of subsections of
3350         assumed-size arrays is known.
3351
3352 2007-03-02  Paul Thomas  <pault@gcc.gnu.org>
3353             Tobias Burnus  <burnus@net-b.de>
3354
3355         PR fortran/30873
3356         * decl.c (gfc_match_entry): Remove erroneous entry result check.
3357
3358 2007-03-01  Brooks Moses  <brooks.moses@codesourcery.com>
3359
3360         * Make-lang.in: Add install-pdf target as copied from
3361         automake v1.10 rules.
3362
3363 2007-03-01  Tobias Burnus  <burnus@net-b.de>
3364
3365         PR fortran/30865
3366         * trans-intrinsic.c (gfc_conv_intrinsic_size): Compare pointers.
3367
3368 2007-02-28  Tobias Burnus  <burnus@net-b.de>
3369             Paul Thomas  <pault@gcc.gnu.org>
3370
3371         PR fortran/30888
3372         PR fortran/30887
3373         * resolve.c (resolve_actual_arglist): Allow by-value
3374         arguments and non-default-kind for %VAL().
3375         * trans-expr.c (conv_arglist_function): Allow
3376         non-default-kind for %VAL().
3377
3378 2007-02-28  Tobias Burnus  <burnus@net-b.de>
3379
3380         PR fortran/30968
3381         * primary.c (next_string_char): Correct reading a character
3382         after the delimiter.
3383         (match_string_constant): Print warning message only once.
3384
3385 2007-02-27  Richard Guenther  <rguenther@suse.de>
3386
3387         * trans-array.c (structure_alloc_comps): Use correct type
3388         for null pointer constant.
3389
3390 2007-02-26  Brooks Moses  <brooks.moses@codesourcery.com>
3391
3392         * gfortran.texi: Standardize title page, remove version number
3393         from copyright page.
3394
3395 2007-02-26  Thomas Koenig  <Thomas.Koenig@online.de>
3396             Paul Thomas  <pault@gcc.gnu.org>
3397
3398         PR fortran/30865
3399         * trans-intrinsic.c (gfc_conv_intrinsic_size):
3400         If dim is an optional argument, check for its
3401         presence and call size0 or size1, respectively.
3402
3403 2007-02-23  Paul Thomas <pault@gcc.gnu.org>
3404
3405         PR fortran/30660
3406         * resolve.c (has_default_initializer): New function.
3407         (resolve_fl_variable): Call has_default_initializer to determine if
3408         the derived type has a default initializer to its ultimate
3409         components.
3410
3411
3412 2007-02-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3413
3414         * options.c (set_default_std_flags): New function to consolidate
3415         setting the flags.
3416         (gfc_init_options): Use new function.
3417         (gfc_handle_option): Use new function.
3418
3419 2007-02-22  Brooks Moses  <brooks.moses@codesourcery.com>
3420
3421         * gfortran.texi (Old-style kind specifications): Document
3422         special handling of old-style kind specifiers for COMPLEX.
3423         * decl.c (gfc_match_old_kind_spec): Documented kind/bytesize
3424         assumptions in comment.
3425
3426 2007-02-21  Bernhard Fischer  <aldot@gcc.gnu.org>
3427
3428         * parse.c (next_free): Gooble spaces after OpenMP sentinel.
3429
3430 2007-02-20  Thomas Koenig  <Thomas.Koenig@online.de>
3431
3432         PR fortran/30869
3433         * match.c (gfc_match_iterator): Remove conflict between
3434         loop variable and pointer.
3435
3436 2007-02-20  Tobias Burnus  <burnus@net-b.de>
3437
3438         PR fortran/30522
3439         * symbol.c (gfc_add_volatile): Allow to set VOLATILE
3440           attribute for host-associated variables.
3441         * gfortran.h (symbol_attribute): Save namespace
3442           where VOLATILE has been set.
3443         * trans-decl.c (gfc_finish_var_decl): Move variable
3444           declaration to the top.
3445
3446 2007-02-20  Tobias Burnus  <burnus@net-b.de>
3447
3448         PR fortran/30783
3449         * resolve.c (resolve_symbol): Add character dummy VALUE check.
3450
3451 2007-02-19  Thomas Koenig  <Thomas.Koenig@online.de>
3452
3453         PR libfortran/30533
3454         * fortran/iresolve.c (gfc_resolve_maxloc): Remove coercion of
3455         argument to default integer.
3456         (gfc_resolve_minloc): Likewise.
3457
3458 2007-02-18  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3459
3460         PR fortran/30681
3461         * options.c (gfc_init_options): Relax warning level for obsolescent.
3462         * match.c (match_arithmetic_if): Change to obsolescent from deleted.
3463         (gfc_match_if): Same.
3464
3465 2007-02-18  Roger Sayle  <roger@eyesopen.com>
3466
3467         * trans-array.c (gfc_build_constant_array_constructor): When the
3468         shape of the constructor is known, use that to construct the
3469         gfc_array_spec.
3470         (gfc_trans_constant_array_constructor): Initialize the "info"
3471         information for all of the dimensions of the array constructor.
3472         (constant_array_constructor_loop_size): New function.
3473         (gfc_trans_array_constructor): Use it to determine whether a
3474         loop is suitable for "constant array constructor" optimization.
3475
3476         * trans-intrinsic.c (gfc_conv_intrinsic_anyall): Use fold_build2
3477         instead of build2, to avoid conditions like "(a != b) != 0".
3478
3479 2007-02-18  Roger Sayle  <roger@eyesopen.com>
3480             Paul Thomas <pault@gcc.gnu.org>
3481
3482         PR fortran/30400
3483         * match.c (match_forall_iterator): Use gfc_match_expr instead
3484         of gfc_match_variable to match the iterator variable.  Return
3485         MATCH_NO if not a variable.  Remove the reset of the symbol's
3486         flavor in cleanup.
3487
3488 2007-02-16  Tobias Burnus  <burnus@net-b.de>
3489
3490         PR fortran/30793
3491         * trans-decl.c (gfc_generate_function_code): Do not initialize
3492         pointers to derived components.
3493
3494 2007-02-15  Sandra Loosemore  <sandra@codesourcery.com>
3495             Brooks Moses  <brooks.moses@codesourcery.com>
3496             Lee Millward  <lee.millward@codesourcery.com>
3497
3498         * trans-expr.c (gfc_conv_power_op): Use build_call_expr.
3499         (gfc_conv_string_tmp): Likewise.
3500         (gfc_conv_concat_op): Likewise.
3501         (gfc_build_compare_string): Likewise.
3502         (gfc_conv_function_call): Use build_call_list instead of build3.
3503
3504         * trans-array.c (gfc_trans_allocate_array_storage): Use
3505         build_call_expr.
3506         (gfc_grow_array): Likewise.
3507         (gfc_trans_array_ctor_element): Likewise.
3508         (gfc_trans_array_constructor_value): Likewise.
3509         (gfc_array_allocate): Likewise.
3510         (gfc_array_deallocate): Likewise.
3511         (gfc_trans_auto_array_allocation): Likewise.
3512         (gfc_trans_dummy_array_bias): Likewise.
3513         (gfc_conv_array_parameter): Likewise.
3514         (gfc_trans_dealloc_allocated): Likewise.
3515         (gfc_duplicate_allocatable): Likewise.
3516
3517         * trans-openmp.c (gfc_trans_omp_barrier): Use build_call_expr.
3518         (gfc_trans_omp_flush): Likewise.
3519
3520         * trans-stmt.c (gfc_conv_elementel_dependencies): Use build_call_expr.
3521         (gfc_trans_pause): Likewise.
3522         (gfc_trans_stop): Likewise.
3523         (gfc_trans_character_select): Likewise.
3524         (gfc_do_allocate): Likewise.
3525         (gfc_trans_assign_need_temp): Likewise.
3526         (gfc_trans_pointer_assign_need_temp): Likewise.
3527         (gfc_trans_forall_1): Likewise.
3528         (gfc_trans_where_2): Likewise.
3529         (gfc_trans_allocate): Likewise.
3530         (gfc_trans_deallocate): Likewise.
3531
3532         * trans.c (gfc_trans_runtime_check): Use build_call_expr.
3533
3534         * trans-io.c (gfc_trans_open): Use build_call_expr.
3535         (gfc_trans_close): Likewise.
3536         (build_filepos): Likewise.
3537         (gfc_trans_inquire): Likewise.
3538         (NML_FIRST_ARG): Delete.
3539         (NML_ADD_ARG): Delete.
3540         (transfer_namelist_element): Use build_call_expr.
3541         (build_dt): Likewise.
3542         (gfc_trans_dt_end): Likewise.
3543         (transfer_expr): Likewise.
3544         (transfer_array-desc): Likewise.
3545
3546         * trans-decl.c (gfc_generate_function_code): Use build_call_expr.
3547         (gfc_generate_constructors): Likewise.
3548
3549         * trans-intrinsic.c (gfc_conv_intrinsic_ctime): Use build_call_expr.
3550         (gfc_conv_intrinsic_fdate): Likewise.
3551         (gfc_conv_intrinsic_ttynam): Likewise.
3552         (gfc_conv_intrinsic_array_transfer): Likewise.
3553         (gfc_conv_associated): Likewise.
3554         (gfc_conv_intrinsic_si_kind): Likewise.
3555         (gfc_conv_intrinsic_trim): Likewise.
3556         (gfc_conv_intrinsic_repeat: Likewise.
3557         (gfc_conv_intrinsic_iargc): Likewise.
3558
3559 2007-02-14  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3560
3561         PR fortran/30779
3562         * scanner.c (gfc_next_char_literal): Add check for end of file after
3563         call to advance_line.
3564
3565 2007-02-14  Steven G. Kargl  <kargl@gcc.gnu.org>
3566
3567         PR fortran/30799
3568         * primary.c (match_logical_constant): Return MATCH_ERROR on invalid
3569         kind.
3570
3571 2007-02-14  Steven G. Kargl  <kargl@gcc.gnu.org>
3572
3573         * misc.c (gfc_typename): Fix potential buffer overflow.
3574
3575 2007-02-13  Paul Thomas  <pault@gcc.gnu.org>
3576
3577         PR fortran/30554
3578         * module.c (read_module): Set pointer_info to referenced if the
3579         symbol has no namespace.
3580
3581 2007-02-12  Nick Clifton  <nickc@redhat.com>
3582
3583         * lang.opt: Add Warning attribute to warning options.
3584
3585 2007-02-11  Daniel Franke  <franke.daniel@gmail.com>
3586
3587         * intrinsic.texi (HOSTNM): Fix typographical error in syntax.
3588         (SLEEP): Added section and documentation.
3589
3590 2007-02-11  Tobias Schlüter  <tobi@gcc.gnu.org>
3591
3592         PR fortran/30478
3593         * decl.c (add_init_expr_to_sym): Remove ENUM specific code.
3594         (variable_decl): Likewise.  Rewrap comment.
3595         (match_attr_spec): Remove ENUM specific code.
3596         (gfc_match_enum): Fix typo in error message.
3597         (enumerator_decl): New function.
3598         (gfc_match_enumerator_def): Use enumerator_decl instead of
3599         variable_decl.  Adapt code accordingly.
3600
3601 2007-02-11  Paul Thomas  <pault@gcc.gnu.org>
3602
3603         PR fortran/30554
3604         * module.c (find_symtree_for_symbol): New function to return
3605         a symtree that is not a "unique symtree" given a symbol.
3606         (read_module): Do not automatically set pointer_info to
3607         referenced because this inhibits the generation of a unique
3608         symtree.  Recycle the existing symtree if possible by calling
3609         find_symtree_for_symbol.
3610
3611         PR fortran/30319
3612         * decl.c (add_init_expr_to_sym): Make new charlen for an array
3613         constructor initializer.
3614
3615 2007-02-10  Richard Henderson  <rth@redhat.com>, Jakub Jelinek  <jakub@redhat.com>
3616
3617         * f95-lang.c (gfc_init_builtin_functions): Add __emutls_get_address
3618         and __emutls_register_common.
3619         * openmp.c (gfc_match_omp_threadprivate): Don't error if !have_tls.
3620         * trans-common.c (build_common_decl): Don't check have_tls.
3621         * trans-decl.c (gfc_finish_var_decl): Likewise.
3622         * types.def (BT_WORD, BT_FN_PTR_PTR): New.
3623         (BT_FN_VOID_PTR_WORD_WORD_PTR): New.
3624
3625 2007-02-09  Tobias Burnus  <burnus@net-b.de>
3626
3627         PR fortran/30512
3628         * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc,
3629           gfc_conv_intrinsic_minmaxval): Use HUGE-1 for most negative integer.
3630
3631 2007-02-09  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3632
3633         PR fortran/30720
3634         * trans-array.c (gfc_trans_create_temp_array): Remove use of the
3635         function argument. Always generate code for negative extent.
3636         Simplify said code.
3637         * trans-array.h (gfc_trans_create_temp_array): Change prototype.
3638         * trans-expr.c (gfc_conv_function_call): Remove use of last argument
3639         of gfc_trans_create_temp_array.
3640         * trans-intrinsic.c (gfc_conv_intrinsic_array_transfer): Likewise.
3641         * trans-stmt.c (gfc_conv_elemental_dependencies): Likewise.
3642
3643 2007-02-08  Roger Sayle  <roger@eyesopen.com>
3644
3645         * trans-stmt.c (gfc_trans_forall_1): Optimize the cases where the
3646         mask expression is a compile-time constant (".true." or ".false.").
3647
3648 2007-02-04  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3649
3650         PR fortran/30611
3651         * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Evaluate
3652         arguments only once. Generate check that NCOPIES argument is not
3653         negative.
3654
3655 2007-02-04  Steven G. Kargl <kargl@gcc.gnu.org>
3656
3657         PR fortran/30605
3658         * fortran/invoke.texi: Update documentation.
3659         * fortran/options.c (gfc_post_options): Deal with tabs with -std=f2003
3660         and -pedantic.
3661
3662 2007-02-03  Kazu Hirata  <kazu@codesourcery.com>
3663
3664         * trans-array.c: Fix a comment typo.
3665
3666 2007-02-03  Paul Thomas  <pault@gcc.gnu.org>
3667
3668         PR fortran/30514
3669         * array.c (match_array_element_spec): If the length of an array is
3670         negative, adjust the upper limit to make it zero length.
3671
3672         PR fortran/30660
3673         * resolve.c (pure_function, resolve_function): Initialize name to
3674         null to clear up build warnings.
3675         (resolve_fl_variable): Look at components explicitly to check for
3676         default initializer, rather than using gfc_default_initializer.
3677
3678 2007-02-02  Steven G. Kargl <kargl@gcc.gnu.org>
3679
3680         PR fortran/30683
3681         * resolve.c (resolve_generic_f): Check for non-NULL sym.
3682
3683 2007-02-02  Roger Sayle  <roger@eyesopen.com>
3684
3685         * trans.c (gfc_build_array_ref): Use STRIP_TYPE_NOPS to eliminate
3686         NON_LVALUE_EXPR nodes and useless type conversions.
3687
3688 2007-02-02  Paul Thomas  <pault@gcc.gnu.org>
3689
3690         PR fortran/30284
3691         PR fortran/30626
3692         * trans-expr.c (gfc_conv_aliased_arg): Remove static attribute
3693         from function and make sure that substring lengths are
3694         translated.
3695         (is_aliased_array): Remove static attribute.
3696         * trans.c : Add prototypes for gfc_conv_aliased_arg and
3697         is_aliased_array.
3698         * trans-io.c (set_internal_unit): Add the post block to the
3699         arguments of the function.  Use is_aliased_array to check if
3700         temporary is needed; if so call gfc_conv_aliased_arg.
3701         (build_dt): Pass the post block to set_internal_unit and
3702         add to the block after all io activiy is done.
3703
3704 2007-02-01  Roger Sayle  <roger@eyesopen.com>
3705
3706         * trans-array.c (gfc_conv_expr_descriptor): We don't need to use
3707         a temporary array to pass a constant non-character array constructor.
3708         Generalize the descriptor generation code to handle scalarizer
3709         "info" without an array reference.
3710
3711 2007-02-01  Roger Sayle  <roger@eyesopen.com>
3712
3713         * dependency.c (gfc_check_dependency) <EXPR_ARRAY>: Implement
3714         dependency checking for array constructors.
3715
3716 2007-02-01  Roger Sayle  <roger@eyesopen.com>
3717
3718         * trans-stmt.c (compute_overall_iter_number): Document function
3719         arguments.  Generalize "unconditional forall nest with constant
3720         bounds" optimization to eliminate unconditional inner loops with
3721         constant bounds.
3722
3723 2007-01-31  Tobias Burnus  <burnus@net-b.de>
3724
3725         PR fortran/30520
3726         * interface.c (compare_actual_formal): Check conformance between
3727           actual and VOLATILE dummy arguments.
3728         * symbol.c (gfc_add_volatile): Allow setting of VOLATILE
3729           multiple times in different scopes.
3730         * decl.c (gfc_match_volatile): Search symbol in host association.
3731
3732 2007-01-31  Kazu Hirata  <kazu@codesourcery.com>
3733
3734         * simplify.c, trans-array.c: Fix comment typos.
3735
3736 2007-01-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3737
3738         * invoke.texi (Code Gen Options): Fix abbreviation typo.
3739         * intrinsic.texi (ACCESS, LSHIFT, RSHIFT): Fix typos.
3740
3741 2007-01-30  Steve Ellcey  <sje@cup.hp.com>
3742
3743         PR fortran/30432
3744         * trans-types.c (gfc_get_function_type): Do not add void_type_node
3745         to empty arg list.
3746         * trans-decl.c (create_function_arglist): Change assert.
3747
3748 2007-01-29  Paul Thomas  <pault@gcc.gnu.org>
3749
3750         PR fortran/30554
3751         * module.c (read_module): If a symbol is excluded by an ONLY
3752         clause, check to see if there is a symtree already loaded. If
3753         so, attach the symtree to the pointer_info.
3754
3755 2007-01-28  Thomas Koenig  <Thomas.Koenig@online.de>
3756
3757         PR libfortran/30389
3758         * gfortran.h: Remove gfc_simplify_init_1.
3759         * arith.h: Remove third argument from gfc_compare_string.
3760         * arith.c (gfc_compare_expression): Remove third argument
3761         from call to gfc_compare_string.
3762         (gfc_compare_string): Remove third argument xcoll_table.
3763         Remove use of xcoll_table.
3764         * misc.c (gfc_init_1): Remove call to gfc_simplify_init_1.
3765         * simplify.c (ascii_table): Remove.
3766         (xascii_table): Likewise.
3767         (gfc_simplify_achar): ICE if extract_int fails.  Remove use of
3768         ascii_table.  Warn if -Wsurprising and value < 0 or > 127.
3769         (gfc_simplify_char): ICE if extract_int fails. Error if
3770         value < 0 or value > 255.
3771         (gfc_simplify_iachar): Remove use of xascii_table.
3772         Char values outside of 0..255 are an ICE.
3773         (gfc_simplify_lge): Remove use of xascii_table.
3774         (gfc_simplify_lgt): Likewise.
3775         (gfc_simplify_lle): Likewise.
3776         (gfc_simplify_llt): Likewise.
3777         (invert_table): Remove.
3778         (gfc_simplify_init_1): Remove.
3779
3780 2007-01-27  Roger Sayle  <roger@eyesopen.com>
3781
3782         * trans-stmt.c (forall_info): Replace the next_nest and outer
3783         fields that previously implemented a doubly-linked list with a
3784         single prev_nest field (singly-linked list).
3785         (gfc_trans_nested_forall_loop): The nested_forall_info argument
3786         now denotes the innermost FORALL in the loop nest.
3787         (compute_overall_iter_number): Use prev_nest instead of next_nest.
3788         (gfc_trans_forall_1): Link/cons the new "info" to the head of the
3789         nested_forall_info linked list.  Free the current "info" when done.
3790
3791 2007-01-27  Paul Thomas  <pault@gcc.gnu.org>
3792
3793         PR fortran/30407
3794         * trans-expr.c (gfc_conv_operator_assign): New function.
3795         * trans.h : Add prototype for gfc_conv_operator_assign.
3796         * trans-stmt.c (gfc_trans_where_assign): Add a gfc_symbol for
3797         a potential operator assignment subroutine.  If it is non-NULL
3798         call gfc_conv_operator_assign instead of the first assignment.
3799         ( gfc_trans_where_2): In the case of an operator assignment,
3800         extract the argument expressions from the code for the
3801         subroutine call and pass the symbol to gfc_trans_where_assign.
3802         resolve.c (resolve_where, gfc_resolve_where_code_in_forall,
3803         gfc_resolve_forall_body): Resolve the subroutine call for
3804         operator assignments.
3805
3806 2007-01-26  Steven Bosscher  <stevenb.gcc@gmail.com>
3807             Steven G. Kargl <kargl@gcc.gnu.org>
3808
3809         PR fortran/30278
3810         * fortran/io.c (next_char): Deal with backslash escaped characters.
3811         Issue warnings in non -std=gnu cases.
3812         * fortran/primary.c (next_string_char): Issue warnings in non
3813
3814 2007-01-26  Tobias Burnus  <burnus@net-b.de>
3815
3816         * lang-specs.h: Add support for .f03 and .F03 extensions.
3817         * gfortran.texi: Document .f03 extension.
3818         * options.c (form_from_filename): Recognize .f03.
3819
3820 2007-01-25  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
3821
3822         PR fortran/30437
3823         * lang.opt (Wall): Remove RejectNegative.
3824         * options.c (gfc_handle_option): Wall can be disabled.
3825         (set_Wall): Add a parameter for disabling Wall.
3826         
3827 2007-01-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3828
3829         PR fortran/30532
3830         * scanner.c (load_line): Remove check fot ctrl-z and don't gobble.
3831         
3832 2007-01-23  Paul Thomas  <pault@gcc.gnu.org>
3833
3834         PR fortran/30481
3835         * match.c (gfc_match_namelist): Add check for assumed size character
3836         in namelist and provide error if found.
3837
3838 2007-01-21  Brooks Moses  <brooks.moses@codesourcery.com>
3839
3840         * intrinsic.texi (ACHAR): Added cross-references.
3841         (CHAR): Put cross-references in alphabetical order.
3842         (IACHAR): Added cross-references.
3843         (ICHAR): Added cross-references.
3844
3845 2007-01-20  Brooks Moses  <brooks.moses@codesourcery.com>
3846
3847         * intrinsic.texi: Edited all "Syntax" examples to a consistent form.
3848         (MAXVAL): Corrected description of result characteristics.
3849         (MINVAL): Same.
3850         (UMASK): Added documentation.
3851
3852 2007-01-20  Steven G. Kargl  <kargl@gcc.gnu.org>
3853
3854         * openmp.c, matchexp.c, module.c, scanner.c, resolve.c, st.c,
3855         parse.c, primary.c, options.c, misc.c, simplify.c: Next installment
3856         in the massive whitespace patch.
3857
3858 2007-01-20  Roger Sayle  <roger@eyesopen.com>
3859
3860         * module.c (mio_array_ref): The dimen_type fields of an array ref
3861         are an enumerated type and can't be read/written directly with a
3862         call to mio_integer.  Instead loop over and cast each element.
3863
3864 2007-01-20  Roger Sayle  <roger@eyesopen.com>
3865
3866         * dependency.c (gfc_full_array_ref_p): Check that ref->next is NULL,
3867         i.e. that the ARRAY_REF doesn't mention components.
3868         * trans-array.c (gfc_constant_array_constructor_p): Export external
3869         function renamed from constant_array_constructor_p.
3870         (gfc_build_constant_array_constructor): Export.
3871         (gfc_trans_array_constructor): Update call to the renamed function
3872         constant_array_constructor_p.
3873         * trans-array.h (gfc_constant_array_constructor_p): Prototype here.
3874         (gfc_build_constant_array_constructor): Likewise.
3875         * trans-expr.c (gfc_build_memcpy_call): New helper function split
3876         out from gfc_trans_array_copy.
3877         (gfc_trans_array_copy): Use gfc_build_memcpy_call.
3878         (gfc_trans_array_constructor_copy): New function to optimize
3879         assigning an entire array from a constant array constructor.
3880         (gfc_trans_assignment): Call gfc_trans_array_constructor_copy
3881         when appropriate.
3882
3883 2007-01-20  Roger Sayle  <roger@eyesopen.com>
3884
3885         * trans-intrinsic.c (gfc_conv_intrinsic_sign): New branchless
3886         implementation for the SIGN intrinsic with integral operands.
3887         (gfc_conv_intrinsic_minmax): Fix whitespace.
3888
3889 2007-01-20  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3890
3891         * gfortran.h (gfc_options_t): Add flag_allow_leading_underscore.
3892         * lang.opt: Add -fallow-leading-underscore.
3893         * match.c (gfc_match_name): Allow leading underscore in symbol
3894         name if -fallow-leading-underscore is used.
3895         * symbol.c (gfc_get_default_type): Add special case for symbol
3896         names beginning with an underscore.
3897         * trans-decl.c (gfc_get_extern_function_decl,
3898         gfc_build_intrinsic_function_decls): Add _gfortran prefix to
3899         library symbols selected_int_kind, selected_real_kind and 
3900         all specifics.
3901         * options.c (gfc_init_options, gfc_handle_option): Handle the
3902         new -fallow-leading-underscore option.
3903
3904 2007-01-20  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3905
3906         PR fortran/30446
3907         * options.c (gfc_handle_module_path_options): Path used in -J
3908         option is now added to the module search path.
3909
3910 2007-01-20  Richard Guenther  <rguenther@suse.de>
3911
3912         PR fortran/30223
3913         * f95-lang.c (gfc_init_builtin_functions): Provide cbrt and
3914         cexpi builtins if we have TARGET_C99_FUNCTIONS.  Provide
3915         sincos builtins if the target has sincos.
3916
3917 2007-01-19  Brooks Moses  <brooks.moses@codesourcery.com>
3918
3919         * intrinsic.texi (MATMUL): Corrected a typo.
3920         (MAX): Separated @var arguments.
3921         (MIN): Separated @var arguments.
3922
3923 2007-01-19  Brooks Moses  <brooks.moses@codesourcery.com>
3924
3925         * intrinsic.texi: general whitespace cleanup.
3926         (menu): Added TIME8, removed UNMASK.
3927         (AINT): Clarified argument requirement.
3928         (ANINT): Clarified argument requirement.
3929         (CEILING): Clarified argument requirement.
3930         (CHAR): Clarified argument requirement.
3931         (CMPLX): Clarified argument requirement.
3932         (DCMPLX): Clarified argument requirement.
3933         (FGET): Line rewrapping.
3934         (FLOOR): Clarified argument requirement.
3935         (GMTIME): Added documentation.
3936         (IAND): Added cross-reference.
3937         (IBCLR): Added cross-reference.
3938         (IBSET): Added cross-reference.
3939         (IEOR): Added cross-reference.
3940         (INT): Collapsed examples, clarified argument requirement.
3941         (IOR): Added cross-references.
3942         (LEN_TRIM): Corrected result kind.
3943         (LINK): Added cross-reference.
3944         (LLT): Removed "documentation pending".
3945         (LOGICAL): Added documentation.
3946         (LSHIFT): Added documentation.
3947         (LTIME): Added documentation.
3948         (MATMUL): Added documentation.
3949         (MAX): Added documentation.
3950         (MAXLOC): Added documentation.
3951         (MAXVAL): Added documentation.
3952         (MERGE): Added documentation.
3953         (MIN): Added documentation.
3954         (MINLOC): Added documentation.
3955         (MINVAL): Added documentation.
3956         (MVBITS): Moved to correct place, added documentation.
3957         (NOT): Added documentation.
3958         (PERROR): Added documentation.
3959         (RAN): Moved to correct place, added documentation.
3960         (REAL): Clarified argument requirement.
3961         (RENAME): Added documentation.
3962         (RSHIFT): Clarified argument requirement.
3963         (SIGN): Corrected table specification.
3964         (SYMLNK): Added documentation.
3965         (SYSTEM): Added documentation.
3966         (TIME): Added documentation.
3967         (TIME8): Added section and documentation.
3968         (UNMASK): Removed erroneous section.
3969
3970 2007-01-18  H.J. Lu  <hongjiu.lu@intel.com>
3971
3972         * trans-stmt.c (compute_overall_iter_number): Fix a typo.
3973
3974 2007-01-18  Roger Sayle  <roger@eyesopen.com>
3975
3976         * trans-expr.c (copyable_array_p): Consider user derived types without
3977         allocatable components to be copyable.
3978
3979 2007-01-18  Roger Sayle  <roger@eyesopen.com>
3980
3981         * trans-stmt.c (compute_overall_iter_number): Enhance to precompute
3982         the number of interations in unconditional FORALL nests with constant
3983         bounds.
3984
3985 2007-01-18  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3986             Tobias Burnus  <burnus@net-b.de>
3987
3988         PR libfortran/29649
3989         * gfortran.h (gfc_option_t): Add flag_dump_core.
3990         * lang.opt: Add -fdump-core option.
3991         * invoke.texi: Document the new options.
3992         * trans-decl.c (gfc_build_builtin_function_decls): Add new
3993           options to the call to set_std.
3994         * options.c (gfc_init_options, gfc_handle_option): Set the
3995           new options.
3996
3997 2007-01-17  Paul Thomas  <pault@gcc.gnu.org>
3998
3999         PR fortran/30476
4000         * module.c (load_generic_interfaces): Make the marking of the
4001         symbol as ambiguous conditional on the module names being
4002         different.
4003         (write_generic): Ensure that the generic interface has a
4004         non-NULL module field.
4005
4006 2007-01-16  Roger Sayle  <roger@eyesopen.com>
4007
4008         PR fortran/30404
4009         * trans-stmt.c (forall_info): Remove pmask field.
4010         (gfc_trans_forall_loop): Remove NVAR argument, instead assume that
4011         NVAR covers all the interation variables in the current forall_info.
4012         Add an extra OUTER parameter, which specified the loop header in
4013         which to place mask index initializations.
4014         (gfc_trans_nested_forall_loop): Remove NEST_FLAG argument.
4015         Change the semantics of MASK_FLAG to only control the mask in the
4016         innermost loop.
4017         (compute_overall_iter_number): Optimize the trivial case of a
4018         top-level loop having a constant number of iterations.  Update
4019         call to gfc_trans_nested_forall_loop.  Calculate the number of
4020         times the inner loop will be executed, not to size of the 
4021         iteration space.
4022         (allocate_temp_for_forall_nest_1): Reuse SIZE as BYTESIZE when
4023         sizeof(type) == 1.  Tidy up.
4024         (gfc_trans_assign_need_temp): Remove NEST_FLAG argument from calls
4025         to gfc_trans_nested_forall_loop.
4026         (gfc_trans_pointer_assign_need_temp): Likewise.
4027         (gfc_trans_forall_1): Remove unused BYTESIZE, TMPVAR, SIZEVAR and
4028         LENVAR local variables.  Split mask allocation into a separate
4029         hunk/pass from mask population.  Use allocate_temp_for_forall_nest
4030         to allocate the FORALL mask with the correct size.  Update calls
4031         to gfc_trans_nested_forall_loop.
4032         (gfc_evaluate_where_mask): Update call to
4033         gfc_trans_nested_forall_loop.
4034         (gfc_trans_where_2): Likewise.
4035
4036 2007-01-15  Paul Thomas  <pault@gcc.gnu.org>
4037
4038         PR fortran/28172
4039         * trans-stmt.c (gfc_trans_call): If it does not have one, get
4040         a backend_decl for an alternate return.
4041
4042         PR fortran/29389
4043         * resolve.c (pure_function): Statement functions are pure. Note
4044         that this will have to recurse to comply fully with F95.
4045
4046         PR fortran/29712
4047         * resolve.c (resolve_function): Only a reference to the final
4048         dimension of an assumed size array is an error in an inquiry
4049         function.
4050
4051         PR fortran/30283
4052         * resolve.c (resolve_function): Make sure that the function
4053         expression has a type.
4054
4055 2007-01-14  Paul Thomas  <pault@gcc.gnu.org>
4056
4057         PR fortran/30410
4058         * trans-decl.c (gfc_sym_mangled_function_id): Module, external
4059         symbols must not have the module name prepended.
4060
4061 2007-01-11  Thomas Koenig  <Thomas.Koenig@online.de>
4062
4063         PR libfortran/30415
4064         * iresolve.c (gfc_resolve_maxloc): If the rank
4065         of the return array is nonzero and we process an
4066         integer array smaller than default kind, coerce
4067         the array to default integer.
4068         * iresolve.c (gfc_resolve_minloc): Likewise.
4069
4070 2007-01-11  Brooks Moses  <brooks.moses@codesourcery.com>
4071
4072         * simplify.c: Update copyright to 2007.
4073         * scanner.c: Same.
4074
4075 2007-01-11  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
4076
4077         PR fortran/30430
4078         * scanner.c (gfc_release_include_path): Free gfc_option.module_dir
4079         only once!
4080
4081 2007-01-09  Brooks Moses  <brooks.moses@codesourcery.com>
4082
4083         * simplify.c (gfc_simplify_ibclr): Fix POS comparison.
4084         (gfc_simplify_ibset): Same.
4085
4086 2007-01-09  Brooks Moses  <brooks.moses@codesourcery.com>
4087
4088         PR 30381
4089         PR 30420
4090         * simplify.c (convert_mpz_to_unsigned): New function.
4091         (convert_mpz_to_signed): New function, largely based on
4092         twos_complement().
4093         (twos_complement): Removed.
4094         (gfc_simplify_ibclr): Add conversions to and from an
4095         unsigned representation before bit-twiddling.
4096         (gfc_simplify_ibset): Same.
4097         (gfc_simplify_ishftc): Add checks for overly large
4098         constant arguments, only check the third argument if
4099         it's present, carry over high bits into the result as
4100         appropriate, and perform the final conversion back to
4101         a signed representation using the correct sign bit.
4102         (gfc_simplify_not): Removed unnecessary masking.
4103
4104 2007-01-09  Paul Thomas  <pault@gcc.gnu.org>
4105
4106         PR fortran/30408
4107         * resolve.c (resolve_code): Use the code->expr character length
4108         directly to set length of llen.
4109
4110 2007-01-09  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
4111
4112         PR fortran/30408
4113         * lang.opt: Add Wcharacter_truncation option.
4114         * options.c (gfc_init_options): Initialize
4115         gfc_option.warn_character_truncation to zero.
4116         (gfc_handle_option): Add case for OPT_Wcharacter_truncation.
4117
4118 2007-01-08  Steven G. Kargl  <kargl@gcc.gnu.org>
4119
4120         * interface.c, intrinsic.c, gfortranspec.c, io.c, f95-lang.c,
4121         iresolve.c, match.c: Update Copyright years.  Whitespace.
4122
4123 2007-01-08  Richard Guenther  <rguenther@suse.de>
4124
4125         * trans-io.c (transfer_array_desc): Use build_int_cst instead
4126         of build_int_cstu.
4127
4128 2007-01-08  Roger Sayle  <roger@eyesopen.com>
4129
4130         * trans-array.c (constant_array_constructor_p): New function to
4131         determine whether an array constructor consists only of constant
4132         elements, and if so return it's size.
4133         (gfc_build_constant_array_constructor): Construct a statically
4134         initialized gfortran array for a given EXPR_ARRAY.
4135         (gfc_trans_constant_array_constructor): Efficiently scalarize
4136         a constant array constructor.
4137         (gfc_trans_array_constructor): Tidy up use of CONST_STRING.
4138         Special case scalarization of constant array constructors, all of
4139         whose elements are specified, using constant_array_constructor_p 
4140         and gfc_trans_constant_array_constructor.
4141         (gfc_conv_scalarized_array_ref): Check whetger info->offset is zero
4142         before adding it to index, to avoid creating a NON_LVALUE_EXPR.
4143
4144 2007-01-08  Kazu Hirata  <kazu@codesourcery.com>
4145
4146         gfortran.texi: Fix typos.
4147
4148 2007-01-07  Steven G. Kargl  <kargl@gcc.gnu.org>
4149
4150         * decl.c, dump-parse-tree.c, error.c, data.c, expr.c, dependency.c,
4151         convert.c: Update Copyright dates.  Fix whitespace.
4152
4153 2007-01-07  Bernhard Fischer  <aldot@gcc.gnu.org>
4154
4155         * data.c (gfc_assign_data_value): Fix whitespace.
4156
4157 2007-01-07  Bernhard Fischer  <aldot@gcc.gnu.org>
4158
4159         * trans-array.c (gfc_trans_create_temp_array, gfc_array_init_size):
4160         Commentary typo fix.
4161
4162 2007-01-07  Bernhard Fischer  <aldot@gcc.gnu.org>
4163
4164         PR fortran/27698
4165         * match.c (gfc_match_name): Print diagnostics for invalid
4166         character in names.
4167
4168 2007-01-06  Steven G. Kargl  <kargl@gcc.gnu.org>
4169
4170         * array.c: Fix whitespace in comment table.
4171
4172 2007-01-06  Steven G. Kargl  <kargl@gcc.gnu.org>
4173
4174         * array.c, bbt.c, check.c: Update copyright years.  Whitespace.
4175
4176 2007-01-06  Steven G. Kargl  <kargl@gcc.gnu.org>
4177
4178         * arith.c: Update copyright years.  Whitespace.
4179
4180 2007-01-05  Roger Sayle  <roger@eyesopen.com>
4181
4182         * trans-expr.c (gfc_trans_assignment_1): New subroutine to scalarize
4183         array assignments split out from gfc_trans_assignment.
4184         (gfc_trans_array_copy): New function to implement array to array
4185         copies via calls to __builtin_memcpy.
4186         (copyable_array_p): New helper function to identify an array of
4187         simple/POD types, that may be copied/assigned using memcpy.
4188         (gfc_trans_assignment): Use gfc_trans_array_copy to handle simple
4189         whole array assignments considered suitable by copyable_array_p.
4190         Invoke gfc_trans_assignment_1 to perform the fallback scalarization.
4191
4192 2007-01-05  Roger Sayle  <roger@eyesopen.com>
4193
4194         * trans-array.c (gfc_trans_array_constructor_value): Make the
4195         static const "data" array as TREE_READONLY.
4196         * trans-stmt.c (gfc_trans_character_select): Likewise.
4197
4198 2007-01-05  Roger Sayle  <roger@eyesopen.com>
4199
4200         * trans-array.c (gfc_conv_loop_setup): Test whether the loop
4201         stride is one, to avoid fold_build2 introducing a useless
4202         NON_LVALUE_EXPR node.
4203
4204 2007-01-05  Tobias Burnus  <burnus@net-b.de>
4205
4206         * symbol.c (check_conflict): Fix error message.
4207
4208 2007-01-05  Paul Thomas  <pault@gcc.gnu.org>
4209
4210         PR fortran/23232
4211         * decl.c (gfc_in_match_data, gfc_set_in_match_data): New
4212         functions to signal that a DATA statement is being matched.
4213         (gfc_match_data): Call gfc_set_in_match_data on entry and on
4214         exit.
4215         * gfortran.h : Add prototypes for above.
4216         * expr.c (check_init_expr): Avoid check on parameter or
4217         variable if gfc_in_match_data is true.
4218         (gfc_match_init_expr): Do not call error on non-reduction of
4219         expression if gfc_in_match_data is true.
4220
4221         PR fortran/27996
4222         PR fortran/27998
4223         * decl.c (gfc_set_constant_character_len): Add boolean arg to
4224         flag array constructor resolution.  Warn if string is being
4225         truncated.  Standard dependent error if string is padded. Set
4226         new arg to false for all three calls to
4227         gfc_set_constant_character_len.
4228         * match.h : Add boolean arg to prototype for
4229         gfc_set_constant_character_len.
4230         * gfortran.h : Add warn_character_truncation to gfc_options.
4231         * options.c (set_Wall): Set warn_character_truncation if -Wall
4232         is set.
4233         * resolve.c (resolve_code): Warn if rhs string in character
4234         assignment has to be truncated.
4235         * array.c (gfc_resolve_character_array_constructor): Set new
4236         argument to true for call to gfc_set_constant_character_len.
4237
4238 2007-01-05  Tobias Burnus  <burnus@net-b.de>
4239
4240         PR fortran/29624
4241         * interface.c (compare_parameter_intent): New function.
4242           (check_intents): Support pointer intents.
4243         * symbol.c (check_conflict): Support pointer intents,
4244           better conflict_std message.
4245         * expr.c (gfc_check_assign,gfc_check_pointer_assign):
4246           Support pointer intents.
4247         * resolve.c (resolve_deallocate_expr,resolve_allocate_expr):
4248           Support pointer intents.
4249
4250 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4251
4252         PR 30371
4253         * check.c (gfc_check_kill_sub): Add checks for non-scalar
4254         arguments.
4255
4256 2007-01-04  Brooks Moses  <brooks.moses@codesourcery.com>
4257
4258         * intrinsic.texi: Minor cleanup, reflowing overlong
4259         paragraphs, and correcting whitespace.
4260
4261 2007-01-04  Brooks Moses  <brooks.moses@codesourcery.com>
4262
4263         * intrinsic.texi (LBOUND): Add documentation.
4264         (LGE): Add documentation.
4265         (LGT): Add documentation.
4266         (LINK): Add documentation.
4267         (LLE): Add documentation.
4268         (LLT): Add documentation.
4269         (LNBLNK): Add documentation.
4270         (UBOUND): Add documentation.
4271         (UNLINK): Add documentation.
4272
4273 2007-01-04  Brooks Moses  <brooks.moses@codesourcery.com>
4274
4275         * intrinsic.texi (IAND): Clarify argument specifications.
4276         (IBCLR): Add documentation.
4277         (IBITS): Add documentation.
4278         (IBSET): Add documentation.
4279         (IEOR): Add documentation.
4280         (IERRNO): Add documentation.
4281         (INDEX): Add documentation.
4282         (IOR): Add documentation.
4283         (ISHFT): Add documentation.
4284         (ISHFTC): Add documentation.
4285         (KILL): Add documentation.
4286         (LEN_TRIM): Add documentation.
4287
4288 2007-01-04  Brooks Moses  <brooks.moses@codesourcery.com>
4289
4290         PR 30235
4291         * interface.c (compare_actual_formal): check for
4292         alternate returns when iterating over non-present
4293         arguments.
4294
4295 2007-01-04  Brooks Moses  <brooks.moses@codesourcery.com>
4296
4297         * invoke.texi: Update manpage copyright to include 2007.
4298
4299 2007-01-04  Brooks Moses  <brooks.moses@codesourcery.com>
4300
4301         * gfortran.texi: Update copyright to include 2007.
4302         * intrinsic.texi: Update copyright to include 2007.
4303         * invoke.texi: Update copyright to include 2007.
4304
4305 2007-01-02  Tobias Burnus  <burnus@net-b.de>
4306             Jakub Jelinek  <jakub@redhat.com>
4307
4308         PR fortran/30276
4309         * scanner.c (open_included_file): Revert patch.
4310           (gfc_open_included_file): Support absolute pathnames.
4311           (gfc_open_intrinsic_module): Support absolute pathnames.
4312
4313 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4314
4315         * gfortran.texi (GNU Fortran and GCC): Rewrite
4316
4317 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4318
4319         * gfortran.texi (Introduction): Lower "Part I:
4320         Introduction" to a chapter, renumber Parts II and III to
4321         Parts I and II.
4322         * intrinsic.texi (Introduction): Rename to "Introduction
4323         to Intrinsics" to avoid conflict with the new chapter.
4324
4325 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4326
4327         * intrinsic.texi (Introduction): Rewrite first paragraph.
4328
4329 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4330
4331         * invoke.texi (OpenMP): Added index entry.
4332         * gfortran.texi (title page): Removed erroneous '*'.
4333
4334 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4335
4336         * gfortran.texi (GFORTRAN_DEFAULT_RECL): Added units
4337         to description.
4338         (Extensions): Miscellaneous minor rewriting and copyediting.
4339         (BOZ-literal constants): Renamed from Hexadecimal constants.
4340         (Hollerith constants support): Added explanation and 
4341         suggestions for standard-conforming modern equivalents.
4342
4343 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4344
4345         * intrinsic.texi: Improvements to index entries; change
4346         @findex entries to @cindex entries.
4347         * invoke.texi: Standardize and improve index entries.
4348         * gfortran.texi: Fix @code in one index entry.
4349
4350 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4351
4352         * invoke.texi: Change @code-type macros to appropriate
4353         variants (@command, @option, etc.)
4354         * gfortran.texi: Same.
4355
4356 2007-01-03  Brooks Moses  <brooks.moses@codesourcery.com>
4357
4358         * intrinsic.texi: Various minor cleanups.
4359
4360 2007-01-02  Steven G. Kargl  <kargls@comcast.net>
4361
4362         * trans-intrinsic.c (gfc_conv_intrinsic_ibits): Fix call to
4363         build_int_cst.
4364
4365 2007-01-02  Tobias Burnus  <burnus@net-b.de>
4366
4367         PR fortran/30276
4368         * scanner.c (open_included_file): Support full-path filenames.
4369
4370 2007-01-02  Paul Thomas  <pault@gcc.gnu.org>
4371
4372         PR fortran/20896
4373         * interface.c (check_sym_interfaces): Remove call to
4374         resolve_global_procedure.
4375         gfortran.h : Remove prototype for resolve_global_procedure.
4376         resolve.c (resolve_global_procedure): Add static attribute
4377         to function declaration.
4378
4379 2007-01-01  Steven G. Kargl  <kargls@comcast.net>
4380
4381         * ChangeLog: Copy to ...
4382         * ChangeLog-2006: here.