1 2005-10-24 Francois-Xavier Coudert <coudert@clipper.ens.fr>
4 * arith.c (gfc_arith_error): Change message to include locus.
5 (check_result, eval_intrinsic, gfc_int2int, gfc_real2real,
6 gfc_real2complex, gfc_complex2real, gfc_complex2complex): Use
7 the new gfc_arith_error.
8 (arith_error): Rewrite full error messages instead of building
10 * check.c (must_be): Removed.
11 (type_check, numeric_check, int_or_real_check, real_or_complex_check,
12 kind_check, double_check, logical_array_check, array_check,
13 scalar_check, same_type_check, rank_check, kind_value_check,
14 variable_check, gfc_check_allocated, gfc_check_associated,
15 gfc_check_cmplx, gfc_check_dcmplx, gfc_check_dot_product,
16 gfc_check_index, gfc_check_kind, gfc_check_matmul, gfc_check_null,
17 gfc_check_pack, gfc_check_precision, gfc_check_present,
18 gfc_check_spread): Rewrite full error messages instead of
19 building them from pieces.
20 * decl.c (gfc_match_entry): Rewrite full error messages instead
21 of building them from pieces.
22 * parse.c (gfc_state_name): Remove.
23 * parse.h: Remove prototype for gfc_state_name.
25 2005-10-23 Andrew Pinski <pinskia@physics.uc.edu>
28 * check.c (gfc_check_ichar_iachar): Move the code around so
29 that the check on the length is after check for
32 2005-10-23 Asher Langton <langton2@llnl.gov>
34 * decl.c (match_type_spec): Add a BYTE type as an extension.
36 2005-10-23 Paul Thomas <pault@gcc.gnu.org>
39 * trans-expr.c (gfc_trans_arrayfunc_assign): Return NULL
40 if there is a component ref during an array ref to force
41 use of temporary in assignment.
45 * fortran/iresolve.c (check_charlen_present): New function to
46 add a charlen to the typespec, in the case of constant
48 (gfc_resolve_merge, gfc_resolve_spread): Call.the above.
49 (gfc_resolve_spread): Make calls to library functions that
50 handle the case of the spread intrinsic with a scalar source.
52 2005-10-22 Erik Edelmann <eedelman@gcc.gnu.org>
55 * decl.c (variable_decl): Don't assign default initializers to
58 2005-10-21 Jakub Jelinek <jakub@redhat.com>
60 * interface.c (compare_actual_formal): Issue error when attempting
61 to pass an assumed-size array as assumed-shape array argument.
63 2005-10-20 Erik Edelmann <erik.edelmann@iki.fi>
66 * resolve.c (expr_to_initialize): New function.
67 (resolve_allocate_expr): Take current statement as new
68 argument. Add default initializers to variables of
69 derived types, if they need it.
70 (resolve_code): Provide current statement as argument to
71 resolve_allocate_expr().
73 2005-10-19 Paul Thomas <pault@gcc.gnu.org>
76 * resolve.c (resolve_symbol): Correct error in check for
77 assumed size array with default initializer by testing
78 for arrayspec before dereferencing it.
80 2005-10-17 Paul Thomas <pault@gcc.gnu.org>
83 * gfortran.h: Primitive for gfc_is_formal_arg.
84 * resolve.c(gfc_is_formal_arg): New function to signal across
85 several function calls that formal argument lists are being
87 (resolve_formal_arglist): Set/reset the flag for gfc_is_formal_arg.
88 *expr.c(check_restricted): Add check, via gfc_is_formal_arg, if
89 symbol is part of an formal argument declaration.
92 * decl.c (add_init_expr_to_sym): Make a new character
93 length for each variable, when the expression is NULL
97 * match.c (recursive_stmt_fcn): New function that tests if
98 a statement function resurses through itself or other other
100 (gfc_match_st_function): Call recursive_stmt_fcn to check
101 if this is recursive and to raise error if so.
105 * resolve.c (resolve_symbol): Errors for assumed size arrays
106 with default initializer and for external objects with an
110 * decl.c (match_attr_spec): Prevent PUBLIC from being used
113 2005-10-16 Erik Edelmann <erik.edelmann@iki.fi>
116 * expr.c (check_inquiry): Add "len" to inquiry_function.
118 2005-10-14 Jakub Jelinek <jakub@redhat.com>
120 * primary.c (match_boz_constant): Add missing break after gfc_error.
122 2005-10-12 Paul Thomas <pault@gcc.gnu.org>
125 * trans-types.c (gfc_get_derived_type): Insert code to obtain backend
126 declaration for derived types, building if necessary. Return the
127 derived type if the fields have been built by this process. Otherwise,
128 continue as before but using the already obtained backend_decls for the
129 derived type components. Change the gcc_assert to act on the field.
131 2005-10-12 Paul Thomas <pault@gcc.gnu.org>
134 * decl.c (variable_decl): Make a new copy of the character
135 length for each variable, when the expression is not a
138 2005-10-12 Francois-Xavier Coudert <coudert@clipper.ens.fr>
140 * gfortran.h: Add bitmasks for different FPE traps. Add fpe
142 * invoke.texi: Document the new -ffpe-trap option.
143 * lang.opt: Add -ffpe-trap option.
144 * options.c (gfc_init_options): Initialize the FPE option.
145 (gfc_handle_fpe_trap_option): New function to parse the argument
146 of the -ffpe-trap option.
147 (gfc_handle_option): Add case for -ffpe-trap.
148 * trans-decl.c: Declare a tree for the set_fpe library function.
149 (gfc_build_builtin_function_decls): Build this tree.
150 (gfc_generate_function_code): Generate a call to set_fpe at
151 the beginning of the main program.
152 * trans.h: New tree for the set_fpe library function.
154 2005-10-12 Paul Thomas <pault@gcc.gnu.org>
158 * symbol.c (check_conflict): Prevent common variables and
159 function results from having the SAVE attribute,as required
162 2005-10-12 Paul Thomas <pault@gcc.gnu.org>
165 * resolve.c (resolve_symbol): Exclude use and host associated
166 symbols from the test for private objects in a public namelist.
168 2005-10-12 Jakub Jelinek <jakub@redhat.com>
170 * trans-common.c (build_field): Fix comment typo.
171 (create_common): Set backend_decl of COMMON or EQUIVALENCEd
172 variables to a VAR_DECL with the COMPONENT_REF in
173 DECL_HAS_VALUE_EXPR rather than COMPONENT_REF directly.
174 * f95-lang.c (gfc_expand_function): Emit debug info for
175 EQUIVALENCEd variables if the equiv union is going to be output.
177 2005-10-11 Steven G. Kargl <kargls@comcast.net>
180 * iresolve.c (gfc_resolve_aint, gfc_resolve_anint): Type conversion
183 2005-10-11 Jakub Jelinek <jakub@redhat.com>
185 * f95-lang.c (gfc_init_decl_processing): Initialize
188 2005-10-07 Erik Edelmann <erik.edelmann@iki.fi>
191 * resolve.c (find_array_spec): Search through the list of
192 components in the symbol of the type instead of the symbol of the
195 2005-10-05 Richard Guenther <rguenther@suse.de>
198 * parse.c (gfc_parse_file): Exit early for empty files.
200 2005-10-03 Steve Ellcey <sje@cup.hp.com>
202 * fortran/trans-types.c (gfc_init_kinds): Only pass float, double,
203 and long double floating point types through to Fortran compiler.
205 2005-10-03 Francois-Xavier Coudert <coudert@clipper.ens.fr>
208 * f95-lang.c (DO_DEFINE_MATH_BUILTIN): Add support for long
209 double builtin function.
210 (gfc_init_builtin_functions): Add mfunc_longdouble,
211 mfunc_clongdouble and func_clongdouble_longdouble trees. Build
212 them for round, trunc, cabs, copysign and pow functions.
213 * iresolve.c (gfc_resolve_reshape, gfc_resolve_transpose): Add
214 case for kind 10 and 16.
215 * trans-decl.c: Add trees for cpowl10, cpowl16, ishftc16,
216 exponent10 and exponent16.
217 (gfc_build_intrinsic_function_decls): Build nodes for int16,
218 real10, real16, complex10 and complex16 types. Build all possible
219 combinations for function _gfortran_pow_?n_?n. Build function
220 calls cpowl10, cpowl16, ishftc16, exponent10 and exponent16.
221 * trans-expr.c (gfc_conv_power_op): Add case for integer(16),
222 real(10) and real(16).
223 * trans-intrinsic.c: Add suppport for long double builtin
224 functions in BUILT_IN_FUNCTION, LIBM_FUNCTION and LIBF_FUNCTION
226 (gfc_conv_intrinsic_aint): Add case for integer(16), real(10) and
228 (gfc_build_intrinsic_lib_fndecls): Add support for real10_decl
229 and real16_decl in library functions.
230 (gfc_get_intrinsic_lib_fndecl): Add cases for real and complex
232 (gfc_conv_intrinsic_exponent): Add cases for real(10) and real(16)
234 (gfc_conv_intrinsic_sign): Likewise.
235 (gfc_conv_intrinsic_ishftc): Add case for integer(16) kind.
236 * trans-types.c (gfc_get_int_type, gfc_get_real_type,
237 gfc_get_complex_type, gfc_get_logical_type): Doesn't error out in
238 the case of kinds not available.
239 * trans.h: Declare trees for cpowl10, cpowl16, ishftc16,
240 exponent10 and exponent16.
242 2005-10-01 Paul Thomas <pault@gcc.gnu.org>
251 * gfortran.h: Prototype for gfc_add_in_equivalence.
252 * match.c (gfc_match_equivalence): Make a structure component
253 an explicit,rather than a syntax, error in an equivalence
254 group. Call gfc_add_in_equivalence to add the constraints
255 imposed in check_conflict.
256 * resolve.c (resolve_symbol): Add constraints: No public
257 structures with private-type components and no public
258 procedures with private-type dummy arguments.
259 (resolve_equivalence_derived): Add constraint that prevents
260 a structure equivalence member from having a default
262 (sequence_type): New static function to determine whether an
263 object is default numeric, default character, non-default
264 or mixed sequence. Add corresponding enum typespec.
265 (resolve_equivalence): Add constraints to equivalence groups
266 or their members: No more than one initialized member and
267 that different types are not equivalenced for std=f95. All
268 the simple constraints have been moved to check_conflict.
269 * symbol.c (check_conflict): Simple equivalence constraints
270 added, including those removed from resolve_symbol.
271 (gfc_add_in_equivalence): New function to interface calls
272 match_equivalence to check_conflict.
274 2005-09-27 Jakub Jelinek <jakub@redhat.com>
277 * trans-common.c (build_equiv_decl): Add IS_SAVED argument.
278 If it is true, set TREE_STATIC on the decl.
279 (create_common): If any symbol in equivalence has SAVE attribute,
280 pass true as last argument to build_equiv_decl.
282 2005-09-24 Janne Blomqvist <jblomqvi@cc.hut.fi>
284 * trans-io.c (gfc_build_io_library_fndecls): Add entry
285 iocall_x_array for transfer_array.
286 (transfer_array_desc): New function.
287 (gfc_trans_transfer): Add code to call transfer_array_desc.
289 2005-09-26 Jakub Jelinek <jakub@redhat.com>
292 * symbol.c (gfc_is_var_automatic): Return true if character length
293 is non-constant rather than constant.
294 * resolve.c (gfc_resolve): Don't handle !gfc_option.flag_automatic
296 * options.c (gfc_post_options): Set gfc_option.flag_max_stack_var_size
297 to 0 for -fno-automatic.
299 2005-09-23 Paul Thomas <pault@gcc.gnu.org>
302 * module.c (mio_component_ref): Return if the symbol is NULL
303 and wait for another iteration during module reads.
304 (mio_symtree_ref): Suppress the writing of contained symbols,
305 when a symbol is available in the main namespace.
306 (read_module): Restrict scope of special treatment of contained
307 symbols to variables only and suppress redundant call to
310 2005-09-22 Steven G. Kargl <kargls@comcast.net>
313 * interface.c (check_interface1): Fix NULL dereference.
315 2005-09-22 Erik Edelmann <erik.edelmann@iki.fi>
318 * resolve.c (derived_inaccessible): New function.
319 (resolve_transfer): Use it to check for private
322 2005-09-22 Steven G. Kargl <kargls@comcast.net>
325 * intrinsic.c (add_function): Add IMAG, IMAGPART, and REALPART
327 * intrinsic.h: Prototypes for gfc_simplify_realpart and
328 gfc_resolve_realpart.
329 * intrinsic.texi: Document intrinsic procedures.
330 * simplify.c (gfc_simplify_realpart): New function.
331 * irseolve.c (gfc_resolve_realpart): New function.
333 2005-09-21 Erik Edelmann <erik.edelmann@iki.fi>
336 * trans-stmt.c (gfc_trans_deallocate): Check if the
337 object to be deallocated is an array by looking at
338 expr->rank instead of expr->symtree->n.sym->attr.dimension.
340 2005-09-20 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
343 * io.c (resolve_tag): Don't allow non-CHARACTER constants as formats.
344 (match_io): Fix usage of gfc_find_symbol.
346 2005-09-20 Jakub Jelinek <jakub@redhat.com>
349 * primary.c (match_actual_arg): Handle ENTRY the same way
352 2005-09-18 Francois-Xavier Coudert <coudert@clipper.ens.fr>
354 * Make-lang.in: Make check-fortran alias for check-gfortran.
356 2005-09-18 Andreas Jaeger <aj@suse.de>
358 * module.c (read_module): Add missed line from last patch.
360 2005-09-18 Erik Edelmann <erik.edelmann@iki.fi>
363 * resolve.c (resolve_symbol): Don't assign default
364 initializer to pointers.
366 2005-09-18 Paul Thomas <pault@gcc.gnu.org>
369 * module.c (read_module): Give symbols from module procedures
370 different true_name entries to those from the module proper.
372 2005-09-17 Francois-Xavier Coudert <coudert@clipper.ens.fr>
375 * arith.c (gfc_arith_error): Add translation support for error
377 * array.c (gfc_match_array_ref): Likewise.
378 (gfc_match_array_spec): Likewise.
379 * check.c (must_be): Add msgid convention to third argument.
380 (same_type_check): Add translation support for error message.
381 (rank_check): Likewise.
382 (kind_value_check): Likewise.
383 (gfc_check_associated): Correct typo.
384 (gfc_check_reshape): Add translation support for error message.
385 (gfc_check_spread): Likewise.
386 * error.c (error_printf): Add nocmsgid convention to argument.
387 (gfc_warning, gfc_notify_std, gfc_warning_now, gfc_warning_check)
388 (gfc_error, gfc_error_now): Likewise.
389 (gfc_status): Add cmsgid convention to argument.
390 * expr.c (gfc_extract_int): Add translation support for error
392 (gfc_check_conformance): Add msgid convention to argument.
393 (gfc_check_pointer_assign): Correct tabbing.
394 * gfortran.h: Include intl.h header. Remove prototype for gfc_article.
395 * gfortranspec.c: Include intl.h header.
396 (lang_specific_driver): Add translation support for --version.
397 * io.c (check_format): Add translation support for error message.
398 (format_item_1): Likewise.
399 (data_desc): Likewise.
400 * matchexp.c: Likewise.
401 * misc.c (gfc_article): Remove function.
402 * module.c (bad_module): Use msgid convention. Add translation support
404 (require_atom): Add translation support for error messages.
405 * parse.c (gfc_ascii_statement): Likewise.
406 (gfc_state_name): Likewise.
407 * primary.c (match_boz_constant): Reorganise error messages for
409 * resolve.c (resolve_entries): Likewise.
410 (resolve_operator): Add translation support for error messages.
411 (gfc_resolve_expr): Use msgid convention. Reorganise error messages
413 (resolve_symbol): Add translation support for error messages.
414 * symbol.c (gfc_add_procedure): Remove use of gfc_article function.
415 * trans-const.c (gfc_build_string_const): Use msgid convention.
417 2005-09-16 Paul Brook <paul@codesourcery.com>
420 * dependency.c (transform_sections): Divide by correct value.
423 2005-09-14 Paul Thomas <pault@gcc.gnu.org>
425 PR fortran/21875 Internal Unit Array I/O, NIST
426 * fortran/trans-io.c (gfc_build_io_library_fndecls): Add field for
427 array descriptor to IOPARM structure.
428 * fortran/trans-io.c (set_internal_unit): New function to generate code
429 to store the character (array) and the character length for an internal
431 * fortran/trans-io (build_dt): Use the new function set_internal_unit.
433 2005-09-14 Paul Thomas <pault@gcc.gnu.org>
436 * trans-array.c (gfc_trans_dummy_array_bias): correct the typo
437 which uses dim[i].upper for lbound, rather than dim[i].lower.
439 2005-09-13 Erik Edelmann <erik.edelmann@iki.fi>
442 * trans-expr.c (gfc_trans_arrayfunc_assign): Check value
443 of attr.elemental for specific function instead of generic name.
445 2005-09-13 Richard Sandiford <richard@codesourcery.com>
448 * trans-intrinsic.c (gfc_conv_intrinsic_bound): Move initialization
449 of argse. Remove now-redundant want_pointer assignment.
450 * trans-array.c (gfc_conv_expr_descriptor): When not assigning to
451 a pointer, keep the original bounds of a full array reference.
453 2005-09-13 Richard Sandiford <richard@codesourcery.com>
456 * iresolve.c (gfc_resolve_cshift, gfc_resolve_eoshift)
457 (gfc_resolve_pack, gfc_resolve_reshape, gfc_resolve_spread)
458 (gfc_resolve_transpose, gfc_resolve_unpack): Add "_char" to the name
459 for character-based operations.
460 (gfc_resolve_pack): Remove ATTRIBUTE_UNUSED from array argument.
461 (gfc_resolve_unpack): Copy the whole typespec from the vector.
462 * trans-array.c (gfc_conv_expr_descriptor): In the EXPR_FUNCTION
463 case, get the string length from the scalarization state.
465 2005-09-14 Francois-Xavier Coudert <coudert@clipper.ens.fr>
467 * Make-lang.in: Change targets prefixes from f95 to fortran.
468 * config-lang.in: Change language name to "fortran".
469 * lang.opt: Change language name to "fortran".
470 * options.c: Change CL_F95 to CL_Fortran.
472 2005-09-09 Thomas Koenig <Thomas.Koenig@online.de>
474 gfortran.texi: Document IOSTAT= specifier.
476 2005-09-09 Thomas Koenig <Thomas.Koenig@online.de>
478 * gfortran.h: Add iomsg to gfc_open, gfc_close, gfc_filepos,
479 gfc_inquire and gfc_dt.
480 * dump-parse-tree.c (gfc_show_code_node): Add iomsg
481 for open, close, file positioning, inquire and namelist.
482 * io.c (io_tag): Add tag_iomsg.
483 (resolve_tag): Add standards warning for iomsg.
484 (match_open_element): Add iomsg.
485 (gfc_free_open): Add iomsg.
486 (gfc_resolve_open): Add iomsg.
487 (gfc_free_close): Add iomsg.
488 (match_close_element): Add iomsg.
489 (gfc_resolve_close): Add iomsg.
490 (gfc_free_filepos): Add iomsg.
491 (match_file_element): Add iomsg.
492 (gfc_resolve_filepos): Add iostat and iomsg.
493 (match-dt_element): Add iomsg.
494 (gfc_free_dt): Add iomsg.
495 (gfc_resolve_dt): Add iomsg.
496 (gfc_free_inquire): Add iomsg.
497 (match_inquire_element): Add iomsg.
498 (gfc_resolve_inquire): Add iomsg.
499 * trans_io.c: Add ioparm_iomsg and ioparm_iomsg_len.
500 (gfc_build_io_library_fndecls): Add iomsg as last field.
501 (gfc_trans_open): Add iomsg.
502 (gfc_trans_close): Add iomsg.
503 (build_fileos): Call set_string for iomsg.
504 (gfc_trans_inquire): Add iomsg.
505 (build_dt): Add iomsg.
507 2005-09-09 Richard Sandiford <richard@codesourcery.com>
509 * match.h (gfc_match_equiv_variable): Declare.
511 2005-09-09 Richard Sandiford <richard@codesourcery.com>
514 * Makefile.in (fortran/trans-expr.o): Depend on dependency.h.
515 * dependency.h (gfc_ref_needs_temporary_p): Declare.
516 * dependency.c (gfc_ref_needs_temporary_p): New function.
517 (gfc_check_fncall_dependency): Use it instead of inlined check.
518 By so doing, take advantage of the fact that character substrings
519 within an array reference also need a temporary.
520 * trans.h (GFC_SS_VECTOR): Adjust comment.
521 * trans-array.c (gfc_free_ss): Remove GFC_SS_VECTOR case.
522 (gfc_set_vector_loop_bounds): New function.
523 (gfc_add_loop_ss_code): Call it after evaluating the subscripts of
524 a GFC_SS_SECTION. Deal with the GFC_SS_VECTOR case by evaluating
525 the vector expression and caching its descriptor for use within
527 (gfc_conv_array_index_ref, gfc_conv_vector_array_index): Delete.
528 (gfc_conv_array_index_offset): Handle scalar, vector and range
529 dimensions as separate cases of a switch statement. In the vector
530 case, use the loop variable to calculate a vector index and use the
531 referenced element as the dimension's index. Perform bounds checking
533 (gfc_conv_section_upper_bound): Return null for vector indexes.
534 (gfc_conv_section_startstride): Give vector indexes a start value
535 of 0 and a stride of 1.
536 (gfc_conv_ss_startstride): Adjust for new GFC_SS_VECTOR representation.
537 (gfc_conv_expr_descriptor): Expand comments. Generalize the
538 handling of the !want_pointer && !direct_byref case. Use
539 gfc_ref_needs_temporary_p to decide whether the variable case
541 (gfc_walk_variable_expr): Handle DIMEN_VECTOR by creating a
543 * trans-expr.c: Include dependency.h.
544 (gfc_trans_arrayfunc_assign): Fail if the target needs a temporary.
546 2005-09-09 Richard Sandiford <richard@codesourcery.com>
549 * trans.h (gfc_interface_sym_mapping, gfc_interface_mapping): Moved
551 (gfc_init_interface_mapping, gfc_free_interface_mapping)
552 (gfc_add_interface_mapping, gfc_finish_interface_mapping)
553 (gfc_apply_interface_mapping): Declare.
554 * trans-array.h (gfc_set_loop_bounds_from_array_spec): Declare.
555 (gfc_trans_allocate_temp_array): Add pre and post block arguments.
556 * trans-array.c (gfc_set_loop_bounds_from_array_spec): New function.
557 (gfc_trans_allocate_array_storage): Replace loop argument with
558 separate pre and post blocks.
559 (gfc_trans_allocate_temp_array): Add pre and post block arguments.
560 Update call to gfc_trans_allocate_array_storage.
561 (gfc_trans_array_constructor, gfc_conv_loop_setup): Adjust for new
562 interface to gfc_trans_allocate_temp_array.
563 * trans-expr.c (gfc_interface_sym_mapping, gfc_interface_mapping):
565 (gfc_init_interface_mapping, gfc_free_interface_mapping)
566 (gfc_add_interface_mapping, gfc_finish_interface_mapping)
567 (gfc_apply_interface_mapping): Make extern.
568 (gfc_conv_function_call): Build an interface mapping for array
569 return values too. Call gfc_set_loop_bounds_from_array_spec.
570 Adjust call to gfc_trans_allocate_temp_array so that code is
571 added to SE rather than LOOP.
573 2005-09-09 Richard Sandiford <richard@codesourcery.com>
576 * trans.h (gfor_fndecl_internal_realloc): Declare.
577 (gfor_fndecl_internal_realloc64): Declare.
578 * trans-decl.c (gfor_fndecl_internal_realloc): New variable.
579 (gfor_fndecl_internal_realloc64): New variable.
580 (gfc_build_builtin_function_decls): Initialize them.
581 * trans-array.h (gfc_trans_allocate_temp_array): Add a fourth argument.
582 * trans-array.c (gfc_trans_allocate_array_storage): Add an argument
583 to say whether the array can grow later. Don't allocate the array
584 on the stack if so. Don't call malloc for zero-sized arrays.
585 (gfc_trans_allocate_temp_array): Add a similar argument here.
586 Pass it along to gfc_trans_allocate_array_storage.
587 (gfc_get_iteration_count, gfc_grow_array): New functions.
588 (gfc_iterator_has_dynamic_bounds): New function.
589 (gfc_get_array_constructor_element_size): New function.
590 (gfc_get_array_constructor_size): New function.
591 (gfc_trans_array_ctor_element): Replace pointer argument with
593 (gfc_trans_array_constructor_subarray): Likewise. Take an extra
594 argument to say whether the variable-sized part of the constructor
595 must be allocated using realloc. Grow the array when this
597 (gfc_trans_array_constructor_value): Likewise.
598 (gfc_get_array_cons_size): Delete.
599 (gfc_trans_array_constructor): If the loop bound has not been set,
600 split the allocation into a static part and a dynamic part. Set
601 loop->to to the bounds for static part before allocating the
602 temporary. Adjust call to gfc_trans_array_constructor_value.
603 (gfc_conv_loop_setup): Allow any constructor to determine the
604 loop bounds. Check whether the constructor has a dynamic size
605 and prefer to use something else if so. Expect the loop bound
606 to be set later. Adjust call to gfc_trans_allocate_temp_array.
607 * trans-expr.c (gfc_conv_function_call): Adjust another call here.
609 2005-09-09 Paul Thomas <pault@gcc.gnu.org>
612 * module.c (find_use_name_n): Based on original
613 find_use_name. Either counts number of use names for a
614 given real name or returns use name n.
615 (find_use_name, number_use_names): Interfaces to the
616 function find_use_name_n.
617 (read_module): Add the logic and calls to these functions,
618 so that mutiple reuses of the same real name are loaded.
620 2005-09-09 Paul Thomas <pault@gcc.gnu.org>
627 * gfortran.h: Move definition of BLANK_COMMON_NAME from trans-
628 common.c so that it is accessible to module.c. Add common_head
629 field to gfc_symbol structure. Add field for the equivalence
630 name AND new attr field, in_equivalence.
631 * match.c (gfc_match_common, gfc_match_equivalence): In loops
632 that flag common block equivalences, emit an error if the
633 common blocks are different, using sym->common_head as the
634 common block identifier. Ensure that symbols that are equivalence
635 associated with a common block are marked as being in_common.
636 * module.c (write_blank_common): New.
637 (write_common): Use unmangled common block name.
638 (load_equiv): New function ported from g95.
639 (read_module): Call load_equiv.
640 (write_equiv): New function ported from g95. Correct
641 string referencing for gfc functions. Give module
642 equivalences a unique name.
643 (write_module): Call write_equiv and write_blank_common.
644 * primary.c (match_variable) Old gfc_match_variable, made
645 static and third argument provided to indicate if parent
646 namespace to be visited or not.
647 (gfc_match_variable) New. Interface to match_variable.
648 (gfc_match_equiv_variable) New. Interface to match_variable.
649 * trans-common.c (finish_equivalences): Provide the call
650 to create_common with a gfc_common_header so that
651 module equivalences are made external, rather than local.
652 (find_equivalences): Ensure that all members in common block
653 equivalences are marked as used. This prevents the subsequent
654 call to this function from making local unions.
655 * trans-decl.c (gfc_generate_function_code): Move the call to
656 gfc_generate_contained_functions to after the call to
657 gfc_trans_common so the use-associated, contained common
658 blocks produce the correct references.
659 (gfc_create_module_variable): Return for equivalenced symbols
660 with existing backend declaration.
662 2005-09-08 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
665 * match.c (gfc_match_common): Remove unnecessary / wrong special
666 cases for end-of-statement.
668 2005-09-08 Janne Blomqvist <jblomqvi@cc.hut.fi>
670 * gfortran.texi: Add section about implemented F2003 features.
672 2005-09-08 Richard Sandiford <richard@codesourcery.com>
675 * trans-array.c (gfc_add_loop_ss_code): Set ss->string_length in
676 the GFC_SS_FUNCTION case too.
677 * trans-expr.c (gfc_conv_function_val): Allow symbols to be bound
678 to function pointers as well as function decls.
679 (gfc_interface_sym_mapping, gfc_interface_mapping): New structures.
680 (gfc_init_interface_mapping, gfc_free_interface_mapping)
681 (gfc_get_interface_mapping_charlen, gfc_get_interface_mapping_array)
682 (gfc_set_interface_mapping_bounds, gfc_add_interface_mapping)
683 (gfc_finish_interface_mapping, gfc_apply_interface_mapping_to_cons)
684 (gfc_apply_interface_mapping_to_ref)
685 (gfc_apply_interface_mapping_to_expr)
686 (gfc_apply_interface_mapping): New functions.
687 (gfc_conv_function_call): Evaluate the arguments before working
688 out where the result should go. Make the null pointer case provide
689 the string length in parmse.string_length. Cope with non-constant
690 string lengths, using the above functions to evaluate such lengths.
691 Use a temporary typespec; don't assign to sym->cl->backend_decl.
692 Don't assign to se->string_length when returning a cached array
695 2005-09-08 Richard Sandiford <richard@codesourcery.com>
698 * trans-array.c (gfc_conv_array_ref): Call gfc_advance_se_ss_chain
699 after handling scalarized references. Make "indexse" inherit from
700 "se" when handling AR_ELEMENTs.
701 (gfc_walk_variable_expr): Add GFC_SS_SCALAR entries for each
702 substring or scalar reference that follows an array section.
703 * trans-expr.c (gfc_conv_variable): When called from within a
704 scalarization loop, start out with "ref" pointing to the scalarized
705 part of the reference. Don't call gfc_advance_se_ss_chain here.
707 2005-09-07 Richard Sandiford <richard@codesourcery.com>
710 * trans-expr.c (gfc_trans_pointer_assignment): Assign to a temporary
711 descriptor if the rhs is not a null pointer or variable.
713 2005-09-07 Thomas Koenig <Thomas.Koenig@online.de>
716 * symbol.c(check_conflict): Add conflict for parameter/save,
718 2005-09-06 Richard Sandiford <richard@codesourcery.com>
721 * simplify.c (gfc_simplify_transpose): Set the result's typespec from
722 the source, not the first element of the return value.
724 2005-09-04 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
727 * io.c (match_io): Correctly backup if PRINT followed by
728 symbol which is not a namelist. Force blank between PRINT
729 and namelist in free form.
731 2005-08-31 Francois-Xavier Coudert <coudert@clipper.ens.fr>
734 * gfortran.h (gfc_option_t): Add flag_automatic.
735 * invoke.texi: Document the -fno-automatic option.
736 * lang.opt: Add a -fautomatic option.
737 * options.c (gfc_init_options): Default for -fautomatic is on.
738 (gfc_handle_option): Add handling of -fautomatic option.
739 * resolve.c (gfc_resolve): When -fno-automatic is used, mark
740 needed variables as SAVE.
742 2005-08-27 Erik Edelmann <erik.edelmann@iki.fi>
744 * trans-array.c (gfc_trans_deferred_array): Fix comments.
746 2005-08-27 Erik Schnetter <schnetter@aei.mpg.de>
748 * primary.c (match_charkind_name): Fix typo in comment leading to
751 2005-08-25 Erik Edelmann <eedelman@acclab.helsinki.fi>
754 * symbol.c (find_special): Remove.
755 (build_sym, add_init_expr, attr_decl1): Remove calls to
756 find_special in favor of calls to gfc_get_symbol.
758 2005-08-24 Thomas Koenig <Thomas.Koenig@online.de>
761 * gfortran.h (symbol_attribute): Add noreturn to the structure.
762 (gfc_intrinsic_sym): Add noreturn to the structure.
763 * intrinsic.c (make_noreturn): New function.
764 (add_subroutines): Mark subroutines abort and exit as noreturn.
765 (gfc_intrinsic_sub_interface): Copy noreturn attribute from
766 isym to the resolved symbol.
767 * trans-decl.c (gfc_get_extern_function_decl): Set function
768 as VOLATILE (== noreturn) if the noreturn attribute is set.
770 2005-08-21 Steven G. Kargl <kargls@comcast.net>
772 * decl.c: Typo in comment.
774 2005-08-21 Steven G. Kargl <kargls@comcast.net>
776 * array.c: Bump GFC_MAX_AC_EXPAND from 100 to 65535.
778 2005-08-21 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
780 * gfortran.h (gfc_option_t): Remove source field. Add
782 (gfc_new_file): Remove arguments in prototype.
783 (gfc_source_file): Make 'const char *'.
784 * f95-lang.c (gfc_init): Use gfc_source_file instead of
785 gfc_option.source. Call gfc_new_file without arguments.
786 * invoke.texi: Document new options '-fd-lines-as-code' and
787 '-fd-lines-as-comment'.
788 * lang.opt: Add new options. Alphabetize.
789 * options.c (gfc_init_options): Initialize gfc_source_file instead
790 of gfc_option.source. Initialize gfc_option.flag_d_lines.
791 (form_from_filename): Move here from scanner.c. Make
792 'filename' argument 'const'.
793 (gfc_post_options): Set gfc_source_file. Determine source form.
794 Warn if 'd-lines*' are used in free form.
795 * scanner.c (gfc_source_file): Constify.
796 (skip_fixed_comments): Deal with d-lines.
797 (get_file): Constify argument 'name'.
798 (load_file): Constify argument 'filename'.
799 (form_from_filename): Moved to options.c.
800 (gfc_new_file): Remove arguments. Don't initialize
801 gfc_source_file, don't determine source form.
802 * trans-const.c (gfc_init_constants): Use gfc_source_file instead
803 of gfc_option.source.
805 2005-08-19 Steven G. Kargl <kargls@comcast.net>
808 * gfortran.h: Remove PATH_MAX definition.
809 * module.c (write_module, gfc_dump_module): Use alloca to allocate
811 * scanner.c (gfc_release_include_path, form_from_filename): Ditto.
813 2004-08-16 Huang Chun <chunhuang73@hotmail.com>
815 * trans-expr.c (gfc_conv_power_op): Evaluate the expression before
818 2005-08-14 Asher Langton <langton2@llnl.gov>
820 * parse.c (match): Enclose macro in do...while(0) and braces.
822 2005-08-14 Paul Thomas <pault@gcc.gnu.org>
825 * gfortran.texi: Document PRINT namelist.
827 2005-08-14 Paul Thomas <pault@gcc.gnu.org>
830 * io.c (match_io): Add code to implement PRINT namelist.
832 2005-08-14 Canqun Yang <canqun@nudt.edu.cn>
834 * trans-stmt.c (gfc_trans_arithmetic_if): Optimized in case of equal
837 2005-08-11 Francois-Xavier Coudert <coudert@clipper.ens.fr>
838 Steven Bosscher <stevenb@suse.de>
841 * gfortran.h: Add is_main_program member to symbol_attribute.
842 * trans-decl: Add a gfor_fndecl_set_std tree.
843 (gfc_build_builtin_function_decls): Create it.
844 (gfc_generate_function_code): Add this call at the beginning of
846 * trans.c (gfc_generate_code): Move main_program and attr.
847 * trans.h: Add declaration for gfor_fndecl_set_std.
849 2005-08-10 Thomas Koenig <Thomas.Koenig@online.de>
852 gfortran.h: Declare new function gfc_resolve_dim_arg.
853 resolve.c: New function gfc_resolve_dim_arg.
854 iresolve.c (gfc_resolve_all): Use gfc_resolve_dim_arg.
855 (gfc_resolve_any): Likewise.
856 (gfc_resolve_count): Likewise.
857 (gfc_resolve_cshift): Likewise. If the kind of shift is less
858 gfc_default_integer_kind, convert it to default integer type.
859 (gfc_resolve_eoshift): Likewise.
860 (gfc_resolve_maxloc): Use gfc_resolve_dim_arg.
861 (gfc_resolve_maxval): Likewise.
862 (gfc_resolve_minloc): Likewise.
863 (gfc_resolve_minval): Likewise.
864 (gfc_resolve_product): Likewise.
865 (gfc_resolve_spread): Likewise.
866 (gfc_resolve_sum): Likewise.
868 2005-08-09 Francois-Xavier Coudert <coudert@clipper.ens.fr>
870 * check.c (gfc_check_ttynam_sub, gfc_check_isatty): Add check
871 functions for new intrinsics TTYNAM and ISATTY.
872 * intrinsic.c (add_functions, add_subroutines): Add new
874 * intrinsic.h: Add prototypes for new check and resolve
876 * iresolve.c (gfc_resolve_isatty, gfc_resolve_ttynam_sub): New
877 resolve functions for intrinsics TTYNAM and ISATTY.
878 * gfortran.h (gfc_generic_isym_id): Add symbol for ISATTY.
879 * trans-intrinsic.c: Add case for GFC_ISYM_ISATTY.
881 2005-08-09 Jakub Jelinek <jakub@redhat.com>
883 * scanner.c (preprocessor_line): Don't write beyond the end of flag
886 2005-08-07 Janne Blomqvist <jblomqvi@cc.hut.fi>
889 * dump-parse-tree.c (gfc_show_code_node): Add case for FLUSH.
890 * gfortran.h: Add enums for FLUSH.
891 * io.c (gfc_free_filepos,match_file_element,match_filepos): Modify
892 comment appropriately. (gfc_match_flush): New function.
893 * match.c (gfc_match_if): Add match for flush.
894 * match.h: Add prototype.
895 * parse.c (decode_statement): Add flush to 'f' case.
896 (next_statement): Add case for flush. (gfc_ascii_statement): Likewise.
897 * resolve.c (resolve_code): Add flush case.
898 * st.c (gfc_free_statement): Add flush case.
899 * trans-io.c: Add prototype for flush.
900 (gfc_build_io_library_fndecls): Build fndecl for flush.
901 (gfc_trans_flush): New function.
902 * trans-stmt.h: Add prototype.
903 * trans.c (gfc_trans_code): Add case for flush.
905 2005-08-06 Francois-Xavier Coudert <coudert@clipper.ens.fr>
907 * primary.c (match_hollerith_constant): Fix typo.
909 2005-08-06 Kazu Hirata <kazu@codesourcery.com>
911 * decl.c, dump-parse-tree.c, gfortran.texi, intrinsic.texi,
912 invoke.texi, resolve.c, trans-array.c, trans-array.h,
913 trans-common.c, trans-expr.c, trans-io.c, trans.h: Fix
914 comment/doc typos. Follow spelling conventions.
916 2005-08-06 Jakub Jelinek <jakub@redhat.com>
920 * primary.c (match_varspec): If equiv_flag, don't look at sym's
921 attributes, call gfc_match_array_ref up to twice and don't do any
922 substring or component processing.
923 * resolve.c (resolve_equivalence): Transform REF_ARRAY into
924 REF_SUBSTRING or nothing if needed. Check that substrings
925 don't have zero length.
927 2005-08-05 Thomas Koenig <Thomas.Koenig@online.de>
929 * trans-expr.c (gfc_build_builtin_function_decls): Mark
930 stop_numeric and stop_string as non-returning.
932 2005-08-04 Paul Brook <paul@codesourcery.com>
934 * trans-expr.c (gfc_conv_expr, gfc_conv_expr_type): Update comments.
935 (gfc_conv_expr_lhs): Fix assertion.
936 (gfc_conv_expr_val): Merge post block. Set se.expr to new value.
938 2005-08-02 David Edelsohn <edelsohn@gnu.org>
941 * expr.c (simplify_parameter_variable): Do not copy the subobject
942 references if the expression value is a constant.
944 * expr.c (gfc_simplify_expr): Evaluate constant substrings.
946 2005-07-31 Jerry DeLisle <jvdelisle@verizon.net>
948 * intrinsic.texi: Add documentation for exponent, floor, and fnum and
949 fix description of ceiling in index.
951 2005-07-31 Steven Bosscher <stevenb@suse.de>
953 * trans-decl.c (gfc_build_builtin_function_decls): Give the internal
954 malloc functions the 'malloc' attribute. Give runtime_error the
955 'noreturn' attribute.
957 2005-07-31 Steven Bosscher <stevenb@suse.de>
959 * trans-stmt.c (gfc_trans_goto): Jump to the known label instead
960 of the assigned goto variable.
962 2005-07-29 Steven Bosscher <stevenb@suse.de>
964 * trans-types.h (gfc_array_range_type): Add missing GTY decl for this.
966 2005-07-28 Andrew Pinski <pinskia@physics.uc.edu>
968 * fortran/f95-lang.c (language_function): Remove
969 named_labels, shadowed_labels, returns_value, returns_abnormally,
970 warn_about_return_type, and extern_inline fields.
971 (named_labels): Remove variable.
972 (gfc_init_decl_processing): Remove setting of named_labels.
974 2005-07-27 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
977 * resolve.c (resolve_operator): Improve diagnostic for comparison
978 of logicals with invalid operator.
980 2005-07-25 Jakub Jelinek <jakub@redhat.com>
983 * data.c (gfc_assign_data_value_range): Call
984 create_character_initializer if last_ts is a character type.
986 2005-07-22 Manfred Hollstein <mh@suse.com>
988 * match.c (gfc_match_symbol): Fix uninitialised warnings.
989 * matchexp.c (gfc_match_expr): Likewise.
991 2005-07-20 Giovanni Bajo <giovannibajo@libero.it>
993 Make CONSTRUCTOR use VEC to store initializers.
994 * trans-array.c (gfc_build_null_descriptor,
995 gfc_trans_array_constructor_value, gfc_conv_array_initializer):
996 Update to cope with VEC in CONSTRUCTOR_ELTS.
997 * trans-common.c (create_common): Likewise.
998 * trans-expr.c (gfc_conv_structure): Likewise.
999 * trans-stmt.c (gfc_trans_character_select): Use
1000 build_constructor_from_list instead of build_constructor.
1002 2005-07-19 Paul Thomas <pault@gcc.gnu.org>
1005 * resolve.c (resolve_symbol): A symbol with FL_UNKNOWN
1006 is matched against interfaces in parent namespaces. If there
1007 the symtree is set to point to the interface.
1009 2005-07-16 David Edelsohn <edelsohn@gnu.org>
1012 * decl.c (do_parm): Adjust character initializer to character length
1013 of symbol before assigning.
1015 2005-07-14 Steve Ellcey <sje@cup.hp.com>
1017 * trans-types.c (MAX_REAL_KINDS): Increase from 4 to 5.
1019 2005-07-14 Jakub Jelinek <jakub@redhat.com>
1021 * gfortran.h (MAX_ERROR_MESSAGE): Remove.
1022 (gfc_error_buf): Add allocated and index fields. Change message
1023 field from array to a pointer.
1024 * error.c (use_warning_buffer, error_ptr, warning_ptr): Remove.
1025 (cur_error_buffer): New variable.
1026 (error_char): Use cur_error_buffer->{message,index} instead of
1027 {warning,error}_{buffer.message,ptr}. Reallocate message buffer
1029 (gfc_warning, gfc_notify_std, gfc_error, gfc_error_now): Setup
1030 cur_error_buffer and its index rather than {warning,error}_ptr
1031 and use_warning_buffer.
1032 (gfc_warning_check, gfc_error_check): Don't print anything if
1034 (gfc_push_error): Allocate saved message with xstrdup.
1035 (gfc_pop_error): Free saved message with gfc_free.
1036 (gfc_free_error): New function.
1037 * primary.c (match_complex_constant): Call gfc_free_error if
1038 gfc_pop_error will not be called.
1039 * match.c (gfc_match_st_function): Likewise.
1042 * scanner.c (preprocessor_line): Don't treat flag 3 as the start of a new
1043 file. Fix file left but not entered warning.
1045 2005-07-14 Feng Wang <fengwang@nudt.edu.cn>
1046 Steven G. Kargl <kargls@comcast.net>
1048 * array.c (resolve_character_array_constructor): Allocate gfc_charlen
1049 for the array and attach to namespace list for automatic deallocation.
1051 2005-07-13 Andreas Schwab <schwab@suse.de>
1053 * Make-lang.in (fortran/dependency.o): Depend on
1054 $(GFORTRAN_TRANS_DEPS).
1056 2005-07-11 Jakub Jelinek <jakub@redhat.com>
1058 * trans-stmt.c (gfc_trans_forall_loop): Clear maskindex before
1060 (gfc_trans_assign_need_temp, gfc_trans_pointer_assign_need_temp,
1061 gfc_trans_forall_1, gfc_evaluate_where_mask, gfc_trans_where_2):
1062 Don't clear maskindexes here.
1064 2005-07-08 Daniel Berlin <dberlin@dberlin.org>
1066 * trans-decl.c (create_function_arglist): DECL_ARG_TYPE_AS_WRITTEN
1069 2005-07-08 Jakub Jelinek <jakub@redhat.com>
1071 * primary.c (gfc_match_rvalue): Handle ENTRY the same way
1074 2005-07-07 Jakub Jelinek <jakub@redhat.com>
1076 * scanner.c (load_line): Add pbuflen argument, don't make
1077 buflen static. If maxlen == 0 or preprocessor_flag,
1078 don't truncate at buflen, but at maxlen. In xrealloc add
1079 1 byte at the end for the terminating '\0'. Don't fill
1080 with spaces up to buflen, but gfc_option.fixed_line_length.
1081 (load_file): Adjust load_line caller. Add line_len variable.
1083 * scanner.c (preprocessor_line): Only set current_file->line when errors
1084 have not been encountered. Warn and don't crash if a file leave
1085 preprocessor line has no corresponding entering line. Formatting.
1087 2005-07-07 Steven Bosscher <stevenb@suse.de>
1089 * primary.c (match_hollerith_constant): Use int, not unsigned int,
1090 for the hollerith length. Fix indentation.
1092 2005-07-07 Feng Wang <fengwang@nudt.edu.cn>
1097 * arith.c (gfc_hollerith2int, gfc_hollerith2real,
1098 gfc_hollerith2complex, gfc_hollerith2character, gfc_hollerith2logical):
1100 (eval_intrinsic): Don't evaluate if Hollerith constant arguments exist.
1101 * arith.h (gfc_hollerith2int, gfc_hollerith2real,
1102 gfc_hollerith2complex, gfc_hollerith2character, gfc_hollerith2logical):
1104 * expr.c (free_expr0): Free memery allocated for Hollerith constant.
1105 (gfc_copy_expr): Allocate and copy string if Expr is from Hollerith.
1106 (gfc_check_assign): Enable conversion from Hollerith to other.
1107 * gfortran.h (bt): Add BT_HOLLERITH.
1108 (gfc_expr): Add from_H flag.
1109 * intrinsic.c (gfc_type_letter): Return 'h' for BT_HOLLERITH.
1110 (add_conversions): Add conversions from Hollerith constant to other.
1111 (do_simplify): Don't simplify if Hollerith constant arguments exist.
1112 * io.c (resolve_tag): Enable array in FORMAT tag under GFC_STD_GNU.
1113 * misc.c (gfc_basetype_name): Return "HOLLERITH" for BT_HOLLERITH.
1114 (gfc_type_name): Print "HOLLERITH" for BT_HOLLERITH.
1115 * primary.c (match_hollerith_constant): New function.
1116 (gfc_match_literal_constant): Add match Hollerith before Integer.
1117 * simplify.c (gfc_convert_constant): Add conversion from Hollerith
1119 * trans-const.c (gfc_conv_constant_to_tree): Use VIEW_CONVERT_EXPR to
1120 convert Hollerith constant to tree.
1121 * trans-io.c (gfc_convert_array_to_string): Get array's address and
1122 length to set string expr.
1123 (set_string): Deal with array assigned Hollerith constant and character
1125 * gfortran.texi: Document Hollerith constants as extention support.
1127 2005-07-07 Feng Wang <fengwang@nudt.edu.cn>
1130 * trans-array.c (gfc_trans_array_constructor_value): Fix index of data.
1132 2005-07-07 Jakub Jelinek <jakub@redhat.com>
1134 * decl.c (gfc_match_entry): Allow ENTRY without parentheses
1137 2005-07-03 Kazu Hirata <kazu@codesourcery.com>
1139 * gfortran.texi, intrinsic.texi: Fix typos.
1140 * symbol.c: Fix a comment typo.
1142 2005-07-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1144 * error.c (error_printf, error_print): Use ATTRIBUTE_GCC_GFC.
1145 * gfortran.h (ATTRIBUTE_GCC_GFC): New.
1146 (gfc_warning, gfc_warning_now, gfc_error, gfc_error_now,
1147 gfc_fatal_error, gfc_internal_error, gfc_notify_std): Use
1150 2005-07-03 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1153 * io.c (match_dt_element): Do not allow END tag in PRINT or
1156 2005-07-02 Joseph S. Myers <joseph@codesourcery.com>
1158 * lang.opt: Remove "." from end of help texts.
1160 2005-07-01 Jerry DeLisle <jvdelisle@verizon.net>
1162 * gfortran.texi: Fix typos and grammar.
1163 * invoke.texi: Fix typos and grammar.
1164 * intrinsic.texi: Add documentaion for eoshift, epsilon, etime, and
1165 exit. Fixed alignment of text for dtime syntax. Fixed a few line
1168 2005-06-25 Jakub Jelinek <jakub@redhat.com>
1170 * trans-stmt.c (gfc_trans_forall_1): Prefer to use smaller logical
1171 type than boolean_type_node.
1173 2005-06-25 Kelley Cook <kcook@gcc.gnu.org>
1175 * all files: Update FSF address in copyright headers.
1177 2005-06-24 Jerry DeLisle <jvdelisle@verizon.net>
1180 * gfortran.h: Add symbols for new intrinsic functions.
1181 * intrinsic.c: Add new functions acosh, asinh, and atanh.
1182 * intrinsic.h: Add prototypes for the new functions.
1183 * iresolve.c (gfc_resolve_acosh): New function.
1184 (gfc_resolve_asinh): New function.
1185 (gfc_resolve_atanh): New function.
1186 * mathbuiltins.def: Add defines.
1187 * simplify.c (gfc_simplify_acosh): New function.
1188 (gfc_simplify_asinh): New function.
1189 (gfc_simplify_atanh): New function.
1191 2005-06-24 Feng Wang <fengwang@nudt.edu.cn>
1193 * simplify.c (gfc_simplify_modulo): Don't clear before get result.
1195 2005-06-22 Paul Brook <paul@codesourcery.com>
1198 * symbol.c (gfc_is_var_automatic): New function.
1199 (save_symbol): Use it.
1201 2005-06-21 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
1202 Paul Thomas <pault@gcc.gnu.org>
1206 * module.c (mio_namelist): New function. Correct to set
1207 namelist_tail and to give error on renaming namelist by use
1209 (mio_symbol): Call mio_namelist.
1211 2005-06-19 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1213 * gfortran.h: Add flag_backslash compile-time option.
1214 * lang.opt: Add support for -fbackslash option.
1215 * options.c: Likewise.
1216 * primary.c: Implement behavior for -fno-backslash.
1217 * invoke.texi: Add doc for -fbackslash option.
1218 * gfortran.texi: Remove mention of -fno-backslash as a
1221 2005-06-20 Steven G. Kargl <kargls@comcast.net>
1225 * match.c (gfc_match_label): Detect duplicate labels.
1228 2005-06-20 Erik Edelmann <erik.edelmann@iki.fi>
1230 * intrinsic.c (check_intrinsic_standard): Fix spelling error
1231 in a warning message.
1233 2005-06-18 Erik Edelman <eedelman@acclab.helsinki.fi>
1234 Steven G. Kargl <kargls@comast.net>
1237 * primary.c (gfc_match_rvalue): expr_type can be EXPR_CONSTANT
1238 for an array; check that sym->as is NULL.
1241 2005-06-18 Steven G. Kargl <kargls@comcast.net>
1243 * intrinsic.c (gfc_intrinsic_func_interface): Enable errors for generic
1244 functions whose simplification routine return FAILURE.
1246 2005-06-13 Geoffrey Keating <geoffk@apple.com>
1248 * Make-lang.in (fortran.install-man): Doesn't depend on installdirs.
1249 (rule for installing f95.1 manpage): Does depend on installdirs.
1251 2005-06-13 Jakub Jelinek <jakub@redhat.com>
1254 * trans-stmt.c (gfc_trans_forall_loop): Only increment maskindex
1255 in the innermost loop.
1257 * trans-expr.c (gfc_conv_function_call): Return int instead of
1258 void. Use a local variable for has_alternate_specifier and
1259 return it. Avoid modification of function type's return value
1260 in place, since it may be shared.
1261 * trans.h (has_alternate_specifier): Remove.
1262 (gfc_conv_function_call): Change return type.
1263 * trans-stmt.c (has_alternate_specifier): Remove.
1264 (gfc_trans_call): Add a local has_alternate_specifier variable,
1265 set it from gfc_conv_function_call return value.
1267 2005-06-12 Richard Henderson <rth@redhat.com>
1269 * trans-array.c (gfc_conv_descriptor_data_get): Rename from
1270 gfc_conv_descriptor_data. Cast the result to the DATAPTR type.
1271 (gfc_conv_descriptor_data_set, gfc_conv_descriptor_data_addr): New.
1272 (gfc_trans_allocate_array_storage): Use them.
1273 (gfc_array_allocate, gfc_array_deallocate): Likewise.
1274 (gfc_trans_dummy_array_bias, gfc_conv_expr_descriptor): Likewise.
1275 (gfc_trans_deferred_array): Likewise.
1276 * trans-expr.c (gfc_conv_function_call): Likewise.
1277 (gfc_trans_subcomponent_assign): Likewise.
1278 (gfc_trans_pointer_assignment): Likewise.
1279 * trans-intrinsic.c (gfc_conv_allocated): Likewise.
1280 * trans-types.c (gfc_array_descriptor_base): New.
1281 (gfc_get_element_type): Use GFC_TYPE_ARRAY_DATAPTR_TYPE.
1282 (gfc_get_array_descriptor_base): Break out from ...
1283 (gfc_get_array_type_bounds): ... here. Create type variants.
1284 * trans-array.h (gfc_conv_descriptor_data_get): Declare.
1285 (gfc_conv_descriptor_data_set, gfc_conv_descriptor_data_addr): Declare.
1287 2005-06-12 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1289 * trans-expr.c (gfc_conv_variable): POINTER results don't need f2c
1290 calling conventions. Look at sym instead of sym->result.
1291 * trans-types.c (gfc_sym_type): Remove workaround for frontend bug.
1292 Remove condition which is always false with workaround removed.
1293 (gfc_return_by_reference): Always look at sym, never at sym->result.
1295 2005-06-11 Steven G. Kargl <kargls@comcast.net>
1299 * trans-array.c (gfc_array_deallocate): pstat is new argument
1300 (gfc_array_allocate): update gfc_array_deallocate() call.
1301 (gfc_trans_deferred_array): ditto.
1302 * trans-array.h: update gfc_array_deallocate() prototype.
1303 * trans-decl.c (gfc_build_builtin_function_decls): update declaration
1304 * trans-stmt.c (gfc_trans_deallocate): Implement STAT= feature.
1306 2005-06-07 Jerry DeLisle <jvdelisle@verizon.net>
1308 * intrinsic.texi: Add documentation for dcmplx, digits,
1309 dim, idim, ddim, dot_product, dprod, dreal, and dtime.
1311 2005-06-05 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1314 * trans-array.c (gfc_trans_array_constructor_value): Slightly reorder.
1315 Generate correct exit condition in case of negative steps in
1318 * invoke.texi: Fix description of flags required for compatibility
1321 2005-06-04 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1322 Erik Schnetter <schnetter@aei.mpg.de>
1325 * trans.c (gfc_get_backend_locus): Remove unnecessary adjustment,
1326 remove FIXME comment.
1328 2005-06-04 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1330 * match.c (match_forall_iterator): Don't immediately give error if '='
1331 is not followed by an expression.
1333 2005-06-04 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1334 Erik Edelmann <erik.edelmann@iki.fi>
1336 * array.c (gfc_match_array_constructor): Disallow empty array
1339 2005-06-03 Jerry DeLisle <jvdelisle@verizon.net>
1341 * fortran/intrinsic.texi: Add documentation for
1342 command_argument_count, conjg, dconjg, count,
1343 cpu_time, cshift, date_and_time, dble, dfloat.
1345 2005-06-01 Roger Sayle <roger@eyesopen.com>
1347 * intrinsic.c (add_conv): No longer take a "simplify" argument as
1348 its always gfc_convert_constant, instead take a "standard" argument.
1349 (add_conversions): Change all existing calls of add_conv to pass
1350 GFC_STD_F77 as appropriate. Additionally, if we're allowing GNU
1351 extensions support integer-logical and logical-integer conversions.
1352 (gfc_convert_type_warn): Warn about use the use of these conversions
1353 as a extension when appropriate, i.e. with -pedantic.
1354 * simplify.c (gfc_convert_constant): Add support for integer to
1355 logical and logical to integer conversions, using gfc_int2log and
1357 * arith.c (gfc_log2int, gfc_int2log): New functions.
1358 * arith.h (gfc_log2int, gfc_int2log): Prototype here.
1359 * gfortran.texi: Document this new GNU extension.
1361 2005-06-01 Paul Thomas <pault@gcc.gnu.org>
1363 * fortran/trans-expr.c (gfc_conv_variable): Clean up bracketting.
1364 * fortran/trans-expr.c (gfc_conv_function_call): Insert spaces.
1365 Correct comments and replace convert of integer_one_node with
1368 2005-06-01 Jakub Jelinek <jakub@redhat.com>
1371 * resolve.c (resolve_contained_fntype): Use sym->attr.untyped
1372 to avoid giving error multiple times.
1373 (resolve_entries): Don't error about BT_UNKNOWN here.
1374 (resolve_unknown_f): Capitalize IMPLICIT for consistency.
1375 (resolve_fntype): New function.
1376 (gfc_resolve): Call resolve_fntype.
1378 2005-06-01 Feng Wang <fengwang@nudt.edu.cn>
1381 * fortran/io.c (resolve_tag): Fix error message.
1383 2005-05-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
1385 * fortran/trans-decl.c: Don't include errors.h.
1386 * fortran/Make-lang.in: Updates dependencies.
1388 2005-05-31 Paul Thomas <pault@gcc.gnu.org>
1393 * fortran/trans-array.c (gfc_conv_expr_descriptor): Obtain the
1394 string length from the expression typespec character length value
1395 and set temp_ss->stringlength and backend_decl. Obtain the
1396 tree expression from gfc_conv_expr rather than gfc_conv_expr_val.
1397 Dereference the expression to obtain the character.
1398 * fortran/trans-expr.c (gfc_conv_component_ref): Remove the
1399 dereference of scalar character pointer structure components.
1400 * fortran/trans-expr.c (gfc_trans_subarray_assign): Obtain the
1401 string length for the structure component from the component
1404 2005-05-30 Roger Sayle <roger@eyesopen.com>
1406 * gfortran.h (GFC_STD_LEGACY): New "standard" macro. Reindent.
1407 * options.c (gfc_init_options): By default, allow legacy extensions
1408 but warn about them.
1409 (gfc_post_options): Make -pedantic warn about legacy extensions
1410 even with -std=legacy.
1411 (gfc_handle_option): Make -std=gnu follow the default behaviour
1412 of warning about legacy extensions, but allowing them. Make the
1413 new -std=legacy accept everything and warn about nothing.
1414 * lang.opt (std=legacy): New F95 command line option.
1415 * invoke.texi: Document both -std=f2003 and -std=legacy.
1416 * gfortran.texi: Explain the two types of extensions and document
1417 how they are affected by the various -std= command line options.
1419 2005-05-30 Kazu Hirata <kazu@cs.umass.edu>
1421 * trans-expr.c: Remove trailing ^M.
1423 * trans-expr.c: Fix comment typos.
1425 2005-05-29 Paul Thomas <pault@gcc.gnu.org>
1433 * fortran/trans-array.c (gfc_conv_resolve_dependencies): Add string
1434 length to temp_ss for character pointer array assignments.
1435 * fortran/trans-expr.c (gfc_conv_variable): Correct errors in
1436 dereferencing of characters and character pointers.
1437 * fortran/trans-expr.c (gfc_conv_function_call): Provide string
1438 length as return argument for various kinds of handling of return.
1439 Return a char[]* temporary for character pointer functions and
1440 dereference the temporary upon return.
1442 2005-05-29 Janne Blomqvist <jblomqvi@vipunen.hut.fi>
1443 Steven G. Kargl <kargls@comcast.net>
1446 * io.c (gfc_match_inquire): Implement constraints on UNIT and FILE usage.
1448 2005-05-29 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1451 * io.c (format_item_1): Add check and extension warning for
1454 2005-05-28 Steven G. Kargl <kargls@comcast.net>
1456 * arith.c (gfc_arith_init_1): Fix off by one problem;
1457 (gfc_check_integer_range): Chop extra bits in subnormal numbers.
1459 2005-05-28 Jerry DeLisle <jvdelisle@verizon.net>
1460 Steven G. Kargl <kargls@comcast.net>
1462 * intrinsic.texi: added documentation for BIT_SIZE, BTEST, CHAR, CEILING
1465 2005-05-27 Steven G. Kargl <kargls@comcast.net>
1467 * trans-array.c (gfc_trans_deferred_array): Use build_int_cst to force
1468 like types in comparsion.
1470 2005-05-26 Kazu Hirata <kazu@cs.umass.edu>
1472 * data.c, parse.c, trans-array.c, trans-decl.c,
1473 trans-intrinsic.c, trans-stmt.c, trans-types.c, trans.c,
1474 trans.h: Fix comment typos. Follow spelling conventions.
1476 2005-05-22 Roger Sayle <roger@eyesopen.com>
1478 * gfortran.texi: Document some more GNU extensions.
1480 2005-05-22 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1482 * error.c (gfc_warning): Fix typo in comment.
1484 2005-05-18 Thomas Koenig <Thomas.Koenig@online.de>
1487 * fortran/iresolve.c (gfc_resolve_reshape): Add
1488 gfc_type_letter (BT_COMPLEX) for complex to
1489 to resolved function name.
1491 2005-05-18 Erik Edelmann <erik.edelmann@iki.fi>
1493 * array.c (gfc_match_array_constructor): Support [ ... ]
1494 style array constructors.
1496 2005-05-18 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1498 * f95-lang.c (gfc_init_builtin_functions): Define BUILT_IN_TRUNC
1499 and BUILT_IN_TRUNCF instead of BUILT_IN_FLOOR and BUILT_IN_FLOORF.
1500 * trans-intrinsic.c (build_fix_expr): Change 'op' argument
1501 to correct enum type.
1502 (gfc_conv_intrinsic_aint): Likewise. Clarify comment in front of
1503 function. Add default case to switch, deal with FIX_TRUNC_EXPR
1504 instead of FIX_FLOOR_EXPR.
1506 2005-05-18 Feng Wang <fengwang@nudt.edu.cn>
1509 * trans-const.c (gfc_conv_const_charlen): Use gfc_charlen_type_node to
1510 build character length.
1512 2005-05-17 Zdenek Dvorak <dvorakz@suse.cz>
1514 * trans-types.c (gfc_array_range_type): New variable.
1515 (gfc_init_types): Initialize gfc_array_range_type.
1516 (gfc_get_array_type_bounds): Use gfc_array_range_type.
1518 2005-05-17 Jakub Jelinek <jakub@redhat.com>
1521 * trans-stmt.c (generate_loop_for_temp_to_lhs): Remove SIZE and COUNT2
1522 arguments. If LSS is gfc_ss_terminator, increment COUNT1 by 1, instead
1523 of incrementing COUNT2 and using COUNT1+COUNT2 increment COUNT1 and use
1525 (generate_loop_for_rhs_to_temp): Likewise.
1526 (compute_overall_iter_number): Add INNER_SIZE_BODY argument.
1527 It non-NULL, add it to body.
1528 (allocate_temp_for_forall_nest_1): New function, split from
1529 allocate_temp_for_forall_nest.
1530 (allocate_temp_for_forall_nest): Add INNER_SIZE_BODY argument,
1531 propagate it down to compute_overall_iter_number. Use
1532 allocate_temp_for_forall_nest_1.
1533 (gfc_trans_assign_need_temp): Remove COUNT2. Call
1534 compute_inner_temp_size into a new stmtblock_t. Adjust calls to
1535 allocate_temp_for_forall_nest, generate_loop_for_rhs_to_temp
1536 and generate_loop_for_temp_to_lhs.
1537 (gfc_trans_pointer_assign_need_temp): Adjust calls to
1538 allocate_temp_for_forall_nest.
1539 (gfc_evaluate_where_mask): Call compute_inner_temp_size into a new
1540 stmtblock_t. Call compute_overall_iter_number just once, then
1541 allocate_temp_for_forall_nest_1 twice with the same size.
1542 Initialize mask indexes if nested_forall_info != NULL.
1543 (gfc_trans_where_2): Initialize mask indexes before calling
1544 gfc_trans_nested_forall_loop.
1546 2005-05-15 Feng Wang <fengwang@nudt.edu.cn>
1547 Jerry DeLisle <jvdelisle@verizon.net>
1550 * trans-stmt.c (gfc_trans_label_assign): fix pointer type, to
1551 resolve ICE on assign of format label.
1552 * trans-io.c (set_string): add fold-convert to properly
1553 handle assigned format label in write.
1555 2005-05-13 Paul Brook <paul@codesourcery.com>
1557 * trans-stmt.c (gfc_trans_forall_1): Fix comment typo.
1559 2005-05-12 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1561 * trans-types.c (gfc_is_nodesc_array): Remove redundant check.
1563 2005-05-11 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1566 * io.c (check_format): Look for literal characters inside
1569 2005-05-11 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1571 * resolve.c (resolve_symbol): Copy 'pointer' and 'dimension'
1572 attribute from result symbol to function symbol.
1573 * trans-expr.c (gfc_conv_function_call): Look at sym->attr.dimension
1574 instead of sym->result->attr.dimension.
1576 2005-05-10 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1579 * gfortran.h (gfc_option): Add flag_f2c.
1580 * invoke.texi: Document '-ff2c' command line option. Adapt
1581 documentation for '-fno-second-underscore' and '-fno-underscoring'.
1582 * lang.opt (ff2c): New entry.
1583 * options.c (gfc-init_options): Set default calling convention
1584 to -fno-f2c. Mark -fsecond-underscore unset.
1585 (gfc_post_options): Set -fsecond-underscore if not explicitly set
1587 (handle_options): Set gfc_option.flag_f2c according to requested
1589 * trans-decl.c (gfc_get_extern_function_decl): Use special f2c
1590 intrinsics where necessary.
1591 (gfc_trans_deferred_vars): Change todo error to assertion.
1592 * trans-expr.c (gfc_conv_variable): Dereference access
1593 to hidden result argument.
1594 (gfc_conv_function_call): Add hidden result argument to argument
1595 list if f2c calling conventions requested. Slightly restructure
1596 tests. Convert result of default REAL function to requested type
1597 if f2c calling conventions are used. Dereference COMPLEX result
1599 * trans-types.c (gfc_sym_type): Return double for default REAL
1600 function if f2c cc are used.
1601 (gfc_return_by_reference): Slightly restructure logic. Return
1602 COMPLEX by reference depending on calling conventions.
1603 (gfc_get_function_type): Correctly make hidden result argument a
1604 pass-by-reference argument for COMPLEX. Remove old code which does
1605 this for derived types.
1607 2005-05-09 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1609 * match.c (gfc_match_return): Only require space after keyword when
1610 it is obligatory. Only give stdwarn to after matching is successful.
1611 * dump-parse-tree.c (gfc_show_symbol): Deal with alternate returns.
1613 2005-05-08 Kazu Hirata <kazu@cs.umass.edu>
1615 * intrinsic.texi: Fix typos.
1617 2005-05-07 Steven G. Kargl <kargls@comcast.net>
1619 * intrinsic.texi: Document ASSOCIATED and ATAN2. Update Bessel function
1620 description to include information about scalar arguments.
1622 2005-05-03 Kazu Hirata <kazu@cs.umass.edu>
1624 * Make-lang.in, dump-parse-tree.c, invoke.texi, lang.opt,
1625 match.h, trans-array.h: Update copyright.
1627 2005-04-29 Tom Tromey <tromey@redhat.com>
1629 * f95-lang.c (poplevel): Updated for change to build_block.
1631 2005-04-29 Jakub Jelinek <jakub@redhat.com>
1635 * trans-expr.c (gfc_conv_variable): Handle return values in functions
1636 with alternate entry points.
1637 * resolve.c (resolve_entries): Remove unnecessary string termination
1638 after snprintf. Set result of entry master.
1639 If all entries have the same type, set entry master's type
1640 to that common type, otherwise set mixed_entry_master attribute.
1641 * trans-types.c (gfc_get_mixed_entry_union): New function.
1642 (gfc_get_function_type): Use it for mixed_entry_master functions.
1643 * gfortran.h (symbol_attribute): Add mixed_entry_master bit.
1644 * decl.c (gfc_match_entry): Set entry->result properly for
1646 * trans-decl.c (gfc_get_symbol_decl): For entry_master, skip over
1648 (build_entry_thunks): Handle return values in entry thunks.
1649 Clear BT_CHARACTER's ts.cl->backend_decl, so that it is not
1650 shared between multiple contexts.
1651 (gfc_get_fake_result_decl): Use DECL_ARGUMENTS from
1652 current_function_decl instead of sym->backend_decl. Skip over
1653 entry master's entry id argument. For mixed_entry_master entries or
1654 their results, return a COMPONENT_REF of the fake result.
1655 (gfc_trans_deferred_vars): Don't warn about missing return value if
1656 at least one entry point uses RESULT.
1657 (gfc_generate_function_code): For entry master returning
1658 CHARACTER, copy ts.cl->backend_decl to all entry result syms.
1659 * trans-array.c (gfc_trans_dummy_array_bias): Don't consider return
1660 values optional just because they are in entry master.
1662 2005-04-29 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1664 * gfortran.h (gfc_namespace): Add seen_implicit_none field,
1665 Tobias forgot this in previous commit.
1667 2005-04-29 Paul Brook <paul@codesourcery.com>
1669 * trans-expr.c (gfc_conv_expr_present): Fix broken assert. Update
1672 2005-04-29 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1674 * gfortran.h (gfc_namespace): Add seen_implicit_none field.
1675 * symbol.c (gfc_set_implicit_none): Give error if there's a previous
1676 IMPLICIT NONE, set seen_implicit_none.
1677 (gfc_merge_new_implicit): Error if there's an IMPLICIT NONE statement.
1679 2005-04-28 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1681 * gfortran.h (gfc_gsymbol): Make name a const char *.
1682 * symbol.c (gfc_get_gsymbol): Allocate gsymbol name via
1685 2005-04-28 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1688 * resolve.c (resolve_actual_arglist): Issue an error if a statement
1689 functions is used as actual argument.
1691 2005-04-27 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1694 * interface.c (compare_parameter): Ignore type for EXPR_NULL
1695 only if type is BT_UNKNOWN.
1697 2005-04-25 Paul Brook <paul@codesourcery.com>
1698 Steven G. Kargl <kargls@comcast.net>
1701 * check.c (gfc_check_ichar_iachar): New function.
1702 * instinsic.h (gfc_check_ichar_iachar): Add prototype.
1703 * intrinsic.c (add_functions): Use it.
1704 * primary.c (match_varspec, gfc_match_rvalue): Clear incorrect
1705 character expression lengths.
1707 2005-04-24 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1710 * trans-common.c (translate_common): Cast offset and
1711 common_segment->offset to type int for warning message.
1713 2005-04-23 DJ Delorie <dj@redhat.com>
1715 * trans-decl.c: Adjust warning() callers.
1717 2005-04-23 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1719 * trans-const.c (gfc_conv_mpfr_to_tree): Use hexadecimal string as
1720 intermediate representation. Fix typo in comment.
1722 2005-04-21 Steven G. Kargl <kargls@comcast.net>
1724 * trans-const.c (gfc_conv_mpfr_to_tree): Remove unneeded computation;
1725 simplify logic; Add a gcc_assert.
1727 2005-04-19 Steven G. Kargl <kargls@comcast.net>
1729 * trans-const.c (gfc_conv_mpz_to_tree): Fix comment.
1731 2005-04-19 Arnaud Desitter <arnaud.desitter@ouce.ox.ac.uk>
1732 Steven G. Kargl <kargls@comcast.net>
1734 * invoke.texi: Update -Waliasing description
1736 2005-04-19 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1739 * resolve.c (resolve_variable): If e->symtree is not set, this
1740 ought to be a FAILURE, and not a segfault.
1742 2005-04-17 Paul Thomas <pault@gcc.gnu.org>
1749 * fortran/trans-io.c (gfc_build_io_library_fndecls): Create
1750 declaration for st_set_nml_var and st_set_nml_var_dim. Remove
1751 declarations of old namelist functions.
1752 (build_dt): Simplified call to transfer_namelist_element.
1753 (nml_get_addr_expr): Generates address expression for start of
1754 object data. New function.
1755 (nml_full_name): Qualified name for derived type components. New
1757 (transfer_namelist_element): Modified for calls to new functions
1758 and improved derived type handling.
1760 2005-04-17 Richard Guenther <rguenth@gcc.gnu.org>
1762 * scanner.c (gfc_next_char_literal): Reset truncation flag
1763 for lines ending in a comment for both fixed and free form.
1764 (load_line): Do not set truncated flag if only truncating
1767 2005-04-15 Richard Guenther <rguenth@gcc.gnu.org>
1770 * gfortran.h (gfc_linebuf): Add truncated field.
1771 * parse.c (next_statement): Handle warning for truncated
1773 * scanner.c (load_line): Return if line was truncated.
1774 No longer warn for truncated lines. Remove unused parameters.
1775 (load_file): Store load_line return value to linebuf.
1776 (gfc_error_recovery): Do not advance line at the end.
1778 2005-04-14 Steven G. Kargl <kargls@comcast.net>
1780 * gfortran.h (gfc_real_info): Add subnormal struct member.
1781 * arith.c (gfc_arith_init_1): Set it.
1782 (gfc_check_real_range): Use it.
1783 * simplify.c (gfc_simplify_nearest): Fix nearest(0.,1.).
1785 2005-04-12 Kazu Hirata <kazu@cs.umass.edu>
1787 * simplify.c: Fix a comment typo.
1789 2005-04-11 Richard Sandiford <rsandifo@redhat.com>
1791 * lang.opt: Refer to the GCC internals documentation instead of c.opt.
1793 2005-04-11 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1795 * simplify.c (gfc_simplify_nearest): Overhaul.
1797 2005-04-10 Kazu Hirata <kazu@cs.umass.edu>
1799 * interface.c: Fix a comment typo.
1801 2005-04-10 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1803 * match.c (match_arithmetic_if): Arithmetic IF is obsolete in
1806 2005-04-09 Steven G. Kargl <kargls@comcast.net>
1808 * simplify.c (gfc_simplify_anint): Use mpfr_round()
1809 (gfc_simplify_dnint): ditto.
1810 (gfc_simplify_nint): ditto.
1812 2005-04-09 Andrew Pinski <pinskia@physics.uc.edu>
1815 * io.c (check_format): Allow an optional comma
1816 between descriptors.
1818 2005-04-09 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1820 * match.c (match_arithmetic_if): Remove gfc_ prefix and correct
1821 comment according to GNU coding style.
1822 (gfc_match_if): Remove gfc_ prefix in call to
1823 match_arithmetic_if.
1825 2005-04-08 Diego Novillo <dnovillo@redhat.com>
1827 * match.c (gfc_match_arithmetic_if): Declare static.
1829 2005-04-08 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1832 * match.c (gfc_match_arithmetic_if): New function to match an
1833 arithmetic IF statement.
1834 (gfc_match_if): Use gfc_match_arithmetic_if to match an
1835 arithmetic IF statement embedded in a simple IF statement.
1837 2005-04-07 Steven G. Kargl <kargls@comcast.net>
1839 * simplify.c (gfc_simplify_exponent): Fix exponent(tiny(x))
1841 2005-04-06 Steven G. Kargl <kargls@comcast.net>
1843 * invoke.texi: Remove documentation of -std=f90
1845 2005-04-06 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1847 * expr.c (gfc_check_assign): Don't allow NULL as rhs in a
1848 non-pointer assignment.
1850 2005-04-05 Feng Wang <fengwang@nudt.edu.cn>
1855 * array.c (resolve_character_array_constructor): New function. Set
1856 constant character array's character length.
1857 (gfc_resolve_array_constructor): Use it.
1858 * decl.c (add_init_expr_to_sym): Set symbol and initializer character
1860 (gfc_set_constant_character_len): New function. Set constant character
1861 expression according the given length.
1862 * match.h (gfc_set_constant_character_len): Add prototype.
1864 2005-04-04 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1866 * intrinsic.texi: BES?? functions are not in the f95 standard.
1868 2005-04-03 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1870 * intrinsic.texi: Document COS, EXP, LOG, LOG10, SIN, SQRT, TAN.
1872 2005-04-03 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1874 * intrinsic.texi: Document BESJ0, BESJ1, BESJN, BESY0, BESY1,
1875 BESYN, ATAN, COSH, ERF, ERC, SINH, TANH.
1877 2005-04-02 Steven G. Kargl <kargls@comcast.net>
1879 * intrinsic.texi: Document ALLOCATED, ANINT, ANY, ASIN; fix typos
1881 2005-04-01 Kazu Hirata <kazu@cs.umass.edu>
1883 * decl.c, f95-lang.c, interface.c, module.c, trans-stmt.c,
1884 trans.h: Fix comment typos.
1886 2005-03-29 Steven G. Kargl <kargls@comcast.net>
1888 * gfortran.h (option_t): Change d8, i8, r8 to flag_default_double,
1889 flag_default_integer, flag_default_real
1890 * invoke.texi: Update documentation
1891 * lang.opt: Remove d8, i8, r8 definitions; Add fdefault-double-8
1892 fdefault-integer-8, and fdefault-real-8 definitions.
1893 * options.c (gfc_init_options): Set option defaults
1894 (gfc_handle_option): Handle command line options.
1895 * trans-types.c (gfc_init_kinds): Use options.
1897 2005-03-29 Keith Besaw <kbesaw@us.ibm.com>
1899 * f95-lang.c (builtin_function): Process the attrs parameter
1900 and apply the "const" attribute to the builtin if found.
1902 2005-03-27 Steven G. Kargl <kargls@comcast.net>
1904 * intrinsic.texi: Document AIMAG, AINT, ALL
1906 2005-03-26 Steven G. Kargl <kargls@comcast.net>
1908 * arith.c (check_result): Fix illogical logic.
1910 2005-03-26 Canqun Yang <canqun@nudt.edu.cn>
1912 * trans-common.c (create_common): Build RECORD_NODE for common blocks
1913 contain no equivalence objects.
1914 (add_equivalences): New argument saw_equiv.
1915 (trans_common): New local variable saw_equiv.
1916 (finish_equivalences): Add a local variable dummy, Always pass true
1917 for the 3rd parameter to create_common.
1919 2005-03-25 Steven G. Kargl <kargls@comcast.net>
1921 * intrinsic.texi: Fix "make dvi"
1923 2005-03-24 Steven G. Kargl <kargls@comcast.net>
1925 * intrinsic.texi: New file.
1926 * gfortran.texi: Include it; white space change; fix typo.
1928 2005-03-23 Joseph S. Myers <joseph@codesourcery.com>
1930 * f95-lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Remove.
1932 2005-03-23 Steven Bosscher <stevenb@suse.de>
1934 * convert.c (convert): Replace fold (buildN (...)) with fold_buildN.
1935 * trans-array.c (gfc_trans_allocate_array_storage,
1936 gfc_trans_allocate_temp_array gfc_trans_array_constructor_value,
1937 gfc_conv_array_index_ref, gfc_trans_array_bound_check,
1938 gfc_conv_array_index_offset, gfc_conv_scalarized_array_ref,
1939 gfc_conv_array_ref, gfc_trans_preloop_setup, gfc_conv_ss_startstride,
1940 gfc_conv_loop_setup, gfc_array_init_size, gfc_trans_array_bounds,
1941 gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias,
1942 gfc_conv_expr_descriptor): Likewise.
1943 * trans-expr.c (gfc_conv_powi, gfc_conv_string_tmp,
1944 gfc_conv_concat_op, gfc_conv_expr_op): Likewise.
1945 * trans-intrinsic.c (build_round_expr, gfc_conv_intrinsic_bound,
1946 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_sign,
1947 gfc_conv_intrinsic_minmaxloc, gfc_conv_intrinsic_minmaxval,
1948 gfc_conv_intrinsic_btest, gfc_conv_intrinsic_bitop,
1949 gfc_conv_intrinsic_singlebitop, gfc_conv_intrinsic_ibits,
1950 gfc_conv_intrinsic_ishft, gfc_conv_intrinsic_ishftc,
1951 gfc_conv_intrinsic_merge, prepare_arg_info,
1952 gfc_conv_intrinsic_rrspacing, gfc_conv_intrinsic_repeat): Likewise.
1953 * trans-stmt.c (gfc_trans_simple_do, gfc_trans_do, gfc_trans_do_while,
1954 gfc_trans_forall_loop, gfc_do_allocate, generate_loop_for_temp_to_lhs,
1955 generate_loop_for_rhs_to_temp, compute_inner_temp_size,
1956 allocate_temp_for_forall_nest, gfc_trans_pointer_assign_need_temp,
1957 gfc_trans_forall_1, gfc_evaluate_where_mask, gfc_trans_where_assign):
1959 * trans-types.c (gfc_get_dtype, gfc_get_array_type_bounds): Likewise.
1960 * trans.c (gfc_add_modify_expr): Likewise.
1962 2005-03-22 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1964 * check.c (gfc_check_chdir, gfc_check_chdir_sub, gfc_check_kill,
1965 gfc_check_kill_sub, gfc_check_link, gfc_check_link_sub,
1966 gfc_check_symlnk, gfc_check_symlnk_sub, gfc_check_rename,
1967 gfc_check_rename_sub, gfc_check_sleep_sub, gfc_check_gerror,
1968 gfc_check_getlog, gfc_check_hostnm, gfc_check_hostnm_sub,
1969 gfc_check_perror): new functions to check newly implemented
1971 * gfortran.h: adding symbols for new intrinsics.
1972 * intrinsic.c (add_functions): adding new intrinsics.
1973 (add_subroutines): adding new intrinsics.
1974 * intrinsic.h: prototype for all checking and resolving
1976 * iresolve.c (gfc_resolve_chdir, gfc_resolve_chdir_sub,
1977 gfc_resolve_hostnm, gfc_resolve_ierrno, gfc_resolve_kill,
1978 gfc_resolve_link, gfc_resolve_rename, gfc_resolve_symlnk,
1979 gfc_resolve_time, gfc_resolve_time8, gfc_resolve_rename_sub,
1980 gfc_resolve_kill_sub, gfc_resolve_link_sub,
1981 gfc_resolve_symlnk_sub, gfc_resolve_sleep_sub,
1982 gfc_resolve_gerror, gfc_resolve_getlog, gfc_resolve_hostnm_sub,
1983 gfc_resolve_perror): new functions to resolve intrinsics.
1984 * trans-intrinsic.c (gfc_conv_intrinsic_function): add case
1987 2005-03-19 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1989 * dump-parse-tree.c (gfc_show_expr): Dump name of namespace
1990 in which the variable is declared.
1993 * resolve.c (was_declared): Also check for dummy attribute.
1995 2005-03-19 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
1997 * gfortran.h (arith): Remove ARITH_0TO0.
1998 * arith.c (gfc_arith_error): Remove handling of ARITH_0TO0.
1999 (gfc_arith_power): Remove special casing of zero to integral
2002 2005-03-18 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2004 * Make-lang.in (fortran-warn): Remove -Wno-error.
2005 (expr.o-warn, resolve.o-warn, simplify.o-warn,
2006 trans-common.o-warn): Specify -Wno-error.
2008 2005-03-17 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2010 * trans-array.c (gfc_trans_static_array_pointer,
2011 get_array_ctor_var_strlen, gfc_conv_array_index_offset): Fix
2012 comment and formatting typos.
2014 2005-03-17 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2016 * invoke.texi: Fix typos.
2018 2005-03-15 Zack Weinberg <zack@codesourcery.com>
2020 * Make-lang.in (GFORTRAN_TEXI): Add gcc-vers.texi.
2022 2005-03-15 Feng Wang <fengwang@nudt.edu.cn>
2024 * trans-stmt.c (gfc_trans_label_assign): Don't set DECL_ARTIFICIAL flag
2025 to zero on label_tree.
2027 2005-03-15 Feng Wang <fengwang@nudt.edu.cn>
2030 * io.c (resolve_tag): Add checking on assigned label.
2031 (match_dt_format): Does not set symbol assign attribute.
2032 * match.c (gfc_match_goto):Does not set symbol assign attribute.
2033 * resolve.c (resolve_code): Add checking on assigned label.
2034 * trans-common.c (build_field): Deals with common variable assigned
2036 * trans-stmt.c (gfc_conv_label_variable): New function.
2037 (gfc_trans_label_assign): Use it.
2038 (gfc_trans_goto): Ditto.
2039 * trans-io.c (set_string): Ditto.
2040 * trans.h (gfc_conv_label_variable): Add prototype.
2042 2005-03-14 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2045 * symbol.c (check_conflict): A dummy argument can't be a statement
2048 2005-03-14 Zdenek Dvorak <dvorakz@suse.cz>
2050 * fortran/trans-intrinsic.c (gfc_conv_intrinsic_ishft): Convert
2051 the argument of the shift to the unsigned type.
2053 2005-03-13 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2056 * resolve.c (gfc_resolve_index): Allow REAL indices as an extension.
2058 2005-03-13 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2061 * resolve.c (gfc_resolve): Check if character lengths are
2062 specification expressions.
2064 2005-03-12 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2067 * trans-array.c (gfc_stack_space_left): Remove unused variable.
2068 (gfc_can_put_var_on_stack): Move to trans-decl.c, remove #if 0'ed
2070 * trans-array.h (gfc_stack_space_left, gfc_can_put_var_on_stack):
2071 Remove declaration / prototype.
2072 * trans-common.c (build_equiv_decl): Give union a name. Check if
2073 it can be put on the stack.
2074 * trans-decl.c (gfc_stack_space_left): Move function here.
2075 (gfc_build_qualified_array): Fix comment typo.
2076 * trans.h (gfc_put_var_on_stack): Add prototype.
2078 2005-03-11 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
2080 * Make-lang.in (fortran-warn): Set to $(STRICT_WARN) -Wno-error.
2081 * decl.c, trans.c: Don't use C++ style comments.
2082 * gfortran.h (sym_flavor, procedure_type, sym_intent, gfc_access,
2083 ifsrc): Give names to enums and use ENUM_BITFIELD.
2084 (gfc_access): Remove trailing comma.
2086 2005-03-05 Steven G. Kargl <kargls@comcast.net>
2089 * primary.c (match_complex_constant): Mangled complex constant may
2090 be an implied do-loop. Give implied do-loop matcher a chance.
2092 2005-03-05 Steven G. Kargl <kargls@comcast.net>
2095 * resolve.c (compare_shapes): New function.
2096 (resolve_operator): Use it.
2098 2005-03-05 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2100 * trans-const.c (gfc_conv_constant_to_tree): Use correct tree
2101 type for COMPLEX constants.
2103 2005-03-04 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2106 * trans-expr.c (gfc_conv_function_call): Correctly dereference
2107 argument from a pointer function also if it has a result clause.
2109 2005-03-04 Steven G. Kargl <kargls@comcast.net>
2111 * expr.c (gfc_copy_shape_excluding): Change && to ||.
2113 2005-03-04 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2115 * trans-intrinsic.c (gfc_get_symbol_for_expr): Fix comment typo,
2118 2005-02-28 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2122 * simplify.c (gfc_simplify_bound): Rename to ...
2123 (simplify_bound): ... this and overhaul.
2125 2005-02-28 Steven G. Kargl <kargl@gcc.gnu.org>
2127 * trans-intrinsic.c (gfc_conv_intrinsic_iargc): remove boolean argument.
2128 (gfc_conv_intrinsic_function): update function calls
2130 2005-02-27 Steven G. Kargl <kargl@gcc.gnu.org>
2133 * trans-types.c (gfc_max_integer_kind): Declare
2134 (gfc_init_kinds): Initialize it.
2135 * gfortran.h (gfc_max_integer_kind): extern it.
2136 * primary.c (match_boz_constant): Use it; remove gfortran extension
2137 of kind suffixes on BOZ literal constants
2140 2005-02-27 Steven G. Kargl <kargls@comcast.net>
2142 * arith.c (gfc_check_real_range): Remove multiple returns
2143 (check_result): New function.
2144 (gfc_arith_uminus,gfc_arith_plus,gfc_arith_times,
2145 gfc_arith_divide,gfc_arith_power,gfc_arith_minus): Use it.
2148 2005-02-24 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
2150 * decl.c, resolve.c, trans-array.c, trans.h: Fix comment typo(s).
2153 2005-02-24 Tobias Schl"uter <tobias.schlueter@physik.uni-meunchen.de>
2155 Unrevert previously reverted patch. Adding this fix:
2156 * module.c (find_true_name): Deal with NULL module.
2158 2005-02-24 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2160 Revert yesterday's patch:
2161 2005-02-23 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2163 * gfortran.h (gfc_component, gfc_actual_arglist, ...
2164 ... argument. Copy string instead of pointing to it.
2166 2005-02-23 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2168 * gfortran.h (gfc_get_namespace): Add second argument to prototype.
2169 * intrinsic.c (gfc_intrinsic_init_1): Pass second argument to
2171 * module.c (mio_namespace_ref, load_needed): Likewise.
2172 * parse.c (parse_interface, parse_contained): Likewise. Here the
2173 correct second argument matters.
2174 * symbol.c (gfc_get_namespace): Add parent_types argument, only copy
2175 parent's implicit types if this is set.
2176 (gfc_symbol_init_2): Pass second argument to gfc_get_namespace.
2177 * trans-common.c (build_common_decl): Likewise.
2179 * gfortran.h (symbol_attribute): New 'untyped' field, fix comment
2181 * symbol.c (gfc_set_default_type): Issue error only once, by setting
2182 and checking 'untyped' attribute.
2184 * gfortran.h (gfc_expr): Move 'operator', 'op1', 'op2', and 'uop'
2185 fields into new struct 'op' inside the 'value' union.
2186 * arith.c (eval_intrinsic): Adapt all users.
2187 * dependency.c (gfc_check_dependency): Likewise.
2188 * dump-parse-tree.c (gfc_show_expr): Likewise.
2189 * expr.c (gfc_get_expr): Don't clear removed fields.
2190 (free_expr0, gfc_copy_expr, gfc_type_convert_binary,
2191 gfc_is_constant_expr, simplify_intrinsic_op, check_init_expr,
2192 check_intrinsic_op): Adapt to new field names.
2193 * interface.c (gfc_extend_expr): Likewise. Also explicitly
2194 nullify 'esym' and 'isym' fields of new function call.
2195 * iresolve.c (gfc_resolve_dot_product, gfc_resolve_matmul):
2196 Adapt to renamed structure fields.
2197 * matchexp.c (build_node, match_level_1, match_expr): Likewise.
2198 * module.c (mio_expr): Likewise.
2199 * resolve.c (resolve_operator): Likewise.
2200 (gfc_find_forall_index): Likewise. Only look through operands
2201 if dealing with EXPR_OP
2202 * trans-array.c (gfc_walk_op_expr): Adapt to renamed fields.
2203 * trans-expr.c (gfc_conv_unary_op, gfc_conv_power_op,
2204 gfc_conv_concat_op, gfc_conv_expr_op): Likewise.
2207 * gfortran.h (gfc_component, gfc_actual_arglist, gfc_user_op): Make
2208 'name' a 'const char *'.
2209 (gfc_symbol): Likewise, also for 'module'.
2210 (gfc_symtree): Make 'name' a 'const char *'.
2211 (gfc_intrinsic_sym): Likewise, also for 'lib_name'.
2212 (gfc_get_gsymbol, gfc_find_gsymbol): Add 'const' qualifier to
2214 (gfc_intrinsic_symbol): Use 'gfc_get_string' instead of 'strcpy' to
2215 initialize 'SYM->module'.
2216 * check.c (gfc_check_minloc_maxloc, check_reduction): Check for NULL
2217 pointer instead of empty string.
2218 * dump-parse-tree.c (gfc_show_actual_arglist): Likewise.
2219 * interface.c (gfc_compare_types): Adapt check to account for possible
2221 (compare_actual_formal): Check for NULL pointer instead of empty
2223 * intrinsic.c (gfc_current_intrinsic, gfc_current_intrinsic_arg):
2224 Add 'const' qualifier.
2225 (conv_name): Return a heap allocated string.
2226 (find_conv): Add 'const' qualifier to 'target'.
2227 (add_sym): Use 'gfc_get_string' instead of 'strcpy'.
2228 (make_generic): Check for NULL pointer instead of empty string.
2229 (make_alias): Use 'gfc_get_string' instead of 'strcpy'.
2230 (add_conv): No need to strcpy result from 'conv_name'.
2231 (sort_actual): Check for NULL pointer instead of empty string.
2232 * intrinsic.h (gfc_current_intrinsic, gfc_current_intrinsic_arg):
2234 * module.c (compare_true_names): Compare pointers instead of strings
2235 for 'module' member.
2236 (find_true_name): Initialize string fields with gfc_get_string.
2237 (mio_pool_string): New function.
2238 (mio_internal_string): Adapt comment.
2239 (mio_component_ref, mio_component, mio_actual_arg): Use
2240 'mio_pool_string' instead of 'mio_internal_string'.
2241 (mio_symbol_interface): Add 'const' qualifier to string arguments.
2242 Add level of indirection. Use 'mio_pool_string' instead of
2243 'mio_internal_string'.
2244 (load_needed, read_module): Use 'gfc_get_string' instead of 'strcpy'.
2245 (write_common, write_symbol): Use 'mio_pool_string' instead of
2246 'mio_internal_string'.
2247 (write_symbol0, write_symbol1): Likewise, also check for NULL pointer
2248 instead of empty string.
2249 (write_operator, write_generic): Pass correct type variable to
2250 'mio_symbol_interface'.
2251 (write_symtree): Use 'mio_pool_string' instead of
2252 'mio_internal_string'.
2253 * primary.c (match_keyword_arg): Adapt check to possible
2254 case of NULL pointer. Use 'gfc_get_string' instead of 'strcpy'.
2255 * symbol.c (gfc_add_component, gfc_new_symtree, delete_symtree,
2256 gfc_get_uop, gfc_new_symbol): Use 'gfc_get_string' instead of
2258 (ambiguous_symbol): Check for NULL pointer instead of empty string.
2259 (gfc_find_gsymbol, gfc_get_gsymbol): Add 'const' qualifier on string
2261 * trans-array.c (gfc_trans_auto_array_allocation): Check for NULL
2262 pointer instead of empty string.
2263 * trans-decl.c (gfc_sym_mangled_identifier,
2264 gfc_sym_mangled_function_id, gfc_finish_var_decl, gfc_get_symbol_decl,
2265 gfc_get_symbol_decl): Likewise.
2266 * trans-io.c (gfc_new_nml_name_expr): Add 'const' qualifier to
2267 argument. Copy string instead of pointing to it.
2269 2005-02-23 Kazu Hirata <kazu@cs.umass.edu>
2271 * intrinsic.h, st.c: Update copyright.
2273 2005-02-20 Steven G. Kargl <kargls@comcast.net>
2275 * symbol.c: Typos in comments.
2277 2005-02-20 Steven G. Kargl <kargls@comcast.net>
2279 * expr.c (gfc_type_convert_binary): Typo in comment.
2281 2005-02-19 Steven G. Kargl <kargls@comcast.net>
2283 * check.c (gfc_check_selected_int_kind): New function.
2284 * intrinsic.h: Prototype it.
2285 * intrinsic.c (add_function): Use it.
2286 * simplify (gfc_simplify_ceiling,gfc_simplify_floor): Change
2287 BT_REAL to BT_INTEGER and use gfc_default_integer_kind.
2289 2005-02-19 Steven G. Kargl <kargls@comcast.net>
2291 * check.c (gfc_check_int): improve checking of optional kind
2292 * simplify.c (gfc_simplify_int): Change BT_REAL to BT_INTEGER
2294 2005-02-19 Steven G. Kargl <kargls@comcast.net>
2296 * check.c (gfc_check_achar): New function
2297 * intrinsic.h: Prototype it.
2298 * intrinsic.c (add_function): Use it.
2300 2005-02-13 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2302 * trans-stmt.c (generate_loop_for_temp_to_lhs,
2303 generate_loop_for_rhs_to_temp): Remove if whose condition is
2306 2005-02-12 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2308 * symbol.c (gfc_use_ha_derived): Remove, fold functionality into ...
2309 (gfc_use_derived): ... this function.
2311 2005-02-09 Richard Henderson <rth@redhat.com>
2313 * f95-lang.c (gfc_init_builtin_functions): Call
2314 build_common_builtin_nodes; do not define any functions handled
2317 2005-02-08 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2319 * expr.c (gfc_copy_expr): Don't copy 'op1' and 'op2' for
2321 (gfc_is_constant_expr): Check 'ref' to determine if substring
2322 reference is constant.
2323 (gfc_simplify_expr): Simplify 'ref' instead of 'op1' and 'op2'.
2324 (check_init_expr, check_restricted): Check 'ref' instead of 'op1'
2326 * module.c (mio_expr): Read / write 'ref' instead of 'op1' and 'op2'.
2328 2005-02-07 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2330 * gfortran.h (gfc_add_dimension, gfc_add_result, gfc_add_save,
2331 gfc_add_dummy, gfc_add_generic, gfc_add_in_common, gfc_add_data,
2332 gfc_add_in_namelist, gfc_add_sequence, gfc_add_function,
2333 gfc_add_subroutine, gfc_add_access, gfc_add_flavor, gfc_add_entry,
2334 gfc_add_procedure): Add argument.
2335 * array.c (gfc_set_array_spec), decl.c (var_element, get_proc_name,
2336 gfc_match_null, match_type_spec, match_attr_spec,
2337 gfc_match_formal_arglist, match_result, gfc_match_function_decl):
2338 Update callers to match.
2339 (gfc_match_entry) : Likewise, fix comment typo.
2340 (gfc_match_subroutine, attr_decl1, gfc_add_dimension,
2341 access_attr_decl, do_parm, gfc_match_save, gfc_match_modproc,
2342 gfc_match_derived_decl): Update callers.
2343 * interface.c (gfc_match_interface): Likewise.
2344 * match.c (gfc_match_label, gfc_add_flavor,
2345 gfc_match_call, gfc_match_common, gfc_match_block_data,
2346 gfc_match_namelist, gfc_match_module, gfc_match_st_function):
2348 * parse.c (parse_derived, parse_interface, parse_contained),
2349 primary.c (gfc_match_rvalue, gfc_match_variable): Likewise.
2350 * resolve.c (resolve_formal_arglist, resolve_entries): Update callers.
2351 * symbol.c (check_conflict, check_used): Add new 'name' argument,
2352 use when printing error message.
2353 (gfc_add_dimension, gfc_add_result, gfc_add_save, gfc_add_dummy,
2354 gfc_add_generic, gfc_add_in_common, gfc_add_data,
2355 gfc_add_in_namelist, gfc_add_sequence, gfc_add_function,
2356 gfc_add_subroutine, gfc_add_access, gfc_add_flavor, gfc_add_entry,
2357 gfc_add_procedure): Add new 'name' argument. Pass along to
2358 check_conflict and check_used.
2359 (gfc_add_allocatable, gfc_add_external, gfc_add_intrinsic,
2360 gfc_add_optional, gfc_add_pointer, gfc_add_target, gfc_add_elemental,
2361 gfc_add_pure, gfc_add_recursive, gfc_add_intent,
2362 gfc_add_explicit_interface, gfc_copy_attr): Pass NULL for new
2363 argument in calls to any of the modified functions.
2365 2005-02-06 Joseph S. Myers <joseph@codesourcery.com>
2367 * gfortran.texi: Don't give last update date.
2369 2006-01-30 Richard Henderson <rth@redhat.com>
2371 * options.c (gfc_init_options): Zero flag_errno_math.
2373 2005-01-29 Paul Brook <paul@codesourcery.com>
2376 * check.c (real_or_complex_check): New function.
2377 (gfc_check_fn_c, gfc_check_fn_r, gfc_check_fn_rc): New functions.
2378 * intrinsic.c (add_functions): Use new check functions.
2379 * intrinsic.h (gfc_check_fn_c, gfc_check_fn_r, gfc_check_fn_rc):
2382 2005-01-29 Steven G. Kargl <kargls@comcast.net>
2385 * expr.c (gfc_check_assign): Check for conformance of logical operands
2387 2004-01-27 Steven Bosscher <stevenb@suse.de>
2389 * trans-decl.c (gfc_build_label_decl): Set DECL_ARTIFICAL and
2390 TREE_USED for all labels.
2391 (gfc_trans_entry_master_switch): Use it instead of building a
2393 * trans-io.c (add_case): Likewise.
2394 * trans-stmt.c (gfc_trans_integer_select): Likewise.
2396 2004-01-23 Paul Brook <paul@codesourcery.com>
2397 Steven G. Kargl <kargls@comcast.net>
2400 * arith.c (gfc_convert_real): Remove sign handling.
2401 * primary.c (match_digits): Allow whitespace after initial sign.
2402 (match_real_const): Handle signs here. Allow whitespace after
2403 initial sign. Remove dead code.
2404 (match_const_complex_part): Remove.
2405 (match_complex_part): Use match_{real,integer}_const.
2406 (match_complex_constant): Cross-promote integer types.
2408 2005-01-23 James A. Morrison <phython@gcc.gnu.org>
2411 * iresolve.c (gfc_resolve_transpose): Resolve to transpose_c4 or
2412 transpose_c8 for complex types.
2414 2005-01-23 Kazu Hirata <kazu@cs.umass.edu>
2416 * data.c, dependency.c, f95-lang.c, io.c, trans-array.c,
2417 trans-decl.c, trans-expr.c, trans-intrinsic.c, trans-io.c,
2418 trans-stmt.c, trans-types.c, trans.h: Fix comment typos.
2419 Follow spelling conventions.
2421 2005-01-22 Bud Davis <bdavis9659@comcast.net>
2424 * trans-io.c (gfc_trans_inquire): Added code to support
2427 2005-01-22 Steven G. Kargl <kargls@comcast.net>
2429 * intrinsic.c (make_alias): Add standard argument.
2430 (add_functions): Update make_alias calls.
2432 2005-01-22 Paul Brook <paul@codesourcery.com>
2434 * trans-expr.c (gfc_conv_function_call): Remove bogus TODO.
2436 2005-01-22 Paul Brook <paul@codesourcery.com>
2438 * gfortran.h (gfc_check_access): Add prototype.
2439 * match.c (gfc_match_namelist): Remove TODO.
2440 * module.c (check_access): Rename ...
2441 (gfc_check_access): ... to this. Boolify. Update callers.
2442 * resolve.c (resolve_symbol): Check for private objects in public
2445 2005-01-22 Paul Brook <paul@codesourcery.com>
2447 * primary.c (gfc_match_rvalue): Only apply implicit type if variable
2448 does not have an explicit type.
2449 (gfc_match_variable): Resolve implicit derived types in all cases.
2450 Resolve contained function types from their own namespace, not the
2452 * resolve.c (resolve_contained_fntype): Remove duplicate sym->result
2453 checking. Resolve from the contained namespace, not the parent.
2455 2005-01-22 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2458 * trans-const.c (gfc_conv_constant_to_tree): Give logical
2459 constants the correct type.
2462 * trans-io.c (ADD_STRING): Use gfc_charlen_type_node for string
2464 (gfc_build_io_library_fndecls): 'rec' and 'recl_in' are not
2467 2005-01-18 Kazu Hirata <kazu@cs.umass.edu>
2469 * arith.c, array.c, check.c, decl.c, expr.c, f95-lang.c,
2470 gfortran.h, interface.c, intrinsic.c, io.c, iresolve.c,
2471 match.c, matchexp.c, misc.c, module.c, options.c, parse.c,
2472 scanner.c, simplify.c, symbol.c, trans-array.c, trans-expr.c,
2473 trans-io.c, trans-stmt.c, trans.c: Update copyright.
2475 2005-01-17 Ira Rosen <irar@il.ibm.com>
2477 * f95-lang.c (gfc_init_builtin_functions): Call targetm.init_builtins.
2479 2005-01-16 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2482 * error.c (error_char): Line-buffer errors / warnings.
2484 2005-01-16 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2486 * trans-intrinsic.c (gfc_conv_intrinsic_ishft): Fix signed /
2487 unsigned issue. Use build_int_cst instead of converting
2488 integer_zero_node. Remove unnecessary conversion.
2490 * trans-types.c (gfc_get_character_type_len): : Use
2491 gfc_charlen_type_node as basic type for the range field.
2493 * trans-intrinsic.c (build_fixbound_expr,
2494 gfc_conv_intrinsic_bound, gfc_conv_intrinsic_anyall,
2495 gfc_conv_intrinsic_count, gfc_conv_intrinsic_btest,
2496 gfc_conv_intrinsic_singlebitop): Use 'build_int_cst' instead
2497 of converting 'integer_zero_node' or 'integer_one_node'
2499 (gfc_conv_intrinsic_ishftc): Same, but store in local variable to
2501 (gfc_conv_intrinsic_strcmp, gfc_conv_intrinsic_rrspacing,
2502 gfc_conv_intrinsic_trim, gfc_conv_intrinsic_iargc): Use
2503 'build_int_cst' instead of converting 'integer_zero_node' or
2504 'integer_one_node' respectively.
2506 * trans-intrinsic.c (gfc_conv_intrinsic_index,
2507 gfc_conv_intrinsic_scan, gfc_conv_intrinsic_verify): Remove
2508 'gfc'-prefix from local variable, remove dead code, use correct
2509 type when inserting argument.
2511 * trans-intrinsic.c, trans-types.c: Update copyright years.
2513 2005-01-16 Steven G. Kargl <kargls@comcast.net>
2516 * resolve.c (check_case_overlap): Typo in comment.
2517 (validate_case_label_expr): Fix up kinds of case values
2518 (resolve_select): Properly handle kind mismatches.
2520 2004-01-16 Paul Brook <paul@codesourcery.com>
2523 * trans-common.c (translate_common): Remove duplicate function call.
2524 (finish_equivalences): Preserve alignment when biasing offsets.
2526 2005-01-15 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de
2528 * primary.c (check_digit): Call 'ISXDIGIT' instead of assuming
2529 ASCII-like character encoding.
2531 2005-01-14 Steven G. Kargl <kargls@comcast.net>
2533 * resolve.c (compare_case): Cleanup.
2535 2005-01-14 Steven G. Kargl <kargls@comcast.net>
2537 * resolve.c (compare_case): Give arguments correct type.
2539 2005-01-13 Kazu Hirata <kazu@cs.umass.edu>
2541 * iresolve.c, trans-common.c, trans-types.c: Fix comment
2544 2005-01-09 Paul Brook <paul@codesourcery.com>
2547 * trans-common.c (current_common, current_offset): Remove.
2548 (create_common): Add head argument.
2549 (align_segment): New function.
2550 (apply_segment_offset): New function.
2551 (translate_common): Merge code from new_segment. Handle alignment.
2552 (new_segment): Remove.
2553 (finish_equivalences): Ensure proper alignment.
2555 2005-01-08 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2557 * trans-const.c: Don't include unused math.h.
2559 * trans-intrinsic.c (gfc_get_intrinsic_lib_fndecl,
2560 gfc_conv_intrinsic_bound, gfc_conv_intrinsic_minmaxloc,
2561 gfc_conv_intrinsic_ishft, gfc_conv_intrinsic_len): Remove
2562 trailing whitespace.
2563 (prepare_arg_info): Fix formatting, indenting and remove trailing
2565 (gfc_conv_intrinsic_spacing, gfc_conv_intrinsic_trim): Remove
2566 trailing whitespace.
2568 * arith.c (arctangent2, gfc_arith_init_1, gfc_arith_done_1,
2569 gfc_constant_result, gfc_range_check, gfc_arith_power,
2570 eval_type_intrinsic0, eval_intrinsic_f2, gfc_real2real,
2571 gfc_real2complex, gfc_complex2int, gfc_complex2real,
2572 gfc_complex2complex): Fix whitespace issues.
2573 * check.c (must_be, type_check, numeric_check, int_or_real_check,
2574 logical_array_check, array_check, scalar_check, nonoptional_check,
2575 variable_check, dim_check, check_a_kind, gfc_check_a_ikind,
2576 gfc_check_a_xkind, gfc_check_abs, gfc_check_all_any,
2577 gfc_check_allocated, gfc_check_a_p, gfc_check_besn,
2578 gfc_check_btest, gfc_check_char, gfc_check_cmplx, gfc_check_count,
2579 gfc_check_cshift, gfc_check_dcmplx, gfc_check_dble,
2580 gfc_check_digits, gfc_check_dot_product, gfc_check_eoshift,
2581 gfc_check_fnum, gfc_check_g77_math1, gfc_check_huge, gfc_check_i,
2582 gfc_check_iand, gfc_check_ibclr, gfc_check_ibits, gfc_check_ibset,
2583 gfc_check_idnint, gfc_check_ieor, gfc_check_index, gfc_check_int,
2584 gfc_check_ior, gfc_check_ishft, gfc_check_ishftc, gfc_check_kind,
2585 gfc_check_lbound, gfc_check_logical, min_max_args,
2586 gfc_check_min_max_integer, gfc_check_min_max_real,
2587 gfc_check_min_max_double, gfc_check_matmul,
2588 gfc_check_minval_maxval, gfc_check_merge, gfc_check_nearest,
2589 gfc_check_pack, gfc_check_precision, gfc_check_radix,
2590 gfc_check_range, gfc_check_real, gfc_check_repeat,
2591 gfc_check_scale, gfc_check_scan, gfc_check_selected_real_kind,
2592 gfc_check_set_exponent): Fix formatting issues.
2593 (gfc_check_size, gfc_check_sign): Alphabetize function order,
2594 remove whitespace-only line.
2595 (gfc_check_fstat, gfc_check_fstat_sub, gfc_check_stat,
2596 gfc_check_stat_sub, gfc_check_transfer, gfc_check_transpose,
2597 gfc_check_ubound, gfc_check_unpack, gfc_check_verify, gfc_check_x,
2598 gfc_check_cpu_time, gfc_check_date_and_time, gfc_check_mvbits,
2599 gfc_check_random_number, gfc_check_random_seed,
2600 gfc_check_second_sub, gfc_check_system_clock,
2601 gfc_check_getcwd_sub, gfc_check_exit, gfc_check_flush,
2602 gfc_check_umask, gfc_check_umask_sub, gfc_check_unlink,
2603 gfc_check_unlink_sub): Fix formatting issues.
2605 2005-01-08 Tobias Schl"uter <tobias.schlueter@physik.uni-muenchen.de>
2607 * gfortran.h: Remove outdated comment. Don't include stdio.h
2610 2005-01-06 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2612 * gfortranspec.c (lang_specific_driver): Change year to 2005 in
2613 output of 'gfortran --version'.
2615 2005-01-03 Steven G. Kargl <kargls@comcast.net>
2617 * arith.c: Add system.h; remove string.h
2623 * check.c: Remove stdlib.h and stdarg.h
2624 * error.c: Remove stdlib.h, stdarg.h, stdio.h, string.h
2625 * expr.c: Add system.h; remove stdarg.h, stdio.h, and string.h
2626 * f95-lang.c: Add system.h; remove stdio.h
2627 * interface.c: Add system.h; remove stdlib.h and string.h
2628 * intrinsic.c: Remove stdarg.h, stdio.h, and string.h
2629 * io.c: Remove string.h
2631 * match.c: Remove stdarg.h and string.h
2632 * misc.c: Update copyright; add system.h; remove stdlib.h,
2633 string.h, and sys/stat.h
2634 * module.c: Add system.h; remove string.h, stdio.h, errno.h,
2635 unistd.h, and time.h
2636 * option.c: Remove string.h and stdlib.h
2638 * scanner.c: Update copyright; add system.h; remove stdlib.h,
2639 stdio.h, string.h, and strings.h
2640 * symbol.c: Add system.h; remove stdlib.h, stdio.h, and string.h
2641 * trans-array.c: Remove stdio.h and gmp.h
2642 * trans-const.c: Ditto
2643 * trans-expr.c: Ditto
2645 * trans-stmt.c: Ditto
2647 * trans-intrinsic.c: Remove stdio.h and string.h
2649 2004-12-29 Steven G. Kargl <kargls@comcast.net>
2651 * gfortran.h (gfc_case): fix typo in comment.
2653 2004-12-27 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2655 * trans-intrinsic.c (gfc_conv_intrinsic_ishft): Change to
2656 logical shift. Call fold. Remove 0-bit shift shortcut.
2657 (gfc_conv_intrinsic_ishftc): Convert first argument to at least
2658 4 bytes bits. Convert 2nd and 3rd argument to 4 bytes. Convert
2659 result if width(arg 1) < 4 bytes. Call fold.
2662 * trans-intrinsic.c (gfc_conv_intrinsic_mod): Update comment
2663 in front of function to match the standard. Correct handling
2666 2004-12-27 Andrew Pinski <pinskia@physics.uc.edu>
2668 * trans-expr.c (gfc_conv_cst_int_power): Only check for
2669 flag_unsafe_math_optimizations if we have a float type.
2671 2004-12-23 Steven G. Kargl <kargls@comcast.net>
2673 * gfortran.texi: Fix typo.
2675 2004-12-16 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2677 * trans-intrinsic.c (build_fixbound_expr): Clarify comment, fix
2680 2004-12-15 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2683 * match.c (gfc_match_if): Don't explicitly skip optional whitespace.
2684 (gfc_match_nullify): Make sure that ')' is in front of the end of
2687 * scanner.c (skip_fixed_comments): Fix typo in comment preceding
2690 2004-12-14 Richard Henderson <rth@redhat.com>
2692 * gfortran.h (gfc_expr.function.name): Make const.
2693 (gfc_iresolve_init_1, gfc_iresolve_done_1): Remove.
2694 (gfc_get_string): Update prototype.
2695 * iresolve.c: Include tree.h.
2696 (string_node, HASH_SIZE, string_head, hash): Remove.
2697 (gfc_get_string): Use vsnprintf, get_identifier.
2698 (free_strings, gfc_iresolve_init_1, gfc_iresolve_done_1): Remove.
2699 * misc.c (gfc_init_1): Don't call gfc_iresolve_init_1.
2700 (gfc_done_1): Don't call gfc_iresolve_done_1.
2701 * module.c (mio_allocated_string): Take and return const char *,
2702 instead of modifying char**.
2703 (mio_expr): Update to match.
2704 * resolve.c (pure_function): Constify name argument.
2705 (resolve_function): Constify name.
2706 * trans-intrinsic.c (gfc_conv_intrinsic_function): Likewise.
2708 2004-12-12 Richard Henderson <rth@redhat.com>
2710 * iresolve.c (gfc_resolve_all, gfc_resolve_any, gfc_resolve_count,
2711 gfc_resolve_cshift, gfc_resolve_dot_product, gfc_resolve_eoshift,
2712 gfc_resolve_matmul, gfc_resolve_maxloc, gfc_resolve_maxval,
2713 gfc_resolve_minloc, gfc_resolve_minval, gfc_resolve_pack,
2714 gfc_resolve_product, gfc_resolve_reshape, gfc_resolve_shape,
2715 gfc_resolve_spread, gfc_resolve_sum, gfc_resolve_transpose,
2716 gfc_resolve_unpack: Use PREFIX.
2718 2004-12-12 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2721 * match.c (gfc_match_common): Skip whitespace.
2723 2004-12-12 Steven G. Kargl <kargls@comcast.net>
2726 * check.c (gfc_check_iand, gfc_check_ibclr, gfc_check_ibits,
2727 gfc_check_ibset, gfc_check_ieor, gfc_check_ior): Remove default
2728 integer kind check; Issue error for -std=f95 when needed.
2729 * intrinsic.c (add_functions): Change ieor from GFC_STD_GNU to
2731 * iresolve.c (gfc_resolve_iand, gfc_resolve_ieor, gfc_resolve_ior):
2732 Promote arguments to same kind.
2734 2004-12-12 Steven G. Kargl <kargls@comcast.net>
2735 Paul Brook <paul@codesourcery.com>
2738 * resolve.c (gfc_resolve_iterator_expr): New function.
2739 (gfc_resolve_iterator): Use it. Add real_ok argument. Convert
2740 start, end and stride to correct type.
2741 (resolve_code): Pass extra argument.
2742 * array.c (resolve_array_list): Pass extra argument.
2743 * gfortran.h (gfc_resolve): Add prototype.
2744 * trans-stmt.c (gfc_trans_do): Remove redundant type conversions.
2745 Handle real type iterators.
2747 2004-12-11 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2750 * iresolve.c (gfc_resolve_scale): Convert 'I' argument if not of
2751 same kind as C's 'int'.
2752 (gfc_resolve_set_exponent): Convert 'I' argument if not of kind 4.
2754 2004-12-08 Richard Henderson <rth@redhat.com>
2756 * intrinsic.c (gfc_convert_type_warn): Propagate the input shape
2757 to the output expression.
2758 * iresolve.c (gfc_resolve_cshift, gfc_resolve_eoshift): Suppress
2760 (gfc_resolve_reshape): Force convert SHAPE and ORDER parameters
2763 2004-12-08 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2766 * resolve.c (resolve_code): Impose correct restrictions on
2769 * decl.c (gfc_match_end): Use locus of END when eos is an error.
2771 2004-12-02 Steven G. Kargl <kargls@comcast.net>
2772 Paul Brook <paul@codesourcery.com>
2774 * check.c (gfc_check_flush, gfc_check_fnum): New functions.
2775 (gfc_check_fstat, gfc_check_fstat_sub): New functions.
2776 (gfc_check_stat, gfc_check_stat_sub): New functions.
2777 * gfortran.h (GFC_ISYM_FNUM,GFC_ISYM_FSTAT,GFC_ISYM_STAT): New symbols
2778 * intrinsic.c (add_functions,add_subroutines): Add flush, fnum,
2779 fstat, and stat to intrinsics symbol tables.
2780 * intrinsic.h (gfc_check_flush, gfc_resolve_stat_sub): Add prototypes.
2781 (gfc_resolve_fstat_sub, gfc_resolve_stat): Ditto.
2782 * iresolve.c (gfc_resolve_fnum, gfc_resolve_fstat): New functions.
2783 (gfc_resolve_stat, gfc_resolve_flush): New functions.
2784 (gfc_resolve_stat_sub,gfc_resolve_fstat_sub): New functions
2785 * trans-intrinsic.c (gfc_conv_intrinsic_function): Add new intrinsics.
2787 2004-12-02 Steven G. Kargl <kargls@comcast.net>
2789 * intrinsic.c: Fix and add comments, fix function declarations
2790 (OPTIONAL,REQUIRED): New symbols
2791 (add_functions,add_subroutines): Use symbols
2792 (gmp.h): Remove unused include
2794 2004-11-25 Joseph S. Myers <joseph@codesourcery.com>
2796 * f95-lang.c, gfortranspec.c, trans-decl.c: Avoid ` as left quote
2799 2004-11-24 Steven Bosscher <stevenb@suse.de>
2801 * options.c (gfc_post_options): Don't clear flag_inline_functions.
2803 2004-11-20 Steven G. Kargl <kargls@comcast.net>
2805 * check.c (gfc_check_getcwd_sub): Fix seg fault.
2807 * check.c (gfc_check_exit,gfc_check_umask,gfc_check_umask_sub,
2808 gfc_check_unlink,gfc_check_unlink_sub): New functions
2809 * gfortran.h (GFC_ISYM_UMASK,GFC_ISYM_UNLINK): New symbols
2810 * intrinsic.c (add_functions,add_subroutines): Add umask, unlink,
2811 exit to intrinsics symbol tables.
2812 * intrinsic.h (gfc_check_umask,gfc_check_unlink,gfc_check_exit,
2813 gfc_check_umask_sub,gfc_check_unlink_sub,gfc_resolve_umask,
2814 gfc_resolve_unlink,gfc_resolve_exit,gfc_resolve_umask_sub,
2815 gfc_resolve_unlink_sub): Add and sort prototypes.
2816 * iresolve.c (gfc_resolve_umask,gfc_resolve_unlink,gfc_resolve_exit,
2817 gfc_resolve_umask_sub,gfc_resolve_unlink_sub): New functions
2818 * trans-intrinsic.c (gfc_conv_intrinsic_function): Use symbols
2820 2004-11-16 Paul Brook <paul@codesourcery.com>
2823 * trans-array.c (gfc_trans_allocate_temp_array): Use gfc_get_dtype.
2824 (gfc_array_init_size, gfc_conv_expr_descriptor): Ditto.
2825 * trans-types.c (gfc_get_dtype): Accept array type rather than element
2827 (gfc_get_nodesc_array_type): Don't set GFC_TYPE_ARRAY_DTYPE.
2828 (gfc_get_array_type_bounds): Ditto.
2829 (gfc_get_derived_type): Recurse into derived type pointers.
2830 * trans-types.h (gfc_get_dtype): Add prototype.
2831 * trans.h (GFC_TYPE_ARRAY_DTYPE): Add comment.
2833 2004-11-15 Paul Brook <paul@codesourcery.com>
2835 * trans-types.c (gfc_get_dtype): Remove obsolete TODO.
2837 2004-11-10 Paul Brook <paul@codesourcery.com>
2840 * trans-expr.c (gfc_trans_subarray_assign): Free shape before ss.
2841 * trans-io.c (transfer_array_component): Ditto.
2843 2004-11-10 Paul Brook <paul@codesourcery.com>
2845 * invoke.texi: Fix typo.
2847 2004-11-08 Kazu Hirata <kazu@cs.umass.edu>
2849 * arith.c, array.c, decl.c, expr.c, f95-lang.c, gfortran.h,
2850 gfortranspec.c, interface.c, intrinsic.c, iresolve.c, match.c,
2851 module.c, parse.c, parse.h, primary.c, resolve.c, scanner.c,
2852 trans-array.c, trans-array.h, trans-expr.c, trans-intrinsic.c,
2853 trans-io.c, trans-stmt.c, trans.h: Fix comment formatting.
2855 2004-11-06 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2858 * io.c (resolve_tag): Tighten up exception for assigned FORMAT.
2860 2004-11-06 Kazu Hirata <kazu@cs.umass.edu>
2862 * gfortranspec.c: Replace GNU CC with GCC.
2864 2004-11-05 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2866 * gfortranspec.c (lang_specific_driver): Change year to 2004.
2868 2004-11-05 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2871 * trans-decl.c (create_function_arglist): Set DECL_ARTIFICIAL for
2874 2004-11-05 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2877 * trans-decl.c (gfc_finish_var_decl): Don't declare arguments to
2878 module procedures as if they were module variables.
2880 2004-11-03 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2885 * module.c (write_symbol1): Set module_name for dummy arguments.
2887 2004-11-02 Paul Brook <paul@codesourcery.com>
2889 * intrinsic.c (check_intrinsic_standard): Include error locus.
2891 (gfc_intrinsic_func_interface, gfc_intrinsic_sub_interface): Pass
2892 locus to check_intrinsic_standard.
2894 2004-10-31 Janne Blomqvist <jblomqvi@cc.hut.fi>
2897 * gfortran.h: Change GFC_STD_* flags to more appropriate
2898 ones. (struct gfc_intrinsic_isym): Add field for standard. (struct
2899 gfc_option_t): Add field for warning about use of nonstandard
2901 * intrinsic.c (add_sym): Add parameter for standard version, check
2902 this against current standard.
2903 (add_sym_0): Pass standard parameter to add_sym.
2904 (add_sym_1, add_sym_0s, add_sym_1s, add_sym_1m, add_sym_2): Ditto.
2905 (add_sym_2s, add_sym_3, add_sym_3ml, add_sym_3red, add_sym_3s): Ditto.
2906 (add_sym_4, add_sym_4s, add_sym_5, add_sym_5s): Ditto.
2907 (make_generic): Add parameter for standard, check this
2908 against currently selected standard.
2909 (add_functions, add_subroutines): Add parameter to tell which
2910 standard an intrinsic belongs to.
2911 (check_intrinsic_standard): New function.
2912 (gfc_intrinsic_func_interface): Add call to check_intrinsic_standard.
2913 (gfc_intrinsic_sub_interface): Ditto.
2914 * lang.opt: Add Wnonstd-intrinsics option.
2915 * options.c (gfc_init_options): Change to use new GFC_STD_* flags,
2917 (set_Wall): Add warning about nonstd intrinsics.
2918 (gfc_handle_option): Change to use new GFC_STD_* flags,
2920 * invoke.texi: Update manual to include -Wnonstd-intrinsics.
2922 2004-10-30 Andrew Pinski <pinskia@physics.uc.edu>
2924 * f95-lang.c (lang_tree_node): Add chain_next to be the TREE_CHAIN.
2926 2004-10-30 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2928 * simplify.c (twos_complement): Calculate mask in GMP arithmetic.
2930 2004-10-30 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2932 * trans.c (gfc_trans_code): Set global locus after recursing. Fix
2935 2004-10-30 Canqun Yang <canqun@nudt.edu.cn>
2937 * check.c (gfc_check_rand): Allow missing optional argument.
2938 (gfc_check_irand): Ditto.
2939 * intrinsic.c (add_functions): Set arg optional flag for {i,}rand.
2941 2004-10-28 Scott Robert Ladd <scott.ladd@coyotegulch.com>
2943 PR fortran/13490, PR fortran/17912
2944 * gcc/fortran/gfortran.h: Added pedantic_min_int to gfc_integer_info
2945 * gcc/fortran/gfortran.h: Added ARITH_ASYMMETRIC to arith
2946 * gcc/fortran/arith.c: Added support for an "asymmetric integer"
2947 warning when compiling with pedantic.
2948 * gcc/fortran/arith.c: Set minimum integer values to reflect
2949 realities of two's complement signed integers. Added
2952 2004-10-17 Andrew Pinski <pinskia@physics.uc.edu>
2954 * Make-lang.in (F95_ADDITIONAL_OBJS): Kill.
2955 (f951): Do not depend on F95_ADDITIONAL_OBJS and don't
2958 2004-10-14 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2960 * trans-decl.c (generate_local_decl): Simplify logic, fix comment
2962 (gfc_generate_function_code): Fix formatting issue.
2964 2004-10-10 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2966 * module.c: Fix formatting issues.
2968 2004-10-09 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2970 * module.c (mio_interface_rest): Set where member of interface
2973 2004-10-08 Andrew Pinski <pinskia@physics.uc.edu>
2976 * options.c (gfc_handle_option): Add break after handing the
2979 2004-10-08 Tobias Schlueter <tobias.shclueter@physik.uni-muenchen.de>
2981 * arith.c: Fix formatting issues.
2983 2004-10-07 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2986 * resolve.c (resolve_operator): Use correct operator name in message.
2988 2004-10-07 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
2990 * primary.c (match_boz_constant): Allow kind parameter suffixes.
2991 Move standard warning further to the front.
2993 2004-10-07 Kazu Hirata <kazu@cs.umass.edu>
2995 * trans-stmt.c: Fix a comment typo.
2997 2004-10-07 Paul Brook <paul@codesourcery.com>
3000 * trans-array.c (gfc_trans_deferred_array): Leave use associated
3003 2004-10-06 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3006 * simplify.c (twos_complement): New function.
3007 (gfc_simplify_ishft, gfc_simplify_ishftc): Revise.
3009 * simplify.c (gfc_simplify_abs): Use mpfr_hypot for CABS.
3011 2004-10-06 Paul Brook <paul@codesourcery.com>
3013 * trans-stmt.c (gfc_trans_simple_do): New function.
3014 (gfc_trans_do): Use it. Evaluate iteration bounds before entering
3015 loop. Update comments.
3017 2004-10-04 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3020 * iresolve.c (gfc_resolve_pack): Choose function depending if mask
3024 * intrinsic.c (add_sym_5): Remove.
3025 (add_subroutines): Add resolution function for MVBITS.
3026 * intrinsic.h (gfc_resolve_mvbits): Declare resolution function for
3028 * iresolve.c (gfc_resolve_mvbits): New function.
3029 (gfc_resolve_random_number): Remove empty line at end of function.
3031 * trans-const.c (gfc_build_cstring_const): New function.
3032 (gfc_init_cst): Use new function.
3033 * trans-const.h (gfc_build_cstring_const): Add prototype.
3034 * trans-io.c (set_string, set_error_locus): Use new function.
3035 * trans-stmt.c (gfc_trans_goto): Use new function.
3038 * parse.c (accept_statement): Don't treat END DO like END IF and
3040 (parse_do_block): Generate possible END DO label inside END DO
3044 * check.c (gfc_check_system_sub): New function.
3045 * gfortran.h (gfc_generic_isym_id): Add GFC_ISYM_SYSTEM.
3046 * intrinsic.c (add_functions): Add 'system'.
3047 (add_subroutines): Add 'system'.
3048 * intrinsic.h (gfc_check_etime_sub, gfc_check_getcwd_sub):
3049 Move prototypes to other suborutines.
3050 (gfc_check_system_sub, gfc_resolve_system, gfc_resolve_system_sub):
3052 (gfc_resolve_system_clock): Fix formatting of prototype.
3053 * iresolve.c (gfc_resolve_system, gfc_resolve_system_sub): New
3055 * trans-intrinsic.c (gfc_conv_intrinsic_function): Deal with
3058 2004-10-04 Erik Schnetter <schnetter@aei.mpg.de>
3060 * scanner.c (preprocessor_line): Accept preprocessor lines without
3061 file names. Check file names for closing quotes. Handle escaped
3062 quotes in file names.
3064 2004-10-04 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3065 Paul Brook <paul@codesourcery.com>
3067 * trans-array.c (gfc_conv_expr_descriptor): Check for substriungs.
3068 Use gfc_get_expr_charlen.
3069 * trans-expr.c (gfc_get_expr_charlen): New function.
3070 * trans.h (gfc_get_expr_charlen): Add prototype.
3072 2004-10-04 Kazu Hirata <kazu@cs.umass.edu>
3074 * trans-intrinsic.c: Fix a comment typo.
3076 2004-10-03 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3078 * simplify.c (range_check): Remove blank line at beginning of function.
3079 (gfc_simplify_dint): Same at end of function.
3080 (gfc_simplify_exponent, gfc_simplify_fraction): Simplify calculations.
3081 (gfc_simplify_bound): Fix indentation.
3082 (gfc_simplify_log10): Simplify calculation.
3083 (gfc_simplify_min, gfc_simplify_max): Remove blank line at beginning
3085 (gfc_simplify_nearest): Same at end of function.
3086 (gfc_simplify_nint, gfc_simplify_idnint): Same at beginning of
3088 (gfc_simplify_rrspacing, gfc_simplify_set_exponent,
3089 gfc_simplify_spacing): Simplify calulations.
3091 2004-10-03 Feng Wang <fengwang@nudt.edu.cn>
3093 * trans-intrinsic.c: Fix comments on spacing and rrspacing
3094 (gfc_conv_intrinsic_rrspacing): Add fold on constant trees.
3096 2004-10-01 Jan Hubicka <jh@suse.cz>
3098 * f95-lang.c (gfc_expand_function): Update call of
3099 tree_rest_of_compilation.
3100 * trans-decl.c (gfc_generate_constructors): Likewise.
3102 2004-09-26 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3104 * trans-intrinsic.c: Comment fixes.
3106 2004-09-25 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3108 * decl.c (add_init_expr_to_sym, variable_decl): Comment fixes.
3110 2004-09-24 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3112 * trans-types.c (gfc_return_by_reference): Remove superfluous
3115 * intrinsic.h (gfc_resolve_getcwd): Update prototype.
3116 * iresolve.c (gfc_resolve_getcwd): Add second argument to function.
3119 * trans-expr.c (gfc_trans_arrayfunc_assign): Look at resolved
3120 function to determine return type.
3122 2004-09-20 Jan Hubicka <jh@suse.cz>
3124 * trans-decl.c (build_entry_thunks): Finalize the function; do not lower
3126 (gfc_generate_function_code): Likewise.
3128 2004-09-20 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3131 * simplify.c (gfc_simplify_reshape): Set shape of return value
3134 2004-09-17 Jeffrey D. Oldham <oldham@codesourcery.com>
3135 Zack Weinberg <zack@codesourcery.com>
3137 * f95-lang.c, trans-expr.c, trans.c: Update for new tree-class
3138 enumeration constants.
3140 2004-09-17 Paul Brook <paul@codesourcery.com>
3142 * gfortran.h (struct gfc_linebuf): Don't use C99 empty arrays.
3143 (gfc_linebuf_header_size): Define.
3144 * scanner.c (load_file): Use it.
3146 2004-09-16 Kazu Hirata <kazu@cs.umass.edu>
3148 * array.c, data.c, decl.c, dependency.c, error.c, f95-lang.c,
3149 interface.c, intrinsic.c, io.c, misc.c, module.c, parse.h,
3150 resolve.c, scanner.c, trans-array.c, trans-array.h,
3151 trans-common.c, trans-const.h, trans-decl.c, trans-expr.c,
3152 trans-intrinsic.c, trans-stmt.c, trans-types.c, trans.c,
3153 trans.h: Fix comment typos. Follow spelling conventions.
3155 2004-09-16 Victor Leikehman <lei@il.ibm.com>
3158 * trans-io.c (transfer_array_component): New function.
3159 (transfer_expr): For array fields, call transfer_array_component.
3161 2004-09-16 Kazu Hirata <kazu@cs.umass.edu>
3163 * gfortran.texi: Fix a typo.
3165 2004-09-15 Aaron W. LaFramboise <aaronavay62@aaronwl.com>
3167 * parse.c (eof_buf): Rename eof to eof_buf.
3168 (unexpected_eof): Same.
3169 (gfc_parse_file): Same.
3171 2004-09-15 Steven G. Kargl <kargls@comcast.net>
3173 * check.c (gfc_check_getcwd_sub): New function.
3174 * gfortran.h (GFC_ISYM_GETCWD): New symbol.
3175 * intrinsic.c (add_functions): Add function definition;
3177 * intrinsic.c (add_subroutines): Add subroutine definitions.
3178 * intrinsic.h: Add prototypes.
3179 * iresolve.c (gfc_resolve_getcwd, gfc_resolve_getcwd_sub):
3181 * trans-intrinsic.c (gfc_conv_intrinsic_function): Use symbol.
3183 2004-09-15 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3186 * module.c (write_symbol): Don't fill in module name here.
3187 (write_symbol0): Fill in here instead.
3189 2004-09-14 Kazu Hirata <kazu@cs.umass.edu>
3191 * data.c, decl.c, f95-lang.c, gfortran.h, match.c,
3192 trans-array.c, trans-common.c, trans-expr.c,
3193 trans-intrinsic.c, trans-stmt.c, trans-types.c, trans.h: Fix
3194 comment typos. Follow spelling conventions.
3196 2004-09-09 Paul Brook <paul@codesourcery.com>
3198 * scanner.c (get_file): Add ATTRIBUTE_UNUSED.
3200 2004-09-08 Paul Brook <paul@codesourcery.com>
3202 * array.c: Don't include assert.h.
3203 * data.c: Don't include assert.h. Replace assert and abort with
3204 gcc_assert and gcc_unreachable.
3205 * dependency.c: Ditto.
3206 * f95-lang.c: Ditto.
3207 * iresolve.c: Ditto.
3209 * simplify.c: Ditto.
3211 * trans-array.c: Ditto.
3212 * trans-common.c: Ditto.
3213 * trans-const.c: Ditto.
3214 * trans-decl.c: Ditto.
3215 * trans-expr.c: Ditto.
3216 * trans-intrinsic.c: Ditto.
3217 * trans-io.c: Ditto.
3218 * trans-stmt.c: Ditto.
3219 * trans-types.c: Ditto.
3222 2004-09-07 Per Bothner <per@bothner.com>
3223 Paul Brook <paul@codesourcery.com>
3225 * error.c (show_locus): Handle mapped locations.
3226 * f95-lang.c (gfc_be_parse_file): Initialize mapped locations.
3227 * gfortran.h: Include input.h.
3228 (struct gfc_linebuf): Use source_location.
3229 * scanner.c (get_file): Initialize linemap.
3230 (preprocessor_line): Pass extra argument to get_file.
3231 (load_file): Ditto. Setup linemap.
3232 (gfc_new_file): Handle mapped locations.
3233 * trans-common.c (build_field, build_equiv_decl, build_common_decl):
3234 Set decl source locations.
3235 (gfc_trans_common): Set blank common block location.
3236 * trans-decl.c (gfc_set_decl_location): New function.
3237 (gfc_get_label_decl, gfc_get_symbol_decl): Use it.
3238 (trans_function_start): Move call to gfc_set_backend_locus..
3239 (build_function_decl): ... to here.
3240 (build_entry_thunks): Set and restore the backend locus.
3241 (gfc_generate_constructors): Remove excess arguments to
3242 init_function_start.
3243 (gfc_generate_block_data): Add comments. Set the decl locus.
3244 * trans-io.c (set_error_locus): Handle mapped locations.
3245 * trans.c (gfc_get_backend_locus, gfc_get_backend_locus): Ditto.
3246 (gfc_trans_code): Use SET_EXPR_LOCATION.
3247 (gfc_generate_code): Override the location of the new symbol.
3248 * trans.h (gfc_set_decl_location): Add prototype.
3250 2004-08-31 Paul Brook <paul@codesourcery.com>
3252 * trans-types.c (gfc_type_for_mode): Return NULL for unknown modes.
3254 2004-09-01 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3257 * trans-intrinsic.c (gfc_conv_intrinsic_merge): Do the right thing for
3260 2004-09-01 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3265 * resolve.c (resolve_transfer): New function.
3266 (resolve_code): Call resolve_transfer in case of EXEC_TRANSFER.
3268 2004-08-31 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3271 * trans-types.c (gfc_init_types): Make gfc_character1_type_node an
3274 2004-08-31 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3276 * CONTRIB, NEWS, README, TODO: Remove obsolete files.
3278 2004-08-31 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3281 * trans-types.c (gfc_return_by_reference): Remove TODO error,
3282 add comment pointing out possible issue WRT compatibility with g77.
3284 2004-08-31 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3286 * trans-decl.c, trans-expr.c, trans-io.c, trans-types.c: Replace
3287 all occurences of 'gfc_strlen_type_node' by
3288 'gfc_charlen_type_node'.
3289 * trans-types.h: Same. Also update comment accordingly.
3291 2004-08-31 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
3293 * primary.c: Update copyright boilerplate to say GCC.
3294 * f95-lang.c: Change initial comment to say gfortran.
3296 2004-08-31 Paul Brook <paul@codesourcery.com>
3298 * trans-types.h: Add comments.
3299 (intmax_type_node, string_type_node, const_string_type_node): Remove.
3301 2004-08-30 Richard Henderson <rth@redhat.com>
3303 * Make-lang.in (fortran/f95-lang.o): Update dependencies.
3304 (fortran/trans-decl.o, fortran/trans-types.o): Likewise.
3305 * gfortran.h (gfc_integer_info): Add c_char, c_short, c_int,
3306 c_long, c_long_long.
3307 (gfc_logical_info): Add c_bool.
3308 (gfc_real_info): Add mode_precision, c_float, c_double, c_long_double.
3309 * trans-array.c (gfc_array_allocate): Use TYPE_PRECISION
3310 rather than gfc_int[48]_type_node for allocate choice.
3311 * trans-decl.c (gfc_build_intrinsic_function_decls): Cache
3312 local copies of some kind type nodes.
3313 (gfc_build_builtin_function_decls): Likewise.
3314 * trans-expr.c (gfc_conv_power_op): Likewise.
3315 * trans-intrinsic.c (gfc_conv_intrinsic_index,
3316 gfc_conv_intrinsic_scan, gfc_conv_intrinsic_verify,
3317 gfc_conv_intrinsic_trim, gfc_conv_intrinsic_repeat): Likewise.
3318 * trans-stmt.c (gfc_trans_pause, gfc_trans_stop,
3319 gfc_trans_character_select, gfc_trans_allocate): Likewise.
3320 * trans-io.c (gfc_pint4_type_node): Move into ...
3321 (gfc_build_io_library_fndecls): ... here. Cache local copies of
3322 some kind type nodes.
3323 * trans-types.c (gfc_type_nodes): Remove.
3324 (gfc_character1_type_node, gfc_strlen_type_node): New.
3325 (gfc_integer_types, gfc_logical_types): New.
3326 (gfc_real_types, gfc_complex_types): New.
3327 (gfc_init_kinds): Fill in real mode_precision.
3328 (gfc_build_int_type, gfc_build_real_type): New.
3329 (gfc_build_complex_type, gfc_build_logical_type): New.
3330 (c_size_t_size): New.
3331 (gfc_init_types): Loop over kinds.
3332 (gfc_get_int_type, gfc_get_real_type): Use gfc_validate_kind.
3333 (gfc_get_complex_type, gfc_get_logical_type): Likewise.
3334 (gfc_get_character_type_len): Likewise.
3335 (gfc_type_for_size): Loop over kinds; use a reduced set of
3336 unsigned type nodes.
3337 (gfc_type_for_mode): Loop over kinds.
3338 (gfc_signed_or_unsigned_type): Use gfc_type_for_size.
3339 (gfc_unsigned_type, gfc_signed_type): Use gfc_signed_or_unsigned_type.
3340 * trans-types.h (F95_INT1_TYPE, F95_INT2_TYPE, F95_INT4_TYPE,
3341 F95_INT8_TYPE, F95_INT16_TYPE, F95_REAL4_TYPE, F95_REAL8_TYPE,
3342 F95_REAl16_TYPE, F95_COMPLEX4_TYPE, F95_COMPLEX8_TYPE,
3343 F95_COMPLEX16_TYPE, F95_LOGICAL1_TYPE, F95_LOGICAL2_TYPE,
3344 F95_LOGICAL4_TYPE, F95_LOGICAL8_TYPE, F95_LOGICAL16_TYPE,
3345 F95_CHARACTER1_TYPE, NUM_F95_TYPES, gfc_type_nodes,
3346 gfc_int1_type_node, gfc_int2_type_node, gfc_int4_type_node,
3347 gfc_int8_type_node, gfc_int16_type_node, gfc_real4_type_node,