1 2007-07-14 Paul Thomas <pault@gcc.gnu.org>
4 * parse.c (parse_spec): Emit error on unexpected statement
7 2007-07-13 Daniel Franke <franke.daniel@gmail.com>
9 * invoke.texi: Unified upper- and lower-case in menus.
10 (-w, -W): Removed, documented by gcc.
11 * intrinsic.texi: Unified Class-section entries, added
12 subroutine/function warning where appropiate.
14 2007-07-12 Daniel Franke <franke.daniel@gmail.com>
17 * decl.c (gfc_match_suffix): Removed surplus general error that hides
18 a more specific message.
19 * resolve.c (resolve_fl_variable): Reject illegal initializiers only
21 (resolve_fl_procedure): Added check for initializers of functions.
23 2007-07-12 Daniel Franke <franke.daniel@gmail.com>
26 * invoke.texi (-static-libgfortran): Document new option.
28 2007-07-12 Paul Thomas <pault@gcc.gnu.org>
32 * module.c (write_generic): Restore patch of 2007-07-10 and use
33 symbol name if there are no use names.
35 2007-07-12 Christopher D. Rickett <crickett@lanl.gov>
38 * decl.c (verify_c_interop_param): Require character string dummy
39 args to BIND(C) procedures to have length 1.
40 * resolve.c (resolve_fl_procedure): Modify parameter checking for
44 * resolve.c (gfc_iso_c_func_interface): Verify that a valid
45 expression is given as an argument to C_LOC and C_ASSOCIATED.
46 * trans-io.c (transfer_expr): Add argument for code block. Add
47 standards check to determine if an error message should be
48 reported for printing C_PTR or C_FUNPTR.
49 (transfer_array_component): Update arguments to transfer_expr.
50 (gfc_trans_transfer): Ditto.
52 * symbol.c (gen_cptr_param): Fix whitespace.
54 2007-07-12 Jakub Jelinek <jakub@redhat.com>
57 * trans.h (GFC_POINTER_TYPE_P): Define.
58 * trans-types.c (gfc_sym_type): Set it for types on attr->sym.pointer.
59 * trans-openmp.c (gfc_omp_privatize_by_reference): Return false
60 if GFC_POINTER_TYPE_P is set on the type.
62 2007-07-12 Richard Guenther <rguenther@suse.de>
64 * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Convert
65 arguments to gfc_charlen_type_node.
66 * trans-io.c (gfc_convert_array_to_string): Convert type
67 size to gfc_array_index_type.
69 2007-07-12 Daniel Franke <franke.daniel@gmail.com>
73 * module.c: Reverted Paul's patch from 2007-07-10.
75 2007-07-11 Richard Guenther <rguenther@suse.de>
77 * trans-array.c (gfc_conv_array_parameter): Use correct
79 * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Use
80 correct types for POINTER_PLUS_EXPR.
81 * trans-stmt.c (gfc_trans_forall_loop): Use correct type
82 for integer one constant.
84 2007-07-10 Paul Thomas <pault@gcc.gnu.org>
87 * resolve.c (is_external_proc): New function. Adds test that
88 the symbol is not an intrinsic procedure.
89 * (resolve_function, resolve_call): Replace logical statements
90 with call to is_external_proc.
93 * simplify.c (gfc_simplify_transfer): If mold has rank, the
97 * module.c (write_generic): Write the local name of the
100 2007-07-09 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
103 * trans-array.c (gfc_trans_array_constructor): Mark offset field
104 with TREE_NO_WARNING.
105 * trans-decl.c (gfc_build_qualified_array): Mark lbound, ubound,
106 stride and size variables with TREE_NO_WARNING.
108 2007-07-09 Steven G. Kargl <kargl@gcc.gnu.org>
110 * trans-decl.c (set_tree_decl_type_code): Remove function.
111 (generate_local_decl): Remove reference to set_tree_decl_type_code.
113 2007-07-09 Daniel Franke <franke.daniel@gmail.com>
116 * trans-decl.c (generate_local_decl) Emit a warning if an unused
119 2007-07-08 Daniel Franke <franke.daniel@gmail.com>
122 * module.c (gfc_match_use): Do not set an non-existant
123 intrinsic operator if a user-defined operator is found.
125 2007-07-08 Daniel Franke <franke.daniel@gmail.com>
129 * trans-decl.c (generate_local_decl): Adjusted warning on unused
130 dummy arguments, tell middle-end not to emit additional warnings.
132 2007-07-08 Daniel Franke <franke.daniel@gmail.com>
133 Tobias Schlüter <tobias.schlueter@physik.uni-muenchen.de>
136 * gfortran.h (gfc_intrinsic_op): Added INTRINSIC_EQ_OS,
137 INTRINSIC_NE_OS, INTRINSIC_GT_OS, INTRINSIC_GE_OS,
138 INTRINSIC_LT_OS and INTRINSIC_LE_OS.
139 * arith.c (eval_intrinsic, eval_type_intrinsic0): Likewise.
140 * arith.h (gfc_eq, gfc_ne, gfc_gt, gfc_ge, gfc_lt, gfc_le):
141 Added gfc_intrinsic_op as third argument type.
142 * dump-parse-tree.c (gfc_show_expr): Account for new enum values.
143 * expr.c (simplify_intrinsic_op, check_intrinsic_op): Likewise.
144 * interface.c (check_operator_interface): Likewise.
145 (gfc_check_interfaces): Added cross-checks for FORTRAN 77 and
146 Fortran 90 style operators using new enum values.
147 (gfc_extend_expr): Likewise.
148 (gfc_add_interface): Likewise.
149 * match.c (intrinsic_operators): Distinguish FORTRAN 77 style
150 operators from Fortran 90 style operators using new enum values.
151 * matchexp.c (match_level_4): Account for new enum values.
152 * module.c (mio_expr): Likewise.
153 * resolve.c (resolve_operator): Deal with new enum values, fix
154 inconsistent error messages.
155 * trans-expr.c (gfc_conv_expr_op): Account for new enum values.
157 2007-07-08 Tobias Burnus <burnus@net-b.de>
160 * interface.c (get_expr_storage_size): Properly obtain lower bound.
161 (compare_actual_formal): Add space before parenthesis.
163 2007-07-08 Daniel Franke <franke.daniel@gmail.com>
166 * resolve.c (resolve_fl_procedure): Added check for PRIVATE types
167 in PUBLIC interfaces.
169 2007-07-07 Jerry DeLisle <jvdelisle@gcc.gnu.org>
172 * decl.c (match_attr_spec): Don't return MATCH_ERROR if comma found and
173 gfc_match_bind_c does not return MATCH_YES.
175 2007-07-07 Kazu Hirata <kazu@codesourcery.com>
177 * decl.c, gfortran.h, interface.c, module.c, resolve.c,
178 trans-array.c, trans-decl.c: Fix comment typos. Follow
179 spelling conventions.
180 * intrinsic.texi: Fix typos. Follow spelling conventions.
182 2007-05-06 Daniel Franke <franke.daniel@gmail.com>
185 * symbol.c (save_status): New.
186 * gfortran.h (save_status): Added external declaration.
187 (check_conflict): Check for conflicting explicite SAVE statements
189 (gen_special_c_interop_ptr): Use SAVE_EXPLICIT constant.
190 * module.c (ab_attribute, attr_bits): Removed enumerator value
191 AB_SAVE for save attribute.
192 (mio_symbol_attribute): Import/export the full SAVE status,
193 removed usage of AB_SAVE.
194 * dump-parse-tree.c (gfc_show_attr): Dump full SAVE status.
195 * decl.c (add_init_expr_to_sym): Set SAVE_IMPLICIT only if not
198 2007-07-05 Daniel Franke <franke.daniel@gmail.com>
199 Tobias Burnus <burnus@net-b.de>
202 * gfortran.h (symbol_attribute): Change save attribute into an enum.
203 * decl.c (add_init_expr_to_sym): Set it to SAVE_IMPLICIT.
204 * symbol.c (gfc_add_save): Check for SAVE_EXPLICIT.
205 * resolve.c (resolve_fl_variable): Check for SAVE_EXPLICIT.
206 (resolve_symbol): Allow OMP threadprivate with
207 initialization SAVEd and save_all variable.
208 * trans-decl.c (gfc_finish_var_decl): Remove obsolete sym->value check.
210 2007-07-05 Paul Thomas <pault@gcc.gnu.org>
213 * match.c (gfc_match_call): Check, in all cases, that a symbol
214 is neither generic nor a subroutine before trying to add it as
218 * match.c (gfc_match_do): Reset the implied_index attribute.
220 2007-07-04 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
223 * trans-intrinsic.c (trans-intrinsic.c): Handle optional
224 arguments correctly for MIN and MAX intrinsics.
226 2007-07-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
229 * io.c (check_format): Always call gfc_error for errors.
230 (check_format_string): Change type of this function to try and
231 return the result of check_format.
232 (check_io_constraints): Return MATCH_ERROR if check_format_string
235 2007-07-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
238 * decl.c (get_proc_name): Include attr->mod_proc in check for error.
240 2007-07-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
243 * gfortran.h: Change type of gfc_assign_data_value from void to try.
244 * data.c (gfc_assign_data_value): Return FAILURE if error found.
245 * resolve.c (check_data_variable): If gfc_assign_data_value returns
246 failure, break out of loop and return failure.
248 2007-07-03 Christopher D. Rickett <crickett@lanl.gov>
251 * symbol.c (gen_cptr_param): Generate C_PTR and C_FUNPTR if necessary.
252 (build_formal_args): Pass intrinsic module symbol id to
255 2007-07-03 Tobias Burnus <burnus@net-b.de>
258 * resolve.c (resolve_common_blocks): New check function.
259 (resolve_types): Use it.
261 2007-07-03 Tobias Burnus <burnus@net-b.de>
264 * interface.c (get_sym_storage_size): New function.
265 (get_sym_storage_size): New function.
266 (compare_actual_formal): Enhance sequence association
267 support and improve checking.
269 2007-07-03 Janne Blomqvist <jb@gcc.gnu.org>
271 * trans-decl.c (gfc_build_builtin_function_decls): Mark
272 internal_realloc as a malloc function.
274 2007-07-03 Tobias Burnus <burnus@net-b.de>
277 * resolve.c (resolve_operator): Check for NULL as operand.
279 2007-07-02 Tobias Burnus <burnus@net-b.de>
281 * gfortran.texi (Fortran 2003): Add ISO Bind C.
282 * intrinsic.texi (C_ASSOCIATED,C_F_POINTER,C_F_PROCPOINTER,
283 C_FUNLOC,C_LOC): Document new ISO Bind C intrinsics.
285 2007-07-01 Christopher D. Rickett <crickett@lanl.gov>
287 * interface.c (gfc_compare_derived_types): Special case for comparing
288 derived types across namespaces.
289 (gfc_compare_types): Deal with BT_VOID.
290 (compare_parameter): Use BT_VOID to accept ISO C Binding pointers.
291 * trans-expr.c (gfc_conv_function_call): Remove setting parm_kind
293 (gfc_conv_initializer): Deal with ISO C Binding NULL_PTR and
295 (gfc_conv_expr): Convert expressions for ISO C Binding derived types.
296 * symbol.c (gfc_set_default_type): BIND(C) variables should not be
298 (check_conflict): Add BIND(C) and check for conflicts.
299 (gfc_add_explicit_interface): Whitespace.
300 (gfc_add_is_bind_c): New function.
301 (gfc_copy_attr): Use it.
302 (gfc_new_symbol): Initialize ISO C Binding objects.
303 (get_iso_c_binding_dt): New function.
304 (verify_bind_c_derived_type): Ditto.
305 (gen_special_c_interop_ptr): Ditto.
306 (add_formal_arg): Ditto.
307 (gen_cptr_param): Ditto.
308 (gen_fptr_param): Ditto.
309 (gen_shape_param): Ditto.
310 (add_proc_interface): Ditto.
311 (build_formal_args): Ditto.
312 (generate_isocbinding_symbol): Ditto.
313 (get_iso_c_sym): Ditto.
314 * decl.c (num_idents_on_line, has_name_equals): New variables.
315 (verify_c_interop_param): New function.
316 (build_sym): Finish binding labels and deal with COMMON blocks.
317 (add_init_expr_to_sym): Check if the initialized expression is
318 an iso_c_binding named constants
319 (variable_decl): Set ISO C Binding type_spec components.
320 (gfc_match_kind_spec): Check match for C interoperable kind.
321 (match_char_spec): Fix comment. Chnage gfc_match_small_int
322 to gfc_match_small_int_expr. Check for C interoperable kind.
323 (match_type_spec): Clear the current binding label.
324 (match_attr_spec): Add DECL_IS_BIND_C. If BIND(C) is found, use it
326 (set_binding_label): New function.
327 (set_com_block_bind_c): Ditto.
328 (verify_c_interop): Ditto.
329 (verify_com_block_vars_c_interop): Ditto.
330 (verify_bind_c_sym): Ditto.
331 (set_verify_bind_c_sym): Ditto.
332 (set_verify_bind_c_com_block): Ditto.
333 (get_bind_c_idents): Ditto.
334 (gfc_match_bind_c_stmt): Ditto.
335 (gfc_match_data_decl): Use num_idents_on_line.
336 (match_result): Deal with right paren in BIND(C).
337 (gfc_match_suffix): New function.
338 (gfc_match_function_decl): Use it. Code is re-arranged to deal with
339 ISO C Binding result clauses.
340 (gfc_match_subroutine): Deal with BIND(C).
341 (gfc_match_bind_c): New function.
342 (gfc_get_type_attr_spec): New function. Code is re-arranged in and
343 taken from gfc_match_derived_decl.
344 (gfc_match_derived_decl): Add check for BIND(C).
345 * trans-common.c: Forward declare gfc_get_common.
346 (gfc_sym_mangled_common_id): Change arg from 'const char *name' to
347 'gfc_common_head *com'. Check for ISO C Binding of the common block.
348 (build_common_decl): 'com->name' to 'com in SET_DECL_ASSEMBLER_NAME.
349 * gfortran.h: Add GFC_MAX_BINDING_LABEL_LEN
351 (sym_flavor): Add FL_VOID.
352 (iso_fortran_env_symbol, iso_c_binding_symbol, intmod_id): New enum
353 (CInteropKind_t): New struct.
354 (c_interop_kinds_table): Use it. Declare an array of structs.
355 (symbol_attribute): Add is_bind_c, is_c_interop, and is_iso_c
357 (gfc_typespec): Add is_c_interop; is_iso_c, and f90_type members.
358 (gfc_symbol): Add from_intmod, intmod_sym_id, binding_label, and
359 common_block members.
360 (gfc_common_head): Add binding_label and is_bind_c members.
361 (gfc_gsymbol): Add sym_name, mod_name, and binding_label members.
362 Add prototypes for get_c_kind, gfc_validate_c_kind,
363 gfc_check_any_c_kind, gfc_add_is_bind_c, gfc_add_value,
364 verify_c_interop, verify_c_interop_param, verify_bind_c_sym,
365 verify_bind_c_derived_type, verify_com_block_vars_c_interop,
366 generate_isocbinding_symbol, get_iso_c_sym, gfc_iso_c_sub_interface
367 * iso-c-binding.def: New file. This file contains the definitions
368 of the types provided by the Fortran 2003 ISO_C_BINDING intrinsic
370 * trans-const.c (gfc_conv_constant_to_tree): Deal with C_NULL_PTR
371 or C_NULL_FUNPTR expressions.
372 * expr.c (gfc_copy_expr): Add BT_VOID case. For BT_CHARACTER, the
373 ISO C Binding requires a minimum string length of 1 for '\0'.
374 * module.c (intmod_sym): New struct.
375 (pointer_info): Add binding_label member.
376 (write_atom): Set len to 0 for NULL pointers. Check for NULL p and *p.
377 (ab_attribute): Add AB_IS_BIND_C, AB_IS_C_INTEROP and AB_IS_ISO_C.
378 (attr_bits): Add "IS_BIND_C", "IS_C_INTEROP", and "IS_ISO_C".
379 (mio_symbol_attribute): Deal with ISO C Binding attributes.
380 (bt_types): Add "VOID".
381 (mio_typespec): Deal with ISO C Binding components.
382 (mio_namespace_ref): Add intmod variable.
383 (mio_symbol): Check for symbols from an intrinsic module.
384 (load_commons): Check for BIND(C) common block.
385 (read_module): Read binding_label and use it.
386 (write_common): Add label. Write BIND(C) info.
387 (write_blank_common): Blank commons are not BIND(C). Explicitly
389 (write_symbol): Deal with binding_label.
390 (sort_iso_c_rename_list): New function.
391 (import_iso_c_binding_module): Ditto.
392 (create_int_parameter): Add to args.
393 (use_iso_fortran_env_module): Adjust to deal with iso_c_binding
395 * trans-types.c (c_interop_kinds_table): new array of structs.
396 (gfc_validate_c_kind): New function.
397 (gfc_check_any_c_kind): Ditto.
398 (get_real_kind_from_node): Ditto.
399 (get_int_kind_from_node): Ditto.
400 (get_int_kind_from_width): Ditto.
401 (get_int_kind_from_minimal_width): Ditto.
402 (init_c_interop_kinds): Ditto.
403 (gfc_init_kinds): call init_c_interop_kinds.
404 (gfc_typenode_for_spec): Adjust for BT_VOID and ISO C Binding pointers.
405 Adjust handling of BT_DERIVED.
406 (gfc_sym_type): Whitespace.
407 (gfc_get_derived_type): Account for iso_c_binding derived types
408 * resolve.c (is_scalar_expr_ptr): New function.
409 (gfc_iso_c_func_interface): Ditto.
410 (resolve_function): Use gfc_iso_c_func_interface.
411 (set_name_and_label): New function.
412 (gfc_iso_c_sub_interface): Ditto.
413 (resolve_specific_s0): Use gfc_iso_c_sub_interface.
414 (resolve_bind_c_comms): New function.
415 (resolve_bind_c_derived_types): Ditto.
416 (gfc_verify_binding_labels): Ditto.
417 (resolve_fl_procedure): Check for ISO C interoperability.
418 (resolve_symbol): Check C interoperability.
419 (resolve_types): Walk the namespace. Check COMMON blocks.
420 * trans-decl.c (gfc_sym_mangled_identifier): Prevent the mangling
421 of identifiers that have an assigned binding label.
422 (gfc_sym_mangled_function_id): Use the binding label rather than
424 (gfc_finish_var_decl): Put variables that are BIND(C) into a common
425 segment of the object file, because this is what C would do.
426 (gfc_create_module_variable): Conver to proper types
427 (set_tree_decl_type_code): New function.
428 (generate_local_decl): Check dummy variables and derived types for
429 ISO C Binding attributes.
430 * match.c (gfc_match_small_int_expr): New function.
431 (gfc_match_name_C): Ditto.
432 (match_common_name): Deal with ISO C Binding in COMMON blocks
433 * trans-io.c (transfer_expr): Deal with C_NULL_PTR or C_NULL_FUNPTR
435 * match.h: Add prototypes for gfc_match_small_int_expr,
436 gfc_match_name_C, match_common_name, set_com_block_bind_c,
437 set_binding_label, set_verify_bind_c_sym,
438 set_verify_bind_c_com_block, get_bind_c_idents,
439 gfc_match_bind_c_stmt, gfc_match_suffix, gfc_match_bind_c,
440 gfc_get_type_attr_spec
441 * parse.c (decode_statement): Use gfc_match_bind_c_stmt
442 (parse_derived): Init *derived_sym = NULL, and gfc_current_block
443 later for valiadation.
444 * primary.c (got_delim): Set ISO C Binding components of ts.
445 (match_logical_constant): Ditto.
446 (match_complex_constant): Ditto.
447 (match_complex_constant): Ditto.
448 (gfc_match_rvalue): Check for existence of at least one arg for
449 C_LOC, C_FUNLOC, and C_ASSOCIATED.
450 * misc.c (gfc_clear_ts): Clear ISO C Bindoing components in ts.
451 (get_c_kind): New function.
453 2007-07-01 Janne Blomqvist <jb@gcc.gnu.org>
456 * trans-expr.c (gfc_conv_power_op): Use builtin_powi for
458 * f95-lang.c (gfc_init_builtin_functions): Add builtin_powi to the
461 2007-07-01 Janne Blomqvist <jb@gcc.gnu.org>
463 * trans.h: Remove decls for 64-bit allocation functions.
464 * trans-array.c (gfc_grow_array): Always pick the standard realloc
466 (gfc_array_allocate): Likewise.
467 * trans-decl.c: Remove trees for 64-bit allocation functions.
468 (gfc_build_builtin_function_decls): Don't build fndecls for 64-bit
469 allocations functions, use index_int_type for normal allocation
472 2007-06-30 Daniel Franke <franke.daniel@gmail.com>
475 * intrinsic.c (add_functions): Additional function types.
476 (gfc_convert_type_warn): Remove intrinsic-flag from
477 conversion functions.
478 * resolve.c (resolve_symbol): Added type checks to
479 explicitly defined intrinsics.
481 2007-06-30 Tobias Burnus <burnus@net-b.de>
484 * io.c (check_format): Allow zero to precede the
487 2007-06-30 Paul Thomas <pault@gcc.gnu.org>
490 * simplify.c (gfc_simplify_repeat): Add handling of character
491 literal for first argument.
493 2007-06-29 Daniel Franke <franke.daniel@gmail.com>
495 * resolve.c (resolve_operator): Added check whether a user
496 defined operator is available.
498 2007-06-29 Daniel Franke <franke.daniel@gmail.com>
500 * openmp.c (resolve_omp_clauses): Adjust error message to
501 better reflect the actual requirement.
503 2007-06-29 Tobias Burnus <burnus@net-b.de>
506 * io.c (format_lex): Fix FMT_ZERO.
507 (check_format,check_format_string,gfc_match_format,
508 check_io_constraints) Additional checking for READ.
510 2007-06-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
513 * lang.opt (static-libgfortran): New option.
514 * gfortranspec.c (ADD_ARG_LIBGFORTRAN): New macro.
515 (Option): Add OPTION_static and OPTION_static_libgfortran.
516 (lookup_option): Handle the new -static-libgfortran option.
517 (lang_specific_driver): Check whether -static is passed.
518 Handle the new -static-libgfortran option.
519 * options.c (gfc_handle_option): If -static-libgfortran is
520 passed and isn't supported on this configuration, error out.
522 2007-06-27 Daniel Franke <franke.daniel@gmail.com>
525 * openmp.c (resolve_omp_clauses): Emit error on allocatable
526 components in COPYIN, COPYPRIVATE, FIRSTPRIVATE and LASTPRIVATE
529 2007-06-25 Paul Thomas <pault@gcc.gnu.org>
532 * resolve.c (check_host_association): Return if the old symbol
533 is use associated. Introduce retval to reduce the number of
534 evaluations of the first-order return value.
537 * match.c (gfc_match_call): If a host associated symbol is not
538 a subroutine, build a new symtree/symbol in the current name
541 2007-06-24 Tobias Burnus <burnus@net-de>
544 * interface.c (gfc_compare_derived_types): Add access check.
545 * symbol.c (gfc_find_component): Ditto.
546 (gfc_set_component_attr,gfc_get_component_attr) Copy access state.
547 * dump-parse-tree.c (gfc_show_components): Dump access state.
548 * gfortran.h (struct gfc_component): Add gfc_access.
549 * module.c (mio_component): Add access state.
550 * (gfc_match_structure_constructor): Check for private access state.
552 2007-06-24 Paul Thomas <pault@gcc.gnu.org>
556 * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc): Calculate
557 the offset between the loop counter and the position as
558 defined. Add the offset within the loop so that the mask acts
559 correctly. Do not advance the location on the basis that it
562 2007-06-22 Daniel Franke <franke.daniel@gmail.com>
565 * symbol.c (gfc_copy_attr): Emit errors for duplicate
566 EXTERNAL/INTRINSIC statements.
568 2007-06-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
571 * expr.c (gfc_check_assign): If the rvalue expression type is NULL_EXPR,
572 check to see if the lvalue has attribute pointer and data.
574 2007-06-21 Jerry DeLisle <jvdelisle@gcc.gnu.org>
577 * resolve.c (gfc_resolve_iterator_expr): Add check for REAL using
578 gfc_notify_standard. (gfc_resolve_iterator): Remove check.
579 (resolve_branch): Change "Obsolete" to "Deleted feature".
580 * io.c (resolve_tag): Ditto.
581 * match.c (gfc_match_pause, gfc_match_assign, gfc_match_goto): Ditto.
583 2007-06-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
586 * match.c (gfc_match_common): If the symbol value expression type is
587 NULL_EXPR, don't error if previously initialized.
589 2007-06-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
592 * decl.c (get_proc_name) Check symbol for generic interface
595 2007-06-20 Andrew Pinski <andrew_pinski@playstation.sony.com>
596 Richard Guenther <rguenther@suse.de>
599 * trans.c (gfc_build_addr_expr): Use the correct types.
601 2007-06-19 Paul Thomas <pault@gcc.gnu.org>
605 * resolve.c (resolve_code): Use gfc_impure_variable as a
606 condition for rejecting derived types with pointers, in pure
608 (gfc_impure_variable): Add test for dummy arguments of pure
609 procedures; any for functions and INTENT_IN for subroutines.
612 * data.c (gfc_assign_data_value): Change the ICE on an array
613 reference initializer not being an array into an error and
614 clear init to prevent a repetition of the error.
616 2007-06-17 Janne Blomqvist <jb@gcc.gnu.org>
618 * gfortran.texi: Add documentation for GFORTRAN_UNBUFFERED_n
619 environment variables. Fix documentation for
620 GFORTRAN_UNBUFFERED_ALL environment variable.
622 2007-06-15 Andrew Pinski <andrew_pinski@playstation.sony.com>
624 * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Use
625 POINTER_PLUS_EXPR instead of PLUS_EXPR for pointer addition.
626 * trans-expr.c (gfc_trans_string_copy): Create
627 POINTER_PLUS_EXPR instead of a PLUS_EXPR
630 2007-06-14 Paul Thomas <pault@gcc.gnu.org>
633 * trans-common.c (build_common_decl): If resizing of common
634 decl is needed, update the TREE_TYPE.
636 2007-06-13 Tobias Burnus <burnus@net-b.de>
639 * interface.c (has_vector_section): New.
640 (compare_actual_formal): Check for array sections with vector subscript.
642 2007-06-12 Dirk Mueller <dmueller@suse.de>
644 * trans-stmt.c (gfc_trans_call): fix gcc_assert to
645 a comparison, not an assignment.
647 2007-06-12 Paul Thomas <pault@gcc.gnu.org>
649 * trans-common.c (create_common): Initialize 'field_init'.
651 2007-06-12 Paul Thomas <pault@gcc.gnu.org>
655 * trans-common.c (get_init_field): New function.
656 (create_common): Call get_init_field for overlapping
657 initializers in equivalence blocks.
658 * resolve.c (resolve_equivalence_derived, resolve_equivalence):
659 Remove constraints on initializers in equivalence blocks.
660 * target-memory.c (expr_to_char, gfc_merge_initializers):
662 (encode_derived): Add the bit offset to the byte offset to get
663 the total offset to the field.
664 * target-memory.h : Add prototype for gfc_merge_initializers.
666 2007-06-11 Rafael Avila de Espindola <espindola@google.com>
668 * trans-types.c (gfc_signed_type): Remove.
669 * trans-types.h (gfc_signed_type): Remove.
670 * f95-lang.c (LANG_HOOKS_SIGNED_TYPE): Remove.
672 2007-06-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
674 * trans-intrinsic.c: Revert Lee's 2007-06-04 patch.
676 2007-06-07 Steven G. Kargl <kargl@gcc.gnu.org>
677 Jerry DeLisle <jvdelisle@gcc.gnu.org>
680 * match.c (gfc_match_special_char): New function. Match special char.
682 * match.h: Add prototype.
683 * io.c (next_char): Use it.
684 * primary.c (next_string_char): Ditto.
686 2007-06-06 Steven G. Kargl <kargl@gcc.gnu.org>
688 * decl.c: Miscellaneous whitespace fixes.
690 * gfortran.h: Likewise.
691 * interface.c : Likewise.
695 * module.c: Likewise.
697 * resolve.c: Likewise.
698 * symbol.c: Likewise.
699 * trans-array.c: Likewise.
700 * trans-common.c: Likewise.
701 * trans-decl.c: Likewise.
702 * trans-intrinsic.c: Likewise.
703 * trans-io.c: Likewise.
704 * trans-stmt.c: Likewise.
705 * trans-types.c: Likewise.
707 2007-06-05 Jerry DeLisle <jvdelisle@gcc.gnu.org>
710 * parse.c (decode_statement): Don't call gfc_undo_symbols on MATCH_ERROR
711 for ST_FUNCTION since it is called in reject_statement.
712 (parse_contained): If error, loop back after reject_statement and try
713 again. Free the namespace if an error occured.
715 2007-06-04 Lee Millward <lee.millward@codesourcery.com>
717 * trans-intrinsic.c (gfc_conv_intrinsic_function_args): Adjust
718 to operate on a stack allocated array for the intrinsic arguments
719 instead of creating a TREE_LIST. Add two new parameters for the
720 array and the number of elements. Update all callers to allocate
721 an array of the correct length to pass in. Update comment.
722 (gfc_intrinsic_argument_list_length): New function.
723 (gfc_conv_intrinsic_mnimax): Call it.
724 (gfc_conv_intrinsic_merge): Likewise.
725 (gfc_conv_intrinsic_lib_function): Call it. Use new CALL_EXPR
727 (gfc_conv_intrinsic_cmplx): Likewise.
728 (gfc_conv_intrinsic_ctime): Likewise.
729 (gfc_covn_intrinsic_fdate): Likewise.
730 (gfc_conv_intrinsic_ttynam): Likewise.
731 (gfc_conv_intrinsic_ishftc): Likewise.
732 (gfc_conv_intrinsic_index): Likewise.
733 (gfc_conv_intrinsic_scan): Likewise.
734 (gfc_conv_intrinsic_verify): Likewise.
735 (gfc_conv_intrinsic_trim): Likewise.
736 (gfc_conv_intrinsic_aint): Use new CALL_EXPR constructors.
737 (gfc_conv_intrinsic_exponent): Likewise.
738 (gfc_conv_intrinsic_bound): Likewise.
739 (gfc_conv_intrinsic_abs): Likewise.
740 (gfc_conv_intrinsic_mod): Likewise.
741 (gfc_conv_intrinsic_sign): Likewise.
742 (gfc_conv_intrinsic_len): Likewise.
743 (gfc_conv_intrinsic_adjust): Likewise.
744 (gfc_conv_intrinsic_si_kind): Likewise.
746 2007-06-04 Steve Ellcey <sje@cup.hp.com>
748 * trans-array.c (gfc_conv_array_parameter): Initialize tmp.
750 2007-05-31 Richard Guenther <rguenther@suse.de>
752 * trans-expr.c (gfc_conv_expr_op): Use zero constant
753 that matches the lse type.
754 (gfc_trans_string_copy): Use sizetype zero constant.
755 * intrinsic.c (add_functions): The sizeof intrinsic has
757 * trans-types.c (gfc_get_dtype): Convert size to index
758 type before shifting.
759 * trans-array.c (gfc_trans_array_constructor_value): Use
760 index type for offset computation.
761 * trans-intrinsic.c (gfc_conv_associated): Use correct type
764 2007-05-31 Paul Thomas <pault@gcc.gnu.org>
767 * trans-array.c (gfc_trans_array_constructor): Treat the case
768 where the ss expression charlen is missing.
770 22007-05-31 Paul Thomas <pault@gcc.gnu.org>
773 * module.c (mio_symtree_ref): If an equivalence group member
774 is not used, give it a hidden symbol and set the pointer_info.
775 (load_equiv): Only free the equivalence if none of the members
778 2007-05-29 Daniel Franke <franke.daniel@gmail.com>
780 * gfortran.h: Renamed 'enum gfc_generic_isym_id' to 'enum gfc_isym_id',
781 added missing GFC_ISYM_* enumerators, ordered alphabetically.
782 (struct gfc_intrinsic_sym): Renamed 'generic_id' to 'id'.
783 (gfc_find_subroutine): New prototype.
784 * intrinsic.c (add_sym, add_sym_*): Added argument 'id' and changed all callers.
785 (find_subroutine): Renamed to 'gfc_find_subroutine', removed static.
786 * dependency.c: Changed usage of isym->generic_id to isym->id.
787 * openmp.c: Likewise.
788 * resolve.c: Likewise.
789 * trans-array.c: Likewise.
790 * trans-expr.c: Likewise.
791 * trans-intrinsic.c: Likewise.
792 * trans-openmp.c: Likewise.
794 2007-05-28 Tobias Schlüter <tobi@gcc.gnu.org>
796 * gfortran.h (gfc_generic_isym_id): Add GFC_ISYM_SIZEOF.
797 * intrinsic.c (add_functions): Add stuff for SIZEOF intrinsic.
798 * intrinsic.h (gfc_check_sizeof): Add prototype of ...
799 * check.c (gfc_check_sizeof): .. new function.
800 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): New function.
801 (gfc_conv_intrinsic_strcmp): Whitespace fix.
802 (gfc_conv_intrinsic_array_transfer): Remove double initialization,
803 use fold_build. where appropriate.
804 (gfc_conv_intrinsic_function): Add case for SIZEOF.
805 * intrinsic.texi: Add documentation for SIZEOF.
807 2007-05-28 Brooks Moses <brooks.moses@codesourcery.com>
809 * trans-array.c (gfc_conv_expr_descriptor): Edit comment.
811 2007-05-28 Brooks Moses <brooks.moses@codesourcery.com>
814 * target-memory.c (gfc_target_expr_size): Add handling
815 for size of BT_HOLLERITH variables.
816 * check.c (gfc_check_transfer): Reject BT_HOLLERITH
817 variables in MOLD argument of TRANSFER.
819 2007-05-28 Brooks Moses <brooks.moses@codesourcery.com>
821 * gfortran.h (gfc_expr): Remove from_H, add "representation"
823 * primary.c (match_hollerith_constant): Store the representation
824 of the Hollerith in representation, not in value.character.
825 * arith.c: Add dependency on target-memory.h.
826 (eval_intrinsic): Remove check for from_H.
827 (hollerith2representation): New function.
828 (gfc_hollerith2int): Determine value of the new constant.
829 (gfc_hollerith2real): Likewise.
830 (gfc_hollerith2complex): Likewise.
831 (gfc_hollerith2logical): Likewise.
832 (gfc_hollerith2character): Point both representation.string and
833 value.character.string at the value string.
834 * data.c (create_character_initializer): For BT_HOLLERITH
835 rvalues, get the value from the representation rather than
837 * expr.c (free_expr0): Update handling of BT_HOLLERITH values
838 and values with representation.string.
839 (gfc_copy_expr): Likewise.
840 * intrinsic.c (do_simplify): Remove special treatement of
841 variables resulting from Hollerith constants.
842 * dump-parse-trees.c (gfc_show_expr): Update handling of
844 * trans-const.c (gfc_conv_constant_to_tree): Replace from_H
845 check with check for representation.string; get Hollerith
846 representation from representation.string, not value.character.
847 * trans-expr.c (is_zero_initializer_p): Replace from_H check
848 with check for representation.string.
849 * trans-stmt.c (gfc_trans_integer_select): Use
850 gfc_conv_mpz_to_tree for case values, so as to avoid picking up
851 the memory representation if the case is given by a transfer
853 * target-memory.c (gfc_target_encode_expr): Use the known memory
854 representation rather than the value, if it exists.
855 (gfc_target_interpret_expr): Store the memory representation of
856 the interpreted expression as well as its value.
857 (interpret_integer): Move to gfc_interpret_integer, make
859 (interpret_float): Move to gfc_interpret_float, make non-static.
860 (interpret_complex): Move to gfc_interpret_complex, make
862 (interpret_logical): Move to gfc_interpret_logical, make
864 (interpret_character): Move to gfc_interpret_character, make
866 (interpret_derived): Move to gfc_interpret_derived, make
868 * target-memory.h: Add prototypes for newly-exported
869 gfc_interpret_* functions.
871 2007-05-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
874 * parse.c (next_statement): Warn for truncated lines if source is free
877 2007-05-27 Paul Thomas <pault@gcc.gnu.org>
878 Tobias Burnus <burnus@net-b.de>
881 * symbol.c (gfc_check_function_type): Copy dimensions of
883 * resolve.c (resolve_contained_fntype): Improve symbol output in
886 2007-05-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
889 * io.c (check_format): Add warning for H specifier in format.
891 2007-05-26 Tobias Burnus <burnus@net-b.de>
893 * gfortran.texi: Document the GFORTRAN_ERROR_DUMPCORE and
894 GFORTRAN_ERROR_BACKTRACE environment variables.
896 2007-05-26 Paul Thomas <pault@gcc.gnu.org>
899 * trans.h : Add no_function_call bitfield to gfc_se structure.
900 Add stmtblock_t argument to prototype of get_array_ctor_strlen.
901 * trans-array.c (get_array_ctor_all_strlen): New function.
902 (get_array_ctor_strlen): Add new stmtblock_t argument and call
903 new function for character elements that are not constants,
905 (gfc_conv_array_parameter): Call get_array_ctor_strlen to get
907 * trans-intrinsic (gfc_conv_intrinsic_len): Add new argument
908 to call of get_array_ctor_strlen.
910 2007-05-25 Kazu Hirata <kazu@codesourcery.com>
912 * intrinsic.texi: Fix typos.
914 2007-05-25 Paul Thomas <pault@gcc.gnu.org>
917 * trans-expr.c (gfc_apply_interface_mapping_to_expr): Change
918 order in logic under EXPR_FUNCTION to handle functions with
921 2007-05-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
924 * array.c (spec_dimen_size): Test for correct BT_INTEGER type.
926 2007-05-23 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
929 * trans-expr.c (gfc_trans_zero_assign): Convert the result of
930 TYPE_SIZE_UNIT into a signed type.
931 (gfc_trans_array_copy): Likewise.
932 (gfc_trans_array_constructor_copy): Likewise.
933 * trans-array.c (gfc_trans_create_temp_array): Likewise.
934 (gfc_grow_array): Likewise.
935 (gfc_array_init_size): Likewise.
936 (gfc_duplicate_allocatable): Likewise.
937 * trans-stmt.c (allocate_temp_for_forall_nest_1): Likewise.
939 2007-05-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
942 * resolve.c (resolve_function): Don't call resolve_global_procedure if
943 there is no name. Delete duplicated statement in ELSE clause.
945 2007-05-22 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
948 * trans-array.c (gfc_trans_array_bound_check): Take extra argument to
949 indicate whether we should check the upper bound in that dimension.
950 (gfc_conv_array_index_offset): Check only the lower bound of the
951 last dimension for assumed-size arrays.
952 (gfc_conv_array_ref): Likewise.
953 (gfc_conv_ss_startstride): Likewise.
955 2007-05-21 Jerry DeLisle <jvdelisle@gcc.gnu.org>
956 Daniel Franke <franke.daniel@gmail.com>
959 * resolve.c (resolve_actual_arglist): Resolve actual argument after
960 being identified as variable.
962 2007-05-21 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
965 * trans-stmt.c (gfc_trans_do): Fix the value of loop variable
968 2007-05-21 H.J. Lu <hongjiu.lu@intel.com>
970 * trans-stmt.c (gfc_trans_do): Fix a typo in comment.
972 2007-05-21 Paul Thomas <pault@gcc.gnu.org>
976 * trans-array.c (gfc_conv_expr_descriptor): Obtain the stored
977 offset for non-descriptor, source arrays and correct for stride
978 not equal to one before writing to field of output descriptor.
980 2007-05-20 Daniel Franke <franke.daniel@gmail.com>
983 * check.c (check_rest): Improved argument conformance check and
984 fixed error message generation.
986 2007-05-19 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
989 * Make-lang.in: Remove use of -Wno-error for expr.o, resolve.o,
990 simplify.o and trans-common.o.
992 2007-05-19 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
995 * trans-array.c (gfc_trans_auto_array_allocation): Avoid
996 multiplication of mismatched types.
998 2007-05-18 Daniel Franke <franke.daniel@gmail.com>
1001 * symbol.c (gfc_add_flavor): Add the NAME to error message if
1004 2007-05-15 Daniel Franke <franke.daniel@gmail.com>
1009 * intrinsic.c (check_specific): Check elemental intrinsics for
1011 (add_functions): Fixed dummy argument names of BESJN and BESYN.
1012 Fixed elemental status of MCLOCK and MCLOCK8.
1013 * check.c (check_rest): Added check for array conformance.
1014 (gfc_check_merge): Removed check for array conformance.
1015 (gfc_check_besn): Removed check for scalarity.
1016 * intrinsic.texi (CSHIFT, EOSHIFT): Fixed typos.
1017 (BESJN, BESYN): Clarified documentation.
1019 2007-05-17 Tobias Burnus <burnus@net-b.de>
1021 * gfortran.texi (GFORTRAN_CONVERT_UNIT): Improve documentation.
1023 2007-05-16 Brooks Moses <brooks.moses@codesourcery.com>
1030 * target-memory.c: New file.
1031 * target-memory.h: New file.
1032 * simplify.c: Add #include "target-memory.h".
1033 (gfc_simplify_transfer): Implement constant-
1034 folding for TRANSFER intrinsic.
1035 * Make-lang.in: Add dependencies on new target-memory.* files.
1037 2007-05-15 Paul Brook <paul@codesourcery.com>
1039 * trans-types.c (gfc_type_for_size): Handle signed TImode.
1041 2007-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1044 * trans.h (gfor_fndecl_internal_malloc, gfor_fndecl_internal_malloc64,
1045 gfor_fndecl_internal_free): Remove prototypes.
1046 (gfor_fndecl_os_error, gfc_call_free, gfc_call_malloc): Add prototypes.
1047 * trans.c (gfc_call_malloc, gfc_call_free): New functions.
1048 * f95-lang.c (gfc_init_builtin_functions): Add __builtin_free
1049 and __builtin_malloc builtins.
1050 * trans-decl.c (gfor_fndecl_internal_malloc,
1051 gfor_fndecl_internal_malloc64, gfor_fndecl_internal_free): Remove.
1052 (gfor_fndecl_os_error): Add.
1053 (gfc_build_builtin_function_decls): Don't create internal_malloc,
1054 internal_malloc64 and internal_free library function declaration.
1055 Create os_error library call function declaration.
1056 * trans-array.c (gfc_trans_allocate_array_storage,
1057 gfc_trans_auto_array_allocation, gfc_trans_dummy_array_bias,
1058 gfc_conv_array_parameter, gfc_duplicate_allocatable): Use
1059 gfc_call_malloc and gfc_call_free instead of building calls to
1060 internal_malloc and internal_free.
1061 * trans-expr.c (gfc_conv_string_tmp): Likewise.
1062 * trans-stmt.c (gfc_do_allocate, gfc_trans_assign_need_temp,
1063 gfc_trans_pointer_assign_need_temp, gfc_trans_forall_1,
1064 gfc_trans_where_2: Likewise.
1065 * trans-intrinsic.c (gfc_conv_intrinsic_ctime,
1066 gfc_conv_intrinsic_fdate, gfc_conv_intrinsic_ttynam,
1067 gfc_conv_intrinsic_array_transfer, gfc_conv_intrinsic_trim): Likewise.
1069 2007-05-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1072 * trans-expr.c (gfc_conv_substring): Evaluate substring bounds
1075 2007-05-14 Rafael Avila de Espindola <espindola@google.com>
1077 * f95-lang.c (LANG_HOOKS_UNSIGNED_TYPE): Remove.
1078 * trans-intrinsic.c (gfc_conv_intrinsic_ishft): Use unsigned_type_for
1079 instead of gfc_unsigned_type.
1080 * trans-stmt.c (gfc_trans_do): Use unsigned_type_for instead of
1082 * trans-types.c (gfc_unsigned_type): Remove.
1083 * trans-types.h (gfc_unsigned_type): Remove.
1085 2007-05-12 Paul Thomas <pault@gcc.gnu.org>
1088 * resolve.c (check_host_association): New function that detects
1089 incorrect host association and corrects it.
1090 (gfc_resolve_expr): Call the new function for variables and
1092 * match.h : Remove prototype for gfc_match_rvalue.
1093 * gfortran.h : Add prototype for gfc_match_rvalue.
1095 2007-05-11 Paul Thomas <pault@gcc.gnu.org>
1098 * trans-expr.c (gfc_conv_function_call): Reduce indirection for
1099 direct assignments of recursive array valued functions.
1100 * primary.c (gfc_match_rvalue): Correct error for recursive
1101 function calls such that directly recursive calls of scalar
1102 function without an explicit result are disallowed.
1104 2007-05-11 Paul Thomas <pault@gcc.gnu.org>
1107 * resolve.c (resolve_fl_namelist): It is not an error if the
1108 namelist element is the result variable of the enclosing
1109 function. Search for the symbol in current and all parent
1110 namespaces for a potential conflict.
1111 * symbol.c (check_conflict): Remove the conflict between
1112 'in_namelist' and 'FL_PROCEDURE' because the symbol info
1113 is not available to exclude function result variables.
1114 * trans-io.c (nml_get_addr_expr): Use the fake result decl
1115 if the symbol is an implicit result variable.
1117 2007-05-11 Paul Thomas <pault@gcc.gnu.org>
1120 * decl.c (get_proc_name): If an entry has already been declared
1121 as a module procedure, pick up the symbol and the symtree and
1122 use them for the entry.
1124 2007-05-08 Paul Thomas <pault@gcc.gnu.org>
1127 * resolve.c (resolve_symbol): Remove the flagging mechanism from the
1128 formal namespace resolution and instead check that the formal
1129 namespace is not the current namespace.
1131 2007-05-08 Paul Thomas <pault@gcc.gnu.org>
1134 * trans-array.c (gfc_conv_array_parameter): Convert full array
1135 references to the result of the procedure enclusing the call.
1137 2007-05-08 Paul Thomas <pault@gcc.gnu.org>
1141 * decl.c (add_init_expr_to_sym): Expand a scalar initializer
1142 for a parameter array into an array expression with the right
1144 * array.c (spec_dimen_size): Remove static attribute.
1145 * gfortran.h : Prototype for spec_dimen_size.
1147 2007-05-07 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1150 * trans-stmt.c (gfc_trans_do): Handle large loop counts.
1152 2007-05-07 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1155 * simplify.c (gfc_simplify_new_line): NEW_LINE can be simplified
1156 even for non constant arguments.
1158 2007-05-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1159 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1162 * gfortran.h: Add runtime error codes from libgfortran.h. Define
1164 * trans.c (gfc_trans_runtime_check): Update the format of runtime error
1165 messages to match library runtime errors. Use call to new library
1166 function runtime_error_at().
1167 * trans.h: Add prototype for new function gfc_trans_io_runtime_check.
1168 Add declaration for library functions runtime_error_at and
1170 * trans_io.c (gfc_trans_io_runtime_check): New function.
1171 (set_parameter_value): Add error checking for UNIT numbers.
1172 (set_parameter_ref): Initialize the users variable to zero.
1173 (gfc_trans_open): Move setting of unit number to after setting of common
1174 flags so that runtime error trapping can be detected.
1175 (gfc_trans_close): Likewise. (build_filepos): Likewise.
1176 (gfc_trans_inquire): Likewise. (build_dt): Likewise.
1177 * trans-decl.c: Add declarations for runtime_error_at and
1178 generate_error. (gfc_build_builtin_function_decls): Build function
1179 declarations for runtime_error_at and generate_error.
1181 2007-05-06 Paul Thomas <pault@gcc.gnu.org>
1184 * resolve.c (resolve_fl_procedure): Resolve constant character
1187 2007-05-05 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1190 * decl.c (match_char_spec): Add check for invalid character lengths.
1192 2007-05-04 Brooks Moses <brooks.moses@codesourcery.com>
1194 * intrinsic.texi (CMPLX): Document result kind.
1195 (COMPLEX): Add documentation.
1197 2007-05-04 Daniel Franke <franke.daniel@gmail.com>
1200 * intrinsic.c (add_functions): Replaced calls to gfc_check_g77_math1
1201 by gfc_check_fn_r to avoid checks for scalarity.
1202 * check.c (gfc_check_besn): Removed check for scalarity.
1203 (gfc_check_g77_math1): Removed.
1204 * intrinsic.h (gfc_check_g77_math1): Removed.
1206 2007-05-04 Daniel Franke <franke.daniel@gmail.com>
1208 * check.c (gfc_check_fseek_sub): Fixed typo.
1210 2007-05-04 Daniel Franke <franke.daniel@gmail.com>
1213 * intrinsic.c (add_subroutines): Added FSEEK.
1214 * intrinsic.h (gfc_resolve_fseek_sub, gfc_check_fseek_sub): New.
1215 * iresolve.c (gfc_resolve_fseek_sub): New.
1216 * check.c (gfc_check_fseek_sub): New.
1217 * intrinsic.texi (FSEEK): Updated.
1219 2007-05-04 Tobias Burnus <burnus@net-b.de>
1222 * expr.c (gfc_check_pointer_assign): Check for NULL pointer.
1224 2007-05-04 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1227 * simplify.c (gfc_simplify_len): Only simplify integer lengths.
1229 2007-05-04 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1232 * simplify.c (gfc_simplify_repeat): Don't put function call with
1233 side effect in a gcc_assert().
1235 2007-05-04 Tobias Burnus <burnus@net-b.de>
1238 * interface.c (compare_actual_formal): Check character length.
1240 2007-05-01 Thomas Koenig <tkoenig@gcc.gnu.org>
1243 * dependency.c (gfc_full_array_ref_p): If the reference is
1244 to a single element, check that the array has a single
1245 element and that the correct element is referenced.
1247 2007-05-01 Daniel Franke <franke.daniel@gmail.com>
1249 * intrinsic.c (add_functions): Fixed ELEMENTAL specifications.
1250 (add_subroutines): Replaced magic numbers in function calls by
1251 ELEMENTAL and NOT_ELEMENTAL respectively.
1252 * intrinsic.texi (MVBITS): Changed class to elemental subroutine.
1253 (RANDOM_NUMBER): Changed class to subroutine.
1254 (HUGE, TINY): Changed class to inquiry function.
1256 2007-04-30 Brooks Moses <brooks.moses@codesourcery.com>
1258 * trans-const.c (gfc_conv_mpz_to_tree): Use mpz_get_double_int.
1259 (gfc_conv_tree_to_mpz): New function.
1260 (gfc_conv_mpfr_to_tree): Use real_from_mpfr.
1261 (gfc_conv_tree_to_mpfr): New function.
1262 * trans-const.h: (gfc_conv_tree_to_mpz): New prototype.
1263 (gfc_conv_tree_to_mpfr): New prototype.
1265 2007-04-30 Daniel Franke <franke.daniel@gmail.com>
1267 * intrinsic.texi (IERRNO): Changed class to non-elemental function.
1268 (LOG10): Removed COMPLEX as accepted argument type.
1269 (NEW_LINE): Changed class from elemental to inquiry function.
1270 (SIGN): Removed requirement of scalar arguments.
1271 (SNGL): Changed class to elemental function.
1273 2007-04-29 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1276 * simplify.c (simplify_bound_dim): New function.
1277 (simplify_bound): Use the above. Perform simplification of LBOUND
1278 and UBOUND when DIM argument is not present.
1280 2007-04-29 Daniel Franke <franke.daniel@gmail.com>
1282 * gfortran.texi: Cleaned up keyword index.
1283 * invoke.texi: Likewise.
1284 * intrinsic.texi: Likewise.
1286 2007-04-29 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1289 * scanner.c (load_file): Discard the byte order mark if one is
1290 found on the first non-preprocessor line of a file.
1292 2007-04-29 Paul Thomas <pault@gcc.gnu.org>
1295 * trans-array.c (gfc_conv_resolve_dependencies): Create a temp
1296 whenever a dependency is found.
1298 2007-04-28 Tobias Schlüter <tobi@gcc.gnu.org>
1300 * options.c (gfc_handle_option): Ensure requested free form line
1301 length is not too small.
1303 2007-04-27 Brooks Moses <brooks.moses@codesourcery.com>
1305 * intrinsic.texi (Transfer): Improve documentation.
1307 2007-04-27 Brooks Moses <brooks.moses@codesourcery.com>
1309 * gfortran.texi (Option Index): Add @samp as needed.
1311 2007-04-27 Daniel Franke <franke.daniel@gmail.com>
1313 * gfortran.texi: Added node and menu entry for an option index.
1314 * invoke.texi: Moved command line option related entries of the concept
1315 index to the option index.
1317 2007-04-27 Daniel Franke <franke.daniel@gmail.com>
1319 * intrinsic.texi (AND, FPUT, FPUTC, MODULO, OR, SET_EXPONENT,
1320 XOR): Fixed examples.
1322 2007-04-27 Daniel Franke <franke.daniel@gmail.com>
1324 * intrinsic.texi (PRODUCT, RESHAPE, SPACING, SPREAD, SUM,
1325 SYSTEM_CLOCK, TRANSFER, UNPACK): New.
1326 (DATE_AND_TIME, CPU_TIME, RRSPACING): Added cross references.
1328 2007-04-26 Daniel Franke <franke.daniel@gmail.com>
1330 * intrinsic.texi (NULL, PACK, PRESENT, REPEAT, SCAN, SHAPE,
1331 SIZE, TRANSPOSE, TRIM, VERIFY): New.
1332 (ADJUSTL, ADJUSTR, INDEX): Added cross references.
1333 (INT, INT2, INT8, LONG): Enabled section header.
1335 2007-04-25 Janne Blomqvist <jb@gcc.gnu.org>
1337 * module.c (module_char): Replace fgetc() with
1339 (write_char): Replace fputc() with putc().
1340 * scanner.c (load_line): Replace fgetc() with getc().
1341 (gfc_read_orig_filename): Likewise.
1343 2007-04-25 Tobias Burnus <burnus@net-b.de>
1346 * error.c (error_print): Fix %% support.
1347 * intrinsic.c (sort_actual): Improve error message.
1348 * resolve.c (resolve_actual_arglist): Allow %VAL for
1349 interfaces defined in the module declaration part.
1351 2007-04-25 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1354 * intrinsic.texi (GETLOG): Update documentation to reflect
1357 2007-04-24 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1360 * module.c (write_char): Add character to the MD5 buffer.
1361 (read_md5_from_module_file): New function.
1362 (gfc_dump_module): Compute MD5 for new module file. Call
1363 read_md5_from_module_file. Only overwrite old module file
1364 if the new MD5 is different.
1366 2007-04-23 Paul Thomas <pault@gcc.gnu.org>
1369 * resolve.c (resolve_symbol): Allow resolution of formal
1370 namespaces nested within formal namespaces coming from modules.
1373 * trans-expr.c (gfc_trans_assignment): Make the call to
1374 gfc_trans_zero_assign conditional on the lhs array ref being
1377 2007-04-23 Tobias Burnus <burnus@net-b.de>
1379 * primary.c (match_integer_constant): Mention -fno-range-check
1380 in the error message.
1382 2007-04-21 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1385 * scanner.c (load_line): Remove check for comment after ampersand and
1386 adjust tracking of ampersand.
1388 2007-04-21 Andrew Pinski <andrew_pinski@playstation.sony.com>
1390 * f95-lang.c (lang_tree_node): Use GENERIC_NEXT
1391 instead of checking GIMPLE_STMT_P in chain_next.
1393 2007-04-17 Tobias Schlüter <tobi@gcc.gnu.org>
1395 * trans-types.h (gfc_packed): New enum.
1396 (gfc_get_nodesc_array_type): Change prototype to use new enum.
1397 * trans-types.c (gfc_get_nodesc_array): Use gfc_packed for
1398 argument packed. Adapt all references to values accordingly.
1399 (gfc_sym_type): Use enum values in call to gfc_get_nodesc_array.
1400 (gfc_get_derived_type): Likewise.
1401 * trans-array.c (gfc_build_constant_array_constructor): Likewise.
1402 * trans-expr.c (gfc_get_interface_mapping_charlen): Changed packed
1403 argument to type gfc_packed.
1404 (gfc_add_interface_mapping): Use enum values in call to
1405 gfc_get_interface_mapping.
1406 * trans-decl.c (gfc_build_dummy_array_decl): Adapt to use enum
1407 values when determining packing.
1409 * trans-decl.c (gfc_finish_decl): Remove unused second argument
1410 'init'. Simplify code accordingly. Remove calls to
1411 gfc_fatal_error in favor of gcc_assert.
1412 (create_function_arglist): Remove second argument from calls to
1414 (gfc_trans_dummy_character): Likewise.
1416 * arith.h: Update copyright years.
1417 * dependency.h: Likewise.
1418 * gfortran.h: Likewise.
1419 * lang-specs.h: Likewise.
1420 * parse.h: Likewise.
1421 * symbol.c: Likewise.
1422 * trans.h: Likewise.
1423 * trans.c: Likewise.
1424 * trans-array.c: Likewise.
1425 * trans-common.c: Likewise.
1426 * trans-const.h: Likewise.
1427 * trans-const.c: Likewise.
1428 * trans-decl.c: Likewise.
1429 * trans-expr.c: Likewise.
1430 * trans-io.c: Likewise.
1431 * trans-openmp.c: Likewise.
1432 * trans-types.h: Likewise.
1433 * types.def: Likewise.
1435 2007-04-17 Tobias Schlüter <tobi@gcc.gnu.org>
1438 * decl.c (gfc_sym_mangled_identifier): Use capital letters in name
1440 (gfc_sym_mangled_function_id): Likewise.
1442 2007-04-15 Paul Thomas <pault@gcc.gnu.org>
1445 * primary.c (check_for_implicit_index): New function to check
1446 that a host associated variable is not an undeclared implied
1448 (gfc_match_rvalue, match_variable): Use it and reset the
1449 implied_index attribute.
1450 * gfortran.h : Add the implied_index field to symbol_attribute.
1451 * match.c (gfc_match_iterator): Mark the iterator variable
1452 with the new attribute.
1453 * decl.c (build_sym): Reset the new attribute.
1455 2007-04-15 Kazu Hirata <kazu@codesourcery.com>
1457 * gfc-internals.texi: Fix typos.
1458 * simplify.c: Fix a comment typo.
1460 2007-04-14 Bernhard Fischer <aldot@gcc.gnu.org>
1462 * primary.c: Commentary typo fix; Add question about redundant (?)
1465 2007-04-14 Paul Thomas <pault@gcc.gnu.org>
1469 * expr.c (scalarize_intrinsic_call): New function to
1470 scalarize elemental intrinsic functions in initialization
1472 (check_init_expr): Detect elemental intrinsic functions
1473 in initalization expressions and call previous.
1475 2007-04-13 Tobias Burnus <burnus@net-b.de>
1478 * primary.c (match_variable): External functions
1481 2007-04-13 Paul Thomas <pault@gcc.gnu.org>
1484 * trans-types.c (copy_dt_decls_ifequal): Do not get pointer
1485 derived type components.
1487 2007-04-13 Tobias Schlüter <tobi@gcc.gnu.org>
1490 * resolve.c: Include obstack.h and bitmap.h. New variable
1492 (code_stack): Add tail and reachable_labels fields.
1493 (reachable_labels): New function.
1494 (resolve_branch): Rework to use new fields in code_stack.
1495 (resolve_code): Call reachable_labels.
1496 (resolve_codes): Allocate and free labels_obstack.
1498 2007-04-12 Tobias Schlüter <tobi@gcc.gnu.org>
1501 * decl.c (match_char_spec): Move check for negative CHARACTER
1503 * resolve.c (resolve_charlen): ... here.
1504 (resolve_types): Resolve CHARACTER lengths earlier.
1506 2007-04-12 Daniel Franke <franke.daniel@gmail.com>
1509 * intrinsic.texi (RANDOM_SEED, RANDOM_NUMBER): New.
1511 2007-04-12 Tobias Schlüter <tobi@gcc.gnu.org>
1514 * primary.c (gfc_variable_attr): Don't copy string length if it
1516 * resolve.c (resolve_code): Clarify error message.
1519 * decl.c (gfc_match_end): Also check for construct name in END
1520 FORALL and END WERE statements.
1521 * match.c (match_case_eos): Use uppercase for statement name in
1523 (match_elsewhere): Construct name may appear iff construct has a
1526 * trans-types.c: Update copyright years. Reformat long comment
1527 explaining array descriptor format. Remove obsolete mention of
1530 * arith.c (gfc_arith_uplus): Rename to ...
1531 (gfc_arith_identity): ... this.
1532 (gfc_parentheses): New function.
1533 (gfc_uplus): Adapt to renamed function.
1534 * arith.h (gfc_parentheses): Add prototype.
1535 * expr.c (gfc_copy_expr): Deal with INTRINSIC_PARENTHESES.
1536 (simplifiy_intrinsic_op): Treat INTRINSIC_UPLUS separately from
1537 INTRINSIC_PARENTHESES.
1539 2007-04-12 Tobias Burnus <burnus@net-b.de>
1542 * decl.c (match_attr_spec): Allow PRIVATE/PUBLIC
1543 attribute in type definitions.
1544 (gfc_match_private): Allow PRIVATE statement only
1545 in specification part of modules.
1546 (gfc_match_public): Ditto for PUBLIC.
1547 (gfc_match_derived_decl): Allow PRIVATE/PUBLIC attribute only in
1548 specificification part of modules.
1550 2007-04-07 Paul Thomas <pault@gcc.gnu.org>
1553 * intrinsic.c (add_functions): Add ref. to gfc_resolve_achar.
1554 * intrinsic.h : Add prototype for gfc_resolve_achar.
1555 * iresolve.c (gfc_resolve_achar): New function.
1557 2007-04-07 Paul Thomas <pault@gcc.gnu.org>
1560 * resolve.c (resolve_fl_variable): Set flag to 2 for automatic
1561 arrays. Make condition for automatic array error explicit.
1562 If a dummy, no error on an INTENT(OUT) derived type.
1564 2007-04-07 Paul Thomas <pault@gcc.gnu.org>
1567 * expr.c (find_array_element): Correct arithmetic for rank > 1.
1569 2007-04-07 Paul Thomas <pault@gcc.gnu.org>
1572 * check.c (numeric_check): If an expresson has not got a type,
1573 see if it is a symbol for which a default type applies.
1575 2007-04-07 Paul Thomas <pault@gcc.gnu.org>
1578 * trans-decl.c (gfc_get_symbol_decl): Allow unreferenced use
1581 2007-04-07 Paul Thomas <pault@gcc.gnu.org>
1584 * symbol.c (gfc_check_function_type): New function.
1585 * gfortran.h : Add prototype for previous.
1586 * parse.c (parse_progunit): Call it after parsing specification
1589 2007-04-05 Paul Thomas <pault@gcc.gnu.org>
1592 * trans-expr.c (gfc_conv_function_call): Give a dummy
1593 procedure the correct type if it has alternate returns.
1595 2007-04-05 Paul Thomas <pault@gcc.gnu.org>
1598 * decl.c (gfc_match_modproc): Go up to the top of the namespace
1599 tree to find the module namespace for gfc_get_symbol.
1601 2007-04-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1604 * fortran/gfortran.h (gfc_charlen_int_kind): New prototype.
1605 * fortran/trans-types.c (gfc_charlen_int_kind): New variable.
1606 (gfc_init_types): Define gfc_charlen_int_kind.
1607 * fortran/trans.h (gfor_fndecl_string_repeat): Remove prototype.
1608 * fortran/trans-decl.c (gfor_fndecl_string_repeat): Delete.
1609 (gfc_build_intrinsic_function_decls): Don't set
1610 gfor_fndecl_string_repeat.
1611 * fortran/trans-intrinsic.c (gfc_conv_intrinsic_repeat): Rewrite
1612 so that we don't have to call a library function.
1613 * fortran/simplify.c (gfc_simplify_repeat): Perform the necessary
1614 checks on the NCOPIES argument, and work with arbitrary size
1617 2007-03-31 Tobias Burnus <burnus@net-b.de>
1619 * intrinsic.c (add_functions): Fix name of dummy argument
1620 for new_line and exit intrinsic.
1622 2007-03-31 Paul Thomas <pault@gcc.gnu.org>
1625 * gfortran.texi: Add a section for the %VAL, %REF and %LOC
1628 2007-03-30 Rafael Avila de Espindola <espindola@google.com>
1630 * trans-types.c (gfc_signed_or_unsigned_type): Remove.
1631 (gfc_unsigned_type): Use get_signed_or_unsigned_type instead of
1632 gfc_signed_or_unsigned_type.
1633 (gfc_signed_type): Ditto.
1634 * trans-types.h (gfc_signed_or_unsigned_type): Remove.
1635 * f95-lang.c (LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): Remove.
1637 2007-03-30 Tobias Schlüter <tobi@gcc.gnu.org>
1639 * symbol.c (gfc_find_gsymbol): Simplify, don't unconditionally
1640 descend into all branches.
1642 2007-03-29 Tobias Schlüter <tobi@gcc.gnu.org>
1644 * intrinsic.c (conv_name): Let gfc_get_string handle the format.
1645 (find_conv): Compare pointers instead of calling strcmp.
1646 (find_sym): Likewise, but ensure that the compared pointer is in
1647 the global string table.
1649 2007-03-28 Tobias Schlüter <tobi@gcc.gnu.org>
1651 * gfc-internals.texi: Fix output filename. Merge type index into
1652 concept index. Start documentation of gfc_code structure.
1654 2007-03-26 Brooks Moses <brooks.moses@codesourcery.com>
1656 * gfc-internals.texi: New file,
1657 * Make-lang.in: Add rules to convert it to dvi, pdf, and info.
1659 2007-03-26 Brooks Moses <brooks.moses@codesourcery.com>
1661 * error.c (show_locus): Remove always-false test.
1663 2007-03-26 Brooks Moses <brooks.moses@codesourcery.com>
1665 * lang.opt: Minor edits to descriptions.
1667 2007-03-25 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1670 * fortran/interface.c (check_operator_interface): Implement
1671 the standard checks on user operators extending intrinsic operators.
1672 * fortran/resolve.c (resolve_operator): If the ranks of operators
1673 don't match, don't error out but try the user-defined ones first.
1675 2007-03-24 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1678 * expr.c (check_dimension): Fix logic of comparisons.
1680 2007-03-24 Paul Thomas <pault@gcc.gnu.org>
1683 * trans-expr.c (gfc_apply_interface_mapping_to_expr): Return
1684 int result that is non-zero if the expression is the function
1685 result. Only the characteristics of the result expression
1686 can be used in a procedure interface, so simplify LEN in situ
1687 using its character length.
1691 * trans-expr.c (gfc_conv_function_call): Do not use
1692 gfc_conv_expr_reference for actual pointer function with formal
1693 target because a temporary is created that does not transfer
1694 the reference correctly. Do not indirect formal pointer
1695 functions since it is the function reference that is needed.
1697 2007-03-24 Brooks Moses <brooks.moses@codesourcery.com>
1699 * gfortran.h: Edit comments on GFC_STD_*.
1701 2007-03-23 Brooks Moses <brooks.moses@codesourcery.com>
1703 * invoke.texi: Misc. small typo fixes.
1704 (-Wcharacter-truncation): Add.
1705 (-Wnonstd-intrinsics): Correct spelling.
1707 (-fintrinsic-modules-path): Add.
1709 2007-03-23 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1712 * arith.c (complex_pow): Rewrite to handle large power.
1713 (gfc_arith_power): Handle large power in the real and integer
1716 2007-03-22 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1719 * trans-const.c (gfc_conv_mpz_to_tree): Allow integer constants
1720 larger than twice the width of a HOST_WIDE_INT.
1722 2006-03-22 Paul Thomas <pault@gcc.gnu.org>
1725 * trans-intrinsic.c (gfc_size_in_bytes): Remove function.
1726 (gfc_conv_intrinsic_array_transfer): Remove calls to previous.
1727 Explicitly extract TREE_TYPEs for source and mold. Use these
1728 to calculate length of source and mold, except for characters,
1729 where the se string_length is used. For mold, the TREE_TYPE is
1730 recalculated using gfc_get_character_type_len so that the
1731 result is correctly cast for character literals and substrings.
1732 Do not use gfc_typenode_for_spec for the final cast.
1734 2007-03-22 Tobias Schlüter <tobi@gcc.gnu.org>
1737 * decl.c (gfc_match_derived_decl): Reliably reject
1738 'doubleprecision' and 'doublecomplex' as type names.
1740 2007-03-19 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1743 * trans-expr.c (gfc_trans_init_string_length): Length should
1745 (gfc_conv_function_call): Likewise.
1747 2007-03-18 Paul Thomas <pault@gcc.gnu.org>
1751 * symbo.c : Add gfc_derived_types.
1752 (gfc_free_dt_list): Free derived type list gfc_derived_types.
1753 (gfc_free_namespace): Remove call to gfc_free_dt_list.
1754 (gfc_symbol_done_2): Call gfc_free_dt_list.
1755 * gfortran.h : Declare gfc_derived_types to be external. Remove
1756 derived types field from gfc_namespace.
1757 * resolve.c (resolve_fl_derived): Refer to gfc_derived types
1758 rather than namespace derived_types.
1759 (resolve_fntype): Remove special treatment for module
1760 derived type functions.
1761 * trans-types.c (gfc_get_derived_type): Remove search for like
1762 derived types. Finish by copying back end declaration to like
1763 derived types in the derived type list gfc_derived_types.
1765 2007-03-17 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1768 * trans-expr.c (gfc_conv_powi): Make n argument unsigned hwi.
1769 (gfc_conv_cst_int_power): Handle integer exponent with care,
1770 since it might be too large for us.
1772 2007-03-17 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1775 * invoke.texi: Fix typo.
1777 2007-03-16 Tobias Burnus <burnus@net-b.de>
1779 * trans-decl.c (gfc_generate_function_code): Use all arguments of
1782 2007-03-15 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1784 * gfortran.h (gfc_option_t): Add flag_backtrace field.
1785 * lang.opt: Add -fbacktrace option.
1786 * invoke.texi: Document the new option.
1787 * trans-decl.c (gfc_build_builtin_function_decls): Add new
1788 option to the call to set_std.
1789 * options.c (gfc_init_options, gfc_handle_option): Handle the
1792 2007-03-15 Tobias Burnus <burnus@gcc.gnu.org>
1793 Paul Thomas <pault@gcc.gnu.org>
1796 * decl.c (gfc_match_import): If the parent of the current name-
1797 space is null, try looking for an imported symbol in the parent
1798 of the proc_name interface.
1799 * resolve.c (resolve_fl_variable): Do not check for blocking of
1800 host association by a same symbol, if the symbol is in an
1803 2007-03-15 Paul Thomas <pault@gcc.gnu.org>
1806 * decl.c (match_data_constant): Before going on to try to match
1807 a name, try to match a structure component.
1811 * resolve.c (resolve_actual_arglist): Do not reject a generic
1812 actual argument if it has a same name specific interface.
1815 * trans-array.c (parse_interface): Do not nullify allocatable
1816 components if the symbol has the saved attribute.
1818 2007-03-14 Francois-Xavier Coudert <coudert@clipper.ens.fr>
1820 * trans-array.c (gfc_trans_auto_array_allocation): Replace
1821 fold(convert()) by fold_convert().
1822 (gfc_duplicate_allocatable): Likewise.
1823 * trans-intrinsic.c (gfc_conv_intrinsic_dot_product): Use
1824 build_int_cst instead of converting an integer_zero_node
1827 2007-03-14 Jakub Jelinek <jakub@redhat.com>
1829 * module.c (mio_typespec): Don't look at ts->cl if not BT_CHARACTER.
1831 2007-03-13 Brooks Moses <brooks.moses@codesourcery.com>
1836 * intrinsics.texi (CHDIR): Fix argument names, note
1837 that STATUS must be a default integer.
1838 (CTIME): Fix argument names, note that RESULT must
1839 be a default integer.
1840 (EXIT): Note that STATUS must be a default integer.
1842 2007-03-13 Brooks Moses <brooks.moses@codesourcery.com>
1845 * intrinsic.texi: General whitespace cleanup, remove
1846 comment about missing intrinsics.
1847 (menu): Add lines for new entries listed below.
1848 (ACOSH): Mention specific function DACOSH, correct
1849 description phrasing.
1850 (ASINH): Mention specific function DASINH, correct
1851 description phrasing.
1852 (ATANH): Mention specific function DATANH, correct
1853 description phrasing.
1854 (COS): Add index entry for CCOS.
1855 (CPU_TIME): Correct "REAL" to "REAL(*)".
1856 (EXP): Add index entry for CEXP.
1857 (INT): Correct argument name to "A".
1861 (MAX): Add index entries for specific variants.
1862 (MCLOCK): New entry.
1863 (MCLOCK8): New entry.
1864 (SECNDS): Adjust to a more standard form.
1865 (SECOND): New entry.
1866 (TIME): Add cross-reference to MCLOCK.
1867 (TIME8): Add cross-reference to MCLOCK8.
1869 2007-03-11 Paul Thomas <pault@gcc.gnu.org>
1872 * parse.c (parse_interface): Use the default types from the
1873 formal namespace if a function or its result do not have a type
1874 after parsing the specification statements.
1876 2007-03-08 Brooks Moses <brooks.moses@codesourcery.com>
1878 * intrinsic.texi: (ICHAR) Improve internal I/O note.
1879 (ACHAR): Reference it.
1880 (CHAR): Reference it.
1881 (IACHAR): Reference it.
1883 2007-03-08 Brooks Moses <brooks.moses@codesourcery.com>
1885 * intrinsic.texi: (LINK) Document function form.
1891 2007-03-08 Brooks Moses <brooks.moses@codesourcery.com>
1893 * intrinsic.texi: minor typo fixes, removed prologue.
1894 (FSEEK): moved to correct place in alphabetical order.
1896 2007-03-08 Daniel Franke <franke.daniel@gmail.com>
1899 * check.c (gfc_check_alarm_sub): Added check for default integer
1900 kind of status argument.
1901 * iresolve.c (gfc_resolve_alarm_sub): Removed conversion of
1903 * intrinsic.texi (ALARM): Extended documentation.
1905 2007-03-08 Daniel Franke <franke.daniel@gmail.com>
1907 * intrinsic.texi (GERROR, ISATTY, TTYNAM): New.
1908 (ABORT, FLUSH, FNUM, IRAND, MALLOC, SIGNAL, SRAND): Fixed typo.
1909 * intrinsic.c (add_subroutines): Adjusted dummy argument names
1910 of GERROR and TTYNAM.
1912 2007-07-08 Tobias Burnus <burnus@net-b.de>
1914 * module.c (gfc_match_use): Support renaming of operators
1916 * gfortran.texi (Fortran 2003 Status): Document support of
1917 renaming of operators.
1919 2007-07-08 Tobias Burnus <burnus@net-b.de>
1922 * module.c (read_module): Always import module name as symbol.
1923 (gfc_match_use): Disallow module name in the only clause of
1926 2007-03-08 Paul Thomas <pault@gcc.gnu.org>
1929 * expr.c (find_array_section): Correct arithmetic for section
1932 2007-03-07 Brooks Moses <brooks.moses@codesourcery.com>
1934 * iresolve.c (gfc_resolve_ishftc): Correct s_kind value.
1936 2007-03-06 Daniel Franke <franke.daniel@gmail.com>
1938 PR documentation/30950
1939 * intrinsic.texi (AND, CPU_TIME): Fix dummy argument names.
1940 (FREE): Fix call syntax.
1942 2007-03-06 Brooks Moses <brooks.moses@codesourcery.com>
1944 * intrinsic.texi: Limit column widths to a total of .85.
1946 2007-03-05 Brooks Moses <brooks.moses@codesourcery.com>
1948 * gfortran.texi (GFortran and G77): Rewrite completely.
1950 2007-03-05 Brooks Moses <brooks.moses@codesourcery.com>
1952 * match.c (gfc_match_name): Expanded comment.
1954 2007-03-05 Brooks Moses <brooks.moses@codesourcery.com>
1956 * gfortran.texi (Old-style kind specifications): Document
1957 special handling of old-style kind specifiers for COMPLEX.
1958 * decl.c (gfc_match_old_kind_spec): Document kind/bytesize
1959 assumptions for COMPLEX in comment.
1961 2007-03-05 Brooks Moses <brooks.moses@codesourcery.com>
1964 * gfortranspec.c (lang_specific_driver): Update program
1965 name and copyright date.
1967 2007-03-03 Paul Thomas <pault@gcc.gnu.org>
1970 * check.c (dim_rank_check): The shape of subsections of
1971 assumed-size arrays is known.
1973 2007-03-02 Paul Thomas <pault@gcc.gnu.org>
1974 Tobias Burnus <burnus@net-b.de>
1977 * decl.c (gfc_match_entry): Remove erroneous entry result check.
1979 2007-03-01 Brooks Moses <brooks.moses@codesourcery.com>
1981 * Make-lang.in: Add install-pdf target as copied from
1982 automake v1.10 rules.
1984 2007-03-01 Tobias Burnus <burnus@net-b.de>
1987 * trans-intrinsic.c (gfc_conv_intrinsic_size): Compare pointers.
1989 2007-02-28 Tobias Burnus <burnus@net-b.de>
1990 Paul Thomas <pault@gcc.gnu.org>
1994 * resolve.c (resolve_actual_arglist): Allow by-value
1995 arguments and non-default-kind for %VAL().
1996 * trans-expr.c (conv_arglist_function): Allow
1997 non-default-kind for %VAL().
1999 2007-02-28 Tobias Burnus <burnus@net-b.de>
2002 * primary.c (next_string_char): Correct reading a character
2003 after the delimiter.
2004 (match_string_constant): Print warning message only once.
2006 2007-02-27 Richard Guenther <rguenther@suse.de>
2008 * trans-array.c (structure_alloc_comps): Use correct type
2009 for null pointer constant.
2011 2007-02-26 Brooks Moses <brooks.moses@codesourcery.com>
2013 * gfortran.texi: Standardize title page, remove version number
2014 from copyright page.
2016 2007-02-26 Thomas Koenig <Thomas.Koenig@online.de>
2017 Paul Thomas <pault@gcc.gnu.org>
2020 * trans-intrinsic.c (gfc_conv_intrinsic_size):
2021 If dim is an optional argument, check for its
2022 presence and call size0 or size1, respectively.
2024 2007-02-23 Paul Thomas <pault@gcc.gnu.org>
2027 * resolve.c (has_default_initializer): New function.
2028 (resolve_fl_variable): Call has_default_initializer to determine if
2029 the derived type has a default initializer to its ultimate
2033 2007-02-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2035 * options.c (set_default_std_flags): New function to consolidate
2037 (gfc_init_options): Use new function.
2038 (gfc_handle_option): Use new function.
2040 2007-02-22 Brooks Moses <brooks.moses@codesourcery.com>
2042 * gfortran.texi (Old-style kind specifications): Document
2043 special handling of old-style kind specifiers for COMPLEX.
2044 * decl.c (gfc_match_old_kind_spec): Documented kind/bytesize
2045 assumptions in comment.
2047 2007-02-21 Bernhard Fischer <aldot@gcc.gnu.org>
2049 * parse.c (next_free): Gooble spaces after OpenMP sentinel.
2051 2007-02-20 Thomas Koenig <Thomas.Koenig@online.de>
2054 * match.c (gfc_match_iterator): Remove conflict between
2055 loop variable and pointer.
2057 2007-02-20 Tobias Burnus <burnus@net-b.de>
2060 * symbol.c (gfc_add_volatile): Allow to set VOLATILE
2061 attribute for host-associated variables.
2062 * gfortran.h (symbol_attribute): Save namespace
2063 where VOLATILE has been set.
2064 * trans-decl.c (gfc_finish_var_decl): Move variable
2065 declaration to the top.
2067 2007-02-20 Tobias Burnus <burnus@net-b.de>
2070 * resolve.c (resolve_symbol): Add character dummy VALUE check.
2072 2007-02-19 Thomas Koenig <Thomas.Koenig@online.de>
2075 * fortran/iresolve.c (gfc_resolve_maxloc): Remove coercion of
2076 argument to default integer.
2077 (gfc_resolve_minloc): Likewise.
2079 2007-02-18 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2082 * options.c (gfc_init_options): Relax warning level for obsolescent.
2083 * match.c (match_arithmetic_if): Change to obsolescent from deleted.
2084 (gfc_match_if): Same.
2086 2007-02-18 Roger Sayle <roger@eyesopen.com>
2088 * trans-array.c (gfc_build_constant_array_constructor): When the
2089 shape of the constructor is known, use that to construct the
2091 (gfc_trans_constant_array_constructor): Initialize the "info"
2092 information for all of the dimensions of the array constructor.
2093 (constant_array_constructor_loop_size): New function.
2094 (gfc_trans_array_constructor): Use it to determine whether a
2095 loop is suitable for "constant array constructor" optimization.
2097 * trans-intrinsic.c (gfc_conv_intrinsic_anyall): Use fold_build2
2098 instead of build2, to avoid conditions like "(a != b) != 0".
2100 2007-02-18 Roger Sayle <roger@eyesopen.com>
2101 Paul Thomas <pault@gcc.gnu.org>
2104 * match.c (match_forall_iterator): Use gfc_match_expr instead
2105 of gfc_match_variable to match the iterator variable. Return
2106 MATCH_NO if not a variable. Remove the reset of the symbol's
2109 2007-02-16 Tobias Burnus <burnus@net-b.de>
2112 * trans-decl.c (gfc_generate_function_code): Do not initialize
2113 pointers to derived components.
2115 2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
2116 Brooks Moses <brooks.moses@codesourcery.com>
2117 Lee Millward <lee.millward@codesourcery.com>
2119 * trans-expr.c (gfc_conv_power_op): Use build_call_expr.
2120 (gfc_conv_string_tmp): Likewise.
2121 (gfc_conv_concat_op): Likewise.
2122 (gfc_build_compare_string): Likewise.
2123 (gfc_conv_function_call): Use build_call_list instead of build3.
2125 * trans-array.c (gfc_trans_allocate_array_storage): Use
2127 (gfc_grow_array): Likewise.
2128 (gfc_trans_array_ctor_element): Likewise.
2129 (gfc_trans_array_constructor_value): Likewise.
2130 (gfc_array_allocate): Likewise.
2131 (gfc_array_deallocate): Likewise.
2132 (gfc_trans_auto_array_allocation): Likewise.
2133 (gfc_trans_dummy_array_bias): Likewise.
2134 (gfc_conv_array_parameter): Likewise.
2135 (gfc_trans_dealloc_allocated): Likewise.
2136 (gfc_duplicate_allocatable): Likewise.
2138 * trans-openmp.c (gfc_trans_omp_barrier): Use build_call_expr.
2139 (gfc_trans_omp_flush): Likewise.
2141 * trans-stmt.c (gfc_conv_elementel_dependencies): Use build_call_expr.
2142 (gfc_trans_pause): Likewise.
2143 (gfc_trans_stop): Likewise.
2144 (gfc_trans_character_select): Likewise.
2145 (gfc_do_allocate): Likewise.
2146 (gfc_trans_assign_need_temp): Likewise.
2147 (gfc_trans_pointer_assign_need_temp): Likewise.
2148 (gfc_trans_forall_1): Likewise.
2149 (gfc_trans_where_2): Likewise.
2150 (gfc_trans_allocate): Likewise.
2151 (gfc_trans_deallocate): Likewise.
2153 * trans.c (gfc_trans_runtime_check): Use build_call_expr.
2155 * trans-io.c (gfc_trans_open): Use build_call_expr.
2156 (gfc_trans_close): Likewise.
2157 (build_filepos): Likewise.
2158 (gfc_trans_inquire): Likewise.
2159 (NML_FIRST_ARG): Delete.
2160 (NML_ADD_ARG): Delete.
2161 (transfer_namelist_element): Use build_call_expr.
2162 (build_dt): Likewise.
2163 (gfc_trans_dt_end): Likewise.
2164 (transfer_expr): Likewise.
2165 (transfer_array-desc): Likewise.
2167 * trans-decl.c (gfc_generate_function_code): Use build_call_expr.
2168 (gfc_generate_constructors): Likewise.
2170 * trans-intrinsic.c (gfc_conv_intrinsic_ctime): Use build_call_expr.
2171 (gfc_conv_intrinsic_fdate): Likewise.
2172 (gfc_conv_intrinsic_ttynam): Likewise.
2173 (gfc_conv_intrinsic_array_transfer): Likewise.
2174 (gfc_conv_associated): Likewise.
2175 (gfc_conv_intrinsic_si_kind): Likewise.
2176 (gfc_conv_intrinsic_trim): Likewise.
2177 (gfc_conv_intrinsic_repeat: Likewise.
2178 (gfc_conv_intrinsic_iargc): Likewise.
2180 2007-02-14 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2183 * scanner.c (gfc_next_char_literal): Add check for end of file after
2184 call to advance_line.
2186 2007-02-14 Steven G. Kargl <kargl@gcc.gnu.org>
2189 * primary.c (match_logical_constant): Return MATCH_ERROR on invalid
2192 2007-02-14 Steven G. Kargl <kargl@gcc.gnu.org>
2194 * misc.c (gfc_typename): Fix potential buffer overflow.
2196 2007-02-13 Paul Thomas <pault@gcc.gnu.org>
2199 * module.c (read_module): Set pointer_info to referenced if the
2200 symbol has no namespace.
2202 2007-02-12 Nick Clifton <nickc@redhat.com>
2204 * lang.opt: Add Warning attribute to warning options.
2206 2007-02-11 Daniel Franke <franke.daniel@gmail.com>
2208 * intrinsic.texi (HOSTNM): Fix typographical error in syntax.
2209 (SLEEP): Added section and documentation.
2211 2007-02-11 Tobias Schlüter <tobi@gcc.gnu.org>
2214 * decl.c (add_init_expr_to_sym): Remove ENUM specific code.
2215 (variable_decl): Likewise. Rewrap comment.
2216 (match_attr_spec): Remove ENUM specific code.
2217 (gfc_match_enum): Fix typo in error message.
2218 (enumerator_decl): New function.
2219 (gfc_match_enumerator_def): Use enumerator_decl instead of
2220 variable_decl. Adapt code accordingly.
2222 2007-02-11 Paul Thomas <pault@gcc.gnu.org>
2225 * module.c (find_symtree_for_symbol): New function to return
2226 a symtree that is not a "unique symtree" given a symbol.
2227 (read_module): Do not automatically set pointer_info to
2228 referenced because this inhibits the generation of a unique
2229 symtree. Recycle the existing symtree if possible by calling
2230 find_symtree_for_symbol.
2233 * decl.c (add_init_expr_to_sym): Make new charlen for an array
2234 constructor initializer.
2236 2007-02-10 Richard Henderson <rth@redhat.com>, Jakub Jelinek <jakub@redhat.com>
2238 * f95-lang.c (gfc_init_builtin_functions): Add __emutls_get_address
2239 and __emutls_register_common.
2240 * openmp.c (gfc_match_omp_threadprivate): Don't error if !have_tls.
2241 * trans-common.c (build_common_decl): Don't check have_tls.
2242 * trans-decl.c (gfc_finish_var_decl): Likewise.
2243 * types.def (BT_WORD, BT_FN_PTR_PTR): New.
2244 (BT_FN_VOID_PTR_WORD_WORD_PTR): New.
2246 2007-02-09 Tobias Burnus <burnus@net-b.de>
2249 * trans-intrinsic.c (gfc_conv_intrinsic_minmaxloc,
2250 gfc_conv_intrinsic_minmaxval): Use HUGE-1 for most negative integer.
2252 2007-02-09 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2255 * trans-array.c (gfc_trans_create_temp_array): Remove use of the
2256 function argument. Always generate code for negative extent.
2258 * trans-array.h (gfc_trans_create_temp_array): Change prototype.
2259 * trans-expr.c (gfc_conv_function_call): Remove use of last argument
2260 of gfc_trans_create_temp_array.
2261 * trans-intrinsic.c (gfc_conv_intrinsic_array_transfer): Likewise.
2262 * trans-stmt.c (gfc_conv_elemental_dependencies): Likewise.
2264 2007-02-08 Roger Sayle <roger@eyesopen.com>
2266 * trans-stmt.c (gfc_trans_forall_1): Optimize the cases where the
2267 mask expression is a compile-time constant (".true." or ".false.").
2269 2007-02-04 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2272 * trans-intrinsic.c (gfc_conv_intrinsic_repeat): Evaluate
2273 arguments only once. Generate check that NCOPIES argument is not
2276 2007-02-04 Steven G. Kargl <kargl@gcc.gnu.org>
2279 * fortran/invoke.texi: Update documentation.
2280 * fortran/options.c (gfc_post_options): Deal with tabs with -std=f2003
2283 2007-02-03 Kazu Hirata <kazu@codesourcery.com>
2285 * trans-array.c: Fix a comment typo.
2287 2007-02-03 Paul Thomas <pault@gcc.gnu.org>
2290 * array.c (match_array_element_spec): If the length of an array is
2291 negative, adjust the upper limit to make it zero length.
2294 * resolve.c (pure_function, resolve_function): Initialize name to
2295 null to clear up build warnings.
2296 (resolve_fl_variable): Look at components explicitly to check for
2297 default initializer, rather than using gfc_default_initializer.
2299 2007-02-02 Steven G. Kargl <kargl@gcc.gnu.org>
2302 * resolve.c (resolve_generic_f): Check for non-NULL sym.
2304 2007-02-02 Roger Sayle <roger@eyesopen.com>
2306 * trans.c (gfc_build_array_ref): Use STRIP_TYPE_NOPS to eliminate
2307 NON_LVALUE_EXPR nodes and useless type conversions.
2309 2007-02-02 Paul Thomas <pault@gcc.gnu.org>
2313 * trans-expr.c (gfc_conv_aliased_arg): Remove static attribute
2314 from function and make sure that substring lengths are
2316 (is_aliased_array): Remove static attribute.
2317 * trans.c : Add prototypes for gfc_conv_aliased_arg and
2319 * trans-io.c (set_internal_unit): Add the post block to the
2320 arguments of the function. Use is_aliased_array to check if
2321 temporary is needed; if so call gfc_conv_aliased_arg.
2322 (build_dt): Pass the post block to set_internal_unit and
2323 add to the block after all io activiy is done.
2325 2007-02-01 Roger Sayle <roger@eyesopen.com>
2327 * trans-array.c (gfc_conv_expr_descriptor): We don't need to use
2328 a temporary array to pass a constant non-character array constructor.
2329 Generalize the descriptor generation code to handle scalarizer
2330 "info" without an array reference.
2332 2007-02-01 Roger Sayle <roger@eyesopen.com>
2334 * dependency.c (gfc_check_dependency) <EXPR_ARRAY>: Implement
2335 dependency checking for array constructors.
2337 2007-02-01 Roger Sayle <roger@eyesopen.com>
2339 * trans-stmt.c (compute_overall_iter_number): Document function
2340 arguments. Generalize "unconditional forall nest with constant
2341 bounds" optimization to eliminate unconditional inner loops with
2344 2007-01-31 Tobias Burnus <burnus@net-b.de>
2347 * interface.c (compare_actual_formal): Check conformance between
2348 actual and VOLATILE dummy arguments.
2349 * symbol.c (gfc_add_volatile): Allow setting of VOLATILE
2350 multiple times in different scopes.
2351 * decl.c (gfc_match_volatile): Search symbol in host association.
2353 2007-01-31 Kazu Hirata <kazu@codesourcery.com>
2355 * simplify.c, trans-array.c: Fix comment typos.
2357 2007-01-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
2359 * invoke.texi (Code Gen Options): Fix abbreviation typo.
2360 * intrinsic.texi (ACCESS, LSHIFT, RSHIFT): Fix typos.
2362 2007-01-30 Steve Ellcey <sje@cup.hp.com>
2365 * trans-types.c (gfc_get_function_type): Do not add void_type_node
2367 * trans-decl.c (create_function_arglist): Change assert.
2369 2007-01-29 Paul Thomas <pault@gcc.gnu.org>
2372 * module.c (read_module): If a symbol is excluded by an ONLY
2373 clause, check to see if there is a symtree already loaded. If
2374 so, attach the symtree to the pointer_info.
2376 2007-01-28 Thomas Koenig <Thomas.Koenig@online.de>
2379 * gfortran.h: Remove gfc_simplify_init_1.
2380 * arith.h: Remove third argument from gfc_compare_string.
2381 * arith.c (gfc_compare_expression): Remove third argument
2382 from call to gfc_compare_string.
2383 (gfc_compare_string): Remove third argument xcoll_table.
2384 Remove use of xcoll_table.
2385 * misc.c (gfc_init_1): Remove call to gfc_simplify_init_1.
2386 * simplify.c (ascii_table): Remove.
2387 (xascii_table): Likewise.
2388 (gfc_simplify_achar): ICE if extract_int fails. Remove use of
2389 ascii_table. Warn if -Wsurprising and value < 0 or > 127.
2390 (gfc_simplify_char): ICE if extract_int fails. Error if
2391 value < 0 or value > 255.
2392 (gfc_simplify_iachar): Remove use of xascii_table.
2393 Char values outside of 0..255 are an ICE.
2394 (gfc_simplify_lge): Remove use of xascii_table.
2395 (gfc_simplify_lgt): Likewise.
2396 (gfc_simplify_lle): Likewise.
2397 (gfc_simplify_llt): Likewise.
2398 (invert_table): Remove.
2399 (gfc_simplify_init_1): Remove.
2401 2007-01-27 Roger Sayle <roger@eyesopen.com>
2403 * trans-stmt.c (forall_info): Replace the next_nest and outer
2404 fields that previously implemented a doubly-linked list with a
2405 single prev_nest field (singly-linked list).
2406 (gfc_trans_nested_forall_loop): The nested_forall_info argument
2407 now denotes the innermost FORALL in the loop nest.
2408 (compute_overall_iter_number): Use prev_nest instead of next_nest.
2409 (gfc_trans_forall_1): Link/cons the new "info" to the head of the
2410 nested_forall_info linked list. Free the current "info" when done.
2412 2007-01-27 Paul Thomas <pault@gcc.gnu.org>
2415 * trans-expr.c (gfc_conv_operator_assign): New function.
2416 * trans.h : Add prototype for gfc_conv_operator_assign.
2417 * trans-stmt.c (gfc_trans_where_assign): Add a gfc_symbol for
2418 a potential operator assignment subroutine. If it is non-NULL
2419 call gfc_conv_operator_assign instead of the first assignment.
2420 ( gfc_trans_where_2): In the case of an operator assignment,
2421 extract the argument expressions from the code for the
2422 subroutine call and pass the symbol to gfc_trans_where_assign.
2423 resolve.c (resolve_where, gfc_resolve_where_code_in_forall,
2424 gfc_resolve_forall_body): Resolve the subroutine call for
2425 operator assignments.
2427 2007-01-26 Steven Bosscher <stevenb.gcc@gmail.com>
2428 Steven G. Kargl <kargl@gcc.gnu.org>
2431 * fortran/io.c (next_char): Deal with backslash escaped characters.
2432 Issue warnings in non -std=gnu cases.
2433 * fortran/primary.c (next_string_char): Issue warnings in non
2435 2007-01-26 Tobias Burnus <burnus@net-b.de>
2437 * lang-specs.h: Add support for .f03 and .F03 extensions.
2438 * gfortran.texi: Document .f03 extension.
2439 * options.c (form_from_filename): Recognize .f03.
2441 2007-01-25 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
2444 * lang.opt (Wall): Remove RejectNegative.
2445 * options.c (gfc_handle_option): Wall can be disabled.
2446 (set_Wall): Add a parameter for disabling Wall.
2448 2007-01-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2451 * scanner.c (load_line): Remove check fot ctrl-z and don't gobble.
2453 2007-01-23 Paul Thomas <pault@gcc.gnu.org>
2456 * match.c (gfc_match_namelist): Add check for assumed size character
2457 in namelist and provide error if found.
2459 2007-01-21 Brooks Moses <brooks.moses@codesourcery.com>
2461 * intrinsic.texi (ACHAR): Added cross-references.
2462 (CHAR): Put cross-references in alphabetical order.
2463 (IACHAR): Added cross-references.
2464 (ICHAR): Added cross-references.
2466 2007-01-20 Brooks Moses <brooks.moses@codesourcery.com>
2468 * intrinsic.texi: Edited all "Syntax" examples to a consistent form.
2469 (MAXVAL): Corrected description of result characteristics.
2471 (UMASK): Added documentation.
2473 2007-01-20 Steven G. Kargl <kargl@gcc.gnu.org>
2475 * openmp.c, matchexp.c, module.c, scanner.c, resolve.c, st.c,
2476 parse.c, primary.c, options.c, misc.c, simplify.c: Next installment
2477 in the massive whitespace patch.
2479 2007-01-20 Roger Sayle <roger@eyesopen.com>
2481 * module.c (mio_array_ref): The dimen_type fields of an array ref
2482 are an enumerated type and can't be read/written directly with a
2483 call to mio_integer. Instead loop over and cast each element.
2485 2007-01-20 Roger Sayle <roger@eyesopen.com>
2487 * dependency.c (gfc_full_array_ref_p): Check that ref->next is NULL,
2488 i.e. that the ARRAY_REF doesn't mention components.
2489 * trans-array.c (gfc_constant_array_constructor_p): Export external
2490 function renamed from constant_array_constructor_p.
2491 (gfc_build_constant_array_constructor): Export.
2492 (gfc_trans_array_constructor): Update call to the renamed function
2493 constant_array_constructor_p.
2494 * trans-array.h (gfc_constant_array_constructor_p): Prototype here.
2495 (gfc_build_constant_array_constructor): Likewise.
2496 * trans-expr.c (gfc_build_memcpy_call): New helper function split
2497 out from gfc_trans_array_copy.
2498 (gfc_trans_array_copy): Use gfc_build_memcpy_call.
2499 (gfc_trans_array_constructor_copy): New function to optimize
2500 assigning an entire array from a constant array constructor.
2501 (gfc_trans_assignment): Call gfc_trans_array_constructor_copy
2504 2007-01-20 Roger Sayle <roger@eyesopen.com>
2506 * trans-intrinsic.c (gfc_conv_intrinsic_sign): New branchless
2507 implementation for the SIGN intrinsic with integral operands.
2508 (gfc_conv_intrinsic_minmax): Fix whitespace.
2510 2007-01-20 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2512 * gfortran.h (gfc_options_t): Add flag_allow_leading_underscore.
2513 * lang.opt: Add -fallow-leading-underscore.
2514 * match.c (gfc_match_name): Allow leading underscore in symbol
2515 name if -fallow-leading-underscore is used.
2516 * symbol.c (gfc_get_default_type): Add special case for symbol
2517 names beginning with an underscore.
2518 * trans-decl.c (gfc_get_extern_function_decl,
2519 gfc_build_intrinsic_function_decls): Add _gfortran prefix to
2520 library symbols selected_int_kind, selected_real_kind and
2522 * options.c (gfc_init_options, gfc_handle_option): Handle the
2523 new -fallow-leading-underscore option.
2525 2007-01-20 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2528 * options.c (gfc_handle_module_path_options): Path used in -J
2529 option is now added to the module search path.
2531 2007-01-20 Richard Guenther <rguenther@suse.de>
2534 * f95-lang.c (gfc_init_builtin_functions): Provide cbrt and
2535 cexpi builtins if we have TARGET_C99_FUNCTIONS. Provide
2536 sincos builtins if the target has sincos.
2538 2007-01-19 Brooks Moses <brooks.moses@codesourcery.com>
2540 * intrinsic.texi (MATMUL): Corrected a typo.
2541 (MAX): Separated @var arguments.
2542 (MIN): Separated @var arguments.
2544 2007-01-19 Brooks Moses <brooks.moses@codesourcery.com>
2546 * intrinsic.texi: general whitespace cleanup.
2547 (menu): Added TIME8, removed UNMASK.
2548 (AINT): Clarified argument requirement.
2549 (ANINT): Clarified argument requirement.
2550 (CEILING): Clarified argument requirement.
2551 (CHAR): Clarified argument requirement.
2552 (CMPLX): Clarified argument requirement.
2553 (DCMPLX): Clarified argument requirement.
2554 (FGET): Line rewrapping.
2555 (FLOOR): Clarified argument requirement.
2556 (GMTIME): Added documentation.
2557 (IAND): Added cross-reference.
2558 (IBCLR): Added cross-reference.
2559 (IBSET): Added cross-reference.
2560 (IEOR): Added cross-reference.
2561 (INT): Collapsed examples, clarified argument requirement.
2562 (IOR): Added cross-references.
2563 (LEN_TRIM): Corrected result kind.
2564 (LINK): Added cross-reference.
2565 (LLT): Removed "documentation pending".
2566 (LOGICAL): Added documentation.
2567 (LSHIFT): Added documentation.
2568 (LTIME): Added documentation.
2569 (MATMUL): Added documentation.
2570 (MAX): Added documentation.
2571 (MAXLOC): Added documentation.
2572 (MAXVAL): Added documentation.
2573 (MERGE): Added documentation.
2574 (MIN): Added documentation.
2575 (MINLOC): Added documentation.
2576 (MINVAL): Added documentation.
2577 (MVBITS): Moved to correct place, added documentation.
2578 (NOT): Added documentation.
2579 (PERROR): Added documentation.
2580 (RAN): Moved to correct place, added documentation.
2581 (REAL): Clarified argument requirement.
2582 (RENAME): Added documentation.
2583 (RSHIFT): Clarified argument requirement.
2584 (SIGN): Corrected table specification.
2585 (SYMLNK): Added documentation.
2586 (SYSTEM): Added documentation.
2587 (TIME): Added documentation.
2588 (TIME8): Added section and documentation.
2589 (UNMASK): Removed erroneous section.
2591 2007-01-18 H.J. Lu <hongjiu.lu@intel.com>
2593 * trans-stmt.c (compute_overall_iter_number): Fix a typo.
2595 2007-01-18 Roger Sayle <roger@eyesopen.com>
2597 * trans-expr.c (copyable_array_p): Consider user derived types without
2598 allocatable components to be copyable.
2600 2007-01-18 Roger Sayle <roger@eyesopen.com>
2602 * trans-stmt.c (compute_overall_iter_number): Enhance to precompute
2603 the number of interations in unconditional FORALL nests with constant
2606 2007-01-18 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2607 Tobias Burnus <burnus@net-b.de>
2610 * gfortran.h (gfc_option_t): Add flag_dump_core.
2611 * lang.opt: Add -fdump-core option.
2612 * invoke.texi: Document the new options.
2613 * trans-decl.c (gfc_build_builtin_function_decls): Add new
2614 options to the call to set_std.
2615 * options.c (gfc_init_options, gfc_handle_option): Set the
2618 2007-01-17 Paul Thomas <pault@gcc.gnu.org>
2621 * module.c (load_generic_interfaces): Make the marking of the
2622 symbol as ambiguous conditional on the module names being
2624 (write_generic): Ensure that the generic interface has a
2625 non-NULL module field.
2627 2007-01-16 Roger Sayle <roger@eyesopen.com>
2630 * trans-stmt.c (forall_info): Remove pmask field.
2631 (gfc_trans_forall_loop): Remove NVAR argument, instead assume that
2632 NVAR covers all the interation variables in the current forall_info.
2633 Add an extra OUTER parameter, which specified the loop header in
2634 which to place mask index initializations.
2635 (gfc_trans_nested_forall_loop): Remove NEST_FLAG argument.
2636 Change the semantics of MASK_FLAG to only control the mask in the
2638 (compute_overall_iter_number): Optimize the trivial case of a
2639 top-level loop having a constant number of iterations. Update
2640 call to gfc_trans_nested_forall_loop. Calculate the number of
2641 times the inner loop will be executed, not to size of the
2643 (allocate_temp_for_forall_nest_1): Reuse SIZE as BYTESIZE when
2644 sizeof(type) == 1. Tidy up.
2645 (gfc_trans_assign_need_temp): Remove NEST_FLAG argument from calls
2646 to gfc_trans_nested_forall_loop.
2647 (gfc_trans_pointer_assign_need_temp): Likewise.
2648 (gfc_trans_forall_1): Remove unused BYTESIZE, TMPVAR, SIZEVAR and
2649 LENVAR local variables. Split mask allocation into a separate
2650 hunk/pass from mask population. Use allocate_temp_for_forall_nest
2651 to allocate the FORALL mask with the correct size. Update calls
2652 to gfc_trans_nested_forall_loop.
2653 (gfc_evaluate_where_mask): Update call to
2654 gfc_trans_nested_forall_loop.
2655 (gfc_trans_where_2): Likewise.
2657 2007-01-15 Paul Thomas <pault@gcc.gnu.org>
2660 * trans-stmt.c (gfc_trans_call): If it does not have one, get
2661 a backend_decl for an alternate return.
2664 * resolve.c (pure_function): Statement functions are pure. Note
2665 that this will have to recurse to comply fully with F95.
2668 * resolve.c (resolve_function): Only a reference to the final
2669 dimension of an assumed size array is an error in an inquiry
2673 * resolve.c (resolve_function): Make sure that the function
2674 expression has a type.
2676 2007-01-14 Paul Thomas <pault@gcc.gnu.org>
2679 * trans-decl.c (gfc_sym_mangled_function_id): Module, external
2680 symbols must not have the module name prepended.
2682 2007-01-11 Thomas Koenig <Thomas.Koenig@online.de>
2685 * iresolve.c (gfc_resolve_maxloc): If the rank
2686 of the return array is nonzero and we process an
2687 integer array smaller than default kind, coerce
2688 the array to default integer.
2689 * iresolve.c (gfc_resolve_minloc): Likewise.
2691 2007-01-11 Brooks Moses <brooks.moses@codesourcery.com>
2693 * simplify.c: Update copyright to 2007.
2696 2007-01-11 Francois-Xavier Coudert <coudert@clipper.ens.fr>
2699 * scanner.c (gfc_release_include_path): Free gfc_option.module_dir
2702 2007-01-09 Brooks Moses <brooks.moses@codesourcery.com>
2704 * simplify.c (gfc_simplify_ibclr): Fix POS comparison.
2705 (gfc_simplify_ibset): Same.
2707 2007-01-09 Brooks Moses <brooks.moses@codesourcery.com>
2711 * simplify.c (convert_mpz_to_unsigned): New function.
2712 (convert_mpz_to_signed): New function, largely based on
2714 (twos_complement): Removed.
2715 (gfc_simplify_ibclr): Add conversions to and from an
2716 unsigned representation before bit-twiddling.
2717 (gfc_simplify_ibset): Same.
2718 (gfc_simplify_ishftc): Add checks for overly large
2719 constant arguments, only check the third argument if
2720 it's present, carry over high bits into the result as
2721 appropriate, and perform the final conversion back to
2722 a signed representation using the correct sign bit.
2723 (gfc_simplify_not): Removed unnecessary masking.
2725 2007-01-09 Paul Thomas <pault@gcc.gnu.org>
2728 * resolve.c (resolve_code): Use the code->expr character length
2729 directly to set length of llen.
2731 2007-01-09 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2734 * lang.opt: Add Wcharacter_truncation option.
2735 * options.c (gfc_init_options): Initialize
2736 gfc_option.warn_character_truncation to zero.
2737 (gfc_handle_option): Add case for OPT_Wcharacter_truncation.
2739 2007-01-08 Steven G. Kargl <kargl@gcc.gnu.org>
2741 * interface.c, intrinsic.c, gfortranspec.c, io.c, f95-lang.c,
2742 iresolve.c, match.c: Update Copyright years. Whitespace.
2744 2007-01-08 Richard Guenther <rguenther@suse.de>
2746 * trans-io.c (transfer_array_desc): Use build_int_cst instead
2749 2007-01-08 Roger Sayle <roger@eyesopen.com>
2751 * trans-array.c (constant_array_constructor_p): New function to
2752 determine whether an array constructor consists only of constant
2753 elements, and if so return it's size.
2754 (gfc_build_constant_array_constructor): Construct a statically
2755 initialized gfortran array for a given EXPR_ARRAY.
2756 (gfc_trans_constant_array_constructor): Efficiently scalarize
2757 a constant array constructor.
2758 (gfc_trans_array_constructor): Tidy up use of CONST_STRING.
2759 Special case scalarization of constant array constructors, all of
2760 whose elements are specified, using constant_array_constructor_p
2761 and gfc_trans_constant_array_constructor.
2762 (gfc_conv_scalarized_array_ref): Check whetger info->offset is zero
2763 before adding it to index, to avoid creating a NON_LVALUE_EXPR.
2765 2007-01-08 Kazu Hirata <kazu@codesourcery.com>
2767 gfortran.texi: Fix typos.
2769 2007-01-07 Steven G. Kargl <kargl@gcc.gnu.org>
2771 * decl.c, dump-parse-tree.c, error.c, data.c, expr.c, dependency.c,
2772 convert.c: Update Copyright dates. Fix whitespace.
2774 2007-01-07 Bernhard Fischer <aldot@gcc.gnu.org>
2776 * data.c (gfc_assign_data_value): Fix whitespace.
2778 2007-01-07 Bernhard Fischer <aldot@gcc.gnu.org>
2780 * trans-array.c (gfc_trans_create_temp_array, gfc_array_init_size):
2781 Commentary typo fix.
2783 2007-01-07 Bernhard Fischer <aldot@gcc.gnu.org>
2786 * match.c (gfc_match_name): Print diagnostics for invalid
2789 2007-01-06 Steven G. Kargl <kargl@gcc.gnu.org>
2791 * array.c: Fix whitespace in comment table.
2793 2007-01-06 Steven G. Kargl <kargl@gcc.gnu.org>
2795 * array.c, bbt.c, check.c: Update copyright years. Whitespace.
2797 2007-01-06 Steven G. Kargl <kargl@gcc.gnu.org>
2799 * arith.c: Update copyright years. Whitespace.
2801 2007-01-05 Roger Sayle <roger@eyesopen.com>
2803 * trans-expr.c (gfc_trans_assignment_1): New subroutine to scalarize
2804 array assignments split out from gfc_trans_assignment.
2805 (gfc_trans_array_copy): New function to implement array to array
2806 copies via calls to __builtin_memcpy.
2807 (copyable_array_p): New helper function to identify an array of
2808 simple/POD types, that may be copied/assigned using memcpy.
2809 (gfc_trans_assignment): Use gfc_trans_array_copy to handle simple
2810 whole array assignments considered suitable by copyable_array_p.
2811 Invoke gfc_trans_assignment_1 to perform the fallback scalarization.
2813 2007-01-05 Roger Sayle <roger@eyesopen.com>
2815 * trans-array.c (gfc_trans_array_constructor_value): Make the
2816 static const "data" array as TREE_READONLY.
2817 * trans-stmt.c (gfc_trans_character_select): Likewise.
2819 2007-01-05 Roger Sayle <roger@eyesopen.com>
2821 * trans-array.c (gfc_conv_loop_setup): Test whether the loop
2822 stride is one, to avoid fold_build2 introducing a useless
2823 NON_LVALUE_EXPR node.
2825 2007-01-05 Tobias Burnus <burnus@net-b.de>
2827 * symbol.c (check_conflict): Fix error message.
2829 2007-01-05 Paul Thomas <pault@gcc.gnu.org>
2832 * decl.c (gfc_in_match_data, gfc_set_in_match_data): New
2833 functions to signal that a DATA statement is being matched.
2834 (gfc_match_data): Call gfc_set_in_match_data on entry and on
2836 * gfortran.h : Add prototypes for above.
2837 * expr.c (check_init_expr): Avoid check on parameter or
2838 variable if gfc_in_match_data is true.
2839 (gfc_match_init_expr): Do not call error on non-reduction of
2840 expression if gfc_in_match_data is true.
2844 * decl.c (gfc_set_constant_character_len): Add boolean arg to
2845 flag array constructor resolution. Warn if string is being
2846 truncated. Standard dependent error if string is padded. Set
2847 new arg to false for all three calls to
2848 gfc_set_constant_character_len.
2849 * match.h : Add boolean arg to prototype for
2850 gfc_set_constant_character_len.
2851 * gfortran.h : Add warn_character_truncation to gfc_options.
2852 * options.c (set_Wall): Set warn_character_truncation if -Wall
2854 * resolve.c (resolve_code): Warn if rhs string in character
2855 assignment has to be truncated.
2856 * array.c (gfc_resolve_character_array_constructor): Set new
2857 argument to true for call to gfc_set_constant_character_len.
2859 2007-01-05 Tobias Burnus <burnus@net-b.de>
2862 * interface.c (compare_parameter_intent): New function.
2863 (check_intents): Support pointer intents.
2864 * symbol.c (check_conflict): Support pointer intents,
2865 better conflict_std message.
2866 * expr.c (gfc_check_assign,gfc_check_pointer_assign):
2867 Support pointer intents.
2868 * resolve.c (resolve_deallocate_expr,resolve_allocate_expr):
2869 Support pointer intents.
2871 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2874 * check.c (gfc_check_kill_sub): Add checks for non-scalar
2877 2007-01-04 Brooks Moses <brooks.moses@codesourcery.com>
2879 * intrinsic.texi: Minor cleanup, reflowing overlong
2880 paragraphs, and correcting whitespace.
2882 2007-01-04 Brooks Moses <brooks.moses@codesourcery.com>
2884 * intrinsic.texi (LBOUND): Add documentation.
2885 (LGE): Add documentation.
2886 (LGT): Add documentation.
2887 (LINK): Add documentation.
2888 (LLE): Add documentation.
2889 (LLT): Add documentation.
2890 (LNBLNK): Add documentation.
2891 (UBOUND): Add documentation.
2892 (UNLINK): Add documentation.
2894 2007-01-04 Brooks Moses <brooks.moses@codesourcery.com>
2896 * intrinsic.texi (IAND): Clarify argument specifications.
2897 (IBCLR): Add documentation.
2898 (IBITS): Add documentation.
2899 (IBSET): Add documentation.
2900 (IEOR): Add documentation.
2901 (IERRNO): Add documentation.
2902 (INDEX): Add documentation.
2903 (IOR): Add documentation.
2904 (ISHFT): Add documentation.
2905 (ISHFTC): Add documentation.
2906 (KILL): Add documentation.
2907 (LEN_TRIM): Add documentation.
2909 2007-01-04 Brooks Moses <brooks.moses@codesourcery.com>
2912 * interface.c (compare_actual_formal): check for
2913 alternate returns when iterating over non-present
2916 2007-01-04 Brooks Moses <brooks.moses@codesourcery.com>
2918 * invoke.texi: Update manpage copyright to include 2007.
2920 2007-01-04 Brooks Moses <brooks.moses@codesourcery.com>
2922 * gfortran.texi: Update copyright to include 2007.
2923 * intrinsic.texi: Update copyright to include 2007.
2924 * invoke.texi: Update copyright to include 2007.
2926 2007-01-02 Tobias Burnus <burnus@net-b.de>
2927 Jakub Jelinek <jakub@redhat.com>
2930 * scanner.c (open_included_file): Revert patch.
2931 (gfc_open_included_file): Support absolute pathnames.
2932 (gfc_open_intrinsic_module): Support absolute pathnames.
2934 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2936 * gfortran.texi (GNU Fortran and GCC): Rewrite
2938 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2940 * gfortran.texi (Introduction): Lower "Part I:
2941 Introduction" to a chapter, renumber Parts II and III to
2943 * intrinsic.texi (Introduction): Rename to "Introduction
2944 to Intrinsics" to avoid conflict with the new chapter.
2946 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2948 * intrinsic.texi (Introduction): Rewrite first paragraph.
2950 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2952 * invoke.texi (OpenMP): Added index entry.
2953 * gfortran.texi (title page): Removed erroneous '*'.
2955 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2957 * gfortran.texi (GFORTRAN_DEFAULT_RECL): Added units
2959 (Extensions): Miscellaneous minor rewriting and copyediting.
2960 (BOZ-literal constants): Renamed from Hexadecimal constants.
2961 (Hollerith constants support): Added explanation and
2962 suggestions for standard-conforming modern equivalents.
2964 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2966 * intrinsic.texi: Improvements to index entries; change
2967 @findex entries to @cindex entries.
2968 * invoke.texi: Standardize and improve index entries.
2969 * gfortran.texi: Fix @code in one index entry.
2971 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2973 * invoke.texi: Change @code-type macros to appropriate
2974 variants (@command, @option, etc.)
2975 * gfortran.texi: Same.
2977 2007-01-03 Brooks Moses <brooks.moses@codesourcery.com>
2979 * intrinsic.texi: Various minor cleanups.
2981 2007-01-02 Steven G. Kargl <kargls@comcast.net>
2983 * trans-intrinsic.c (gfc_conv_intrinsic_ibits): Fix call to
2986 2007-01-02 Tobias Burnus <burnus@net-b.de>
2989 * scanner.c (open_included_file): Support full-path filenames.
2991 2007-01-02 Paul Thomas <pault@gcc.gnu.org>
2994 * interface.c (check_sym_interfaces): Remove call to
2995 resolve_global_procedure.
2996 gfortran.h : Remove prototype for resolve_global_procedure.
2997 resolve.c (resolve_global_procedure): Add static attribute
2998 to function declaration.
3000 2007-01-01 Steven G. Kargl <kargls@comcast.net>
3002 * ChangeLog: Copy to ...
3003 * ChangeLog-2006: here.