OSDN Git Service

2006-12-03 Paul Thomas <pault@gcc.gnu.org>
[pf3gnuchains/gcc-fork.git] / gcc / fortran / ChangeLog
1 2006-12-03  Paul Thomas  <pault@gcc.gnu.org>
2
3         PR fortran/29642
4         * trans-expr.c (gfc_conv_variable): A character expression with
5         the VALUE attribute needs an address expression; otherwise all
6         other expressions with this attribute must not be dereferenced.
7         (gfc_conv_function_call): Pass expressions with the VALUE
8         attribute by value, using gfc_conv_expr.
9         * symbol.c (check_conflict): Add strings for INTENT OUT, INOUT
10         and VALUE.  Apply all the constraints associated with the VALUE
11         attribute.
12         (gfc_add_value): New function.
13         (gfc_copy_attr): Call it for VALUE attribute.
14         * decl.c (match_attr_spec): Include the VALUE attribute.
15         (gfc_match_value): New function.
16         * dump-parse-tree.c (gfc_show_attr): Include VALUE.
17         * gfortran.h : Add value to the symbol_attribute structure and
18         add a prototype for gfc_add_value
19         * module.c (mio_internal_string): Include AB_VALUE in enum.
20         (attr_bits): Provide the VALUE string for it.
21         (mio_symbol_attribute): Read or apply the VLUE attribute.
22         * trans-types.c (gfc_sym_type): Variables with the VLAUE
23         attribute are not passed by reference!
24         * resolve.c (was_declared): Add value to those that return 1.
25         (resolve_symbol): Value attribute requires dummy attribute.
26         * match.h : Add prototype for gfc_match_public.
27         * parse.c (decode_statement): Try to match a VALUE statement.
28
29 2006-12-01  Thomas Koenig  <Thomas.Koenig@online.de>
30
31         PR libfortran/29568
32         * gfortran.h (gfc_option_t):  Add max_subrecord_length.
33         (top level): Define MAX_SUBRECORD_LENGTH.
34         * lang.opt:  Add option -fmax-subrecord-length=.
35         * trans-decl.c:  Add new function set_max_subrecord_length.
36         (gfc_generate_function_code): If we are within the main
37         program and max_subrecord_length has been set, call
38         set_max_subrecord_length.
39         * options.c (gfc_init_options):  Add defaults for
40         max_subrecord_lenght, convert and record_marker.
41         (gfc_handle_option):  Add handling for
42         -fmax_subrecord_length.
43         * invoke.texi:  Document the new default for
44         -frecord-marker=<n>.
45
46 2006-11-28  Paul Thomas  <pault@gcc.gnu.org>
47
48         PR fortran/29976
49         * trans-expr.c (gfc_conv_missing_dummy): Remove build_int_const
50         and replace with cast to type of se->expr of integer_zero_node.
51
52 2006-11-28  Paul Thomas  <pault@gcc.gnu.org>
53
54         PR fortran/20880
55         * resolve.c (resolve_fl_procedure): Error if procedure is
56         ambiguous modified to require attr.referenced.
57
58 2006-11-26  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
59
60         PR fortran/29892
61         * trans-intrinsic.c (gfc_conv_intrinsic_bound): Use a locus in
62         the call to gfc_trans_runtime_check.
63         * trans-array.c (gfc_trans_array_bound_check): Try harder to find
64         the variable or function name for the runtime error message.
65         (gfc_trans_dummy_array_bias): Use a locus in the call to
66         gfc_trans_runtime_check
67
68 2006-11-26  Andrew Pinski  <pinskia@gmail.com>
69
70         * trans-decl.c (gfc_build_intrinsic_function_decls): Mark the
71         pow functions as constant functions.
72
73 2006-11-25  Andrew Pinski  <pinskia@gmail.com>
74
75         PR fortran/29982
76         * trans-expr.c (gfc_conv_expr_reference): Strip off NOP_EXPRs.
77
78 2006-11-25  Andrew Pinski  <pinskia@gmail.com>
79
80         PR fortran/29951
81         * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Change to
82         call memcpy instead of creating a VIEW_CONVERT_EXRP.
83
84 2006-11-25  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
85
86         PR fortran/29711
87         * error.c (error_print): Handle printf-style position specifiers,
88         of the form "%3$d".
89
90 2006-11-24  Paul Thomas  <pault@gcc.gnu.org>
91
92         PR fortran/20880
93         * parse.c (parse_interface): Error if procedure name is that of
94         encompassing scope.
95         * resolve.c (resolve_fl_procedure): Error if procedure is
96         ambiguous.
97
98         PR fortran/29387
99         * interface.c (compare_actual_formal): Add missing condition
100         that 'where' be present for error that asserts that actual
101         arguments be definable.
102
103 2006-11-24  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
104
105         * resolve.c (resolve_actual_arglist): Remove the special case for
106         CHAR.
107         * intrinsic.c (add_functions): Remove the special case for CHAR.
108
109 2006-11-22  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
110
111         PR fortran/29441
112         * intrinsic.c (gfc_intrinsic_func_interface): Always check if
113         intrinsic is allowed in initialization expression.
114
115 2006-11-22  Paul Thomas  <pault@gcc.gnu.org>
116
117         PR fortran/25087
118         * resolve.c (resolve_fl_procedure): Add an error if an external
119         automatic character length function does not have an explicit
120         interface.
121
122 2006-11-22  Paul Thomas  <pault@gcc.gnu.org>
123
124         PR fortran/29652
125         * interface.c (check_interface1): Use a local value, instead of
126         the dummy, as the inner iterator over interface symbols.
127
128 2006-11-21  Paul Thomas  <pault@gcc.gnu.org>
129
130         PR fortran/29820
131         * trans-array.c (gfc_get_derived_type): Once done, spread the
132         backend_decl to all identical derived types in all sibling
133         namespaces.
134
135 2006-11-20  Tobias Burnus  <burnus@net-b.de>
136
137         PR fortran/27546
138         * primary.c (gfc_match_rvalue): Added IMPORT support.
139
140 2006-11-20  Tobias Burnus  <burnus@net-b.de>
141
142         * symbol.c (check_conflict): Add conflict between VOLATILE
143           attribute and program name.
144
145 2006-11-20  Bernhard Fischer  <aldot@gcc.gnu.org>
146
147         PR fortran/24783
148         * resolve.c (resolve_variable): Get the implicit type from the
149         symbols namespace rather than the default namespace. Fix whitespace.
150         (resolve_formal_arglist, resolve_equivalence): Fix typo.
151
152 2006-11-19  Erik Edelmann  <eedelman@gcc.gnu.org>
153
154         * resolve.c (resolve_ref): Check for ALLOCATABLEs to the right of
155           nonzero rank part references too.
156
157 2006-11-19  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
158
159         * module.c (gfc_use_module): Uncomment the ISO_FORTRAN_ENV code.
160         Check that intrinsic and non-intrinsic modules don't conflict.
161         (use_iso_fortran_env_module): New function.
162         (create_int_parameter): New function.
163         * trans-types.c (gfc_init_kinds): Choose values for
164         gfc_numeric_storage_size and gfc_character_storage_size.
165         (gfc_numeric_storage_size, gfc_character_storage_size): New variables.
166         * resolve.c (resolve_symbol): Do no check intrinsic modules
167         against the list of intrinsic symbols.
168         * iso-fortran-env.def: New file.
169         * gfortran.h (gfc_numeric_storage_size,
170         gfc_character_storage_size): Add prototypes.
171
172 2006-11-18  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
173
174         PR fortran/24285
175         * io.c (check_format): Allow dollars everywhere in format, and
176         issue a warning.
177
178 2006-11-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
179
180         * gfortran.h (gfc_add_intrinsic_modules_path,
181         gfc_open_intrinsic_module): New prototypes.
182         (gfc_add_include_path, gfc_open_included_file): Update prototypes.
183         * lang.opt: Add -fintrinsic-modules-path option.
184         * module.c (gfc_match_use): Match the Fortran 2003 form of
185         USE statement.
186         (gfc_use_module): Also handle intrinsic modules. 
187         * scanner.c (gfc_directorylist): Add use_for_modules for field.
188         (intrinsic_modules_dirs): New static variable.
189         (add_path_to_list, gfc_add_intrinsic_modules_path): New functions.
190         (gfc_add_include_path): Use the new add_path_to_list helper
191         function.
192         (gfc_release_include_path): Free memory for intrinsic_modules_dirs.
193         (open_included_file, gfc_open_intrinsic_module): New functions.
194         (gfc_open_included_file): Use the new open_included_file
195         helper function.
196         * lang-specs.h: Use the new -fintrinsic-modules-path option.
197         * parse.c (decode_statement): Do not match the required space
198         after USE here.
199         * options.c (gfc_handle_option): Handle the new option. Use new
200         prototype for gfc_add_include_path.
201         (gfc_post_options): Use new prototype for gfc_add_include_path.
202
203 2006-11-16  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
204
205         PR fortran/29391
206         PR fortran/29489
207         * simplify.c (simplify_bound): Fix the simplification of
208         LBOUND/UBOUND intrinsics.
209         * trans-intrinsic.c (simplify_bound): Fix the logic, and
210         remove an erroneous assert.
211
212 2006-11-16  Francois-Xavier Coudert  <fxcoudert@gcc.gnu,org>
213
214         * trans-decl.c (gfc_get_symbol_decl): Fix formatting.
215
216 2006-11-15  Brooks Moses  <brooks.moses@codesourcery.com>
217
218         * data.c: Remove trailing periods from error messages.
219         * decl.c: Likewise.
220         * expr.c: Likewise.
221         * io.c: Likewise.
222         * match.c: Likewise.
223         * module.c: Likewise.
224         * options.c: Likewise.
225         * resolve.c: Likewise.
226         * symbol.c: Likewise.
227         * trans-io.c: Likewise.
228
229 2006-11-15  Brooks Moses  <brooks.moses@codesourcery.com>
230
231         * lang.opt: Rearrange entries back into ASCII order.
232
233 2006-11-15  Tobias Burnus  <burnus@net-b.de>
234
235         * parse.c (parse_contained): Fix indention
236           of one line.
237
238 2006-11-15  Tobias Burnus  <burnus@net-b.de>
239
240         PR fortran/27546
241         * decl.c (gfc_match_import,variable_decl):
242           Add IMPORT support.
243           (gfc_match_kind_spec): Fix typo in gfc_error.
244         * gfortran.h (gfc_namespace, gfc_statement):
245           Add IMPORT support.
246         * parse.c (decode_statement,gfc_ascii_statement,
247           verify_st_order): Add IMPORT support.
248         * match.h: Add gfc_match_import.
249         * gfortran.texi: Add IMPORT to the supported
250           Fortran 2003 features.
251
252 2006-11-15  Tobias Burnus  <burnus@net-b.de>
253             Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
254
255         PR fortran/27588
256         * trans-expr.c (gfc_conv_substring): Add bounds checking.
257           (gfc_conv_variable, gfc_conv_substring_expr): Pass more
258           arguments to gfc_conv_substring.
259
260 2006-11-15  Tobias Burnus  <burnus@net-b.de>
261
262         PR fortran/29806
263         * parse.c (parse_contained): Check for empty contains statement.
264
265 2006-11-15  Bud Davis <bdavis9659@sbcglobal.net>
266
267         PR fortran/28974
268         * gfortran.h (gfc_expr): Add element which holds a splay-tree
269         for the exclusive purpose of quick access to a constructor by
270         offset.
271         * data.c (find_con_by_offset): Use the splay tree for the search.
272         (gfc_assign_data_value): Use the splay tree.
273         (gfc_assign_data_value_range): ditto.
274         * expr.c (gfc_get_expr): Initialize new element to null.
275         (gfc_free_expr): Delete splay tree when deleting gfc_expr.
276
277 2006-11-14  Brooks Moses  <brooks.moses@codesourcery.com>
278
279         PR fortran/29702
280         * error.c (show_loci): Move column-offset calculation to
281         show_locus.
282         (show_locus): Remove blank lines before "Included in"
283         lines, clean up code, calculate column-offsets, print
284         column number is error-header lines as appropriate.
285         (error_integer): (new function) Print integer to error
286         buffer.
287         (error_print): Use error_integer, avoid possible buffer
288         overflows from buggy error formats.
289
290 2006-11-14  Brooks Moses  <brooks.moses@codesourcery.com>
291  
292         * gfortran.h (GFC_MAX_LINE): Remove constant definition.
293         (gfc_option_t): Clarify comments.
294         * options.c: Set default line length limits to actual default
295         values, rather than flag values.
296         * scanner.c: Eliminate checking and handling of the
297         fixed/free_line_length flag values.
298
299 2006-11-14  Brooks Moses  <brooks.moses@codesourcery.com>
300  
301         * lang.opt: Remove -fno-backend option.
302         * gfortran.h (gfc_option_t): Remove flag_no_backend.
303         * options.c (gfc_init_options): Remove flag_no_backend.
304         (gfc_handle_option): Remove -fno-backend option handler.
305         * parse.c (gfc_parse_file): Remove references to
306         gfc_option.flag_no_backend.
307
308 2006-11-14  Tobias Burnus  <burnus@net-b.de>
309
310         * match.c (gfc_match_namelist): Add missing space to
311           error message.
312
313 2006-11-14  Tobias Burnus  <burnus@net-b.de>
314
315         PR fortran/29657
316         * symbol.c (check_conflict): Add further conflicts.
317
318 2006-11-13  Jakub Jelinek  <jakub@redhat.com>
319
320         PR fortran/29759
321         * fortran/scanner.c (skip_free_comments): Clear openmp_flag
322         before returning true.
323
324 2006-11-12  Andrew Pinski  <andrew_pinski@playstation.sony.com>
325
326         PR fortran/26994
327         * trans-expr.c (gfc_conv_expr_reference): Set TREE_STATIC on the
328         new CONST_DECL.
329
330 2006-11-11  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
331
332         * array.c: Add 2006 to copyright years.
333         * data.c: Same.
334         * interface.c: Same.
335         * misc.c: Same.
336         * trans-io.c: Same.
337
338 2006-11-11  Richard Guenther  <rguenther@suse.de>
339
340         * trans-intrinsic.c (enum rounding_mode): New enum.
341         (build_fix_expr, gfc_conv_intrinsic_aint, gfc_conv_intrinsic_mod,
342         gfc_conv_intrinsic_function): Use it instead of FIX_CEIL_EXPR,
343         FIX_FLOOR_EXPR, FIX_ROUND_EXPR and FIX_TRUNC_EXPR.
344
345 2006-11-10  Brooks Moses  <brooks.moses@codesourcery.com>
346
347         * lang.opt (-fmodule-private): Remove option.
348         * gfortran.h (gfc_option_t): Remove module_access_private flag.
349         * options.c (gfc_init_options): Remove initialization for it.
350         (gfc_handle_option): Remove handling for -fmodule-private.
351         * module.c (gfc_check_access): Add comments, remove check for
352         gfc_option.flag_module_access_private.
353
354 2006-11-10 Paul Thomas <pault@gcc.gnu.org>
355
356         PR fortran/29758
357         * check.c (gfc_check_reshape): Check that there are enough
358         elements in the source array as to be able to fill an array
359         defined by shape, when pad is absent.
360
361 2006-11-10 Paul Thomas <pault@gcc.gnu.org>
362
363         PR fortran/29315
364         * trans-expr.c (is_aliased_array): Treat correctly the case where the
365         component is itself and array or array reference.
366
367 2006-11-09  Brooks Moses  <brooks.moses@codesourcery.com>
368
369         * check.c (same_type_check): Typo fix in comment.
370
371 2006-11-09 Paul Thomas <pault@gcc.gnu.org>
372
373         PR fortran/29431
374         * trans-array.c    (get_array_ctor_strlen): If we fall through to
375         default, use a constant character length if it is available.
376
377 2006-11-09 Paul Thomas <pault@gcc.gnu.org>
378
379         PR fortran/29744
380         * trans-types.c (gfc_get_derived_type): Ensure that the
381         proc_name namespace is not the same as the owner namespace and
382         that identical derived types in the same namespace share the
383         same backend_decl.
384
385 2006-11-09 Paul Thomas <pault@gcc.gnu.org>
386
387         PR fortran/29699
388         * trans-array.c (structure_alloc_comps): Detect pointers to
389         arrays and use indirect reference to declaration.
390         * resolve.c (resolve_fl_variable): Tidy up condition.
391         (resolve_symbol): The same and only add initialization code if
392         the symbol is referenced.
393         * trans-decl.c (gfc_trans_deferred_vars): Call gfc_trans_
394         deferred_array before gfc_trans_auto_array_allocation.
395
396         PR fortran/21370
397         * symbol.c (check_done): Remove.
398         (gfc_add_attribute): Remove reference to check_done and remove
399         the argument attr_intent.
400         (gfc_add_allocatable, gfc_add_dimension, gfc_add_external,
401         gfc_add_intrinsic, gfc_add_optional, gfc_add_pointer,
402         gfc_add_cray_pointer, gfc_add_cray_pointee, gfc_add_result,
403         gfc_add_target, gfc_add_in_common, gfc_add_elemental,
404         gfc_add_pure, gfc_add_recursive, gfc_add_procedure,
405         gfc_add_type): Remove references to check_done.
406         * decl.c (attr_decl1): Eliminate third argument in call to
407         gfc_add_attribute.
408         * gfortran.h : Change prototype for gfc_add_attribute.
409
410 2006-11-08  Brooks Moses  <brooks.moses@codesourcery.com>
411
412         * invoke.texi: Added documentation for -fmax-errors option.
413
414 2006-11-08  Brooks Moses  <brooks.moses@codesourcery.com>
415
416         * lang.opt: Add -fmax-errors= option.
417         * gfortran.h (gfc_option_t): Add max_errors element.
418         * options.c (gfc_init_options): Set max_errors default value
419         to 25.
420         (gfc_handle_options): Assign -fmax_errors value to
421         gfc_option.max_errors.
422         * error.c (gfc_increment_error_count): New function, which
423         also checks whether the error count exceeds max_errors.
424         (gfc_warning): Use it.
425         (gfc_warning_now): Use it.
426         (gfc_notify_std): Use it.
427         (gfc_error): Use it.
428         (gfc_error_now): Use it.
429         (gfc_error_check): Use it.
430
431 2006-11-08  Brooks Moses  <brooks.moses@codesourcery.com>
432
433         * lang.opt: Remove non-working -qkind= option.
434         * gfortran.h (gfc_option_t): Remove q_kind member.
435         * options.c (gfc_init_options): Remove q_kind initialization.
436         (gfc_handle_option): Remove -qkind= option handling.
437         * primary.c: (match_real_constant): Remove 'Q' exponent.
438
439 2006-11-08  Tobias Burnus  <burnus@net-b.de>
440
441         * gfortran.texi: Add volatile and internal-file
442           namelist to Fortran 2003 status.
443         * intrinsic.texi: Correct CHMOD entry.
444
445 2006-11-07  Paul Thomas  <pault@gcc.gnu.org>
446
447         PR fortran/29539
448         PR fortran/29634
449         * decl.c (variable_decl): Add test for presence of proc_name.
450         * error.c (gfc_error_flag_test): New function.
451         * gfortran.h : Prototype for gfc_error_flag_test.
452
453 2006-11-07  Tobias Burnus  <burnus@net-b.de>
454
455         PR fortran/29601
456         * symbol.c (check_conflict, gfc_add_volatile): Add volatile support.
457         * decl.c (match_attr_spec, gfc_match_volatile): Add volatile support.
458         * gfortran.h (symbol_attribute): Add volatile_ to struct.
459         * resolve.c (was_declared): Add volatile support.
460         * trans-decl.c (gfc_finish_var_decl): Add volatile support.
461         * match.h: Declare gfc_match_volatile.
462         * parse.c (decode_statement): Recognize volatile.
463         * modules.c (ab_attribute, attr_bits, mio_symbol_attribute):
464           Add volatile support.
465         * dump-parse-tree.c (gfc_show_attr): Add volatile support.
466
467 2006-11-06  Tobias Burnus  <burnus@net-b.de>
468
469         * decl.c (match_attr_spec, gfc_match_enum): Unify gfc_notify_std
470           message for GFC_STD_F2003.
471         * array.c (gfc_match_array_constructor): Unify gfc_notify_std
472           message for GFC_STD_F2003.
473         * io.c (check_io_constraints): Unify gfc_notify_std message for
474           GFC_STD_F2003.
475         * resolve.c (resolve_actual_arglist): Unify gfc_notify_std message
476           for GFC_STD_F2003.
477
478 2006-11-06  Brooks Moses  <brooks.moses@codesourcery.com>
479
480         * intrinsic.texi: Added documentation for FTELL, GETLOG, and
481         HOSTNM intrinsics.
482
483 2006-11-06  Erik Edelmann  <eedelman@gcc.gnu.org>
484
485         PR fortran/29630
486         PR fortran/29679
487         * expr.c (find_array_section): Support vector subscripts.  Don't
488           add sizes for dimen_type == DIMEN_ELEMENT to the shape array.
489
490 2006-11-05  Bernhard Fischer  <aldot@gcc.gnu.org>
491
492         PR fortran/21061
493         * error.c (gfc_warning): If warnings_are_errors then treat
494         warnings as errors with respect to the exit code.
495         (gfc_notify_std): Ditto.
496         (gfc_warning_now): Ditto.
497
498 2006-11-05  Francois-Xavier Coudert  <fxcoudert@gcc.gnu,org>
499             Paul Thomas  <pault@gcc.gnu.org>
500
501         PR fortran/24518
502         * trans-intrinsic.c (gfc_conv_intrinsic_mod): Use built_in fmod
503         for both MOD and MODULO, if it is available.
504
505         PR fortran/29565
506         * trans-expr.c (gfc_conv_aliased_arg): For an INTENT(OUT), save
507         the declarations from the unused loops by merging the block
508         scope for each; this ensures that the temporary is declared.
509
510 2006-11-04  Brooks Moses  <brooks.moses@codesourcery.com>
511
512         * error.c (show_locus): Add trailing colon in error messages.
513         (error_print): Avoid leading space in error lines.
514
515 2006-11-04  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
516
517         PR fortran/29713
518         * expr.c (gfc_simplify_expr): Correct memory allocation.
519
520 2006-11-02  Brooks Moses  <brooks.moses@codesourcery.com>
521
522         * error.c (show_locus): Remove "In file" from error messages.
523
524 2006-10-31  Geoffrey Keating  <geoffk@apple.com>
525
526         * trans-decl.c (gfc_generate_constructors): Update for removal
527         of get_file_function_name.
528
529 2006-11-01  Bernhard Fischer  <aldot@gcc.gnu.org>
530
531         PR fortran/29537
532         * trans-common.c (gfc_trans_common): If the blank common is
533         in a procedure or program without a name then proc_name is null, so
534         use the locus of the common.
535         (gfc_sym_mangled_common_id): Fix whitespace.
536         * match.c (gfc_match_common): Emit warning about blank common in
537         block data.
538
539 2006-10-31  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
540
541         PR fortran/29067
542         * decl.c (gfc_set_constant_character_len): NULL-terminate the
543         character constant string.
544         * data.c (create_character_intializer): Likewise.
545         * expr.c (gfc_simplify_expr): NULL-terminate the substring
546         character constant.
547         * primary.c (match_hollerith_constant): NULL-terminate the
548         character constant string.
549
550 2006-10-31  Paul Thomas  <pault@gcc.gnu.org>
551
552         PR fortran/29387
553         * trans-intrinsic.c (gfc_conv_intrinsic_len): Rearrange to have
554         a specific case for EXPR_VARIABLE and, in default, build an ss
555         to call gfc_conv_expr_descriptor for array expressions..
556
557         PR fortran/29490
558         * trans-expr.c (gfc_set_interface_mapping_bounds): In the case
559         that GFC_TYPE_ARRAY_LBOUND is not available, use descriptor
560         values for it and GFC_TYPE_ARRAY_UBOUND.
561
562         PR fortran/29641
563         * trans-types.c (gfc_get_derived_type): If the derived type
564         namespace has neither a parent nor a proc_name, set NULL for
565         the search namespace.
566
567 2006-10-30  Tobias Burnus  <burnus@net-b.de>
568
569         PR fortran/29452
570         * io.c (check_io_constraints): Fix keyword string comparison.
571
572 2006-10-30  Andrew Pinski  <pinskia@gmail.com>
573
574         PR fortran/29410
575         * trans-intrinsic.c (gfc_conv_intrinsic_array_transfer):
576         Change over to create VIEW_CONVERT_EXPR instead of using an
577         ADDR_EXPR, a cast and then an indirect reference
578
579 2006-10-29  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
580
581         * trans-intrinsic.c (gfc_conv_intrinsic_loc): Make LOC return a
582         signed integer node.
583
584 2006-10-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
585
586         PR fortran/17741
587         * decl.c (get_proc_name): Bump current namespace refs count.
588
589 2006-10-29  Jakub Jelinek  <jakub@redhat.com>
590
591         PR fortran/29629
592         * trans-openmp.c (gfc_trans_omp_array_reduction): Set attr.flavor
593         of init_val_sym and outer_sym to FL_VARIABLE.
594
595 2006-10-29  Kazu Hirata  <kazu@codesourcery.com>
596
597         * intrinsic.texi: Fix a typo.
598
599 2006-10-27  Steven G. Kargl  <kargl@gcc.gnu.org>
600
601         * gfortran.h: Remove GFC_MPFR_TOO_OLD.
602         * arith.c (arctangent2): Remove function
603         (gfc_check_real_range): Remove subnormal kludge.
604         * arith.h: Remove arctangent2 prototype.
605         * simplify.c: (gfc_simplify_atan2): Remove use of arctangent2.
606         (gfc_simplify_exponent, gfc_simplify_log, gfc_simplify_nearest,
607         gfc_simplify_rrspacing, gfc_simplify_spacing): Remove mpfr kludges.
608
609 2006-10-28  Tobias Burnus  <burnus@net-b.de>
610
611         PR fortran/28224
612         * io.c (check_io_constraints): Allow namelists
613           for internal files for Fortran 2003.
614
615 2006-10-27  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
616
617         PR fortran/27954
618         * decl.c (gfc_free_data_all): New function to free all data structures
619         after errors in DATA statements and declarations.
620         (top_var_list): Use new function.(top_val_list): Use new function.
621         (gfc_match_data_decl): Use new function.
622         * misc.c (gfc_typename): Fixed incorrect function name in error text. 
623
624 2006-10-24  Erik Edelmann  <eedelman@gcc.gnu.org>
625
626         PR fortran/29393
627         * expr.c (simplify_parameter_variable): Keep rank of original
628         expression.
629
630 2006-10-23 Rafael Avila de Espindola  <rafael.espindola@gmail.com>
631
632         * Make-lang.in (f951$(exeext)): Depend on and link with attribs.o.
633         * trans.h (builtin_function): Rename to gfc_builtin_function.
634         Change the signature.
635         * 95-lang.c (LANG_HOOKS_BUILTIN_FUNCTION): Define as
636         gfc_builtin_function.
637         (builtin_function): Rename to gfc_builtin_function. Move common
638         code to builtin_function.
639         (gfc_define_builtin): Replace calls to builtin_function with
640         gfc_define_builtin.
641
642 2006-10-22  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
643
644         PR fortran/26025
645         * lang.opt: Add -fexternal-blas and -fblas-matmul-limit options.
646         * options.c (gfc_init_options): Initialize new flags.
647         (gfc_handle_option): Handle new flags.
648         * gfortran.h (gfc_option): Add flag_external_blas and
649         blas_matmul_limit flags.
650         * trans-expr.c (gfc_conv_function_call): Use new argument
651         append_args, appending it at the end of the argument list
652         built for a function call.
653         * trans-stmt.c (gfc_trans_call): Use NULL_TREE for the new
654         append_args argument to gfc_trans_call.
655         * trans.h (gfc_conv_function_call): Update prototype.
656         * trans-decl.c (gfc_build_intrinsic_function_decls): Add
657         prototypes for BLAS ?gemm routines.
658         * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Generate the
659         extra arguments given to the library matmul function, and give
660         them to gfc_conv_function_call.
661         * invoke.texi: Add documentation for -fexternal-blas and
662         -fblas-matmul-limit.
663
664 2006-10-21  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
665
666         * Make-lang.in (F95_LIBS): Delete.
667         * f951$(exeext): Use $(LIBS) instead of $(F95_LIBS).
668         * config-lang.in (need_gmp): Delete.
669
670 2006-10-19  Brooks Moses  <bmoses@stanford.edu>
671
672         * invoke.texi: Fixed "denormal" typo.
673
674 2006-10-19  Paul Thomas <pault@gcc.gnu.org>
675
676         PR fortran/29216
677         PR fortran/29314
678         * gfortran.h : Add EXEC_INIT_ASSIGN.
679         * dump-parse-tree.c (gfc_show_code_node): The same.
680         * trans-openmp.c (gfc_trans_omp_array_reduction): Set new
681         argument for gfc_trans_assignment to false.
682         * trans-stmt.c (gfc_trans_forall_1): The same.
683         * trans-expr.c (gfc_conv_function_call, gfc_trans_assign,
684         gfc_trans_arrayfunc_assign, gfc_trans_assignment): The
685         same. In the latter function, use the new flag to stop
686         the checking of the lhs for deallocation.
687         (gfc_trans_init_assign): New function.
688         * trans-stmt.h : Add prototype for gfc_trans_init_assign.
689         * trans.c (gfc_trans_code): Implement EXEC_INIT_ASSIGN.
690         * trans.h : Add new boolean argument to the prototype of
691         gfc_trans_assignment.
692         * resolve.c (resolve_allocate_exp): Replace EXEC_ASSIGN by
693         EXEC_INIT_ASSIGN.
694         (resolve_code): EXEC_INIT_ASSIGN does not need resolution.
695         (apply_default_init): New function.
696         (resolve_symbol): Call it for derived types that become
697         defined but which do not already have an initialization
698         expression..
699         * st.c (gfc_free_statement): Include EXEC_INIT_ASSIGN.
700
701 2006-10-16  Tobias Burnus  <burnus@net-b.de>
702
703         * primary.c: Revert 'significand'-to-'significant' comment change.
704         * invoke.texi (Warning Options): Minor cleanup for
705           -Wimplicit-interface.
706
707 2006-10-17  Paul Thomas <pault@gcc.gnu.org>
708
709         PR fortran/29451
710         * trans-array.c (gfc_trans_array_bounds): Test for and set
711         negative stride of a non-constant bound array to zero.
712
713         PR fortran/29392
714         * data.c (create_character_intializer): Copy and simplify
715         the expressions for the start and end of a sub-string
716         reference.
717
718 2006-10-16  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
719
720         * io.c (gfc_match_close): Ensure that status is terminated by
721         a NULL element.
722
723 2006-10-16  Tobias Burnus  <burnus@net-b.de>
724
725         * trans-stmt.c: Fix a typo
726         * invoke.texi: Fix typos
727         * resolve.c: Fix a comment typo
728         * trans-decl.c: Fix a comment typo
729         * primary.c: Fix a comment typo
730
731 2006-10-15  Steven G. Kargl  <kargl@gcc.gnu.org>
732
733         PR fortran/29403
734         * io.c (match_io):  Check for a default-char-expr for PRINT format.
735
736 2006-10-15  Bernhard Fischer  <aldot@gcc.gnu.org>
737
738         PR fortran/24767
739         * lang.opt (Wunused-labels): Remove.
740         * options.c: Remove references to gfc_option.warn_unused_labels.
741         * gfortran.h: Remove variable warn_unused_labels.               
742         * resolve.c (warn_unused_fortran_label) : Use warn_unused_label
743         instead of gfc_option.warn_unused_labels.
744         * invoke.texi: Remove documentation of -Wunused-labels.
745
746 2006-10-14  Tobias Burnus  <burnus@net-b.de>
747
748         * gfortran.texi: Add link to GFortran apps
749         * intrinsic.texi: Updated documentation of ACCESS and CHMOD
750
751 2006-10-14  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
752
753         PR fortran/19261
754         * scanner.c (load_line): Add checks for illegal use of '&' and issue
755         warnings.  Issue errors with -pedantic.
756
757 2006-10-14 Paul Thomas <pault@gcc.gnu.org>
758
759         PR fortran/29371
760         * trans-expr.c (gfc_trans_pointer_assignment): Add the expression
761         for the assignment of null to the data field to se->pre, rather
762         than block.     
763
764 2006-10-14  Kazu Hirata  <kazu@codesourcery.com>
765
766         * intrinsic.texi: Fix typos.
767         * trans-array.c: Fix a comment typo.
768
769 2006-10-13  Brooks Moses  <bmoses@stanford.edu>
770
771         * intrinsic.texi (STAT): Reverted a format in example code to
772         octal; noted this in accompanying string.
773
774 2006-10-13 Paul Thomas <pault@gcc.gnu.org>
775
776         PR fortran/29373
777         * decl.c (get_proc_name, gfc_match_function_decl): Add
778         attr.implicit_type to conditions that throw error for
779         existing explicit interface and that allow new type-
780         spec to be applied.
781
782         PR fortran/29407
783         * resolve.c (resolve_fl_namelist): Do not check for
784         namelist/procedure conflict, if the symbol corresponds
785         to a good local variable declaration.
786
787         PR fortran/27701
788         * decl.c (get_proc_name): Replace the detection of a declared
789         procedure by the presence of a formal argument list by the
790         attributes of the symbol and the presence of an explicit
791         interface.
792
793         PR fortran/29232
794         * resolve.c (resolve_fl_variable): See if the host association
795         of a derived type is blocked by the presence of another type I
796         object in the current namespace.
797
798         PR fortran/29364
799         * resolve.c (resolve_fl_derived): Check for the presence of
800         the derived type for a derived type component.
801
802         PR fortran/24398
803         * module.c (gfc_use_module): Check that the first words in a
804         module file are 'GFORTRAN module'.
805
806         PR fortran/29422
807         * resolve.c (resolve_transfer): Test functions for suitability
808         for IO, as well as variables.
809
810         PR fortran/29428
811         * trans-expr.c (gfc_trans_scalar_assign): Remove nullify of
812         rhs expression.
813
814 2006-10-13  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
815
816         PR fortran/29391
817         * trans-intrinsic.c (gfc_conv_intrinsic_bound): Generate correct
818         code for LBOUND and UBOUND intrinsics.
819
820 2006-10-13  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
821
822         PR fortran/21435
823         * io.c (compare_to_allowed_values): New function.
824         (gfc_match_open): Add checks for constant values of specifiers.
825         (gfc_match_close): Add checks for constant values of the STATUS
826         specifier.
827
828 2006-10-12  Brooks Moses  <bmoses@stanford.edu>
829
830         * intrinsic.texi (STAT): Fixed a format typo in sample code.
831
832 2006-10-12  Brooks Moses  <bmoses@stanford.edu>
833
834         * intrinsic.texi (STAT): Shortened lines in sample code.
835
836 2006-10-11  Tobias Schlueter  <tobias.schlueter@physik.uni-muenchen.de>
837
838         * gfortran.h (gfc_show_actual_arglist, gfc_show_array_ref,
839         gfc_show_array_spec, gfc_show_attr, gfc_show_code,
840         gfc_show_components, gfc_show_constructor, gfc_show_equiv,
841         gfc_show_expr, gfc_show_namelist, gfc_show_ref, gfc_show_symbol,
842         gfc_show_typespec): Add prototypes.
843         * dump-parse-tree.c (gfc_show_actual_arglist, gfc_show_array_ref,
844         gfc_show_array_spec, gfc_show_attr, gfc_show_code,
845         gfc_show_components, gfc_show_constructor, gfc_show_equiv,
846         gfc_show_expr, gfc_show_namelist, gfc_show_ref, gfc_show_symbol,
847         gfc_show_typespec): Remove 'static' from declaration.
848
849 2006-10-10  Brooks Moses  <bmoses@stanford.edu>
850
851         * invoke.texi, gfortran.texi: Corrected erronous dashes.
852
853 2006-10-10  Brooks Moses  <bmoses@stanford.edu>
854
855         * Make-lang.in: Added "fortran.pdf", "gfortran.pdf" target
856         support.
857
858 2006-10-10  Daniel Franke  <franke.daniel@gmail.com>
859
860         * intrinsic.texi: added documentation for FSTAT, GETARG,GET_COMMAND,
861         GET_COMMAND_ARGUMENT, GETENV, GET_ENVIRONMENT_VARIABLE, IAND, IARGC,
862         LSTAT and STAT, removed the reference to PR19292 from ACCESS, CHMOD,
863         GMTIME, LSHIFT, LTIME, RSHIFT.
864
865 2006-10-10  Brooks Moses  <bmoses@stanford.edu>
866
867         * gfortran.texi (Standards): Update to current status.
868
869 2006-10-09  Brooks Moses  <bmoses@stanford.edu>
870
871         * Make-lang.in: Added intrinsic.texi to GFORTRAN_TEXI
872         dependences.
873
874 2006-10-09  Brooks Moses  <bmoses@stanford.edu>
875
876         * intrinsic.texi (MOVE_ALLOC): changed "Options" to "Standards".
877
878 2006-10-09  Steven G. Kargl  <kargl@gcc.gnu.org>
879
880         * gfortran.h: Define GFC_MPFR_TOO_OLD via mpfr version info.
881         * arith.c (arctangent, gfc_check_real_range): Use it.   
882         * simplify.c (gfc_simplify_atan2, gfc_simplify_exponent,
883         gfc_simplify_log, gfc_simplify_nearest): Use it.
884
885         PR fortran/15441
886         PR fortran/29312
887         * iresolve.c (gfc_resolve_rrspacing): Give rrspacing library
888         routine hidden precision argument.
889         (gfc_resolve_spacing): Give spacing library routine hidden
890         precision, emin - 1, and tiny(x) arguments.
891         * simplify.c (gfc_simplify_nearest): Remove explicit subnormalization.
892         (gfc_simplify_rrspacing): Implement formula from Fortran 95 standard.
893         (gfc_simplify_spacing): Implement formula from Fortran 2003 standard.
894         * trans-intrinsic.c (gfc_intrinsic_map_t) Declare rrspacing and
895         spacing via LIBF_FUNCTION
896         (prepare_arg_info, call_builtin_clz, gfc_conv_intrinsic_spacing,
897         gfc_conv_intrinsic_rrspacing): Remove functions.
898         (gfc_conv_intrinsic_function): Remove calls to
899         gfc_conv_intrinsic_spacing and gfc_conv_intrinsic_rrspacing.
900         * f95-lang.c (gfc_init_builtin_functions): Remove __builtin_clz,
901         __builtin_clzl and __builtin_clzll
902
903 2006-10-09  Richard Henderson  <rth@redhat.com>
904
905         Revert emutls patch.
906
907 2006-10-09  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
908
909         * intrinsic.c (add_sym_0s, add_sym_1s, add_sym_2s, add_sym_3s,
910         add_sym_4s, add_sym_5s, add_functions): Use macro ACTUAL_NO,
911         ACTUAL_YES, NOT_ELEMENTAL and ELEMENTAL instead of constants
912         0 and 1 as second and third arguments to add_sym* functions.
913
914 2006-10-08  Erik Edelmann <edelmann@gcc.gnu.org>
915             Paul Thomas <pault@gcc.gnu.org>
916
917         PR fortran/20541
918         * interface.c (gfc_compare_derived_types): Add comparison of
919         the allocatable field.
920         * intrinsic.c (add_subroutines): Add MOVE_ALLOC.
921         * trans-expr.c (gfc_conv_aliased_arg, gfc_trans_subarray_assign,
922         gfc_trans_subcomponent_assign, gfc_conv_string_parameter,
923         gfc_trans_scalar_assign): Add extra arguments l_is_temp
924         and r_is_var to references to latter function.
925         (gfc_conv_function_call): Add enum for types of argument and
926         an associated variable parm_kind. Deallocate components of
927         INTENT(OUT) and non-variable arrays.
928         (gfc_trans_subcomponent_assign): Add block to assign arrays
929         to allocatable components.
930         (gfc_trans_scalar_assign): Add block to handle assignments of
931         derived types with allocatable components, using the above new
932         arguments to control allocation/deallocation of memory and the
933         copying of allocated arrays.
934         * trans-array.c (gfc_array_allocate): Remove old identification 
935         of pointer and replace with that of an allocatable array. Add
936         nullify of structures with allocatable components. 
937         (gfc_conv_array_initializer): Treat EXPR_NULL.
938         (gfc_conv_array_parameter): Deallocate allocatable components
939         of non-variable structures.
940         (gfc_trans_dealloc_allocated): Use second argument of library
941         deallocate to inhibit, without error, freeing NULL pointers.
942         (get_full_array_size): New function to return the size of a
943         full array.
944         (gfc_duplicate_allocatable): New function to allocate and copy
945         allocated data.
946         (structure_alloc_comps): New recursive function to deallocate,
947         nullify or copy allocatable components.
948         (gfc_nullify_alloc_comp, gfc_deallocate_alloc_comp,
949         gfc_copy_alloc_comp): New interface functions to call previous.
950         (gfc_trans_deferred_array): Add the code to nullify allocatable
951         components, when entering scope, and to deallocate them on
952         leaving. Do not call gfc_trans_static_array_pointer and return
953         for structures with allocatable components and default
954         initializers.
955         * symbol.c (gfc_set_component_attr): Set allocatable field.
956         (gfc_get_component_attr): Set the allocatable attribute.
957         * intrinsic.h : Prototype for gfc_check_move_alloc.
958         * decl.c (build_struct): Apply TR15581 constraints for
959         allocatable components.
960         (variable_decl): Default initializer is always NULL for
961         allocatable components.
962         (match_attr_spec): Allow, or not, allocatable components,
963         according to the standard in force.
964         * trans-array.h : Prototypes for gfc_nullify_alloc_comp,
965         gfc_deallocate_alloc_comp, gfc_copy_alloc_comp and
966         gfc_duplicate_allocatable.
967         * gfortran.texi : Add mention of TR15581 extensions.
968         * gfortran.h : Add attribute alloc_comp, add
969         gfc_components field allocatable and add the prototype
970         for gfc_expr_to_initialize.
971         * trans-stmt.c (generate_loop_for_temp_to_lhs,
972         generate_loop_for_rhs_to_temp, gfc_trans_where_assign,
973         gfc_trans_where_3): Add extra arguments to calls to
974         gfc_trans_scalar_assign and set appropriately.
975         (gfc_trans_allocate): Nullify allocatable components.
976         (gfc_trans_deallocate): Deallocate to ultimate allocatable
977         components but stop at ultimate pointer components.
978         * module.c (mio_symbol_attribute, mio_symbol_attribute,
979         mio_component): Add module support for allocatable
980         components.
981         * trans-types.c (gfc_get_derived_type): Treat allocatable
982         components.
983         * trans.h : Add two boolean arguments to
984         gfc_trans_scalar_assign.
985         * resolve.c (resolve_structure_cons): Check conformance of
986         constructor element and the component.
987         (resolve_allocate_expr): Add expression to nullify the
988         constructor expression for allocatable components.
989         (resolve_transfer): Inhibit I/O of derived types with
990         allocatable components.
991         (resolve_fl_derived): Skip check of bounds of allocatable
992         components.
993         * trans-decl.c (gfc_get_symbol_decl): Add derived types
994         with allocatable components to deferred variable.
995         (gfc_trans_deferred_vars): Make calls for derived types
996         with allocatable components to gfc_trans_deferred_array.
997         (gfc_generate_function_code): Nullify allocatable
998         component function result on entry.
999         * parse.c (parse_derived): Set symbol attr.allocatable if
1000         allocatable components are present.
1001         * check.c (gfc_check_allocated): Enforce attr.allocatable
1002         for intrinsic arguments.
1003         (gfc_check_move_alloc): Check arguments of move_alloc.
1004         * primary.c (gfc_variable_attr): Set allocatable attribute.
1005         * intrinsic.texi : Add index entry and section for
1006         for move_alloc.
1007
1008 2006-10-08  Paul Thomas <pault@gcc.gnu.org>
1009
1010         PR fortran/29115
1011         * resolve.c (resolve_structure_cons): It is an error if the
1012         pointer component elements of a derived type constructor are
1013         not pointer or target.
1014
1015
1016         PR fortran/29211
1017         * trans-stmt.c (generate_loop_for_temp_to_lhs,
1018         generate_loop_for_rhs_to_temp): Provide a string length for
1019         the temporary by copying that of the other side of the scalar
1020         assignment.
1021
1022 2006-10-08  Tobias Burnus  <burnus@net-b.de>
1023
1024         PR fortran/28585
1025         * intrinsic.c (add_functions): Add new_line Fortran 2003 intrinsic.
1026         * intrinsic.h: Add gfc_simplify_new_line and gfc_check_new_line
1027         prototypes.
1028         * check.c (gfc_check_new_line): New function.
1029         * simplify.c (gfc_simplify_new_line): New function.
1030         * intrinsic.texi: Document new_line intrinsic.
1031
1032 2006-10-07  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1033
1034         PR fortran/16580
1035         PR fortran/29288
1036         * gcc/fortran/intrinsic.c (add_sym): Define the actual_ok when a
1037         gfc_intrinsic_sym structure is filled.
1038         (gfc_intrinsic_actual_ok): New function.
1039         (add_sym_0s, add_sym_1s, add_sym_2s, add_sym_3s, add_sym_4s,
1040         add_sym_5s): Intrinsic subroutines are not allowed as actual
1041         arguments, so we remove argument actual_ok.
1042         (add_functions): Correct the values for actual_ok of all intrinsics.
1043         Add comments for gfc_check_access_func and gfc_resolve_index_func.
1044         (add_subroutines): Remove the actual_ok argument, which was never used.
1045         * gcc/fortran/intrinsic.h (gfc_intrinsic_actual_ok): New prototype.
1046         * gcc/fortran/gfortran.h (gfc_resolve_index_func): New prototype.
1047         * gcc/fortran/resolve.c (resolve_actual_arglist): Check whether
1048         an intrinsic used as an argument list is allowed there.
1049         * gcc/fortran/iresolve.c (gfc_resolve_index_func): New function.
1050         (gfc_resolve_len): Change intrinsic function name to agree with
1051         libgfortran.
1052         * gcc/fortran/trans-decl.c (gfc_get_extern_function_decl): Add
1053         new case, because some specific intrinsics take 3 arguments.
1054         * gcc/fortran/intrinsic.texi: DIMAG is a GNU extension.
1055
1056 2006-10-06  Jakub Jelinek  <jakub@redhat.com>
1057
1058         PR fortran/28415
1059         * trans-decl.c (gfc_finish_var_decl): With -fno-automatic, don't
1060         make artificial variables or pointer to variable automatic array
1061         TREE_STATIC.
1062
1063         * scanner.c (skip_free_comments): Return bool instead of void.
1064         (gfc_next_char_literal): Don't return ' ' if & is missing after
1065         !$omp or !$.  Use skip_{free,fixed}_comments directly instead
1066         of gfc_skip_comments.
1067
1068 2006-10-04  Brooks Moses  <bmoses@stanford.edu>
1069
1070         * gfortran.texi: (Current Status): update and rewrite to reflect
1071         actual status more accurately.
1072
1073 2006-10-04  Brooks Moses  <bmoses@stanford.edu>
1074
1075         * gfortran.texi: Consistently refer to the compiler as "GNU
1076         Fortran".
1077         * intrinsic.texi: Ditto.
1078         * invoke.texi: Ditto.
1079
1080 2006-10-04  Richard Henderson  <rth@redhat.com>
1081             Jakub Jelinek  <jakub@redhat.com>
1082
1083         * f95-lang.c (gfc_init_builtin_functions): Add __emutls_get_address
1084         and __emutls_register_common.
1085         * openmp.c (gfc_match_omp_threadprivate): Don't error if !have_tls.
1086         * trans-common.c (build_common_decl): Don't check have_tls.
1087         * trans-decl.c (gfc_finish_var_decl): Likewise.
1088         * types.def (BT_WORD, BT_FN_PTR_PTR): New.
1089         (BT_FN_VOID_PTR_WORD_WORD_PTR): New.
1090
1091 2006-10-04  Paul Thomas <pault@gcc.gnu.org>
1092
1093         PR fortran/29343
1094         * resolve.c (resolve_allocate_expr): Exclude derived types from
1095         search for dependences between allocated variables and the
1096         specification expressions for other allocations in the same
1097         statement.
1098
1099 2006-10-04  Paul Thomas  <pault@gcc.gnu.org>
1100
1101         PR fortran/29098
1102         * resolve.c (resolve_structure_cons): Do not return FAILURE if
1103         component expression is NULL.
1104
1105 2006-10-03  Paul Thomas  <pault@gcc.gnu.org>
1106
1107         PR fortran/20779
1108         PR fortran/20891
1109         * resolve.c (find_sym_in_expr): New function that returns true
1110         if a symbol is found in an expression.
1111         (resolve_allocate_expr): Check whether the STAT variable is
1112         itself allocated in the same statement.  Use the call above to
1113         check whether any of the allocated arrays are used in array
1114         specifications in the same statement.
1115
1116 2006-10-03  Steven G. Kargl  <kargl@gcc.gnu.org>
1117
1118         * arith.c (gfc_check_real_range):  Use correct exponent range for
1119         subnormal numbers.
1120
1121 2006-10-03  Paul Thomas  <pault@gcc.gnu.org>
1122
1123         PR fortran/29284
1124         PR fortran/29321
1125         PR fortran/29322
1126         * trans-expr.c (gfc_conv_function_call): Check the expression
1127         and the formal symbol are present when testing the actual
1128         argument.
1129
1130         PR fortran/25091
1131         PR fortran/25092
1132         * resolve.c (resolve_entries): It is an error if the entries
1133         of an array-valued function do not have the same shape.
1134
1135 2006-10-03  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1136
1137         PR middle-end/27478
1138         * trans-decl.c (gfc_get_fake_result_decl): Mark var as
1139         TREE_ADDRESSABLE.
1140
1141 2006-10-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1142
1143         PR fortran/19262
1144         * gfortran.h (gfc_option_t): Add max_continue_fixed and
1145         max_continue_free.
1146         * options.c (gfc_init_options): Initialize fixed form and free form
1147         consecutive continuation line limits.
1148         * scanner.c (gfc_scanner_init_1): Initialize continue_line
1149         and continue_count. (gfc_next_char_literal): Count the number of
1150         continuation lines in the current statement and warn if limit
1151         is exceeded.
1152
1153 2006-10-02  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1154
1155         PR fortran/19260
1156         * scanner.c (gfc_next_char_literal): Add check for missing '&'
1157         and warn if in_string, otherwise return ' '.
1158
1159 2006-10-02  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1160
1161         PR fortran/29210
1162         * primary.c (match_sym_complex_part): Named constants as real or
1163         imaginary part of complex a named constant are only allowed in
1164         Fortran 2003.
1165
1166 2006-10-01  Brooks Moses  <bmoses@stanford.edu>
1167
1168         * gfortran.texi: Corrected references to MALLOC intrinsic.
1169         * invoke.texi: Minor cleanup and clarification to the Dialect
1170         Options section.
1171
1172 2006-09-30  Brooks Moses  <bmoses@stanford.edu>
1173
1174         * invoke.texi:  Add mention of BOZ constants and integer
1175         overflow to -fno-range-check.
1176         * gfortran.texi:  Add mention of -fno-range-check to
1177         section on BOZ contants.
1178
1179 2006-09-30  Bernhard Fischer  <aldot@gcc.gnu.org>
1180
1181         * resolve.c: Fix commentary typo.  Fix whitespace.
1182
1183 2006-09-28  Steven G. Kargl  <kargl@gcc.gnu.org>
1184
1185         fortran/29147
1186         * arith.c (gfc_check_integer_range): Disable range checking via
1187         -fno-range-check.
1188
1189 2006-09-28  Steven G. Kargl <kargl@gcc.gnu.org>
1190
1191         * arith.c: Change conditional test for inclusion of arctangent().
1192         (gfc_check_real_range): Change conditional test for use of
1193         mpfr_subnormalize.
1194         * simplify.c (gfc_simplify_atan2): Fix conditional for use of
1195         mpfr_atan2() instead of arctangent().
1196         (gfc_simplify_exponent): Fix conditional for use of mpfr_get_exp().
1197         (gfc_simplify_log): Fix conditional for use of mpfr_atan2() instead
1198          of arctangent().
1199         (gfc_simplify_nearest): Fix conditional for use of mpfr_nextafter(). 
1200
1201 2006-09-27  Steven G. Kargl  <kargl@gcc.gnu.org>
1202
1203         * arith.c: Conditionally include arctangent2().
1204         (gfc_check_real_range): Use mpfr_subnormalize in preference to local
1205         hack.
1206         * trans-intrinsic.c (gfc_get_intrinsic_lib_fndecl): Append
1207         l for long double functions.
1208         * simplify.c: Wrap Copyright to new line.
1209         (gfc_simplify_atan2): Use mpfr_atan2 in preference to arctangent2().
1210         (gfc_simplify_log): Ditto.
1211
1212
1213         PR fortran/28276
1214         * simplify.c (gfc_simplify_exponent): Use mpfr_get_exp in
1215         preference to broken local hack.
1216
1217         PR fortran/27021
1218         * simplify.c (gfc_simplify_nearest): Use mpfr_nexttoward and
1219         mpfr_subnormalize to handle numbers near zero in preference to broken
1220          local hack.
1221
1222 2006-09-26  Jakub Jelinek  <jakub@redhat.com>
1223
1224         PR fortran/29097
1225         * scanner.c (include_line): Handle conditional include.
1226
1227 2006-09-25  Tobias Schluter  <tobias.schlueter@physik.uni-muenchen.de>
1228
1229         PR fortran/21203
1230         * error.c (show_loci): No need to risk an ICE to output a
1231         slightly nicer error message.
1232
1233 2006-09-19 Paul Thomas <pault@gcc.gnu.org>
1234            Steven Bosscher  <steven@gcc.gnu.org>
1235
1236         PR fortran/29101
1237         * trans-stmt.c (gfc_trans_character_select): Store the label
1238         from select_string and then clean up any temporaries from the
1239         conversion of the select expression, before branching to the
1240         selected case.
1241
1242 2006-09-18 Paul Thomas <pault@gcc.gnu.org>
1243
1244         PR fortran/28526
1245         * primary.c (match_variable): If the compiler is in a module
1246         specification block, an interface block or a contains section,
1247         reset host_flag to force the changed symbols mechanism.
1248
1249         PR fortran/29101
1250         * trans-stmt.c (gfc_trans_character_select): Add the post block
1251         for the expression to the main block, after the call to
1252         select_string and the last label.
1253
1254 2006-09-18  Paul Thomas  <pault@gcc.gnu.org>
1255
1256         PR fortran/29060
1257         * iresolve.c (resolve_spread): Build shape for result if the
1258         source shape is available and dim and ncopies are constants.
1259
1260 2006-09-18  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
1261
1262         PR fortran/28817
1263         PR fortran/21918
1264         * trans-decl.c (generate_local_decl): Change from 'warning' to
1265         'gfc_warning' to have line numbers correctly reported.
1266
1267 2006-09-15  Paul Thomas  <pault@gcc.gnu.org>
1268
1269         PR fortran/29051
1270         * decl.c (match_old_style_init): Set the 'where' field of the
1271         gfc_data structure 'newdata'.
1272
1273         * match.c (match_case_eos): Add a comprehensible error message.
1274
1275 2006-09-13  Wolfgang Gellerich  <gellerich@de.ibm.com>
1276
1277         * trans-expr.c (gfc_add_interface_mapping): For characters, dereference
1278         pointer if necessary and then perform the cast.
1279
1280 2006-09-11  Steven G. Kargl  <kargl@gcc.gnu.org>
1281
1282         * intrinsic.c: Update Copyright date.
1283         * intrinsic.h: Ditto.
1284
1285 2006-09-11  Paul Thomas  <pault@gcc.gnu.org>
1286
1287         PR fortran/28890
1288         * trans-expr.c (gfc_conv_function_call): Obtain the string length
1289         of a dummy character(*) function from the symbol if it is not
1290         already translated.  For a call to a character(*) function, use
1291         the passed, hidden string length argument, which is available
1292         from the backend_decl of the formal argument.
1293         * resolve.c (resolve_function): It is an error if a function call
1294         to a character(*) function is other than a dummy procedure or
1295         an intrinsic.
1296
1297 2006-09-10  Paul Thomas  <pault@gcc.gnu.org>
1298
1299         PR fortran/28959
1300         * trans-types.c (gfc_get_derived_type): Use the parent namespace of
1301         the procedure if the type's own namespace does not have a parent.
1302
1303 2006-09-10  Paul Thomas  <pault@gcc.gnu.org>
1304
1305         PR fortran/28923
1306         * expr.c (find_array_section): Only use the array lower and upper
1307         bounds for the start and end of the sections, where the expr is
1308         NULL.
1309
1310 2006-09-10  Paul Thomas <pault@gcc.gnu.org>
1311
1312         PR fortran/28914
1313         * trans-array.c (gfc_trans_array_constructor_value): Create a temporary
1314         loop variable to hold the current loop variable in case it is modified
1315         by the array constructor.
1316
1317 2006-09-07  Steven G. Kargl  <kargls@comcast.net>
1318
1319         * gfortran.h (gfc_integer_info): Eliminate max_int.
1320         * arith.c (gfc_arith_init_1): Remove initialization of max_int.
1321         (gfc_arith_done_1): Remove clearing of max_int.
1322         (gfc_check_integer_range): Fix range chekcing of overflow.
1323         * simplify.c (gfc_simplify_not): Construct mask that was max_int.
1324
1325 2006-09-05  Paul Thomas <pault@gcc.gnu.org>
1326
1327         PR fortran/28908
1328         * gfortran.h : Restore the gfc_dt_list structure and reference
1329         to it in gfc_namespace.
1330         * resolve.c (resolve_fl_derived): Restore the building of the
1331         list of derived types for the current namespace. Modify the
1332         restored code so that a check is made to see if the symbol is
1333         already in the list.
1334         (resolve_fntype): Make sure that the specification block
1335         version of the derived type is used for a module function that
1336         returns that type. 
1337         * symbol.c (gfc_free_dt_list): Restore.
1338         (gfc_free_namespace): Restore call to previous.
1339         * trans-types.c (copy_dt_decls_ifequal): Restore.
1340         (gfc_get_derived_type): Restore all the paraphenalia for
1341         association of derived types, including calls to previous.
1342         Modify the restored code such that all derived types are built
1343         if their symbols are found in the parent namespace; not just
1344         non-module types.  Add backend_decls to like derived types in
1345         sibling namespaces, as well as that of the derived type.
1346
1347 2006-08-30  Kazu Hirata  <kazu@codesourcery.com>
1348
1349         * match.c: Fix a comment typo.
1350
1351 2006-08-30  Paul Thomas  <pault@gcc.gnu.org>
1352
1353         PR fortran/28885
1354         * trans-expr.c (gfc_conv_aliased_arg): Ensure that the temp
1355         declaration is retained for INTENT(OUT) arguments.
1356
1357         PR fortran/28873
1358         PR fortran/20067
1359         * resolve.c (resolve_generic_f): Make error message more
1360         comprehensible.
1361         (resolve_generic_s): Restructure search for specific procedures
1362         to be similar to resolve_generic_f and change to similar error
1363         message.  Ensure that symbol reference is refreshed, in case
1364         the search produces a NULL.
1365         (resolve_specific_s): Restructure search, as above and as
1366         resolve_specific_f. Ensure that symbol reference is refreshed,
1367         in case the search produces a NULL.
1368
1369         PR fortran/25077
1370         PR fortran/25102
1371         * interface.c (check_operator_interface): Throw error if the
1372         interface assignment tries to change intrinsic type assigments
1373         or has less than two arguments.  Also, it is an error if an
1374         interface operator contains an alternate return.
1375
1376         PR fortran/24866
1377         * parse.c (gfc_fixup_sibling_symbols): Do not modify the symbol
1378         if it is a dummy in the contained namespace.
1379
1380 2006-08-29  Steven G. Kargl  <kargls@comcast.net>
1381
1382         PR fortran/28866
1383         * match.c: Wrap copyright.
1384         (gfc_match_assignment):  Return MATCH_NO for failed lvalue.  Remove
1385         gotos.  Move error handling of FL_PARAMETER to ...
1386         * gfc_match_if: Deal with MATCH_NO from above.
1387         * primary.c: Wrap copyright.
1388         (match_variable): ... here.  Improve error messages.
1389
1390 2006-08-29  Paul Thomas  <pault@gcc.gnu.org>
1391
1392         PR fortran/28788
1393         * symbol.c (gfc_use_derived): Never eliminate the symbol,
1394         following reassociation of use associated derived types.
1395
1396 2006-08-26  Steven G. Kargl  <kargls@comcast.net>
1397
1398         * arith.h: Update Copyright dates.  Fix whitespace.
1399         * arith.c: Update Copyright dates.  Fix whitespace.  Fix comments.
1400         (gfc_arith_done_1): Clean up pedantic_min_int and subnormal.
1401
1402 2006-08-26  Tobias Burnus  <burnus@net-b.de>
1403
1404         * gfortran.texi: Note variable initialization causes SAVE attribute.
1405         * intrinsic.texi: Clarify support for KIND=16 and KIND=10.
1406         Mention -std=f2003.  Cross reference INQUIRE from ACCESS intrinsic.
1407         Add missing ) in ACOS.
1408
1409 2006-08-26  Daniel Franke  <franke.daniel@gmail.com>
1410
1411         * intrinsic.texi: Update Copyright date.  Added documentation
1412         for ACOSH, AND, ASINH, ATANH, CHDIR, FGET, FGETC, FPUT, FPUTC,
1413         GETCWD, OR and XOR intrinsics, removed inadvertently introduced
1414         doc-stubs for EQV and NEQV, corrected some typographical errors.
1415
1416 2006-08-24  Daniel Franke  <franke.daniel@gmail.com>,
1417             Brooks Moses  <bmoses@stanford.edu>
1418
1419         * intrinsic.texi: Added doc-stubs for undocumented intrinsics,
1420         added a "See Also" section, renamed the "Options" section to
1421         "Standard", improved the index, and made numerous minor
1422         typo corrections and grammatical fixes.
1423
1424 2006-08-24  Paul Thomas  <pault@gcc.gnu.org>
1425
1426         PR fortran/28788
1427         * symbol.c (shift_types): Shift the derived type references in
1428         formal namespaces.
1429         (gfc_use_derived): Return if the derived type symbol is already
1430         in another namspace.  Add searches for the derived type in
1431         sibling namespaces.
1432
1433         PR fortran/28771
1434         * decl.c (add_init_expr_to_sym): Restore the original but
1435         restricted to parameter arrays to fix a regression.
1436
1437 2006-08-23  Steven G. Kargl  <kargls@comcast.net>
1438
1439         * gfortran.texi:  Fix last commit where a "no" was deleted and
1440         a grammatical error was introduced.
1441
1442 2006-08-23  Steven G. Kargl  <kargls@comcast.net>
1443
1444         * gfortran.texi:  Spell check.  Add a few contributors to
1445         Chapter 9.  Expand the description of BOZ constant handling.
1446
1447 2006-08-20  Janne Blomqvist  <jb@gcc.gnu.org>
1448
1449         PR fortran/25828
1450         * gfortran.texi: Mention STREAM I/O among supported F2003
1451         features.
1452
1453 2006-08-20  Paul Thomas  <pault@gcc.gnu.org>
1454
1455         PR fortran/28601
1456         PR fortran/28630
1457         * gfortran.h : Eliminate gfc_dt_list structure and reference
1458         to it in gfc_namespace.
1459         * resolve.c (resolve_fl_derived): Remove the building of the
1460         list of derived types for the current namespace.
1461         * symbol.c (find_renamed_type): New function to find renamed
1462         derived types by symbol name rather than symtree name.
1463         (gfc_use_derived): Search parent namespace for identical
1464         derived type and use it, even if local version is complete,
1465         except in interface bodies. Ensure that renamed derived types
1466         are found by call to find_renamed_type. Recurse for derived
1467         type components.
1468         (gfc_free_dt_list): Remove.
1469         (gfc_free_namespace): Remove call to previous.
1470         * trans-types.c (copy_dt_decls_ifequal): Remove.
1471         (gfc_get_derived_type): Remove all the paraphenalia for
1472         association of derived types, including calls to previous.
1473         * match.c (gfc_match_allocate): Call gfc_use_derived to
1474         associate any derived types that are being allocated.
1475
1476         PR fortran/20886
1477         * resolve.c (resolve_actual_arglist): The passing of
1478         a generic procedure name as an actual argument is an
1479         error.
1480
1481         PR fortran/28735
1482         * resolve.c (resolve_variable): Check for a symtree before
1483         resolving references.
1484
1485         PR fortran/28762
1486         * primary.c (match_variable): Return MATCH_NO if the symbol
1487         is that of the program.
1488
1489         PR fortran/28425
1490         * trans-expr.c (gfc_trans_subcomponent_assign): Translate
1491         derived type component expressions other than another derived
1492         type constructor.
1493
1494         PR fortran/28496
1495         * expr.c (find_array_section): Correct errors in
1496         the handling of a missing start value for the
1497         index triplet in an array reference.
1498
1499         PR fortran/18111
1500         * trans-decl.c (gfc_build_dummy_array_decl): Before resetting
1501         reference to backend_decl, set it DECL_ARTIFICIAL.
1502         (gfc_get_symbol_decl): Likewise for original dummy decl, when
1503         a copy is made of an array.
1504         (create_function_arglist): Likewise for the _entry paramter
1505         in entry_masters.
1506         (build_entry_thunks): Likewise for dummies in entry thunks.
1507
1508         PR fortran/28600
1509         * trans-decl.c (gfc_get_symbol_decl): Ensure that the
1510         DECL_CONTEXT of the length of a character dummy is the
1511         same as that of the symbol declaration.
1512
1513         PR fortran/28771
1514         * decl.c (add_init_expr_to_sym): Remove setting of charlen for
1515         an initializer of an assumed charlen variable.
1516
1517         PR fortran/28660
1518         * trans-decl.c (generate_expr_decls): New function.
1519         (generate_dependency_declarations): New function.
1520         (generate_local_decl): Call previous if not either a dummy or
1521         a declaration in an entry master.
1522
1523 2006-08-19  Erik Edelmann  <eedelman@gcc.gnu.org>
1524
1525         PR fortran/25217
1526         * resolve.c (resolve_fl_variable): Set a default initializer for
1527         derived types with INTENT(OUT) even if 'flag' is true.
1528         * trans-expr.c (gfc_conv_function_call): Insert code to
1529         reinitialize INTENT(OUT) arguments of derived type with default
1530         initializers.
1531
1532 2006-08-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1533
1534         PR fortran/25828
1535         * gfortran.h: Add new pointer for stream position to st_inquire.
1536         Rename gfc_large_io_int_kind to gfc_intio_kind.
1537         * trans-types.c (gfc_init_kinds): use gfc_intio_kind.
1538         * io.c: Add new IO tag for file position going in and another for out.
1539         (match_dt_element): Match new tag_spos.
1540         (gfc_resolve_dt): Resolve new tag_spos.
1541         (gfc_free_inquire): Free inquire->strm_pos.
1542         (match_inquire_element): Match new tag_strm_out.
1543         (gfc_resolve_inquire): Resolve new tag_strm_out.
1544         * trans-io.c: Rename IOPARM_type_large_io_int to IOPARM_type_intio.
1545         (gfc_build_st_parameter): Same.
1546         (gfc_build_io_library_fndecls) Same. and add build pointer type pintio.
1547         (gfc_trans_inquire): Translate strm_pos for inquire.
1548         * ioparm.def: Reorder flags to accomodate addition of new inquire
1549         flag for strm_pos_out and add it in.
1550
1551 2006-08-06  Paul Thomas  <pault@gcc.gnu.org>
1552
1553         PR fortran/28590
1554         * parse.c (parse_derived): Remove the test for sequence type
1555         components of a sequence type.
1556         * resolve.c (resolve_fl_derived): Put the test here so that
1557         pointer components are tested.
1558
1559 2006-08-05  Steven G. Kargl <kargls@comcast.nt>
1560
1561         PR fortran/28548
1562         * resolve.c(resolve_elemental_actual): Add flags.h to use -pedantic
1563         and exclude conversion functions in conditional.  Change gfc_error
1564         to gfc_warning.
1565         (warn_unused_label) Rename to ...
1566         (warn_unused_fortran_label) avoid warn_unused_label in flags.h.
1567
1568 2006-07-30  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1569
1570         * intrinsic.c (add_functions): Add ACCESS, CHMOD, RSHIFT, LSHIFT.
1571         (add_subroutines): Add LTIME, GMTIME and CHMOD.
1572         * intrinsic.h (gfc_check_access_func, gfc_check_chmod,
1573         gfc_check_chmod_sub, gfc_check_ltime_gmtime, gfc_simplify_rshift,
1574         gfc_simplify_lshift, gfc_resolve_access, gfc_resolve_chmod,
1575         gfc_resolve_rshift, gfc_resolve_lshift, gfc_resolve_chmod_sub,
1576         gfc_resolve_gmtime, gfc_resolve_ltime): Add prototypes.
1577         * gfortran.h (gfc_generic_isym_id): Add GFC_ISYM_ACCESS,
1578         GFC_ISYM_CHMOD, GFC_ISYM_LSHIFT, GFC_ISYM_RSHIFT.
1579         * iresolve.c (gfc_resolve_access, gfc_resolve_chmod,
1580         gfc_resolve_rshift, gfc_resolve_lshift, gfc_resolve_chmod_sub,
1581         gfc_resolve_gmtime, gfc_resolve_ltime): New functions.
1582         * check.c (gfc_check_access_func, gfc_check_chmod,
1583         gfc_check_chmod_sub, gfc_check_ltime_gmtime): New functions.
1584         * trans-intrinsic.c (gfc_conv_intrinsic_rlshift): New function.
1585         (gfc_conv_intrinsic_function): Add cases for the new GFC_ISYM_*.
1586
1587 2006-07-28  Volker Reichelt  <reichelt@igpm.rwth-aachen.de>
1588
1589         * Make-lang.in: Use $(HEADER_H) instead of header.h in dependencies.
1590
1591 2006-07-26  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1592
1593         * intrinsic.c (add_functions): Add INT2, SHORT, INT8, LONG,
1594         LSTAT, MCLOCK and MCLOCK8 intrinsic functions.
1595         (add_subroutines): Add LSTAT intrinsic subroutine.
1596         * gfortran.h (gfc_generic_isym_id): Add GFC_ISYM_INT2,
1597         GFC_ISYM_INT8, GFC_ISYM_LONG, GFC_ISYM_LSTAT, GFC_ISYM_MCLOCK
1598         and GFC_ISYM_MCLOCK8.
1599         * iresolve.c (gfc_resolve_int2, gfc_resolve_int8,
1600         gfc_resolve_long, gfc_resolve_lstat, gfc_resolve_mclock,
1601         gfc_resolve_mclock8, gfc_resolve_lstat_sub): New functions.
1602         * check.c (gfc_check_intconv): New function.
1603         * trans-intrinsic.c (gfc_conv_intrinsic_function): Add cases for
1604         the added GFC_ISYM_*.
1605         * simplify.c (gfc_simplify_intconv, gfc_simplify_int2,
1606         gfc_simplify_int8, gfc_simplify_long): New functions.
1607         * intrinsic.h (gfc_check_intconv, gfc_simplify_int2,
1608         gfc_simplify_int8, gfc_simplify_long, gfc_resolve_int2,
1609         gfc_resolve_int8, gfc_resolve_long, gfc_resolve_lstat,
1610         gfc_resolve_mclock, gfc_resolve_mclock8, gfc_resolve_lstat_sub):
1611         Add prototypes.
1612
1613 2006-07-24  Erik Edelmann  <eedelman@gcc.gnu.org>
1614
1615         PR fortran/28416
1616         * trans-array.c (gfc_conv_array_parameter): Give special treatment for
1617         ALLOCATABLEs if they are themselves dummy variables.
1618
1619 2006-07-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1620
1621         PR fortran/25289
1622         * gfortran.h: Declare gfc_large_io_int_kind.
1623         * trans-types.c (gfc_init_kinds): Set gfc_large_io_int_kind
1624         to size 8 or 4.
1625         * trans-io.c (enum iofield_type): Add large_io_int type.
1626         (gfc_build_st_parameter): Same.
1627         (gfc_build_io_library_fndecls): Same.
1628         * ioparm_def: Use large_io_int to define rec.
1629
1630 2006-07-22  Steven Bosscher  <steven@gcc.gnu.org> 
1631
1632         PR fortran/28439
1633         * trans-stmt.c (gfc_trans_arithmetic_if): Evaluate the condition once.
1634
1635 2006-07-16  Jakub Jelinek  <jakub@redhat.com>
1636
1637         PR fortran/28390
1638         * trans-openmp.c (gfc_trans_omp_do): Look for LASTPRIVATE in
1639         code->exp.omp_clauses rather than in the 3rd function argument.
1640
1641 2006-07-16  Paul Thomas  <pault@gcc.gnu.org>
1642
1643         PR fortran/28384
1644         * trans-common.c (translate_common): If common_segment is NULL
1645         emit error that common block does not exist.
1646
1647         PR fortran/20844
1648         * io.c (check_io_constraints): It is an error if an ADVANCE
1649         specifier appears without an explicit format.
1650
1651         PR fortran/28201
1652         * resolve.c (resolve_generic_s): For a use_associated function,
1653         do not search for an alternative symbol in the parent name
1654         space.
1655
1656         PR fortran/20893
1657         * resolve.c (resolve_elemental_actual): New function t combine
1658         all the checks of elemental procedure actual arguments. In
1659         addition, check of array valued optional args(this PR) has
1660         been added.
1661         (resolve_function, resolve_call): Remove parts that treated
1662         elemental procedure actual arguments and call the above.
1663
1664 2006-07-14  Steven G. Kargl  <kargls@comcast.net>
1665
1666         * trans-expr.c (gfc_trans_string_copy): Evaluate the string lengths
1667
1668 006-07-13  Paul Thomas  <pault@gcc.gnu.org>
1669
1670         PR fortran/28353
1671         * trans-expr.c (gfc_conv_aliased_arg): Missing formal arg means
1672         that intent is INOUT (fixes regression).
1673
1674         PR fortran/25097
1675         * check.c (check_present): The only permitted reference is a
1676         full array reference.
1677
1678         PR fortran/20903
1679         * decl.c (variable_decl): Add error if a derived type is not
1680         from the current namespace if the namespace is an interface
1681         body.
1682
1683 2006-07-12  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1684
1685         PR fortran/28163
1686         * trans-expr.c (gfc_trans_string_copy): Generate inline code
1687         to perform string copying instead of calling a library function.
1688         * trans-decl.c (gfc_build_intrinsic_function_decls): Don't build
1689         decl for copy_string.
1690         * trans.h (gfor_fndecl_copy_string): Remove prototype.
1691
1692 2006-07-11  Feng Wang  <fengwang@nudt.edu.cn>
1693
1694         PR fortran/28213
1695         * trans-io.c (transfer_expr): Deal with Hollerith constants used in
1696         I/O list.
1697
1698 2006-07-07  Kazu Hirata  <kazu@codesourcery.com>
1699
1700         * intrinsic.texi: Fix typos.
1701
1702 2006-07-07  Paul Thomas  <pault@gcc.gnu.org>
1703
1704         PR fortran/28237
1705         PR fortran/23420
1706         * io.c (resolve_tag): Any integer that is not an assigned
1707         variable is an error.
1708
1709 2006-07-06  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1710
1711         PR fortran/28129
1712         * trans-array.c (gfc_trans_array_bound_check): Add a locus
1713         argument, and use it in the error messages.
1714         (gfc_conv_array_index_offset): Donc perform bounds checking on
1715         the last dimension of assumed-size arrays.
1716
1717 2006-07-06  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1718
1719         PR fortran/27874
1720         * trans-stmt.c (compute_inner_temp_size): Don't perform bounds
1721         checking when calculating the bounds of scalarization.
1722
1723 2006-07-05  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1724
1725         PR fortran/20892
1726         * interface.c (gfc_match_interface): Don't allow dummy procedures
1727         to have a generic interface.
1728
1729 2006-07-04  Paul Thomas  <pault@gcc.gnu.org>
1730
1731         PR fortran/28174
1732         * trans-array.c (gfc_conv_expr_descriptor): When building temp,
1733         ensure that the substring reference uses a new charlen.
1734         * trans-expr.c (gfc_conv_aliased_arg): Add the formal intent to
1735         the argument list, lift the treatment of missing string lengths
1736         from the above and implement the use of the intent.
1737         (gfc_conv_function_call): Add the extra argument to the call to
1738         the above.
1739
1740         PR fortran/28167
1741         * trans-array.c (get_array_ctor_var_strlen): Treat a constant
1742         substring reference.
1743         * array.c (gfc_resolve_character_array_constructor): Remove 
1744         static attribute and add the gfc_ prefix, make use of element
1745         charlens for the expression and pick up constant string lengths
1746         for expressions that are not themselves constant.
1747         * gfortran.h : resolve_character_array_constructor prototype
1748         added.
1749         * resolve.c (gfc_resolve_expr): Call resolve_character_array_
1750         constructor again after expanding the constructor, to ensure
1751         that the character length is passed to the expression.
1752
1753 2006-07-04  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1754             Daniel Franke  <franke.daniel@gmail.com>
1755
1756         * intrinsic.c (add_subroutines): Add ITIME and IDATE.
1757         * intrinsic.h (gfc_check_itime_idate,gfc_resolve_idate,
1758         fc_resolve_itime): New protos.
1759         * iresolve.c (gfc_resolve_itime, gfc_resolve_idate): New functions.
1760         * check.c (gfc_check_itime_idate): New function.
1761         * intrinsic.texi: Document the new intrinsics.
1762
1763 2006-07-03  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1764
1765         * intrinsics/date_and_time.c (itime0,idate0,itime_i4,itime_i8,
1766         idate_i4,idate_i8): New functions.
1767
1768
1769 2006-07-03  Asher Langton  <langton2@llnl.gov>
1770
1771         * decl.c (match_old_style_init): Add data attribute to symbol.
1772
1773 2006-07-03  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1774
1775         * iresolve.c (gfc_resolve_cpu_time, gfc_resolve_random_number):
1776         Remove ATTRIBUTE_UNUSED for used argument.
1777
1778 2006-07-03  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1779
1780         * intrinsic.texi: Document new intrinsics.
1781
1782 2006-07-01  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
1783
1784         PR fortran/19259
1785         * parse.c (next_free): Error out on line starting with semicolon.
1786         (next_fixed): Fix formatting.  Error out on line starting with
1787         semicolon.
1788
1789 2006-06-30  Kazu Hirata  <kazu@codesourcery.com>
1790
1791         * check.c: Fix a comment typo.
1792
1793 2006-06-25  Paul Thomas  <pault@gcc.gnu.org>
1794
1795         PR fortran/25056
1796         * interface.c (compare_actual_formal): Signal an error if the formal
1797         argument is a pure procedure and the actual is not pure.
1798
1799         PR fortran/27554
1800         * resolve.c (resolve_actual_arglist): If the type of procedure
1801         passed as an actual argument is not already declared, see if it is
1802         an intrinsic.
1803
1804         PR fortran/25073
1805         * resolve.c (resolve_select): Use bits 1 and 2 of a new int to
1806         keep track of  the appearance of constant logical case expressions.
1807         Signal an error is either value appears more than once.
1808
1809         PR fortran/20874
1810         * resolve.c (resolve_fl_procedure): Signal an error if an elemental
1811         function is not scalar valued.
1812
1813         PR fortran/20867
1814         * match.c (recursive_stmt_fcn): Perform implicit typing of variables.
1815
1816         PR fortran/22038
1817         * match.c (match_forall_iterator): Mark new variables as
1818         FL_UNKNOWN if the match fails.
1819
1820         PR fortran/28119
1821         * match.c (gfc_match_forall): Remove extraneous call to
1822         gfc_match_eos.
1823
1824         PR fortran/25072
1825         * resolve.c (resolve_code, resolve_function): Rework
1826         forall_flag scheme so that it is set and has a value of
1827         2, when the code->expr (ie. the forall mask) is resolved.
1828         This is used to change "block" to "mask" in the non-PURE
1829         error message.
1830
1831 2006-06-24  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1832
1833         PR fortran/28081
1834         * resolve.c (resolve_substring): Don't issue out-of-bounds
1835         error messages when the range has zero size.
1836
1837 2006-06-24  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1838
1839         PR fortran/23862
1840         * lang-specs.h (f95-cpp-input): Pass -ffree-form to f951 unless
1841         -ffixed-form is explicitly specified.
1842
1843 2006-06-24  Paul Thomas  <pault@gcc.gnu.org>
1844
1845         PR fortran/28118
1846         * trans-array.c (gfc_conv_expr_descriptor): When building temp,
1847         use the substring reference to calculate the length if the
1848         expression does not have a charlen.
1849
1850 2006-06-24  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1851
1852         PR fortran/28094
1853         * trans-intrinsic.c (gfc_conv_intrinsic_mod): Support cases where
1854         there is no integer kind equal to the resulting real kind.
1855         * intrinsic.c (add_functions): MODULO is not allowed as an actual
1856         argument.
1857
1858 2006-06-23  Steven G. Kargl  <kargls@comcast.net>
1859
1860         PR fortran/27981
1861         * match.c (gfc_match_if):  Handle errors in assignment in simple if.
1862
1863 2006-06-22  Asher Langton  <langton2@llnl.gov>
1864
1865         PR fortran/24748
1866         * primary.c (gfc_match_rvalue): Don't call match_substring for
1867         implicit non-character types.
1868
1869 2006-06-22  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1870
1871         PR libfortran/26769
1872         * iresolve.c (gfc_resolve_reshape): Call reshape_r4 and
1873         reshape_r8 instead of reshape_4 and reshape_8.
1874         (gfc_resolve_transpose): Likewise for transpose.
1875
1876 2006-06-21  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1877
1878         * trans-expr.c (gfc_conv_missing_dummy, gfc_conv_unary_op,
1879         gfc_conv_cst_int_power, gfc_conv_string_tmp,
1880         gfc_conv_function_call): Replace calls to convert on constant
1881         integer nodes by build_int_cst.
1882         * trans-stmt.c (gfc_trans_do): Likewise.
1883         * trans-io.c (set_internal_unit, transfer_namelist_element):
1884         Likewise.
1885         * trans-decl.c (build_entry_thunks): Likewise.
1886
1887 2006-06-20  Steven G. Kargl  <kargls@comcast.net>
1888
1889         * simplify.c (gfc_simplify_rrspacing): Initialize and clear mpfr_t
1890         variable.
1891
1892 2006-06-20  Paul Thomas  <pault@gcc.gnu.org>
1893
1894         PR fortran/25049
1895         PR fortran/25050
1896         * check.c (non_init_transformational): New function.
1897         (find_substring_ref): New function to signal use of disallowed
1898         transformational intrinsic in an initialization expression.
1899         (gfc_check_all_any): Call previous if initialization expr.
1900         (gfc_check_count): The same.
1901         (gfc_check_cshift): The same.
1902         (gfc_check_dot_product): The same.
1903         (gfc_check_eoshift): The same.
1904         (gfc_check_minloc_maxloc): The same.
1905         (gfc_check_minval_maxval): The same.
1906         (gfc_check_gfc_check_product_sum): The same.
1907         (gfc_check_pack): The same.
1908         (gfc_check_spread): The same.
1909         (gfc_check_transpose): The same.
1910         (gfc_check_unpack): The same.
1911
1912         PR fortran/18769
1913         *intrinsic.c (add_functions): Add gfc_simplify_transfer.
1914         *intrinsic.h : Add prototype for gfc_simplify_transfer.
1915         *simplify.c (gfc_simplify_transfer) : New function to act as
1916         placeholder for eventual implementation.  Emit error for now.
1917
1918         PR fortran/16206
1919         * expr.c (find_array_element): Eliminate condition on length of
1920         offset. Add bounds checking. Rearrange exit. Return try and
1921         put gfc_constructor result as an argument.
1922         (find_array_section): New function.
1923         (find_substring_ref): New function.
1924         (simplify_const_ref): Add calls to previous.
1925         (simplify_parameter_variable): Return on NULL expr.
1926         (gfc_simplify_expr): Only call gfc_expand_constructor for full
1927         arrays.
1928
1929         PR fortran/20876
1930         * match.c (gfc_match_forall): Add missing locus to gfc_code.
1931
1932 2006-06-18  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1933
1934         PR fortran/26801
1935         * trans-intrinsic.c (gfc_conv_associated): Use pre and post blocks
1936         of the scalarization expression.
1937
1938 2006-06-18  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1939
1940         PR fortran/19310
1941         PR fortran/19904
1942         * arith.c (gfc_range_check): Return ARITH_OK if -fno-range-check. Add
1943         return of ARITH_NAN, ARITH_UNDERFLOW, and ARITH_OVERFLOW.
1944         (gfc_arith_divide): If -fno-range-check allow mpfr to divide by zero.
1945         * gfortran.h (gfc_option_t): Add new flag.
1946         * invoke.texi: Document new flag.
1947         * lang.opt: Add option -frange-check.
1948         * options.c (gfc_init_options): Initialize new flag.
1949         (gfc_handle_options): Set flag if invoked.
1950         * simplify.c (range_check): Add error messages for
1951         overflow, underflow, and other errors.
1952         * trans-const.c (gfc_conv_mpfr_to_tree): Build NaN and Inf from mpfr
1953         result.
1954
1955 2006-06-17  Karl Berry  <karl@gnu.org>
1956
1957         * gfortran.texi (@dircategory): Use "Software development"
1958         instead of "Programming", following the Free Software Directory.
1959
1960 2006-06-16  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
1961
1962         PR fortran/27965
1963         * trans-array.c (gfc_conv_ss_startstride): Correct the runtime
1964         conditions for bounds-checking. Check for nonzero stride.
1965         Don't check the last dimension of assumed-size arrays. Fix the
1966         dimension displayed in the error message.
1967
1968 2006-06-15  Thomas Koenig <Thomas.Koenig@online.de>
1969
1970         * trans-array.h (gfc_trans_create_temp_array):  Add bool
1971         argument.
1972         * trans-arrray.c (gfc_trans_create_temp_array): Add extra
1973         argument "function" to show if we are translating a function.
1974         If we are translating a function, perform checks whether
1975         the size along any argument is negative.  In that case,
1976         allocate size 0.
1977         (gfc_trans_allocate_storage):  Add function argument (as
1978         false) to gfc_trans_create_temp_array call.
1979         * trans-expr.c (gfc_conv_function_call):  Add function
1980         argument (as true) to gfc_trans_create_temp_array call.
1981         * trans-stmt.c (gfc_conv_elemental_dependencies): Add
1982         function argument (as false) to gfc_trans_create_temp_array
1983         call.
1984         * trans-intrinsic.c:  Likewise.
1985
1986 2006-06-10  Paul Thomas  <pault@gcc.gnu.org>
1987
1988         PR fortran/24558
1989         PR fortran/20877
1990         PR fortran/25047
1991         * decl.c (get_proc_name): Add new argument to flag that a
1992         module function entry is being treated. If true, correct
1993         error condition, add symtree to module namespace and add
1994         a module procedure.
1995         (gfc_match_function_decl, gfc_match_entry,
1996         gfc_match_subroutine): Use the new argument in calls to
1997         get_proc_name.
1998         * resolve.c (resolve_entries): ENTRY symbol reference to
1999         to master entry namespace if a module function.
2000         * trans-decl.c (gfc_create_module_variable): Return if
2001         the symbol is an entry.
2002         * trans-exp.c (gfc_conv_variable): Check that parent_decl
2003         is not NULL.
2004
2005 2006-06-09  Jakub Jelinek  <jakub@redhat.com>
2006
2007         PR fortran/27916
2008         * trans-openmp.c (gfc_omp_clause_default_ctor): New function.
2009         * trans.h (gfc_omp_clause_default_ctor): New prototype.
2010         * f95-lang.c (LANG_HOOKS_OMP_CLAUSE_DEFAULT_CTOR): Define.
2011
2012 2006-06-08  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2013
2014         PR fortran/27958
2015         * trans-expr.c (gfc_conv_substring): If the substring start is
2016         greater than its end, the length of the substring is zero, and
2017         not negative.
2018         (gfc_trans_string_copy): Don't generate a call to
2019         _gfortran_copy_string when destination length is zero.
2020
2021 2006-06-08  Asher Langton  <langton2@llnl.gov>
2022         
2023         PR fortran/27786
2024         * trans-array.c (gfc_conv_array_ref): Eliminate bounds checking
2025         for assumed-size Cray pointees.
2026
2027 2006-06-08  Steven G. Kargl  <kargls@comcat.net>
2028
2029         * intrinsic.c (add_subroutine):  Make make_noreturn() conditional on
2030         the appropriate symbol name.
2031         
2032 2006-06-07  Paul Thomas  <pault@gcc.gnu.org>
2033
2034         PR fortran/23091
2035         * resolve.c (resolve_fl_variable): Error if an automatic
2036         object has the SAVE attribute.
2037
2038         PR fortran/24168
2039         * expr.c (simplify_intrinsic_op): Transfer the rank and
2040         the locus to the simplified expression.
2041
2042         PR fortran/25090
2043         PR fortran/25058
2044         * gfortran.h : Add int entry_id to gfc_symbol.
2045         * resolve.c : Add static variables current_entry_id and
2046         specification_expr.
2047         (resolve_variable): During code resolution, check if a
2048         reference to a dummy variable in an executable expression
2049         is preceded by its appearance as a parameter in an entry.
2050         Likewise check its specification expressions.
2051         (resolve_code): Update current_entry_id on EXEC_ENTRY.
2052         (resolve_charlen, resolve_fl_variable): Set and reset
2053         specifiaction_expr.
2054         (is_non_constant_shape_array): Do not return on detection
2055         of a variable but continue to resolve all the expressions.
2056         (resolve_codes): set current_entry_id to an out of range
2057         value.
2058
2059 2006-06-06  Mike Stump  <mrs@apple.com>
2060
2061         * Make-lang.in: Rename to htmldir to build_htmldir to avoid
2062         installing during build.
2063
2064 2006-06-06  Paul Thomas  <pault@gcc.gnu.org>
2065
2066         PR fortran/27897
2067         * match.c (gfc_match_common):  Fix code typo.  Remove
2068         sym->name, since sym is NULL, and replace with name.
2069
2070 2006-06-05  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2071
2072         PR libfortran/27895
2073         * resolve.c (compute_last_value_for_triplet): New function.
2074         (check_dimension): Correctly handle zero-sized array sections.
2075         Add checking on last element of array sections.
2076
2077 2006-06-05  Steven G. Kargl  <kargls@comcast.net>
2078
2079         * data.c (gfc_assign_data_value):  Fix comment typo.  Remove
2080         a spurious return.
2081
2082 2006-06-05  Paul Thomas  <pault@gcc.gnu.org>
2083
2084         PR fortran/14067
2085         * data.c (create_character_intializer): Add warning message
2086         for truncated string.
2087
2088         PR fortran/16943
2089         * symbol.c : Include flags.h.
2090         (gfc_add_type): If a procedure and types are the same do not
2091         throw an error unless standard is less than gnu or pedantic.
2092
2093         PR fortran/20839
2094         * parse.c (parse_do_block): Error if named block do construct
2095         does not have a named enddo.
2096
2097         PR fortran/27655
2098         * check.c (gfc_check_associated): Pick up EXPR_NULL for pointer
2099         as well as target and put error return at end of function.
2100
2101 2006-06-03  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2102
2103         * trans.c (gfc_msg_bounds, gfc_msg_fault, gfc_msg_wrong_return):
2104         Add strings for common runtime error messages.
2105         (gfc_trans_runtime_check): Add a locus argument, use a string
2106         and not a string tree for the message.
2107         * trans.h (gfc_trans_runtime_check): Change prototype accordingly.
2108         (gfc_msg_bounds, gfc_msg_fault, gfc_msg_wrong_return): Add proto.
2109         * trans-const.c (gfc_strconst_bounds, gfc_strconst_fault,
2110         gfc_strconst_wrong_return, gfc_strconst_current_filename): Remove.
2111         (gfc_init_constants): Likewise.
2112         * trans-const.h: Likewise.
2113         * trans-decl.c (gfc_build_builtin_function_decls): Call to
2114         _gfortran_runtime_error has only one argument, the message string.
2115         * trans-array.h (gfc_conv_array_ref): Add a symbol argument and a
2116         locus.
2117         * trans-array.c (gfc_trans_array_bound_check): Build precise
2118         error messages.
2119         (gfc_conv_array_ref): Use the new symbol argument and the locus
2120         to build more precise error messages.
2121         (gfc_conv_ss_startstride): More precise error messages.
2122         * trans-expr.c (gfc_conv_variable): Give symbol reference and
2123         locus to gfc_conv_array_ref.
2124         (gfc_conv_function_call): Use the new prototype for
2125         gfc_trans_runtime_check.
2126         * trans-stmt.c (gfc_trans_goto): Build more precise error message.
2127         * trans-io.c (set_string): Likewise.
2128         * trans-intrinsic.c (gfc_conv_intrinsic_bound): Use new prototype
2129         for gfc_trans_runtime_check.
2130
2131 2006-06-01  Thomas Koenig  <Thomas.Koenig@online.de>
2132
2133         PR fortran/27715
2134         * arith.c:  Cast the characters from the strings to unsigned
2135         char to avoid values less than 0 for extended ASCII.
2136
2137 2006-06-01  Per Bothner  <bothner@bothner.com>
2138
2139         * data.c (gfc_assign_data_value): Handle USE_MAPPED_LOCATION.
2140         * scanner.c (gfc_gobble_whitespace): Likewise.
2141
2142 2006-06-01  Paul Thomas  <pault@gcc.gnu.org>
2143
2144         PR fortran/25098
2145         PR fortran/25147
2146         * interface.c (compare_parameter): Return 1 if the actual arg
2147         is external and the formal is a procedure.
2148         (compare_actual_formal): If the actual argument is a variable
2149         and the formal a procedure, this an error.  If a gsymbol exists
2150         for a procedure of the same name, this is not yet resolved and
2151         the error is cleared.
2152
2153         * trans-intrinsic.c (gfc_conv_associated): Make provision for
2154         zero array length or zero string length contingent on presence
2155         of target, for consistency with standard.
2156
2157 2006-05-30  Asher Langton  <langton2@llnl.gov>
2158
2159         * symbol.c (check_conflict): Allow external, function, and
2160         subroutine attributes with Cray pointees.
2161         * trans-expr.c (gfc_conv_function_val): Translate Cray pointees
2162         that point to procedures.
2163         * gfortran.texi: Document new feature.
2164
2165 2006-05-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2166
2167         PR fortran/27634
2168         * io.c (check_format): Add error for missing period in format
2169         specifier unless -std=legacy.
2170         * gfortran.texi: Add description of expanded namelist read and
2171         missing period in format extensions.
2172
2173 2006-05-29  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2174
2175         PR fortran/19777
2176         * trans-array.c (gfc_conv_array_ref): Perform out-of-bounds
2177         checking for assumed-size arrrays for all but the last dimension.
2178
2179 2006-05-29  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2180
2181         * invoke.texi: Change -fpackderived into -fpack-derived.
2182
2183 2006-05-29  Kazu Hirata  <kazu@codesourcery.com>
2184
2185         * options.c, primary.c, resolve.c, trans-common.c: Fix typos
2186         in error messages.
2187
2188 2006-05-28  Kazu Hirata  <kazu@codesourcery.com>
2189
2190         * check.c, expr.c, resolve.c, trans-common.c,
2191         trans-intrinsic.c, trans-stmt.c, trans-types.c: Fix comment typos.
2192
2193 2006-05-27  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2194
2195         PR fortran/19777
2196         * trans-array.c (gfc_conv_array_ref): Don't perform out-of-bounds
2197         checking for assumed-size arrrays.
2198
2199 2006-05-27  Paul Thomas  <pault@gcc.gnu.org>
2200
2201         * trans-intrinsic.c (gfc_conv_associated): If pointer in first
2202         arguments has zero array length of zero string length, return
2203         false.
2204
2205 2006-05-26  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2206
2207         PR fortran/27524
2208         * trans-array.c (gfc_trans_dummy_array_bias): Don't use stride as
2209         a temporary variable when -fbounds-check is enabled, since its
2210         value will be needed later.
2211
2212 2006-05-26  Thomas Koenig  <Thomas.Koenig@online.de>
2213
2214         PR fortran/23151
2215         * io.c (match_io):  print (1,*) is an error.
2216
2217 2006-05-26  Paul Thomas  <pault@gcc.gnu.org>
2218
2219         PR fortran/27709
2220         * resolve.c (find_array_spec): Add gfc_symbol, derived, and
2221         use to track repeated component references.
2222
2223         PR fortran/27155
2224         PR fortran/27449
2225         * trans-intrinsic.c (gfc_conv_intrinsic_array_transfer): Use
2226         se->string_length throughout and use memcpy to populate the
2227         expression returned to the scalarizer.
2228         (gfc_size_in_bytes): New function.
2229
2230 2006-05-21  Paul Thomas  <pault@gcc.gnu.org>
2231
2232         PR fortran/27613
2233         * primary.c (gfc_match_rvalue): Test if symbol represents a
2234         direct recursive function reference.  Error if array valued,
2235         go to function0 otherwise.
2236
2237 2006-05-21  Paul Thomas  <pault@gcc.gnu.org>
2238
2239         PR fortran/25746
2240         * interface.c (gfc_extend_assign): Use new EXEC_ASSIGN_CALL.
2241         * gfortran.h : Put EXEC_ASSIGN_CALL in enum.
2242         * trans-stmt.c (gfc_conv_elemental_dependencies): New function.
2243         (gfc_trans_call): Call it.  Add new boolian argument to flag
2244         need for dependency checking. Assert intent OUT and IN for arg1
2245         and arg2.
2246         (gfc_trans_forall_1): Use new code EXEC_ASSIGN_CALL.
2247         trans-stmt.h : Modify prototype of gfc_trans_call.
2248         trans.c (gfc_trans_code): Add call for EXEC_ASSIGN_CALL.
2249         st.c (gfc_free_statement): Free actual for EXEC_ASSIGN_CALL.
2250         * dependency.c (gfc_check_fncall_dependency): Don't check other
2251         against itself.
2252
2253         PR fortran/25090
2254         * resolve.c : Remove resolving_index_expr.
2255         (entry_parameter): Remove.
2256         (gfc_resolve_expr, resolve_charlen, resolve_fl_variable): Lift
2257         calls to entry_parameter and references to resolving_index_expr.
2258
2259         PR fortran/27584
2260         * check.c (gfc_check_associated): Replace NULL assert with an
2261         error message, since it is possible to generate bad code that
2262         has us fall through to here..
2263
2264         PR fortran/19015
2265         * iresolve.c (maxloc, minloc): If DIM is not present, pass the
2266         rank of ARRAY as the shape of the result.  Otherwise, pass the
2267         shape of ARRAY, less the dimension DIM.
2268         (maxval, minval): The same, when DIM is present, otherwise no
2269         change.
2270
2271 2006-05-19  H.J. Lu  <hongjiu.lu@intel.com>
2272
2273         PR fortran/27662
2274         * trans-array.c (gfc_conv_expr_descriptor): Don't zero the
2275         first stride to indicate a temporary.
2276         * trans-expr.c (gfc_conv_function_call): Likewise.
2277
2278 2006-05-18  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2279             Feng Wang  <fengwang@nudt.edu.cn>
2280
2281         PR fortran/27552
2282         * dump-parse-tree.c (gfc_show_expr): Deal with Hollerith constants.
2283         * data.c (create_character_intializer): Set from_H flag if character is
2284         initialized by Hollerith constant.
2285
2286 2006-05-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2287
2288         PR fortran/26551
2289         * resolve.c (resolve_call, resolve_function): Issue an error
2290         if a function or subroutine call is recursive but the function or
2291         subroutine wasn't declared as such.
2292
2293 2006-05-07  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2294
2295         PR fortran/26551
2296         * gfortran.dg/recursive_check_1.f: New test.
2297
2298
2299 2006-05-17  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2300
2301         PR fortran/27320
2302         * dump-parse-tree.c (gfc_show_code_node): Try harder to find the
2303         called procedure name.
2304
2305 2006-05-17  Jakub Jelinek  <jakub@redhat.com>
2306
2307         PR middle-end/27415
2308         * trans-openmp.c (gfc_trans_omp_parallel_do,
2309         gfc_trans_omp_parallel_sections, gfc_trans_omp_parallel_workshare): Set
2310         OMP_PARALLEL_COMBINED flag.
2311
2312 2006-05-16  H.J. Lu  <hongjiu.lu@intel.com>
2313
2314         PR driver/26885
2315         * Make-lang.in (GFORTRAN_D_OBJS): Replace gcc.o with
2316         $(GCC_OBJS).
2317
2318 2006-05-15  Paul Thomas  <pault@gcc.gnu.org>
2319
2320         PR fortran/25090
2321         * resolve.c: Static resolving_index_expr initialized.
2322         (entry_parameter): New function to emit errors for variables
2323         that are not entry parameters.
2324         (gfc_resolve_expr): Call entry_parameter, when resolving
2325         variables, if the namespace has entries and resolving_index_expr
2326         is set.
2327         (resolve_charlen): Set resolving_index_expr before the call to
2328         resolve_index_expr and reset it afterwards.
2329         (resolve_fl_variable): The same before and after the call to
2330         is_non_constant_shape_array, which ultimately makes a call to
2331         gfc_resolve_expr.
2332
2333         PR fortran/25082
2334         * resolve.c (resolve_code): Add error condition that the return
2335         expression must be scalar.
2336
2337         PR fortran/27411
2338         * matchexp.c (gfc_get_parentheses): New function.
2339         (match_primary): Remove inline code and call above.
2340         * gfortran.h: Provide prototype for gfc_get_parentheses.
2341         * resolve.c (resolve_array_ref): Call the above, when start is a
2342         derived type variable array reference.
2343
2344 2006-05-15  Jakub Jelinek  <jakub@redhat.com>
2345
2346         PR fortran/27446
2347         * trans-openmp.c (gfc_trans_omp_array_reduction): Ensure
2348         OMP_CLAUSE_REDUCTION_{INIT,MERGE} are set to BIND_EXPR.
2349
2350 2006-05-14  H.J. Lu  <hongjiu.lu@intel.com>
2351
2352         * Make-lang.in (fortran/options.o): Depend on $(TARGET_H).
2353
2354 2006-05-11  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2355
2356         PR fortran/27553
2357         * parse.c (next_free): Return instead of calling decode_statement
2358         upon error.
2359
2360 2005-05-10  Thomas Koenig  <Thomas.Koenig@online.de>
2361
2362         PR fortran/27470
2363         * trans-array.c(gfc_array_allocate):  If ref->next exists
2364         that is if there is a statement like ALLOCATE(foo%bar(2)),
2365         F95 rules require that bar should be a pointer.
2366
2367 2006-05-10  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2368
2369         PR fortran/20460
2370         * resolve.c (gfc_resolve_index): Make REAL array indices a
2371         GFC_STD_LEGACY feature.
2372
2373 2006-05-10  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2374
2375         PR fortran/24549
2376         * parse.c (reject_statement): Clear gfc_new_block.
2377
2378 2006-05-09  Steven G. Kargl  <kargls@comcast.net>
2379
2380         * invoke.texi: Missed file in previous commit.  Update
2381          description of -fall-intrinsics
2382
2383 2006-05-07  Steven Boscher  <steven@gcc.gnu.org>
2384
2385         PR fortran/27378
2386         * parse.c (next_statement): Add check to avoid an ICE when
2387         gfc_current_locus.lb is not set.
2388
2389 2006-05-07  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
2390
2391         PR fortran/27457
2392         * match.c (match_case_eos): Error out on garbage following
2393         CASE(...).
2394
2395 2006-05-07  Paul Thomas  <pault@gcc.gnu.org>
2396
2397         PR fortran/24813
2398         * trans-array.c (get_array_ctor_strlen): Remove static attribute.
2399         * trans.h: Add prototype for get_array_ctor_strlen.
2400         * trans-intrinsic.c (gfc_conv_intrinsic_len): Switch on EXPR_ARRAY
2401         and call get_array_ctor_strlen.
2402
2403 2006-05-05  Steven G. Kargl  <kargls@comcast.net>
2404
2405         * invoke.texi: Update description of -fall-intrinsics
2406         * options.c (gfc_post_options): Disable -Wnonstd-intrinsics if
2407         -fall-intrinsics is used.
2408         (gfc_handle_option): Permit -Wno-nonstd-intrinsics.
2409
2410 2006-05-04  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
2411
2412         * simplify.c (ascii_table): Fix wrong entry.
2413
2414 2006-05-02  Steven G. Kargl  <kargls@comcast.net>
2415
2416         PR fortran/26896
2417         * lang.opt: Fix -Wtab description
2418
2419         PR fortran/20248  
2420         * lang.opt: New flag -fall-intrinsics.
2421         * invoke.texi:  Document option.
2422         * gfortran.h (options_t):  New member flag_all_intrinsics.
2423         * options.c (gfc_init_options, gfc_handle_option): Set new option.
2424         sort nearby misplaced options.
2425         * intrinsic.c (add_sym, make_generic, make_alias):  Use it.
2426
2427 2006-05-02 Paul Thomas <pault@gcc.gnu.org>
2428
2429         PR fortran/27269
2430         * module.c: Add static flag in_load_equiv.
2431         (mio_expr_ref): Return if no symtree and in_load_equiv.
2432         (load_equiv): If any of the equivalence members have no symtree, free
2433         the equivalence and the associated expressions.
2434
2435         PR fortran/27324
2436         * trans-common.c (gfc_trans_common): Invert the order of calls to
2437         finish equivalences and gfc_commit_symbols.
2438
2439 2006-04-29  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
2440
2441         PR fortran/25681
2442         * simplify.c (simplify_len): Character variables with constant
2443         length can be simplified.
2444
2445 2006-04-29  H.J. Lu  <hongjiu.lu@intel.com>
2446
2447         PR fortran/27351
2448         * trans-array.c (gfc_conv_array_transpose): Move gcc_assert
2449         before gfc_conv_expr_descriptor.
2450
2451 2006-04-23  Paul Thomas  <pault@gcc.gnu.org>
2452
2453         PR fortran/25099
2454         * resolve.c (resolve_call): Check conformity of elemental
2455         subroutine actual arguments.
2456
2457 2006-04-22  Jakub Jelinek  <jakub@redhat.com>
2458
2459         PR fortran/26769
2460         * iresolve.c (gfc_resolve_reshape): Use reshape_r16 for real(16).
2461         (gfc_resolve_transpose): Use transpose_r16 for real(16).
2462
2463 2006-04-21 Paul Thomas <pault@gcc.gnu.org>
2464
2465         PR fortran/27122
2466         * resolve.c (resolve_function): Remove general restriction on auto
2467         character length function interfaces.
2468         (gfc_resolve_uops): Check restrictions on defined operator
2469         procedures.
2470         (resolve_types): Call the check for defined operators.
2471
2472         PR fortran/27113
2473         * trans-array.c (gfc_trans_array_constructor_subarray): Remove
2474         redundant gfc_todo_error.
2475         (get_array_ctor_var_strlen): Remove typo in enum.
2476
2477 2006-04-18  Bernhard Fischer  <aldot@gcc.gnu.org>
2478
2479         * parse.c (next_free): Use consistent error string between
2480         free-form and fixed-form for illegal statement label of zero.
2481         (next_fixed): Use consistent warning string between free-form
2482         and fixed-form for statement labels for empty statements.
2483
2484 2006-04-18  Steve Ellcey  <sje@cup.hp.com>
2485
2486         * trans-io.c (gfc_build_io_library_fndecls): Align pad.
2487
2488 2006-04-16  Thomas Koenig  <Thomas.Koenig@online.de>
2489
2490         PR fortran/26017
2491         * trans-array.c(gfc_array_init_size):  Introduce or_expr
2492         which is true if the size along any dimension
2493         is negative.  Create a temporary variable with base
2494         name size.  If or_expr is true, set the temporary to 0,
2495         to the normal size otherwise.
2496
2497 2006-04-16  Paul Thomas  <pault@gcc.gnu.org>
2498
2499         PR fortran/26822
2500         * intrinsic.c (add_functions): Mark LOGICAL as elemental.
2501
2502         PR fortran/26787
2503         * expr.c (gfc_check_assign): Extend scope of error to include
2504         assignments to a procedure in the main program or, from a
2505         module or internal procedure that is not that represented by
2506         the lhs symbol. Use VARIABLE rather than l-value in message.
2507
2508         PR fortran/27096
2509         * trans-array.c (gfc_trans_deferred_array): If the backend_decl
2510         is not a descriptor, dereference and then test and use the type.
2511
2512         PR fortran/25597
2513         * trans-decl.c (gfc_trans_deferred_vars): Check if an array
2514         result, is also automatic character length.  If so, process
2515         the character length.
2516
2517         PR fortran/18003
2518         PR fortran/25669
2519         PR fortran/26834
2520         * trans_intrinsic.c (gfc_walk_intrinsic_bound): Set
2521         data.info.dimen for bound intrinsics.
2522         * trans_array.c (gfc_conv_ss_startstride): Pick out LBOUND and
2523         UBOUND intrinsics and supply their shape information to the ss
2524         and the loop.
2525
2526         PR fortran/27124
2527         * trans_expr.c (gfc_trans_function_call):  Add a new block, post,
2528         in to which all the argument post blocks are put.  Add this block
2529         to se->pre after a byref call or to se->post, otherwise.
2530
2531 2006-04-14  Roger Sayle  <roger@eyesopen.com>
2532
2533         * trans-io.c (set_string): Use fold_build2 and build_int_cst instead
2534         of build2 and convert to construct "x < 0" rather than "x <= -1".
2535
2536 2006-04-13  Richard Henderson  <rth@redhat.com>
2537
2538         * trans-openmp.c (gfc_trans_omp_sections): Adjust for changed
2539         number of operands to OMP_SECTIONS.
2540
2541 2006-04-08  Kazu Hirata  <kazu@codesourcery.com>
2542
2543         * gfortran.texi: Fix typos.  Follow spelling conventions.
2544         * resolve.c, trans-expr.c, trans-stmt.c: Fix comment typos.
2545         Follow spelling conventions.
2546
2547 2006-04-05  Roger Sayle  <roger@eyesopen.com>
2548
2549         * dependency.c (get_no_elements): Delete function.
2550         (get_deps): Delete function.
2551         (transform_sections): Delete function.
2552         (gfc_check_section_vs_section): Significant rewrite.
2553
2554 2006-04-04  H.J. Lu  <hongjiu.lu@intel.com>
2555
2556         PR fortran/25619
2557         * trans-array.c (gfc_conv_expr_descriptor): Only dereference
2558         character pointer when copying temporary.
2559
2560         PR fortran/23634
2561         * trans-array.c (gfc_conv_expr_descriptor): Properly copy
2562         temporary character with non constant size.
2563
2564 2006-04-03  Paul Thomas  <pault@gcc.gnu.org>
2565
2566         PR fortran/26891
2567         * trans.h: Prototype for gfc_conv_missing_dummy.
2568         * trans-expr (gfc_conv_missing_dummy): New function
2569         (gfc_conv_function_call): Call it and tidy up some of the code.
2570         * trans-intrinsic (gfc_conv_intrinsic_function_args): The same.
2571
2572         PR fortran/26976
2573         * array.c (gfc_array_dimen_size): If available, return shape[dimen].
2574         * resolve.c (resolve_function): If available, use the argument
2575         shape for the function expression.
2576         * iresolve.c (gfc_resolve_transfer): Set shape[0] = size.
2577
2578 2006-04-02  Erik Edelmann  <eedelman@gcc.gnu.org>
2579
2580         * trans-array.c (gfc_trans_dealloc_allocated): Take a
2581         tree representation of the array to be deallocated as argument
2582         instead of its gfc_symbol.
2583         (gfc_trans_deferred_array): Update call to
2584         gfc_trans_dealloc_allocated.
2585         * trans-array.h (gfc_trans_dealloc_allocated): Update
2586         prototype.
2587         * trans-expr.c (gfc_conv_function_call): Update call to
2588         gfc_trans_dealloc_allocated, get indirect reference to dummy
2589         arguments.
2590
2591 2006-04-01  Roger Sayle  <roger@eyesopen.com>
2592
2593         PR fortran/25270
2594         * trans-array.c (gfc_trans_allocate_array_storage): In array index
2595         calculations use gfc_index_zero_node and gfc_index_one_node instead
2596         of integer_zero_node and integer_one_node respectively.
2597         (gfc_conv_array_transpose): Likewise.
2598         (gfc_conv_ss_startstride): Likewise.
2599         (gfc_trans_dummy_array_bias): Likewise.
2600
2601 2006-04-01  Roger Sayle  <roger@eyesopen.com>
2602
2603         * dependency.c (gfc_is_inside_range): Delete.
2604         (gfc_check_element_vs_section): Significant rewrite.
2605
2606 2006-04-01  Roger Sayle  <roger@eyesopen.com>
2607
2608         * dependency.c (gfc_dep_compare_expr): Strip parentheses and unary
2609         plus operators when comparing expressions.  Handle comparisons of
2610         the form "X+C vs. X", "X vs. X+C", "X-C vs. X" and "X vs. X-C" where
2611         C is an integer constant.  Handle comparisons of the form "P+Q vs.
2612         R+S" and "P-Q vs. R-S".  Handle comparisons of integral extensions
2613         specially (increasing functions) so extend(A) > extend(B), when A>B.
2614         (gfc_check_element_vs_element): Move test later, so that we ignore
2615         the fact that "A < B" or "A > B" when A or B contains a forall index.
2616
2617 2006-03-31  Asher Langton  <langton2@llnl.gov>
2618
2619         PR fortran/25358
2620         * expr.c (gfc_check_assign): Allow cray pointee to be assumes-size.
2621         
2622 2006-03-30  Paul Thomas <paulthomas2@wanadoo.fr>
2623             Bud Davis  <bdavis9659@sbcglobal.net>
2624
2625         PR 21130
2626         * module.c (load_needed): Traverse entire tree before returning.
2627
2628 2006-03-30  Roger Sayle  <roger@eyesopen.com>
2629
2630         PR middle-end/22375
2631         * trans.c (gfc_trans_runtime_check): Promote the arguments of
2632         __builtin_expect to the correct types, and the result back to
2633         boolean_type_node.
2634
2635 2006-03-29  Carlos O'Donell  <carlos@codesourcery.com>
2636
2637         * Make-lang.in: Rename docdir to gcc_docdir.
2638
2639 2006-03-28  Steven G. Kargl  <kargls@comcast.net>
2640
2641         * intrinsic.texi: s/floor/float in previous commit.
2642
2643 2006-03-28 Paul Thomas <pault@gcc.gnu.org>
2644
2645         PR fortran/26779
2646         * resolve.c (resolve_fl_procedure): Do not check the access of
2647         derived types for internal procedures.
2648
2649 2006-03-27  Jakub Jelinek  <jakub@redhat.com>
2650
2651         * io.c (check_io_constraints): Don't look at
2652         dt->advance->value.charater.string, unless it is a CHARACTER
2653         constant.
2654
2655         * f95-lang.c (gfc_get_alias_set): New function.
2656         (LANG_HOOKS_GET_ALIAS_SET): Define.
2657
2658 2006-03-25  Steven G. Kargl  <kargls@comcast.net>
2659
2660         PR fortran/26816
2661         * intrinsic.c (add_functions): Allow FLOAT to accept all integer kinds.
2662         * intrinsic.texi: Document FLOAT.
2663
2664 2006-03-25  Thomas Koenig  <Thomas.Koenig@online.de>
2665
2666         PR fortran/26769
2667         * iresolve.c (gfc_resolve_reshape):  Remove doubling of
2668         kind for complex. For real(kind=10), call reshape_r10.
2669         (gfc_resolve_transpose):  For real(kind=10), call
2670         transpose_r10.
2671
2672 2006-03-25  Roger Sayle  <roger@eyesopen.com>
2673
2674         * dependency.c (gfc_check_dependency): Improve handling of pointers;
2675         Two variables of different types can't have a dependency, and two
2676         variables with the same symbol are equal, even if pointers.
2677
2678 2006-03-24  Roger Sayle  <roger@eyesopen.com>
2679
2680         * gfortran.h (gfc_symbol): Add a new "forall_index" bit field.
2681         * match.c (match_forall_iterator): Set forall_index field on
2682         the iteration variable's symbol.
2683         * dependency.c (contains_forall_index_p): New function to
2684         traverse a gfc_expr to check whether it contains a variable
2685         with forall_index set in it's symbol.
2686         (gfc_check_element_vs_element): Return GFC_DEP_EQUAL for scalar
2687         constant expressions that don't variables used as FORALL indices.
2688
2689 2006-03-22  Volker Reichelt  <reichelt@igpm.rwth-aachen.de>
2690
2691         PR driver/22600
2692         * error.c (gfc_fatal_error): Return ICE_EXIT_CODE instead of 4.
2693
2694 2006-03-22  Thomas Koenig  <Thomas.Koenig@online.de>
2695
2696         PR fortran/19303
2697         * gfortran.h (gfc_option_t):  Add record_marker.
2698         * lang.opt:  Add -frecord-marker=4 and -frecord-marker=8.
2699         * trans-decl.c:  Add gfor_fndecl_set_record_marker.
2700         (gfc_build_builtin_function_decls): Set
2701         gfor_fndecl_set_record_marker.
2702         (gfc_generate_function_code):  If we are in the main program
2703         and -frecord-marker was provided, call set_record_marker.
2704         * options.c (gfc_handle_option):  Add handling for
2705         -frecord-marker=4 and -frecord-marker=8.
2706         * invoke.texi:  Document -frecord-marker.
2707
2708 2006-03-22  Paul Thomas  <pault@gcc.gnu.org>
2709
2710         PR fortran/17298
2711         * trans-intrinsic.c (gfc_conv_intrinsic_array_transfer): New
2712         function to implement array valued TRANSFER intrinsic.
2713         (gfc_conv_intrinsic_function): Call the new function if TRANSFER
2714         and non-null se->ss.
2715         (gfc_walk_intrinsic_function): Treat TRANSFER as one of the
2716         special cases by calling gfc_walk_intrinsic_libfunc directly.
2717
2718 2006-03-21  Toon Moene  <toon@moene.indiv.nluug.nl>
2719
2720         * options.c (gfc_init_options): Initialize
2721         flag_argument_noalias to 3.
2722
2723 2006-03-20  Thomas Koenig  <Thomas.Koenig@online.de>
2724
2725         PR fortran/20935
2726         * iresolve.c (gfc_resolve_maxloc):   If mask is scalar,
2727         prefix the function name with an "s".  If the mask is scalar
2728         or if its kind is smaller than gfc_default_logical_kind,
2729         coerce it to default kind.
2730         (gfc_resolve_maxval):  Likewise.
2731         (gfc_resolve_minloc):  Likewise.
2732         (gfc_resolve_minval):  Likewise.
2733         (gfc_resolve_product):  Likewise.
2734         (gfc_resolve_sum):  Likewise.
2735
2736 2006-03-19  Paul Thomas  <pault@gcc.gnu.org>
2737
2738         PR fortran/26741
2739         *expr.c (external_spec_function): Permit elemental functions.
2740
2741         PR fortran/26716
2742         *interface.c (compare_actual_formal): Detect call for procedure
2743         usage and require rank checking, in this case, for assumed shape
2744         and deferred shape arrays.
2745         (gfc_procedure_use): Revert to pre-PR25070 call to
2746         compare_actual_formal that does not require rank checking..
2747
2748 2006-03-16  Roger Sayle  <roger@eyesopen.com>
2749
2750         * gfortran.h (gfc_equiv_info): Add length field.
2751         * trans-common.c (copy_equiv_list_to_ns): Set the length field.
2752         * dependency.c (gfc_are_equivalenced_arrays): Use both the offset
2753         and length fields to determine whether the two equivalenced symbols
2754         overlap in memory.
2755
2756 2006-03-14  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2757
2758         PR fortran/19101
2759         * gfortran.h: Add warn_ampersand.
2760         * invoke.texi: Add documentation for new option.
2761         * lang.opt: Add Wampersand.
2762         * options.c (gfc_init_options): Initialize warn_ampersand.
2763         (gfc_post_options): Set the warn if pedantic.
2764         (set_Wall): Set warn_ampersand.
2765         (gfc_handle_option: Add Wampersand for itself, -std=f95, and -std=f2003.
2766         * scanner.c (gfc_next_char_literal): Add test for missing '&' in
2767         continued character constant and give warning if missing.
2768
2769 2006-03-14  Steven G. Kargl  <kargls@comcast.net>
2770
2771         PR 18537
2772         * gfortran.h: Wrap Copyright line.
2773         (gfc_option_t): add warn_tabs member.
2774         * lang.opt: Update Coyright year.  Add the Wtabs.
2775         * invoke.texi: Document -Wtabs.
2776         * scanner.c (gfc_gobble_whitespace): Use warn_tabs.  Add linenum to
2777         suppress multiple warnings.
2778         (load_line): Use warn_tabs.  Add linenum, current_line, seen_comment
2779         to suppress multiple warnings.
2780         * options.c (gfc_init_options): Initialize warn_tabs.
2781         (set_Wall): set warn_tabs for -Wall.
2782         (gfc_post_options): Adjust flag_tabs depending on -pedantic.
2783         (gfc_handle_option):  Process command-line option -W[no-]tabs
2784
2785 2006-03-13  Paul Thomas  <pault@gcc.gnu.org>
2786
2787         PR fortran/25378
2788         * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc): Set the initial position to zero and
2789         modify the condition for updating it, to implement the F2003 requirement for all(mask)
2790         is false.
2791
2792 2006-03-13  Jakub Jelinek  <jakub@redhat.com>
2793
2794         * trans-openmp.c (gfc_trans_omp_variable): Handle references
2795         to parent result.
2796         * trans-expr.c (gfc_conv_variable): Remove useless setting
2797         of parent_flag, formatting.
2798
2799         * trans-decl.c (gfc_get_fake_result_decl): Re-add setting of
2800         GFC_DECL_RESULT flag.
2801
2802 2003-03-11  Roger Sayle  <roger@eyesopen.com>
2803
2804         * dependency.c (gfc_dep_compare_expr) <EXPR_OP>: Allow unary and
2805         binary operators to compare equal if their operands are equal.
2806         <EXPR_FUNCTION>: Allow "constant" intrinsic conversion functions
2807         to compare equal, if their operands are equal.
2808
2809 2006-03-11  Erik Edelmann  <eedelman@gcc.gnu.org>
2810
2811         * symbol.c (check_conflict): Allow allocatable function results,
2812         except for elemental functions.
2813         * trans-array.c (gfc_trans_allocate_temp_array): Rename to ...
2814         (gfc_trans_create_temp_array): ... this, and add new argument
2815         callee_alloc.
2816         (gfc_trans_array_constructor, gfc_conv_loop_setup): Update call
2817         to gfc_trans_allocate_temp_array.
2818         * trans-array.h (gfc_trans_allocate_temp_array): Update prototype.
2819         * trans-expr.c (gfc_conv_function_call): Use new arg of
2820         gfc_trans_create_temp_array avoid pre-allocation of temporary
2821         result variables of pointer AND allocatable functions.
2822         (gfc_trans_arrayfunc_assign): Return NULL for allocatable
2823         functions.
2824         * resolve.c (resolve_symbol): Copy value of 'allocatable' attribute
2825         from sym->result to sym.
2826
2827 2006-03-09  Erik Edelmann  <eedelman@gcc.gnu.org>
2828
2829         * trans-expr.c (gfc_add_interface_mapping): Copy 'allocatable'
2830         attribute from sym to new_sym.  Call build_fold_indirect_ref()
2831         for allocatable arguments.
2832
2833 2006-03-09 Paul Thomas <pault@gcc.gnu.org>
2834
2835         PR fortran/26257
2836         * trans-array.c (gfc_conv_expr_descriptor): Exclude calculation of
2837         the offset and data when se->data_not_needed is set.
2838         * trans.h: Include the data_not_need bit in gfc_se.
2839         * trans-intrinsic.c (gfc_conv_intrinsic_size): Set it for SIZE.
2840
2841 2006-03-06  Paul Thomas  <pault@gcc.gnu.org>
2842             Erik Edelmann  <eedelman@gcc.gnu.org>
2843
2844         * trans-array.c (gfc_trans_dealloc_allocated): New function.
2845         (gfc_trans_deferred_array): Use it, instead of inline code.
2846         * trans-array.h: Prototype for gfc_trans_dealloc_allocated().
2847         * trans-expr.c (gfc_conv_function_call): Deallocate allocated
2848         ALLOCATABLE, INTENT(OUT) arguments upon procedure entry.
2849
2850 2006-03-06  Paul Thomas  <pault@gcc.gnu.org>
2851
2852         PR fortran/26107
2853         * resolve.c (resolve_function): Add name after test for pureness.
2854
2855         PR fortran/19546
2856         * trans-expr.c (gfc_conv_variable): Detect reference to parent result,
2857         store current_function_decl, replace with parent, whilst calls are
2858         made to gfc_get_fake_result_decl, and restore afterwards. Signal this
2859         to gfc_get_fake_result_decl with a new argument, parent_flag.
2860         * trans-stmt.c (gfc_trans_return): gfc_get_fake_result_decl 2nd arg
2861         is set to zero.
2862         * trans.h: Add parent_flag to gfc_get_fake_result_decl prototype.
2863         * trans-decl.c (gfc_get_fake_result_decl): On parent_flag, being set,
2864         add decl to parent function. Replace refs to current_fake_result_decl
2865         with refs to this_result_decl.
2866         (gfc_generate_function_code): Null parent_fake_result_decl before the
2867         translation of code for contained procedures. Set parent_flag to zero
2868         in call to gfc_get_fake_result_decl.
2869         * trans-intrinsic.c (gfc_conv_intrinsic_len): The same.
2870
2871 2006-03-05  Steven G. Kargl  <kargls@comcast.net>
2872
2873         * simplify.c (gfc_simplify_verify):  Fix return when SET=''.
2874
2875 2006-03-05  Erik Edelmann  <eedelman@gcc.gnu.org>
2876
2877         PR fortran/16136
2878         * symbol.c (conf_std): New macro.
2879         (check_conflict): Use it to allow ALLOCATABLE dummy
2880         arguments for F2003.
2881         * trans-expr.c (gfc_conv_function_call): Pass the
2882         address of the array descriptor when dummy argument is
2883         ALLOCATABLE.
2884         * interface.c (compare_allocatable): New function.
2885         (compare_actual_formal): Use it.
2886         * resolve.c (resolve_deallocate_expr,
2887         resolve_allocate_expr): Check that INTENT(IN) variables
2888         aren't (de)allocated.
2889         * gfortran.texi (Fortran 2003 status): List ALLOCATABLE
2890         dummy arguments as supported.
2891
2892 2006-03-03  Roger Sayle  <roger@eyesopen.com>
2893
2894         * dependency.c (gfc_check_element_vs_element): Revert last change.
2895
2896 2006-03-03  Roger Sayle  <roger@eyesopen.com>
2897
2898         * dependency.c (gfc_check_element_vs_element): Consider two
2899         unordered scalar subscripts as (potentially) equal.
2900
2901 2006-03-03  Roger Sayle  <roger@eyesopen.com>
2902
2903         * dependency.c (gfc_check_dependency): Call gfc_dep_resolver to
2904         check whether two array references have a dependency.
2905         (gfc_check_element_vs_element): Assume lref and rref must be
2906         REF_ARRAYs.  If gfc_dep_compare_expr returns -2, assume these
2907         references could potentially overlap.
2908         (gfc_dep_resolver): Whitespace and comment tweaks.  Assume a
2909         dependency if the references have different depths.  Rewrite
2910         final term to clarrify we only have a dependency for overlaps.
2911
2912 2006-03-03  Thomas Koenig  <Thomas.Koenig@online.de>
2913
2914         PR fortran/25031
2915         * trans-array.h:  Adjust gfc_array_allocate prototype.
2916         * trans-array.c (gfc_array_allocate):  Change type of
2917         gfc_array_allocatate to bool.  Function returns true if
2918         it operates on an array.  Change second argument to gfc_expr.
2919         Find last reference in chain.
2920         If the function operates on an allocatable array, emit call to
2921         allocate_array() or allocate64_array().
2922         * trans-stmt.c (gfc_trans_allocate):  Code to follow to last
2923         reference has been moved to gfc_array_allocate.
2924         * trans.h:  Add declaration for gfor_fndecl_allocate_array and
2925         gfor_fndecl_allocate64_array.
2926         (gfc_build_builtin_function_decls):  Add gfor_fndecl_allocate_array
2927         and gfor_fndecl_allocate64_array.
2928
2929 2006-03-01  Roger Sayle  <roger@eyesopen.com>
2930
2931         * trans-stmt.c (generate_loop_for_temp_to_lhs): Add an additional
2932         INVERT argument to invert the sense of the WHEREMASK argument.
2933         Remove unneeded code to AND together a list of masks.
2934         (generate_loop_for_rhs_to_temp): Likewise.
2935         (gfc_trans_assign_need_temp): Likewise.
2936         (gfc_trans_forall_1): Likewise.
2937         (gfc_evaluate_where_mask): Likewise, add a new INVERT argument
2938         to specify the sense of the MASK argument.
2939         (gfc_trans_where_assign): Likewise.
2940         (gfc_trans_where_2): Likewise.  Restructure code that decides
2941         whether we need to allocate zero, one or two temporary masks.
2942         If this is a top-level WHERE (i.e. the incoming MASK is NULL),
2943         we only need to allocate at most one temporary mask, and can
2944         invert it's sense to provide the complementary pending execution
2945         mask.  Only calculate the size of the required temporary arrays
2946         if we need any.
2947         (gfc_trans_where): Update call to gfc_trans_where_2.
2948
2949 2006-03-01  Paul Thomas  <pault@gcc.gnu.org>
2950
2951         * iresolve.c (gfc_resolve_dot_product):  Remove any difference in
2952         treatment of logical types.
2953         * trans-intrinsic.c (gfc_conv_intrinsic_dot_product):  New function. 
2954
2955         PR fortran/26393
2956         * trans-decl.c (gfc_get_symbol_decl): Extend condition that symbols
2957         must be referenced to include unreferenced symbols in an interface
2958         body. 
2959
2960         PR fortran/20938
2961         * trans-array.c (gfc_conv_resolve_dependencies): Add call to
2962         gfc_are_equivalenced_arrays.
2963         * symbol.c (gfc_free_equiv_infos, gfc_free_equiv_lists): New
2964         functions. (gfc_free_namespace): Call them.
2965         * trans-common.c (copy_equiv_list_to_ns): New function.
2966         (add_equivalences): Call it.
2967         * gfortran.h: Add equiv_lists to gfc_namespace and define
2968         gfc_equiv_list and gfc_equiv_info.
2969         * dependency.c (gfc_are_equivalenced_arrays): New function.
2970         (gfc_check_dependency): Call it.
2971         * dependency.h: Prototype for gfc_are_equivalenced_arrays.
2972
2973 2006-03-01  Roger Sayle  <roger@eyesopen.com>
2974
2975         * dependency.c (gfc_is_same_range): Compare the stride, lower and
2976         upper bounds when testing array reference ranges for equality.
2977         (gfc_check_dependency): Fix indentation whitespace.
2978         (gfc_check_element_vs_element): Likewise.
2979         (gfc_dep_resolver): Likewise.
2980
2981 2006-02-28  Thomas Koenig  <Thomas.Koenig@online.de>
2982
2983         * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc):
2984         If the mask expression exists and has rank 0, enclose the
2985         generated loop in an "if (mask)".  Put the default
2986         initialization into the else branch.
2987
2988 2006-02-25  Thomas Koenig  <Thomas.Koenig@online.de>
2989
2990         PR fortran/23092
2991         * trans-intrinsic.c (gfc_conv_intrinsic_arith):  If the
2992         mask expression exists and has rank 0, enclose the generated
2993         loop in an "if (mask)".
2994         * (gfc_conv_intrinsic_minmaxloc):  Likewise.
2995
2996 2006-02-24  Paul Thomas  <pault@gcc.gnu.org>
2997
2998         PR fortran/26409
2999         * resolve.c (resolve_contained_functions, resolve_types,
3000         gfc_resolve): Revert patch of 2006-02-19.
3001
3002 2006-02-24  Paul Thomas  <pault@gcc.gnu.org>
3003
3004         PR fortran/24519
3005         * dependency.c (gfc_is_same_range): Correct typo.
3006         (gfc_check_section_vs_section): Call gfc_is_same_range.
3007
3008         PR fortran/25395
3009         * trans-common.c (add_equivalences): Add a new flag that is set when
3010         an equivalence is seen that prevents more from being reset until the
3011         start of a new traversal of the list, thus ensuring completion of
3012         all the equivalences.
3013
3014 2006-02-23  Erik Edelmann  <eedelman@gcc.gnu.org>
3015
3016         * module.c (read_module): Remove redundant code lines.
3017
3018 2006-02-20 Rafael \81Ávila de Esp\81índola <rafael.espindola@gmail.com>
3019         * Make-lang.in (FORTRAN): Remove
3020         (.PHONY): Remove F95 and f95. Add fortran
3021
3022 2006-02-20  Roger Sayle  <roger@eyesopen.com>
3023
3024         * trans-stmt.c (gfc_trans_where_2): Avoid updating unused current
3025         execution mask for empty WHERE/ELSEWHERE clauses.  Don't allocate
3026         temporary mask arrays if they won't be used.
3027
3028 2006-02-20  Roger Sayle  <roger@eyesopen.com>
3029
3030         * trans-stmt.c (gfc_trans_where_assign): Remove code to handle
3031         traversing a linked list of MASKs.  The MASK is now always a
3032         single element requiring no ANDing during the assignment.
3033
3034 2006-02-19  Thomas Koenig  <Thomas.Koenig@online.de>
3035
3036         * gfortran.texi:  Document environment variables which
3037         influence runtime behavior.
3038
3039 2006-02-19  H.J. Lu  <hongjiu.lu@intel.com>
3040
3041         * resolve.c (resolve_contained_functions): Call resolve_entries
3042         first.
3043         (resolve_types): Remove calls to resolve_entries and
3044         resolve_contained_functions.
3045         (gfc_resolve): Call resolve_contained_functions.
3046
3047 2006-02-19  Erik Edelmann  <eedelman@gcc.gnu.org>
3048
3049         PR fortran/26201
3050         * intrinsic.c (gfc_convert_type_warn): Call
3051         gfc_intrinsic_symbol() on the newly created symbol.
3052
3053 2006-02-19  Paul Thomas  <pault@gcc.gnu.org>
3054
3055         PR fortran/25054
3056         * resolve.c (is_non_constant_shape_array): New function.
3057         (resolve_fl_variable): Remove code for the new function and call it.
3058         (resolve_fl_namelist): New function.  Add test for namelist array
3059         with non-constant shape, using is_non_constant_shape_array.
3060         (resolve_symbol): Remove code for resolve_fl_namelist and call it.
3061
3062         PR fortran/25089
3063         * match.c (match_namelist): Increment the refs field of an accepted
3064         namelist object symbol.
3065         * resolve.c (resolve_fl_namelist): Test namelist objects for a conflict
3066         with contained or module procedures.
3067
3068 2006-02-18  Roger Sayle  <roger@eyesopen.com>
3069
3070         * trans-stmt.c (struct temporary_list): Delete.
3071         (gfc_trans_where_2): Major reorganization.  Remove no longer needed
3072         TEMP argument.  Allocate and deallocate the control mask and
3073         pending control mask locally.
3074         (gfc_trans_forall_1): Delete TEMP local variable, and update
3075         call to gfc_trans_where_2.  No need to deallocate arrays after.
3076         (gfc_evaluate_where_mask): Major reorganization.  Change return
3077         type to void.  Pass in parent execution mask, MASK, and two
3078         already allocated mask arrays CMASK and PMASK.  On return
3079         CMASK := MASK & COND, PMASK := MASK & !COND.  MASK, CMASK and
3080         CMASK may all be NULL, or refer to the same temporary arrays.
3081         (gfc_trans_where): Update call to gfc_trans_where_2.  We no
3082         longer need a TEMP variable or to deallocate temporary arrays
3083         allocated by gfc_trans_where_2.
3084
3085 2006-02-18   Danny Smith  <dannysmith@users.sourceforeg.net>
3086
3087         * gfortran.h (gfc_add_attribute): Change uint to unsigned int.
3088         * symbol.c (gfc_add_attribute): Likewise for definition.
3089         * resolve.c (resolve_global_procedure): Likewise for variable 'type'.
3090
3091 2006-02-17  Richard Sandiford  <richard@codesourcery.com>
3092
3093         * trans-common.c: Include rtl.h earlier.
3094         * trans-decl.c: Likewise.
3095
3096 2006-02-16  Jakub Jelinek  <jakub@redhat.com>
3097
3098         PR fortran/26224
3099         * parse.c (parse_omp_do, parse_omp_structured_block): Call
3100         gfc_commit_symbols and gfc_warning_check.
3101
3102         * openmp.c (resolve_omp_clauses): Add a dummy case label to workaround
3103         PR middle-end/26316.
3104
3105 2006-02-16  Paul Thomas  <pault@gcc.gnu.org>
3106
3107         PR fortran/24557
3108         * trans-expr.c (gfc_add_interface_mapping): Use the actual argument
3109         for character(*) arrays, rather than casting to the type and kind
3110         parameters of the formal argument.
3111
3112 2006-02-15  Toon Moene  <toon@moene.indiv.nluug.nl>
3113
3114         PR fortran/26054
3115         * options.c: Do not warn for Fortran 2003 features by default.
3116
3117 2006-02-15  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
3118
3119         * check.c: Update copyright years.
3120         
3121         * check.c (gfc_check_minloc_maxloc, check_reduction): Don't call
3122         dim_range_check on not-present optional dim argument.
3123
3124 2006-02-15  Jakub Jelinek  <jakub@redhat.com>
3125
3126         PR libgomp/25938
3127         PR libgomp/25984
3128         * Make-lang.in (install-finclude-dir): New goal.
3129         (fortran.install-common): Depend on install-finclude-dir.
3130         * lang-specs.h: If not -nostdinc, add -I finclude.
3131
3132 2006-02-14  Thomas Koenig  <Thomas.Koenig@online.de>
3133
3134         PR fortran/25045
3135         * check.c (dim_check):  Perform all checks if dim is optional.
3136         (gfc_check_minloc_maxloc):  Use dim_check and dim_rank_check
3137         to check dim argument.
3138         (check_reduction):  Likewise.
3139
3140 2006-02-14  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
3141
3142         PR fortran/26277
3143         * io.c (match_ltag): Mark label as referenced.
3144
3145 2006-02-14  Jakub Jelinek  <jakub@redhat.com>
3146             Richard Henderson  <rth@redhat.com>
3147             Diego Novillo  <dnovillo@redhat.com>
3148
3149         * invoke.texi: Document -fopenmp.
3150         * gfortran.texi (Extensions): Document OpenMP.
3151
3152         Backport from gomp-20050608-branch
3153         * trans-openmp.c: Call build_omp_clause instead of
3154         make_node when creating OMP_CLAUSE_* trees.
3155         (gfc_trans_omp_reduction_list): Remove argument 'code'.
3156         Adjust all callers.
3157
3158         * trans.h (build4_v): Define.
3159         * trans-openmp.c: Call build4_v to create OMP_PARALLEL nodes.
3160         Call build3_v to create OMP_SECTIONS nodes.
3161
3162         PR fortran/25162
3163         * openmp.c (gfc_match_omp_variable_list): Call gfc_set_sym_referenced
3164         on all symbols added to the variable list.
3165
3166         * openmp.c (gfc_match_omp_clauses): Fix check for non-INTRINSIC
3167         procedure symbol in REDUCTION.
3168
3169         * trans-openmp.c (gfc_trans_omp_array_reduction): Use gfc_add
3170         for MINUS_EXPR OMP_CLAUSE_REDUCTION_CODE.
3171
3172         * trans-openmp.c (gfc_trans_omp_do): Add PBLOCK argument.  If PBLOCK
3173         is non-NULL, evaluate INIT/COND/INCR and chunk size expressions in
3174         that statement block.
3175         (gfc_trans_omp_parallel_do): Pass non-NULL PBLOCK to gfc_trans_omp_do
3176         for non-ordered non-static combined loops.
3177         (gfc_trans_omp_directive): Pass NULL PBLOCK to gfc_trans_omp_do.
3178
3179         * openmp.c: Include target.h and toplev.h.
3180         (gfc_match_omp_threadprivate): Emit diagnostic if target does
3181         not support TLS.
3182         * Make-lang.in (fortran/openmp.o): Add dependencies on
3183         target.h and toplev.h.
3184
3185         * trans-decl.c (gfc_get_fake_result_decl): Set GFC_DECL_RESULT.
3186         * trans-openmp.c (gfc_omp_privatize_by_reference): Make
3187         DECL_ARTIFICIAL vars predetermined shared except GFC_DECL_RESULT.
3188         (gfc_omp_disregard_value_expr): Handle GFC_DECL_RESULT.
3189         (gfc_trans_omp_variable): New function.
3190         (gfc_trans_omp_variable_list, gfc_trans_omp_reduction_list): Use it.
3191         * trans.h (GFC_DECL_RESULT): Define.
3192
3193         * trans-openmp.c (gfc_omp_firstprivatize_type_sizes): New function.
3194         * f95-lang.c (LANG_HOOKS_OMP_FIRSTPRIVATIZE_TYPE_SIZES): Define.
3195         * trans.h (gfc_omp_firstprivatize_type_sizes): New prototype.
3196
3197         * trans-openmp.c (gfc_omp_privatize_by_reference): Return
3198         true if a pointer has GFC_DECL_SAVED_DESCRIPTOR set.
3199         (gfc_trans_omp_array_reduction, gfc_trans_omp_reduction_list): New
3200         functions.
3201         (gfc_trans_omp_clauses): Add WHERE argument.  Call
3202         gfc_trans_omp_reduction_list rather than gfc_trans_omp_variable_list
3203         for reductions.
3204         (gfc_trans_omp_do, gfc_trans_omp_parallel, gfc_trans_omp_parallel_do,
3205         gfc_trans_omp_parallel_sections, gfc_trans_omp_parallel_workshare,
3206         gfc_trans_omp_sections, gfc_trans_omp_single): Adjust
3207         gfc_trans_omp_clauses callers.
3208
3209         * openmp.c (omp_current_do_code): New var.
3210         (gfc_resolve_omp_do_blocks): New function.
3211         (gfc_resolve_omp_parallel_blocks): Call it.
3212         (gfc_resolve_do_iterator): Add CODE argument.  Don't propagate
3213         predetermination if argument is !$omp do or !$omp parallel do
3214         iteration variable.
3215         * resolve.c (resolve_code): Call gfc_resolve_omp_do_blocks
3216         for EXEC_OMP_DO.  Adjust gfc_resolve_do_iterator caller.
3217         * fortran.h (gfc_resolve_omp_do_blocks): New prototype.
3218         (gfc_resolve_do_iterator): Add CODE argument.
3219
3220         * trans.h (gfc_omp_predetermined_sharing,
3221         gfc_omp_disregard_value_expr, gfc_omp_private_debug_clause): New
3222         prototypes.
3223         (GFC_DECL_COMMON_OR_EQUIV, GFC_DECL_CRAY_POINTEE): Define.
3224         * trans-openmp.c (gfc_omp_predetermined_sharing,
3225         gfc_omp_disregard_value_expr, gfc_omp_private_debug_clause): New
3226         functions.
3227         * trans-common.c (build_equiv_decl, build_common_decl,
3228         create_common): Set GFC_DECL_COMMON_OR_EQUIV flag on the decls.
3229         * trans-decl.c (gfc_finish_cray_pointee): Set GFC_DECL_CRAY_POINTEE
3230         on the decl.
3231         * f95-lang.c (LANG_HOOKS_OMP_PREDETERMINED_SHARING,
3232         LANG_HOOKS_OMP_DISREGARD_VALUE_EXPR,
3233         LANG_HOOKS_OMP_PRIVATE_DEBUG_CLAUSE): Define.
3234
3235         * openmp.c (resolve_omp_clauses): Remove extraneous comma.
3236
3237         * symbol.c (check_conflict): Add conflict between cray_pointee and
3238         threadprivate.
3239         * openmp.c (gfc_match_omp_threadprivate): Fail if
3240         gfc_add_threadprivate returned FAILURE.
3241         (resolve_omp_clauses): Diagnose Cray pointees in SHARED,
3242         {,FIRST,LAST}PRIVATE and REDUCTION clauses and Cray pointers in
3243         {FIRST,LAST}PRIVATE and REDUCTION clauses.
3244
3245         * resolve.c (omp_workshare_flag): New variable.
3246         (resolve_function): Diagnose use of non-ELEMENTAL user defined
3247         function in WORKSHARE construct.
3248         (resolve_code): Cleanup forall_save use.  Make sure omp_workshare_flag
3249         is set to correct value in different contexts.
3250
3251         * openmp.c (resolve_omp_clauses): Replace %s with '%s' when printing
3252         variable name.
3253         (resolve_omp_atomic): Likewise.
3254
3255         PR fortran/24493
3256         * scanner.c (skip_free_comments): Set at_bol at the beginning of the
3257         loop, not before it.
3258         (skip_fixed_comments): Handle ! comments in the middle of line here
3259         as well.
3260         (gfc_skip_comments): Use skip_fixed_comments for FIXED_FORM even if
3261         not at BOL.
3262         (gfc_next_char_literal): Fix expected canonicalized *$omp string.
3263
3264         * trans-openmp.c (gfc_trans_omp_do): Use make_node and explicit
3265         initialization to build OMP_FOR instead of build.
3266
3267         * trans-decl.c (gfc_gimplify_function): Invoke
3268         diagnose_omp_structured_block_errors.
3269
3270         * trans-openmp.c (gfc_trans_omp_master): Use OMP_MASTER.
3271         (gfc_trans_omp_ordered): Use OMP_ORDERED.
3272
3273         * gfortran.h (gfc_resolve_do_iterator, gfc_resolve_blocks,
3274         gfc_resolve_omp_parallel_blocks): New prototypes.
3275         * resolve.c (resolve_blocks): Renamed to...
3276         (gfc_resolve_blocks): ... this.  Remove static.
3277         (gfc_resolve_forall): Adjust caller.
3278         (resolve_code): Only call gfc_resolve_blocks if code->block != 0
3279         and not for EXEC_OMP_PARALLEL* directives.  Call
3280         gfc_resolve_omp_parallel_blocks for EXEC_OMP_PARALLEL* directives.
3281         Call gfc_resolve_do_iterator if resolved successfully EXEC_DO
3282         iterator.
3283         * openmp.c: Include pointer-set.h.
3284         (omp_current_ctx): New variable.
3285         (gfc_resolve_omp_parallel_blocks, gfc_resolve_do_iterator): New
3286         functions.
3287         * Make-lang.in (fortran/openmp.o): Depend on pointer-set.h.
3288
3289         * openmp.c (gfc_match_omp_clauses): For max/min/iand/ior/ieor,
3290         look up symbol if it exists, use its name instead and, if it is not
3291         INTRINSIC, issue diagnostics.
3292
3293         * parse.c (parse_omp_do): Handle implied end do properly.
3294         (parse_executable): If parse_omp_do returned ST_IMPLIED_ENDDO,
3295         return it instead of continuing.
3296
3297         * trans-openmp.c (gfc_trans_omp_critical): Update for changed
3298         operand numbering.
3299         (gfc_trans_omp_do, gfc_trans_omp_parallel, gfc_trans_omp_parallel_do,
3300         gfc_trans_omp_parallel_sections, gfc_trans_omp_parallel_workshare,
3301         gfc_trans_omp_sections, gfc_trans_omp_single): Likewise.
3302
3303         * trans.h (gfc_omp_privatize_by_reference): New prototype.
3304         * f95-lang.c (LANG_HOOKS_OMP_PRIVATIZE_BY_REFERENCE): Redefine
3305         to gfc_omp_privatize_by_reference.
3306         * trans-openmp.c (gfc_omp_privatize_by_reference): New function.
3307
3308         * trans-stmt.h (gfc_trans_omp_directive): Add comment.
3309
3310         * openmp.c (gfc_match_omp_variable_list): Add ALLOW_COMMON argument.
3311         Disallow COMMON matching if it is set.
3312         (gfc_match_omp_clauses, gfc_match_omp_flush): Adjust all callers.
3313         (resolve_omp_clauses): Show locus in error messages.  Check that
3314         variable types in reduction clauses are appropriate for reduction
3315         operators.
3316
3317         * resolve.c (resolve_symbol): Don't error if a threadprivate module
3318         variable isn't SAVEd.
3319
3320         * trans-openmp.c (gfc_trans_omp_do): Put count into BLOCK, not BODY.
3321         Fix typo in condition.  Fix DOVAR initialization.
3322
3323         * openmp.c (gfc_match_omp_clauses): Match min/iand/ior/ieor
3324         rather than .min. etc.
3325
3326         * trans-openmpc.c (omp_not_yet): Remove.
3327         (gfc_trans_omp_parallel_do): Keep listprivate clause on parallel.
3328         Force creation of BIND_EXPR around the workshare construct.
3329         (gfc_trans_omp_parallel_sections): Likewise.
3330         (gfc_trans_omp_parallel_workshare): Likewise.
3331
3332         * types.def (BT_I16, BT_FN_I16_VPTR_I16,
3333         BT_FN_BOOL_VPTR_I16_I16, BT_FN_I16_VPTR_I16_I16): Add.
3334
3335         * trans-openmp.c (gfc_trans_omp_clauses): Create OMP_CLAUSE_DEFAULT.
3336         (gfc_trans_omp_code): New function.
3337         (gfc_trans_omp_do): Use it, remove omp_not_yet uses.
3338         (gfc_trans_omp_parallel, gfc_trans_omp_single): Likewise.
3339         (gfc_trans_omp_sections): Likewise.  Only treat empty last section
3340         specially if lastprivate clause is present.
3341         * f95-lang.c (gfc_init_builtin_functions): Create BUILT_IN_TRAP
3342         builtin.
3343
3344         * trans-openmp.c (gfc_trans_omp_variable_list): Update for
3345         OMP_CLAUSE_DECL name change.
3346         (gfc_trans_omp_do): Likewise.
3347
3348         * trans-openmp.c (gfc_trans_omp_clauses): Create OMP_CLAUSE_REDUCTION
3349         clauses.
3350         (gfc_trans_omp_atomic): Build OMP_ATOMIC instead of expanding
3351         sync builtins directly.
3352         (gfc_trans_omp_single): Build OMP_SINGLE statement.
3353
3354         * trans-openmp.c (gfc_trans_add_clause): New.
3355         (gfc_trans_omp_variable_list): Take a tree code and build the clause
3356         node here.  Link it to the head of a list.
3357         (gfc_trans_omp_clauses): Update to match.
3358         (gfc_trans_omp_do): Use gfc_trans_add_clause.
3359
3360         * trans-openmp.c (gfc_trans_omp_clauses): Change second argument to
3361         gfc_omp_clauses *.  Use gfc_evaluate_now instead of creating
3362         temporaries by hand.
3363         (gfc_trans_omp_atomic, gfc_trans_omp_critical): Use buildN_v macros.
3364         (gfc_trans_omp_do): New function.
3365         (gfc_trans_omp_master): Dont' check for gfc_trans_code returning NULL.
3366         (gfc_trans_omp_parallel): Adjust gfc_trans_omp_clauses caller.
3367         Use buildN_v macros.
3368         (gfc_trans_omp_parallel_do, gfc_trans_omp_parallel_sections,
3369         gfc_trans_omp_parallel_workshare, gfc_trans_omp_sections,
3370         gfc_trans_omp_single, gfc_trans_omp_workshare): New functions.
3371         (gfc_trans_omp_directive): Use them.
3372         * parse.c (parse_omp_do): Allow new_st.op == EXEC_NOP.
3373         * openmp.c (resolve_omp_clauses): Check for list items present
3374         in multiple clauses.
3375         (resolve_omp_do): Check that iteration variable is not THREADPRIVATE
3376         and is not present in any clause variable lists other than PRIVATE
3377         or LASTPRIVATE.
3378
3379         * gfortran.h (symbol_attribute): Add threadprivate bit.
3380         (gfc_common_head): Add threadprivate member, change use_assoc
3381         and saved into char to save space.
3382         (gfc_add_threadprivate): New prototype.
3383         * symbol.c (check_conflict): Handle threadprivate.
3384         (gfc_add_threadprivate): New function.
3385         (gfc_copy_attr): Copy threadprivate.
3386         * trans-openmp.c (gfc_trans_omp_clauses): Avoid creating a temporary
3387         if IF or NUM_THREADS is constant.  Create OMP_CLAUSE_SCHEDULE and
3388         OMP_CLAUSE_ORDERED.
3389         * resolve.c (resolve_symbol): Complain if a THREADPRIVATE symbol
3390         outside a module and not in COMMON has is not SAVEd.
3391         (resolve_equivalence): Ensure THREADPRIVATE objects don't get
3392         EQUIVALENCEd.
3393         * trans-common.c: Include target.h and rtl.h.
3394         (build_common_decl): Set DECL_TLS_MODEL if THREADPRIVATE.
3395         * trans-decl.c: Include rtl.h.
3396         (gfc_finish_var_decl): Set DECL_TLS_MODEL if THREADPRIVATE.
3397         * dump-parse-tree.c (gfc_show_attr): Handle THREADPRIVATE.
3398         * Make-lang.in (fortran/trans-decl.o): Depend on $(RTL_H).
3399         (fortran/trans-common.o): Depend on $(RTL_H) and $(TARGET_H).
3400         * openmp.c (gfc_match_omp_variable_list): Ensure COMMON block
3401         is from current namespace.
3402         (gfc_match_omp_threadprivate): Rewrite.
3403         (resolve_omp_clauses): Check some clause restrictions.
3404         * module.c (ab_attribute): Add AB_THREADPRIVATE.
3405         (attr_bits): Add THREADPRIVATE.
3406         (mio_symbol_attribute, mio_symbol_attribute): Handle threadprivate.
3407         (load_commons, write_common, write_blank_common): Adjust for type
3408         change of saved, store/load threadprivate bit from the integer
3409         as well.
3410
3411         * types.def (BT_FN_UINT_UINT): New.
3412         (BT_FN_VOID_UINT_UINT): Remove.
3413
3414         * trans-openmp.c (gfc_trans_omp_clauses, gfc_trans_omp_barrier,
3415         gfc_trans_omp_critical, gfc_trans_omp_flush, gfc_trans_omp_master,
3416         gfc_trans_omp_ordered, gfc_trans_omp_parallel): New functions.
3417         (gfc_trans_omp_directive): Use them.
3418
3419         * openmp.c (expr_references_sym): Add SE argument, don't look
3420         into SE tree.
3421         (is_conversion): New function.
3422         (resolve_omp_atomic): Adjust expr_references_sym callers.  Handle
3423         promoted expressions.
3424         * trans-openmp.c (gfc_trans_omp_atomic): New function.
3425         (gfc_trans_omp_directive): Call it.
3426
3427         * f95-lang.c (builtin_type_for_size): New function.
3428         (gfc_init_builtin_functions): Initialize synchronization and
3429         OpenMP builtins.
3430         * types.def: New file.
3431         * Make-lang.in (f95-lang.o): Depend on $(BUILTINS_DEF) and
3432         fortran/types.def.
3433
3434         * trans-openmp.c: Rename GOMP_* tree codes into OMP_*.
3435
3436         * dump-parse-tree.c (show_symtree): Don't crash if ns->proc_name
3437         is NULL.
3438
3439         * dump-parse-tree.c (gfc_show_namelist, gfc_show_omp_node): New
3440         functions.
3441         (gfc_show_code_node): Call gfc_show_omp_node for EXEC_OMP_* nodes.
3442
3443         * parse.c (parse_omp_do): Call pop_state before next_statement.
3444         * openmp.c (expr_references_sym, resolve_omp_atomic, resolve_omp_do):
3445         New functions.
3446         (gfc_resolve_omp_directive): Call them.
3447         * match.c (match_exit_cycle): Issue error if EXIT or CYCLE statement
3448         leaves an OpenMP structured block or if EXIT terminates !$omp do
3449         loop.
3450
3451         * Make-lang.in (F95_PARSER_OBJS): Add fortran/openmp.o.
3452         (F95_OBJS): Add fortran/trans-openmp.o.
3453         (fortran/trans-openmp.o): Depend on $(GFORTRAN_TRANS_DEPS).
3454         * lang.opt: Add -fopenmp option.
3455         * options.c (gfc_init_options): Initialize it.
3456         (gfc_handle_option): Handle it.
3457         * gfortran.h (ST_OMP_ATOMIC, ST_OMP_BARRIER, ST_OMP_CRITICAL,
3458         ST_OMP_END_CRITICAL, ST_OMP_END_DO, ST_OMP_END_MASTER,
3459         ST_OMP_END_ORDERED, ST_OMP_END_PARALLEL, ST_OMP_END_PARALLEL_DO,
3460         ST_OMP_END_PARALLEL_SECTIONS, ST_OMP_END_PARALLEL_WORKSHARE,
3461         ST_OMP_END_SECTIONS, ST_OMP_END_SINGLE, ST_OMP_END_WORKSHARE,
3462         ST_OMP_DO, ST_OMP_FLUSH, ST_OMP_MASTER, ST_OMP_ORDERED,
3463         ST_OMP_PARALLEL, ST_OMP_PARALLEL_DO, ST_OMP_PARALLEL_SECTIONS,
3464         ST_OMP_PARALLEL_WORKSHARE, ST_OMP_SECTIONS, ST_OMP_SECTION,
3465         ST_OMP_SINGLE, ST_OMP_THREADPRIVATE, ST_OMP_WORKSHARE): New
3466         statement codes.
3467         (OMP_LIST_PRIVATE, OMP_LIST_FIRSTPRIVATE, OMP_LIST_LASTPRIVATE,
3468         OMP_LIST_COPYPRIVATE, OMP_LIST_SHARED, OMP_LIST_COPYIN,
3469         OMP_LIST_PLUS, OMP_LIST_REDUCTION_FIRST, OMP_LIST_MULT,
3470         OMP_LIST_SUB, OMP_LIST_AND, OMP_LIST_OR, OMP_LIST_EQV,
3471         OMP_LIST_NEQV, OMP_LIST_MAX, OMP_LIST_MIN, OMP_LIST_IAND,
3472         OMP_LIST_IOR, OMP_LIST_IEOR, OMP_LIST_REDUCTION_LAST, OMP_LIST_NUM):
3473         New OpenMP variable list types.
3474         (gfc_omp_clauses): New typedef.
3475         (gfc_get_omp_clauses): Define.
3476         (EXEC_OMP_CRITICAL, EXEC_OMP_DO, EXEC_OMP_FLUSH, EXEC_OMP_MASTER,
3477         EXEC_OMP_ORDERED, EXEC_OMP_PARALLEL, EXEC_OMP_PARALLEL_DO,
3478         EXEC_OMP_PARALLEL_SECTIONS, EXEC_OMP_PARALLEL_WORKSHARE,
3479         EXEC_OMP_SECTIONS, EXEC_OMP_SINGLE, EXEC_OMP_WORKSHARE,
3480         EXEC_OMP_ATOMIC, EXEC_OMP_BARRIER, EXEC_OMP_END_NOWAIT,
3481         EXEC_OMP_END_SINGLE): New OpenMP gfc_exec_op codes.
3482         (struct gfc_code): Add omp_clauses, omp_name, omp_namelist
3483         and omp_bool fields to ext union.
3484         (flag_openmp): Declare.
3485         (gfc_free_omp_clauses, gfc_resolve_omp_directive): New prototypes.
3486         * scanner.c (openmp_flag, openmp_locus): New variables.
3487         (skip_free_comments, skip_fixed_comments, gfc_next_char_literal):
3488         Handle OpenMP directive lines and conditional compilation magic
3489         comments.
3490         * parse.h (COMP_OMP_STRUCTURED_BLOCK): New compile state.
3491         * parse.c (decode_omp_directive, parse_omp_do, parse_omp_atomic,
3492         parse_omp_structured_block): New functions.
3493         (next_free, next_fixed): Parse OpenMP directives.
3494         (case_executable, case_exec_markers, case_decl): Add ST_OMP_*
3495         codes.
3496         (gfc_ascii_statement): Handle ST_OMP_* codes.
3497         (parse_executable): Rearrange the loop slightly, so that
3498         parse_omp_do can return next_statement.
3499         * match.h (gfc_match_omp_eos, gfc_match_omp_atomic,
3500         gfc_match_omp_barrier, gfc_match_omp_critical, gfc_match_omp_do,
3501         gfc_match_omp_flush, gfc_match_omp_master, gfc_match_omp_ordered,
3502         gfc_match_omp_parallel, gfc_match_omp_parallel_do,
3503         gfc_match_omp_parallel_sections, gfc_match_omp_parallel_workshare,
3504         gfc_match_omp_sections, gfc_match_omp_single,
3505         gfc_match_omp_threadprivate, gfc_match_omp_workshare,
3506         gfc_match_omp_end_nowait, gfc_match_omp_end_single): New prototypes.
3507         * resolve.c (resolve_blocks): Ignore EXEC_OMP_* block directives.
3508         (resolve_code): Call gfc_resolve_omp_directive on EXEC_OMP_*
3509         directives.
3510         * trans.c (gfc_trans_code): Call gfc_trans_omp_directive for
3511         EXEC_OMP_* directives.
3512         * st.c (gfc_free_statement): Handle EXEC_OMP_* statement freeing.
3513         * trans-stmt.h (gfc_trans_omp_directive): New prototype.
3514         * openmp.c: New file.
3515         * trans-openmp.c: New file.
3516
3517 2006-02-13  Andrew Pinski  <pinskia@physics.uc.edu>
3518             Jakub Jelinek  <jakub@redhat.com>
3519
3520         PR fortran/26246
3521         * trans-decl.c (gfc_get_symbol_decl, gfc_get_fake_result_decl): Use
3522         gfc_add_decl_to_function rather than gfc_finish_var_decl on length.
3523
3524 2006-02-13  Paul Thomas  <pault@gcc.gnu.org>
3525
3526         PR fortran/26074
3527         PR fortran/25103
3528         * resolve.c (resolve_symbol): Extend the requirement that module
3529         arrays have constant bounds to those in the main program.  At the
3530         same time simplify the array bounds, to avoiding trapping parameter
3531         array references, and exclude automatic character length from main
3532         and modules. Rearrange resolve_symbol and resolve_derived to put as
3533         each flavor together, as much as is possible and move all specific
3534         code for flavors FL_VARIABLE, FL_PROCEDURE and FL_PARAMETER into new
3535         functions.
3536         (resolve_fl_var_and_proc, resolve_fl_variable, resolve_fl_procedure):
3537         New functions to do work of resolve_symbol.
3538         (resolve_index_expr): New function that is called from resolved_symbol
3539         and is extracted from resolve_charlen.
3540         (resolve_charlen): Call this new function.
3541         (resolve_fl_derived): Renamed resolve_derived to be consistent with
3542         the naming of the new functions for the other flavours.  Change the
3543         charlen checking so that the style is consistent with other similar
3544         checks. Add the generation of the gfc_dt_list, removed from resolve_
3545         symbol.
3546
3547         PR fortran/20861
3548         * resolve.c (resolve_actual_arglist): Prevent internal procedures
3549         from being dummy arguments.
3550
3551         PR fortran/20871
3552         * resolve.c (resolve_actual_arglist): Prevent pure but non-intrinsic
3553         procedures from being dummy arguments.
3554
3555         PR fortran/25083
3556         * resolve.c (check_data_variable): Add test that data variable is in
3557         COMMON.
3558
3559         PR fortran/25088
3560         * resolve.c (resolve_call): Add test that the subroutine does not
3561         have a type.
3562
3563 2006-02-12  Erik Edelmann  <eedelman@gcc.gnu.org>
3564
3565         PR fortran/25806
3566         * trans-array.c (gfc_trans_allocate_array_storage): New argument
3567         dealloc; free the temporary only if dealloc is true.
3568         (gfc_trans_allocate_temp_array): New argument bool dealloc, to be
3569         passed onwards to gfc_trans_allocate_array_storage.
3570         (gfc_trans_array_constructor, gfc_conv_loop_setup): Update call to
3571         gfc_trans_allocate_temp_array.
3572         * trans-array.h (gfc_trans_allocate_temp_array): Update function
3573         prototype.
3574         * trans-expr.c (gfc_conv_function_call): Set new argument 'dealloc'
3575         to gfc_trans_allocate_temp_array to false in case of functions
3576         returning pointers.
3577         (gfc_trans_arrayfunc_assign): Return NULL for functions returning
3578         pointers.
3579
3580 2006-02-10  Steven G. Kargl  <kargls@comcast.net>
3581
3582         PR fortran/20858
3583         *decl.c (variable_decl): Improve error message.  Remove initialization
3584         typespec.  Wrap long line.
3585         *expr.c (gfc_check_pointer_assign): Permit checking of type, kind type,
3586         and rank.
3587         *simplify.c (gfc_simplify_null): Ensure type, kind type, and rank
3588         are set.
3589
3590
3591 2006-02-10  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
3592
3593         PR fortran/14771
3594         * arith.c (eval_intrinsic): Accept INTRINSIC_PARENTHESES.
3595         * expr.c (check_intrinsic_op): Likewise.
3596         * module.c (mio_expr): Likewise.
3597
3598 2006-02-09  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
3599
3600         * dump-parse-tree.c: Update copyright years.
3601         * matchexp.c: Likewise.
3602         * module.c: Likewise.
3603
3604         PR fortran/14771
3605         * gfortran.h (gfc_intrinsic_op): Add INTRINSIC_PARENTHESES.
3606         * dump-parse-tree (gfc_show_expr): Handle INTRINSIC_PARENTHESES.
3607         * expr.c (simplify_intrinsic_op): Treat INTRINSIC_PARENTHESES as
3608         if it were INTRINSIC_UPLUS.
3609         * resolve.c (resolve_operator): Handle INTRINSIC_PARENTHESES.
3610         * match.c (intrinsic_operators): Add INTRINSIC_PARENTHESES.
3611         * matchexp.c (match_primary): Record parentheses surrounding
3612         numeric expressions.
3613         * module.c (intrinsics): Add INTRINSIC_PARENTHESES for module
3614         dumping.
3615         * trans-expr.c (gfc_conv_expr_op): Handle INTRINSIC_PARENTHESES.
3616
3617 2006-02-09  Paul Thomas  <pault@gcc.gnu.org>
3618
3619         PR fortran/26038
3620         * trans-stmt.c (gfc_trans_allocate): Provide assumed character length
3621         scalar with missing backend_decl for the hidden dummy charlen.
3622
3623         PR fortran/25059
3624         * interface.c (gfc_extend_assign): Remove detection of non-PURE
3625         subroutine in assignment interface, with gfc_error, and put it in
3626         * resolve.c (resolve_code).
3627
3628         PR fortran/25070
3629         * interface.c (gfc_procedure_use): Flag rank checking for non-
3630         elemental, contained or interface procedures in call to
3631         (compare_actual_formal), where ranks are checked for assumed
3632         shape arrays..
3633
3634 2006-02-08  Francois-Xavier Coudert  <coudert@clipper.ens.fr>
3635
3636         PR libfortran/25425
3637         * trans-decl.c (gfc_generate_function_code): Add new argument,
3638         pedantic, to set_std call.
3639
3640 2006-02-06  Thomas Koenig  <Thomas.Koenig@online.de>
3641
3642         PR libfortran/23815
3643         * gfortran.texi: Document the GFORTRAN_CONVERT_UNIT environment
3644         variable.
3645         * invoke.texi:  Mention the "Runtime" chapter.
3646         Document the -fconvert= option.
3647         * gfortran.h:  Add options_convert.
3648         * lang.opt:  Add fconvert=little-endian, fconvert=big-endian,
3649         fconvert=native and fconvert=swap.
3650         * trans-decl.c (top level):  Add gfor_fndecl_set_convert.
3651         (gfc_build_builtin_function_decls):  Set gfor_fndecl_set_convert.
3652         (gfc_generate_function_code):  If -fconvert was specified,
3653         and this is the main program, add a call to set_convert().
3654         * options.c:  Handle the -fconvert options.
3655
3656 2006-02-06  Roger Sayle  <roger@eyesopen.com>
3657
3658         * trans-stmt.c (gfc_evaluate_where_mask): Allow the NMASK argument
3659         to be NULL to indicate that the not mask isn't required.
3660         (gfc_trans_where_2): Remove PMASK argument.  Avoid calculating the
3661         pending mask for the last clause of a WHERE chain.  Update recursive
3662         call.
3663         (gfc_trans_forall_1): Update call to gfc_trans_where_2.
3664         (gfc_trans_where): Likewise.
3665
3666 2006-02-06  Jakub Jelinek  <jakub@redhat.com>
3667
3668         Backport from gomp-20050608-branch
3669         * trans-decl.c (create_function_arglist): Handle dummy functions.
3670
3671         * trans-decl.c (gfc_get_symbol_decl): Revert explicit setting of
3672         TYPE_SIZE_UNIT.
3673         (gfc_trans_vla_type_sizes): Also "gimplify"
3674         GFC_TYPE_ARRAY_DATAPTR_TYPE for GFC_DESCRIPTOR_TYPE_P types.
3675         * trans-array.c (gfc_trans_deferred_array): Call
3676         gfc_trans_vla_type_sizes.
3677
3678         * trans-decl.c (saved_function_decls, saved_parent_function_decls):
3679         Remove unnecessary initialization.
3680         (create_function_arglist): Make sure __result has complete type.
3681         (gfc_get_fake_result_decl): Change current_fake_result_decl into
3682         a tree chain.  For entry master, create a separate variable
3683         for each result name.  For BT_CHARACTER results, call
3684         gfc_finish_var_decl on length even if it has been already created,
3685         but not pushdecl'ed.
3686         (gfc_trans_vla_type_sizes): For function/entry result, adjust
3687         result value type, not the FUNCTION_TYPE.
3688         (gfc_generate_function_code): Adjust for current_fake_result_decl
3689         changes.
3690         (gfc_trans_deferred_vars): Likewise.  Call gfc_trans_vla_type_sizes
3691         even on result if it is assumed-length character.
3692
3693         * trans-decl.c (gfc_trans_dummy_character): Add SYM argument.
3694         Call gfc_trans_vla_type_sizes.
3695         (gfc_trans_auto_character_variable): Call gfc_trans_vla_type_sizes.
3696         (gfc_trans_vla_one_sizepos, gfc_trans_vla_type_sizes_1,
3697         gfc_trans_vla_type_sizes): New functions.
3698         (gfc_trans_deferred_vars): Adjust gfc_trans_dummy_character
3699         callers.  Call gfc_trans_vla_type_sizes on assumed-length
3700         character parameters.
3701         * trans-array.c (gfc_trans_array_bounds,
3702         gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias): Call
3703         gfc_trans_vla_type_sizes.
3704         * trans.h (gfc_trans_vla_type_sizes): New prototype.
3705
3706         * trans-decl.c (gfc_build_qualified_array): For non-assumed-size
3707         arrays without constant size, create also an index var for
3708         GFC_TYPE_ARRAY_SIZE (type).  If the type is incomplete, complete
3709         it as 0..size-1.
3710         (gfc_create_string_length): Don't call gfc_defer_symbol_init
3711         if just creating DECL_ARGUMENTS.
3712         (gfc_get_symbol_decl): Call gfc_finish_var_decl and
3713         gfc_defer_symbol_init even if ts.cl->backend_decl is already
3714         set to a VAR_DECL that doesn't have DECL_CONTEXT yet.
3715         (create_function_arglist): Rework, so that hidden length
3716         arguments for CHARACTER parameters are created together with
3717         the parameters.  Resolve ts.cl->backend_decl for CHARACTER
3718         parameters.  If the argument is a non-constant length array
3719         or CHARACTER, ensure PARM_DECL has different type than
3720         its DECL_ARG_TYPE.
3721         (generate_local_decl): Call gfc_get_symbol_decl even
3722         for non-referenced non-constant length CHARACTER parameters
3723         after optionally issuing warnings.
3724         * trans-array.c (gfc_trans_array_bounds): Set last stride
3725         to GFC_TYPE_ARRAY_SIZE (type) to initialize it as well.
3726         (gfc_trans_dummy_array_bias): Initialize GFC_TYPE_ARRAY_SIZE (type)
3727         variable as well.
3728
3729         * trans-expr.c (gfc_conv_expr_val): Fix comment typo.
3730
3731         * trans-stmt.c (gfc_trans_simple_do): Fix comment.
3732
3733 2006-02-04  Roger Sayle  <roger@eyesopen.com>
3734
3735         * dependency.c (gfc_check_dependency): Remove unused vars and nvars
3736         arguments.  Replace with an "identical" argument.  A full array
3737         reference to the same symbol is a dependency if identical is true.
3738         * dependency.h (gfc_check_dependency): Update prototype.
3739         * trans-array.h (gfc_check_dependency): Delete duplicate prototype.
3740         * trans-stmt.c: #include dependency.h for gfc_check_dependency.
3741         (gfc_trans_forall_1): Update calls to gfc_check_dependency.
3742         (gfc_trans_where_2): Likewise.  Remove unneeded variables.
3743         (gfc_trans_where_3): New function for simple non-dependent WHEREs.
3744         (gfc_trans_where): Call gfc_trans_where_3 to translate simple
3745         F90-style WHERE statements without internal dependencies.
3746         * Make-lang.in (trans-stmt.o): Depend upon dependency.h.
3747
3748 2006-02-05  H.J. Lu  <hongjiu.lu@intel.com>
3749
3750         PR fortran/26041
3751         PR fortran/26064
3752         * resolve.c (resolve_types): New function.
3753         (resolve_codes): Likewise.
3754         (gfc_resolve): Use them.
3755
3756 2006-02-05  Roger Sayle  <roger@eyesopen.com>
3757
3758         * trans-stmt.c (gfc_evaluate_where_mask): Use LOGICAL*1 for WHERE
3759         masks instead of LOGICAL*4.
3760
3761 2006-02-05  Jakub Jelinek  <jakub@redhat.com>
3762
3763         * resolve.c (resolve_symbol): Initialize constructor_expr to NULL.
3764
3765 2006-02-04  Thomas Koenig  <Thomas.Koenig@online.de>
3766
3767         PR fortran/25075
3768         check.c (identical_dimen_shape):  New function.
3769         (check_dot_product):  Use identical_dimen_shape() to check sizes
3770         for dot_product.
3771         (gfc_check_matmul):  Likewise.
3772         (gfc_check_merge):  Check conformance between tsource and fsource
3773         and between tsource and mask.
3774         (gfc_check_pack):  Check conformance between array and mask.
3775
3776 2006-02-03  Steven G. Kargl  <kargls@comcast>
3777             Paul Thomas  <pault@gcc.gnu.org>
3778
3779         PR fortran/20845
3780         * resolve.c (resolve_symbol): Default initialization of derived type
3781         component reguires the SAVE attribute.
3782
3783 2006-02-02  Steven G. Kargl  <kargls@comcast>
3784
3785         PR fortran/24958
3786         match.c (gfc_match_nullify):  Free the list from head not tail.
3787
3788         PR fortran/25072
3789         * match.c (match_forall_header): Fix internal error caused by bogus
3790         gfc_epxr pointers.
3791
3792
3793 2006-01-31  Thomas Koenig  <Thomas.Koenig@online.de>
3794
3795         PR fortran/26039
3796         expr.c (gfc_check_conformance):  Reorder error message
3797         to avoid plural.
3798         check.c(gfc_check_minloc_maxloc):  Call gfc_check_conformance
3799         for checking arguments array and mask.
3800         (check_reduction):  Likewise.
3801
3802 2006-01-30  Erik Edelmann  <eedelman@gcc.gnu.org>
3803
3804         PR fortran/24266
3805         * trans-io.c (set_internal_unit): Check the rank of the
3806         expression node itself instead of its symbol.
3807
3808 2006-01-29  Paul Thomas  <pault@gcc.gnu.org>
3809
3810         PR fortran/18578
3811         PR fortran/18579
3812         PR fortran/20857
3813         PR fortran/20885
3814         * interface.c (compare_actual_formal): Error for INTENT(OUT or INOUT)
3815         if actual argument is not a variable.
3816
3817 2006-01-28  Paul Thomas  <pault@gcc.gnu.org>
3818
3819         PR fortran/17911
3820         * expr.c (gfc_check_assign, gfc_check_pointer_assign): Emit error if
3821         the lvalue is a use associated procedure.
3822
3823         PR fortran/20895
3824         PR fortran/25030
3825         * expr.c (gfc_check_pointer_assign): Emit error if lvalue and rvalue
3826         character lengths are not the same.  Use gfc_dep_compare_expr for the
3827         comparison.
3828         * gfortran.h: Add prototype for gfc_dep_compare_expr.
3829         * dependency.h: Remove prototype for gfc_dep_compare_expr.
3830
3831 2006-01-27  Paul Thomas  <pault@gcc.gnu.org>
3832
3833         PR fortran/25964
3834         * resolve.c (resolve_function): Add GFC_ISYM_LOC to the list of
3835         generic_ids exempted from assumed size checking.
3836
3837 2006-01-27  Jakub Jelinek  <jakub@redhat.com>
3838
3839         PR fortran/25324
3840         * Make-lang.in (fortran/scanner.o): Depend on toplev.h.
3841         * lang.opt (fpreprocessed): New option.
3842         * scanner.c: Include toplev.h.
3843         (gfc_src_file, gfc_src_preprocessor_lines): New variables.
3844         (preprocessor_line): Unescape filename if there were any
3845         backslashes.
3846         (load_file): If initial and gfc_src_file is not NULL,
3847         use it rather than opening the file.  If gfc_src_preprocessor_lines
3848         has non-NULL elements, pass it to preprocessor_line.
3849         (unescape_filename, gfc_read_orig_filename): New functions.
3850         * gfortran.h (gfc_option_t): Add flag_preprocessed.
3851         (gfc_read_orig_filename): New prototype.
3852         * options.c (gfc_init_options): Clear flag_preprocessed.
3853         (gfc_post_options): If flag_preprocessed, call
3854         gfc_read_orig_filename.
3855         (gfc_handle_option): Handle OPT_fpreprocessed.
3856         * lang-specs.h: Pass -fpreprocessed to f951 if preprocessing
3857         sources.
3858
3859 2006-01-27  Erik Edelmann  <eedelman@gcc.gnu.org>
3860
3861         * symbol.c (free_old_symbol): Fix confusing comment, and add code
3862           to free old_symbol->formal.
3863
3864 2006-01-26  Paul Thomas  <pault@gcc.gnu.org>
3865
3866         PR fortran/25964
3867         * resolve.c (resolve_function): Exclude statement functions from
3868         global reference checking.
3869
3870         PR fortran/25084
3871         PR fortran/20852
3872         PR fortran/25085
3873         PR fortran/25086
3874         * resolve.c (resolve_function): Declare a gfc_symbol to replace the
3875         references through the symtree to the symbol associated with the
3876         function expresion. Give error on reference to an assumed character
3877         length function is defined in an interface or an external function
3878         that is not a dummy argument.
3879         (resolve_symbol): Give error if an assumed character length function
3880         is array-valued, pointer-valued, pure or recursive. Emit warning
3881         that character(*) value functions are obsolescent in F95.
3882
3883         PR fortran/25416
3884         * trans-expr.c (gfc_conv_function_call): The above patch to resolve.c
3885         prevents any assumed character length function call from getting here
3886         except intrinsics such as SPREAD. In this case, ensure that no
3887         segfault occurs from referencing non-existent charlen->length->
3888         expr_type and provide a backend_decl for the charlen from the charlen
3889         of the first actual argument.
3890
3891         Cure temp name confusion.
3892         * trans-expr.c (gfc_get_interface_mapping_array): Change name of
3893         temporary from "parm" to "ifm" to avoid clash with temp coming from
3894         trans-array.c.
3895
3896 2006-01-25  Erik Edelmann  <eedelman@gcc.gnu.org>
3897
3898         PR fortran/25716
3899         * symbol.c (free_old_symbol): New function.
3900         (gfc_commit_symbols): Use it.
3901         (gfc_commit_symbol): New function.
3902         (gfc_use_derived): Use it.
3903         * gfortran.h: Add prototype for gfc_commit_symbol.
3904         * intrinsic.c (gfc_find_function): Search in 'conversion'
3905         if not found in 'functions'.
3906         (gfc_convert_type_warn): Add a symtree to the new
3907         expression node, and commit the new symtree->n.sym.
3908         * resolve.c (gfc_resolve_index): Make sure typespec is
3909         properly initialized.
3910
3911 2006-01-23  Paul Thomas  <pault@gcc.gnu.org>
3912
3913         PR fortran/25901
3914         * decl.c (get_proc_name): Replace subroutine and function attributes
3915         in "already defined" test by the formal arglist pointer being non-NULL.
3916
3917         Fix regression in testing of admissability of attributes.
3918         * symbol.c (gfc_add_attribute): If the current_attr has non-zero
3919         intent, do not do the check for a dummy being used.
3920         * decl.c (attr_decl1): Add current_attr.intent as the third argument
3921         in the call to gfc_add_attribute.
3922         * gfortran.h: Add the third argument to the prototype for
3923         gfc_add_attribute.
3924
3925 2006-01-21  Joseph S. Myers  <joseph@codesourcery.com>
3926
3927         * gfortranspec.c (lang_specific_driver): Update copyright notice
3928         date.
3929
3930 2006-01-21  Paul Thomas  <pault@gcc.gnu.org>
3931
3932         PR fortran/25124
3933         PR fortran/25625
3934         * decl.c (get_proc_name): If there is an existing
3935         symbol in the encompassing namespace, call errors
3936         if it is a procedure of the same name or the kind
3937         field is set, indicating a type declaration.
3938
3939         PR fortran/20881
3940         PR fortran/23308
3941         PR fortran/25538
3942         PR fortran/25710
3943         * decl.c (add_global_entry): New function to check
3944         for existing global symbol with this name and to
3945         create new one if none exists.
3946         (gfc_match_entry): Call add_global_entry before
3947         matching argument lists for subroutine and function
3948         entries.
3949         * gfortran.h: Prototype for existing function,
3950         global_used.
3951         * resolve.c (resolve_global_procedure): New function
3952         to check global symbols for procedures.
3953         (resolve_call, resolve_function): Calls to this
3954         new function for non-contained and non-module
3955         procedures.
3956         * match.c (match_common): Add check for existing
3957         global symbol, creat one if none exists and emit
3958         error if there is a clash.
3959         * parse.c (global_used): Remove static and use the
3960         gsymbol name rather than the new_block name, so that
3961         the function can be called from resolve.c.
3962         (parse_block_data, parse_module, add_global_procedure):
3963         Improve checks for existing gsymbols.  Emit error if
3964         already defined or if references were to another type.
3965         Set defined flag.
3966
3967         PR fortran/PR24276
3968         * trans-expr.c (gfc_conv_aliased_arg): New function called by 
3969         gfc_conv_function_call that coverts an expression for an aliased
3970         component reference to a derived type array into a temporary array
3971         of the same type as the component.  The temporary is passed as an
3972         actual argument for the procedure call and is copied back to the
3973         derived type after the call.
3974         (is_aliased_array): New function that detects an array reference
3975         that is followed by a component reference.
3976         (gfc_conv_function_call): Detect an aliased actual argument with
3977         is_aliased_array and convert it to a temporary and back again
3978         using gfc_conv_aliased_arg.
3979
3980 2006-01-19  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
3981
3982         * gfortranspec.c: Update copyright years.
3983         * trans.c: Likewise.
3984         * trans-array.c: Likewise.
3985         * trans-array.h: Likewise.
3986         * trans-decl.c: Likewise.
3987         * trans-stmt.c: Likewise.
3988         * trans-stmt.h: Likewise.
3989         * trans-types.c: Likewise.
3990
3991 2006-01-18  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
3992
3993         PR fortran/18540
3994         PR fortran/18937
3995         * gfortran.h (BBT_HEADER): Move definition up.
3996         (gfc_st_label): Add BBT_HEADER, remove 'prev' and 'next'.
3997         * io.c (format_asterisk): Adapt initializer.
3998         * resolve.c (resolve_branch): Allow FORTRAN 66 cross-block GOTOs
3999         as extension.
4000         (warn_unused_label): Take gfc_st_label label as argument, adapt to
4001         new data structure.
4002         (gfc_resolve): Adapt call to warn_unused_label.
4003         * symbol.c (compare_st_labels): New function.
4004         (gfc_free_st_label, free_st_labels, gfc_get_st_label): Convert to
4005         using balanced binary tree.
4006         * decl.c (match_char_length, gfc_match_old_kind_spec): Do away
4007         with 'cnt'.
4008         (warn_unused_label): Adapt to binary tree.
4009         * match.c (gfc_match_small_literal_int): Only set cnt if non-NULL.
4010         * primary.c (match_kind_param): Do away with cnt.
4011
4012 2006-01-18  Paul Thomas  <pault@gcc.gnu.org>
4013
4014         PR fortran/20869
4015         PR fortran/20875
4016         PR fortran/25024
4017         * symbol.c (check_conflict): Add pointer valued elemental
4018         functions and internal procedures with the external attribute
4019         to the list of conflicts.
4020         (gfc_add_attribute): New catch-all function to perform the
4021         checking of symbol attributes for attribute declaration
4022         statements.
4023         * decl.c (attr_decl1): Call gfc_add_attribute for each of -
4024         (gfc_match_external, gfc_match_intent, gfc_match_intrinsic,
4025         gfc_match_pointer, gfc_match_dimension, gfc_match_target):
4026         Remove spurious calls to checks in symbol.c.  Set the
4027         attribute directly and use the call to attr_decl() for
4028         checking.
4029         * gfortran.h:  Add prototype for gfc_add_attribute.
4030
4031         PR fortran/25785
4032         * resolve.c (resolve_function): Exclude PRESENT from assumed size
4033         argument checking. Replace strcmp's with comparisons with generic
4034         codes.
4035
4036 2006-01-16  Rafael \81Ávila de Esp\81índola  <rafael.espindola@gmail.com>
4037
4038         * gfortranspec.c (lang_specific_spec_functions): Remove.
4039
4040 2006-01-16  Richard Guenther  <rguenther@suse.de>
4041
4042         * trans-stmt.c (gfc_trans_if_1): Use fold_buildN and build_int_cst.
4043         (gfc_trans_arithmetic_if): Likewise.
4044         (gfc_trans_simple_do): Likewise.
4045         (gfc_trans_do): Likewise.
4046         (gfc_trans_do_while): Likewise.
4047         (gfc_trans_logical_select): Likewise.
4048         (gfc_trans_forall_loop): Likewise.
4049         (generate_loop_for_temp_to_lhs): Likewise.
4050         (generate_loop_for_rhs_to_temp): Likewise.
4051         (gfc_trans_allocate): Likewise.
4052         * trans.c (gfc_add_expr_to_block): Do not fold expr again.
4053
4054 2006-01-16  Richard Guenther  <rguenther@suse.de>
4055
4056         * trans-expr.c (gfc_conv_function_call): Use fold_build2.
4057         * trans-stmt.c (gfc_trans_goto): Likewise.  Use build_int_cst.
4058         * trans.c (gfc_trans_runtime_check): Don't fold the condition
4059         again.
4060
4061 2006-01-13  Steven G. Kargl  <kargls@comcast.net>
4062
4063         PR fortran/25756
4064         * symbol.c (gfc_free_st_label): Give variable meaningful name. Remove
4065         unneeded parenthesis. Fix-up the head of the list (2 lines gleaned
4066         from g95).
4067
4068 2006-01-13  Diego Novillo  <dnovillo@redhat.com>
4069
4070         * trans.c (gfc_add_expr_to_block): Do not fold tcc_statement
4071         nodes.
4072
4073 2006-01-11  Tobias Schl\81üter  <tobias.schlueter@physik.uni-muenchen.de>
4074
4075         * parse.c (next_fixed): Remove superfluous string concatenation.
4076
4077 2006-01-11  Bernhard Fischer  <rep.nop@aon.at>
4078
4079         PR fortran/25486
4080         * scanner.c (load_line): use maxlen to determine the line-length used
4081         for padding lines in fixed form.
4082
4083 2006-01-11  Paul Thomas  <pault@gcc.gnu.org>
4084
4085         PR fortran/25730
4086         * trans-types.c (copy_dt_decls_ifequal): Copy backend decl for
4087         character lengths.
4088
4089 2006-01-09  Andrew Pinski  <pinskia@physics.uc.edu>
4090
4091         fortran/24936
4092         * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Use fold_convert
4093         to avoid type mismatch.
4094
4095 2006-01-09  Andrew Pinski  <pinskia@physics.uc.edu>
4096
4097         PR fortran/21977
4098         * trans-decl.c (gfc_generate_function_code): Move the NULLing of
4099         current_fake_result_decl down to below generate_local_vars.
4100
4101 2006-01-09  Feng Wang  <fengwang@nudt.edu.cn>
4102
4103         PR fortran/12456
4104         * trans-expr.c (gfc_to_single_character): New function that converts
4105         string to single character if its length is 1.
4106         (gfc_build_compare_string):New function that compare string and handle
4107         single character specially.
4108         (gfc_conv_expr_op): Use gfc_build_compare_string.
4109         (gfc_trans_string_copy): Use gfc_to_single_character.
4110         * trans-intrinsic.c (gfc_conv_intrinsic_strcmp): Use
4111         gfc_build_compare_string.
4112         * trans.h (gfc_build_compare_string): Add prototype.
4113
4114 2006-01-09  Feng Wang  <fengwang@nudt.edu.cn>
4115
4116         * simplify.c (gfc_simplify_char): Use UCHAR_MAX instead of literal
4117         constant.
4118         (gfc_simplify_ichar): Get the result from unsinged char and in the
4119         range 0 to UCHAR_MAX instead of CHAR_MIN to CHAR_MAX.
4120
4121 2006-01-08  Erik Edelmann  <eedelman@gcc.gnu.org>
4122
4123         PR fortran/25093
4124         * resolve.c (resolve_fntype): Check that PUBLIC functions
4125         aren't of PRIVATE type.
4126
4127 2006-01-07  Tobias Schl"uter  <tobias.schlueter@physik.uni-muenchen.de>
4128
4129         * decl.c (gfc_match_function_decl): Correctly error out in case of
4130         omitted function argument list.
4131
4132 2006-01-07  Paul Thomas  <pault@gcc.gnu.org>
4133
4134         PR fortran/22146
4135         * trans-array.c (gfc_reverse_ss): Remove static attribute.
4136         (gfc_walk_elemental_function_args): Replace gfc_expr * argument for
4137         the function call with the corresponding gfc_actual_arglist*.  Change
4138         code accordingly.
4139         (gfc_walk_function_expr): Call to gfc_walk_elemental_function_args
4140         now requires the actual argument list instead of the expression for
4141         the function call.
4142         * trans-array.h: Modify the prototype for gfc_walk_elemental_function_args
4143         and provide a prototype for gfc_reverse_ss.
4144         * trans-stmt.h (gfc_trans_call): Add the scalarization code for the case
4145         where an elemental subroutine has array valued actual arguments.
4146
4147         PR fortran/25029
4148         PR fortran/21256
4149         PR fortran/20868
4150         PR fortran/20870
4151         * resolve.c (check_assumed_size_reference): New function to check for upper
4152         bound in assumed size array references.
4153         (resolve_assumed_size_actual): New function to do a very restricted scan
4154         of actual argument expressions of those procedures for which incomplete
4155         assumed size array references are not allowed.
4156         (resolve_function, resolve_call): Switch off assumed size checking of
4157         actual arguments, except for elemental procedures and intrinsic
4158         inquiry functions, in some circumstances.
4159         (resolve_variable): Call check_assumed_size_reference.
4160
4161 2006-01-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
4162
4163         PR fortran/24268
4164         * io.c (next_char_not_space): New function that returns the next
4165         character that is not white space.
4166         (format_lex): Use the new function to skip whitespace within
4167         a format string.
4168
4169 2006-01-05  Erik Edelmann  <eedelman@gcc.gnu.org>
4170
4171         PR fortran/23675
4172         * expr.c (gfc_expr_set_symbols_referenced): New function.
4173         * gfortran.h: Add a function prototype for it.
4174         * resolve.c (resolve_function): Use it for
4175         use associated character functions lengths.
4176         * expr.c, gfortran.h, resolve.c: Updated copyright years.
4177
4178 2006-01-03  Steven G. Kargl  <kargls@comcast.net>
4179
4180         PR fortran/25101
4181         * resolve.c (resolve_forall_iterators):  Check for scalar variables;
4182         Check stride is nonzero.
4183
4184 2006-01-02  Steven G. Kargl  <kargls@comcast.net>
4185
4186         PR fortran/24640
4187         * parse.c (next_free): Check for whitespace after the label.
4188         * match.c (gfc_match_small_literal_int): Initialize cnt variable.
4189
4190 2006-01-01  Steven G. Kargl  <kargls@comcast.net>
4191
4192         * ChangeLog: Split previous years into ...
4193         * ChangeLog-2002: here.
4194         * ChangeLog-2003: here.
4195         * ChangeLog-2004: here.
4196         * ChangeLog-2005: here.