1 2010-07-13 Daniel Franke <franke.daniel@gmail.com>
2 Tobias Burnus <burnus@net-b.de>
5 * trans-decl.c (gfc_build_intrinsic_function_decls): Add
6 noclobber/noescape annotations to function calls.
7 (gfc_build_builtin_function_decls): Likewise.
9 2010-07-13 Janus Weil <janus@gcc.gnu.org>
15 * gfortran.h (gfc_find_derived_vtab): Modified prototype.
16 * class.c (gfc_build_class_symbol): Modified call to
17 'gfc_find_derived_vtab'.
18 (add_proc_component): Removed, moved code into 'add_proc_comp'.
19 (add_proc_comps): Renamed to 'add_proc_comp', removed treatment of
21 (add_procs_to_declared_vtab1): Removed unnecessary argument 'resolved'.
22 Removed treatment of generics.
23 (copy_vtab_proc_comps): Removed unnecessary argument 'resolved'.
24 Call 'add_proc_comp' instead of duplicating code.
25 (add_procs_to_declared_vtab): Removed unnecessary arguments 'resolved'
27 (add_generic_specifics,add_generics_to_declared_vtab): Removed.
28 (gfc_find_derived_vtab): Removed unnecessary argument 'resolved'.
29 Removed treatment of generics.
30 * iresolve.c (gfc_resolve_extends_type_of): Modified call to
31 'gfc_find_derived_vtab'.
32 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
33 Removed treatment of generics.
34 (resolve_select_type,resolve_fl_derived): Modified call to
35 'gfc_find_derived_vtab'.
36 * trans-decl.c (gfc_get_symbol_decl): Ditto.
37 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
39 * trans-stmt.c (gfc_trans_allocate): Ditto.
41 2010-07-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
44 * trans-io.c (build_dt): Set common.unit to flag chracter(kind=4)
47 2010-07-12 Mikael Morin <mikael@gcc.gnu.org>
49 * expr.c (gfc_get_int_expr): Don't initialize mpfr data twice.
50 * resolve.c (build_default_init_expr): Ditto.
52 2010-07-11 Tobias Burnus <burnus@net-b.de>
55 * module.c (sort_iso_c_rename_list): Remove.
56 (import_iso_c_binding_module,use_iso_fortran_env_module):
57 Allow multiple imports of the same symbol.
59 2010-07-11 Mikael Morin <mikael@gcc.gnu.org>
61 * arith.c (gfc_arith_done_1): Release mpfr internal caches.
63 2010-07-11 Janus Weil <janus@gcc.gnu.org>
66 * decl.c (build_sym,attr_decl1): Only build the class container if the
67 symbol has sufficient attributes.
68 * expr.c (gfc_check_pointer_assign): Use class_pointer instead of
69 pointer attribute for classes.
70 * match.c (gfc_match_allocate,gfc_match_deallocate): Ditto.
71 * module.c (MOD_VERSION): Bump.
72 (enum ab_attribute,attr_bits): Add AB_CLASS_POINTER.
73 (mio_symbol_attribute): Handle class_pointer attribute.
74 * parse.c (parse_derived): Use class_pointer instead of pointer
75 attribute for classes.
76 * primary.c (gfc_variable_attr,gfc_expr_attr): Ditto.
77 * resolve.c (resolve_structure_cons,resolve_deallocate_expr,
78 resolve_allocate_expr,resolve_fl_derived): Ditto.
79 (resolve_fl_var_and_proc): Check for class_ok attribute.
81 2010-07-10 Mikael Morin <mikael@gcc.gnu.org>
83 * trans-io.c (gfc_build_st_parameter): Update calls to
84 gfc_add_field_to_struct.
85 * trans-stmt.c (ADD_FIELD): Ditto.
87 (gfc_get_derived_type): Ditto. Don't create backend_decl for C_PTR's
89 (gfc_add_field_to_struct_1): Set TYPE_FIELDS(context) instead of
90 fieldlist, remove fieldlist from argument list.
91 (gfc_add_field_to_struct): Update call to gfc_add_field_to_struct_1
92 and remove fieldlist from argument list.
93 (gfc_get_desc_dim_type, gfc_get_array_descriptor_base,
94 gfc_get_mixed_entry_union): Move setting
95 TYPE_FIELDS to gfc_add_field_to_struct_1 and update calls to it.
96 * trans-types.h (gfc_add_field_to_struct): Update prototype.
98 2010-07-10 Paul Thomas <pault@gcc.gnu.org>
101 * trans-expr.c (arrayfunc_assign_needs_temporary): No temporary
102 if the lhs has never been host associated, as well as not being
103 use associated, a pointer or a target.
104 * resolve.c (resolve_variable): Mark variables that are host
106 * gfortran.h: Add the host_assoc bit to the symbol_attribute
109 2010-07-09 Janus Weil <janus@gcc.gnu.org>
111 * intrinsic.texi: Add documentation for SAME_TYPE_AS, EXTENDS_TYPE_OF,
112 STORAGE_SIZE, C_NULL_PTR and C_NULL_FUNPTR. Modify documentation of
115 2010-07-08 Janus Weil <janus@gcc.gnu.org>
118 * gfortran.h (gfc_isym_id): Add GFC_ISYM_C_SIZEOF,GFC_ISYM_STORAGE_SIZE.
119 * intrinsic.h (gfc_check_c_sizeof,gfc_check_storage_size,
120 gfc_resolve_storage_size): New prototypes.
121 * check.c (gfc_check_c_sizeof,gfc_check_storage_size): New functions.
122 * intrinsic.c (add_functions): Add STORAGE_SIZE.
123 * iresolve.c (gfc_resolve_storage_size): New function.
124 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Handle polymorphic
126 (gfc_conv_intrinsic_storage_size): New function.
127 (gfc_conv_intrinsic_function): Handle STORAGE_SIZE.
129 2010-07-08 Jakub Jelinek <jakub@redhat.com>
132 * match.c (match_exit_cycle): Error on EXIT also from collapsed
133 !$omp do loops. Error on CYCLE to non-innermost collapsed
136 2010-07-08 Tobias Burnus <burnus@net-b.de>
139 * array.c (gfc_match_array_ref): Better error message for
140 coarrays with too few ranks.
141 (match_subscript): Move one diagnostic to caller.
142 * gfortran.h (gfc_get_corank): Add prottype.
143 * expr.c (gfc_get_corank): New function.
144 * iresolve.c (resolve_bound): Fix rank for cobounds.
145 (gfc_resolve_lbound,gfc_resolve_lcobound, gfc_resolve_ubound,
146 gfc_resolve_ucobound, gfc_resolve_this_image): Update
149 2010-07-06 Tobias Burnus <burnus@net-b.de>
152 * array.c (gfc_expand_constructor): Add optional diagnostic.
153 * gfortran.h (gfc_expand_constructor): Update prototype.
154 * expr.c (gfc_simplify_expr, check_init_expr,
155 gfc_reduce_init_expr): Update gfc_expand_constructor call.
156 * resolve.c (gfc_resolve_expr): Ditto.
158 2010-07-06 Tobias Burnus <burnus@net-b.de>
160 * trans-decl.c: Include diagnostic-core.h besides toplev.h.
161 * trans-intrinsic.c: Ditto.
162 * trans-types.c: Ditto.
163 * convert.c: Include diagnostic-core.h instead of toplev.h.
165 * trans-array.c: Ditto.
166 * trans-const.c: Ditto.
167 * trans-expr.c: Ditto.
169 * trans-openmp.c: Ditto.
172 2010-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
175 * check.c (dim_rank_check): Also check intrinsic functions.
176 Adjust permissible rank for functions which reduce the rank of
177 their argument. Spread is an exception, where DIM can
178 be one larger than the rank of array.
180 2010-07-05 Steven G. Kargl <kargl@gcc.gnu.org>
183 * fortran/io.c (resolve_tag): Check EXIST tag is a default logical.
185 2010-07-05 Paul Thomas <pault@gcc.gnu.org>
188 * trans-types.c (gfc_get_derived_type): Derived type fields
189 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set
190 but build_pointer_type_for_mode must be used for this.
192 2010-07-05 Nathan Froyd <froydnj@codesourcery.com>
194 * trans.h (gfc_conv_procedure_call): Take a VEC instead of a tree.
195 * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Adjust for new
196 type of gfc_conv_procedure_call.
197 (conv_generic_with_optional_char_arg): Likewise.
198 * trans-stmt.c (gfc_trans_call): Likewise.
199 * trans-expr.c (gfc_conv_function_expr): Likewise.
200 (gfc_conv_procedure_call): Use build_call_vec instead of
203 2010-07-04 Daniel Kraft <d@domob.eu>
205 * gfc-internals.texi (gfc_code): Document BLOCK and ASSOCIATE.
207 2010-07-04 Paul Thomas <pault@gcc.gnu.org>
211 * trans-types.c (gfc_get_derived_type): Derived type fields
212 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set.
214 2010-07-02 Mikael Morin <mikael@gcc.gnu.org>
217 * decl.c (match_procedure_in_type): Clear structure before using.
218 (gfc_match_generic): Ditto.
220 2010-07-02 Nathan Froyd <froydnj@codesourcery.com>
222 * trans-types.h (gfc_add_field_to_struct): Add tree ** parameter.
223 * trans-types.c (gfc_add_field_to_struct_1): New function, most
224 of which comes from...
225 (gfc_add_field_to_struct): ...here. Call it. Add new parameter.
226 (gfc_get_desc_dim_type): Call gfc_add_field_to_struct_1 for
228 (gfc_get_array_descriptor_base): Likewise.
229 (gfc_get_mixed_entry_union): Likewise.
230 (gfc_get_derived_type): Add extra chain parameter for
231 gfc_add_field_to_struct.
232 * trans-stmt.c (gfc_trans_character_select): Likewise.
233 * trans-io.c (gfc_build_st_parameter): Likewise.
235 2010-06-29 Janus Weil <janus@gcc.gnu.org>
238 * resolve.c (is_external_proc): Prevent procedure pointers from being
239 regarded as external procedures.
241 2010-06-29 Janus Weil <janus@gcc.gnu.org>
244 * trans-intrinsic.c (gfc_conv_associated): Handle polymorphic variables
245 passed as second argument of ASSOCIATED.
247 2010-06-29 Paul Thomas <pault@gcc.gnu.org>
250 * trans-expr.c (arrayfunc_assign_needs_temporary): New function
251 to determine if a function assignment can be made without a
253 (gfc_trans_arrayfunc_assign): Move all the conditions that
254 suppress the direct function call to the above new functon and
257 2010-06-28 Paul Thomas <pault@gcc.gnu.org>
260 * interface.c (argument_rank_mismatch): New function.
261 (compare_parameter): Call new function instead of generating
264 2010-06-28 Nathan Froyd <froydnj@codesourcery.com>
266 * trans-openmp.c (dovar_init): Define. Define VECs containing it.
267 (gfc_trans_omp_do): Use a VEC to accumulate variables and their
270 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
272 * Make-lang.in: Update dependencies.
274 2010-06-27 Nathan Froyd <froydnj@codesourcery.com>
276 * gfortran.h (gfc_code): Split backend_decl field into cycle_label
277 and exit_label fields.
278 * trans-openmp.c (gfc_trans_omp_do): Assign to new fields
280 * trans-stmt.c (gfc_trans_simple_do): Likewise.
281 (gfc_trans_do): Likewise.
282 (gfc_trans_do_while): Likewise.
283 (gfc_trans_cycle): Use cycle_label directly.
284 (gfc_trans_exit): Use exit_label directly.
286 2010-06-27 Daniel Kraft <d@domob.eu>
288 * dump-parse-tree.c (show_symbol): Dump target-expression for
290 (show_code_node): Make distinction between BLOCK and ASSOCIATE.
291 (show_namespace): Use show_level for correct indentation of
292 "inner namespaces" (contained procedures or BLOCK).
294 2010-06-27 Thomas Koenig <tkoenig@gcc.gnu.org>
297 * dump-parse-tree.c (show_code_node): Show namespace for
300 2010-06-26 Tobias Burnus <burnus@net-b.de>
302 * decl.c (gfc_match_decl_type_spec): Support
303 TYPE(intrinsic-type-spec).
305 2010-06-25 Tobias Burnus <burnus@net-b.de>
307 * intrinsic.h (gfc_check_selected_real_kind,
308 gfc_simplify_selected_real_kind): Update prototypes.
309 * intrinsic.c (add_functions): Add radix support to
311 * check.c (gfc_check_selected_real_kind): Ditto.
312 * simplify.c (gfc_simplify_selected_real_kind): Ditto.
313 * trans-decl.c (gfc_build_intrinsic_function_decls):
314 Change call from selected_real_kind to selected_real_kind2008.
315 * intrinsic.texi (SELECTED_REAL_KIND): Update for radix.
316 (PRECISION, RANGE, RADIX): Add cross @refs.
318 2010-06-25 Tobias Burnus <burnus@net-b.de>
320 * decl.c (gfc_match_entry): Mark ENTRY as GFC_STD_F2008_OBS.
321 * gfortran.texi (_gfortran_set_options): Update for
322 GFC_STD_F2008_OBS addition.
323 * libgfortran.h: Add GFC_STD_F2008_OBS.
324 * options.c (set_default_std_flags, gfc_handle_option): Handle
326 io.c (check_format): Fix allow_std check.
328 2010-06-25 Tobias Burnus <burnus@net-b.de>
330 * decl.c (gfc_match_entry): Allow END besides
331 END SUBROUTINE/END FUNCTION for contained procedures.
333 2010-06-25 Tobias Burnus <burnus@net-b.de>
335 * parse.c (next_free, next_fixed): Allow ";" as first character.
337 2010-06-24 Tobias Burnus <burnus@net-b.de>
340 * decl.c (variable_decl): Fix IMPORT diagnostic for CLASS.
342 2010-06-22 Janus Weil <janus@gcc.gnu.org>
345 * resolve.c (resolve_fl_derived): Avoid checking for abstract on class
348 2010-06-21 Tobias Burnus <burnus@net-b.de>
351 * interface.c (compare_parameter): Add gfc_is_simply_contiguous
353 * symbol.c (gfc_add_contiguous): New function.
354 (gfc_copy_attr, check_conflict): Handle contiguous attribute.
355 * decl.c (match_attr_spec): Ditto.
356 (gfc_match_contiguous): New function.
357 * resolve.c (resolve_fl_derived, resolve_symbol): Handle
359 * gfortran.h (symbol_attribute): Add contiguous.
360 (gfc_is_simply_contiguous): Add prototype.
361 (gfc_add_contiguous): Add prototype.
362 * match.h (gfc_match_contiguous): Add prototype.
363 * parse.c (decode_specification_statement,
364 decode_statement): Handle contiguous attribute.
365 * expr.c (gfc_is_simply_contiguous): New function.
366 * dump-parse-tree.c (show_attr): Handle contiguous.
367 * module.c (ab_attribute, attr_bits, mio_symbol_attribute):
369 * trans-expr.c (gfc_add_interface_mapping): Copy
371 * trans-array.c (gfc_conv_descriptor_stride_get,
372 gfc_conv_array_parameter): Handle contiguous arrays.
373 * trans-types.c (gfc_build_array_type, gfc_build_array_type,
374 gfc_sym_type, gfc_get_derived_type, gfc_get_array_descr_info):
376 * trans.h (gfc_array_kind): Ditto.
377 * trans-decl.c (gfc_get_symbol_decl): Ditto.
379 2010-06-20 Joseph Myers <joseph@codesourcery.com>
381 * options.c (gfc_handle_option): Don't handle N_OPTS.
383 2010-06-19 Janus Weil <janus@gcc.gnu.org>
386 * resolve.c (resolve_fl_derived): Reverse ordering of conditions
389 2010-06-18 Tobias Burnus <burnus@net-b.de>
392 * resolve.c (resolve_allocate_deallocate): Properly check
393 part-refs in stat=/errmsg= for invalid use.
395 2010-06-17 Janus Weil <janus@gcc.gnu.org>
398 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
399 Return directly in case of an error.
401 2010-06-16 Janus Weil <janus@gcc.gnu.org>
404 * gfortran.h (gfc_get_typebound_proc): Modified Prototype.
405 * decl.c (match_procedure_in_type): Give a unique gfc_typebound_proc
406 structure to each procedure in a procedure list.
407 * module.c (mio_typebound_proc): Add NULL argument to
408 'gfc_get_typebound_proc'.
409 * symbol.c (gfc_get_typebound_proc): Add a new argument, which is used
410 to initialize the new structure.
412 2010-06-15 Janus Weil <janus@gcc.gnu.org>
415 * gfortran.h (gfc_expr): Add new member 'mold'.
416 * match.c (gfc_match_allocate): Implement the MOLD tag.
417 * resolve.c (resolve_allocate_expr): Ditto.
418 * trans-stmt.c (gfc_trans_allocate): Ditto.
420 2010-06-15 Jakub Jelinek <jakub@redhat.com>
423 * trans-openmp.c (gfc_omp_predetermined_sharing): Don't return
424 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with
425 GFC_DECL_SAVED_DESCRIPTOR set.
426 (gfc_omp_report_decl): New function.
427 * trans.h (gfc_omp_report_decl): New prototype.
428 * f95-lang.c (LANG_HOOKS_OMP_REPORT_DECL): Redefine.
430 2010-06-13 Daniel Franke <franke.daniel@gmail.com>
434 * gfortranspec.c (lang_specific_driver): Removed deprecation
436 * lang.opt: Add options -M, -MM, -MD, -MMD, -MF, -MG, -MP, -MT, -MQ.
437 * lang-specs.h (CPP_FORWARD_OPTIONS): Add -M* options.
438 * cpp.h (gfc_cpp_makedep): New.
439 (gfc_cpp_add_dep): New.
440 (gfc_cpp_add_target): New.
441 * cpp.c (gfc_cpp_option): Add deps* members.
442 (gfc_cpp_makedep): New.
443 (gfc_cpp_add_dep): New.
444 (gfc_cpp_add_target): New.
445 (gfc_cpp_init_options): Initialize new options.
446 (gfc_cpp_handle_option): Handle new options.
447 (gfc_cpp_post_options): Map new options to libcpp-options.
448 (gfc_cpp_init): Handle deferred -MQ and -MT options.
449 (gfc_cpp_done): If requested, write dependencies to file.
450 * module.c (gfc_dump_module): Add a module filename as target.
451 * scanner.c (open_included_file): New parameter system; add the
452 included file as dependency.
453 (gfc_open_included_file): Add the included file as dependency.
454 (gfc_open_intrinsic_module): Likewise.
455 * invoke.texi: Removed deprecation warning for -M.
456 * gfortran.texi: Removed Makefile-dependencies project.
458 2010-06-12 Daniel Franke <franke.daniel@gmail.com>
460 * resolve.c (resolve_global_procedure): Improved checking if an
461 explicit interface is required.
463 2010-06-12 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
465 * trans-decl.c (gfc_build_intrinsic_function_decls): Fix
467 * trans-intrinsic.c (gfc_conv_intrinsic_fdate): Fix argument type.
468 (gfc_conv_intrinsic_ttynam): Likewise.
469 (gfc_conv_intrinsic_trim): Likewise.
471 2010-06-12 Janus Weil <janus@gcc.gnu.org>
474 * decl.c (match_procedure_in_type): Allow procedure lists (F08).
476 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
478 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Fix comment.
480 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
482 * mathbuiltins.def: Add builtins that do not directly correspond
483 to a Fortran intrinsic, with new macro OTHER_BUILTIN.
484 * f95-lang.c (gfc_init_builtin_functions): Define OTHER_BUILTIN.
485 * trans-intrinsic.c (gfc_intrinsic_map_t): Remove
486 code_{r,c}{4,8,10,16} fields. Add
487 {,complex}{float,double,long_double}_built_in fields.
488 (gfc_intrinsic_map): Adjust definitions of DEFINE_MATH_BUILTIN,
489 DEFINE_MATH_BUILTIN_C and LIB_FUNCTION accordingly. Add
490 definition of OTHER_BUILTIN.
491 (real_compnt_info): Remove unused struct.
492 (builtin_decl_for_precision, builtin_decl_for_float_kind): New
494 (build_round_expr): Call builtin_decl_for_precision instead of
496 (gfc_conv_intrinsic_aint): Call builtin_decl_for_float_kind
498 (gfc_build_intrinsic_lib_fndecls): Match
499 {real,complex}{4,8,10,16}decl into the C-style built_in_decls.
500 (gfc_get_intrinsic_lib_fndecl): Do not hardcode floating-point
502 (gfc_conv_intrinsic_lib_function): Go through all the extended
504 (gfc_trans_same_strlen_check): Call builtin_decl_for_float_kind
506 (gfc_conv_intrinsic_abs): Likewise.
507 (gfc_conv_intrinsic_mod): Likewise.
508 (gfc_conv_intrinsic_sign): Likewise.
509 (gfc_conv_intrinsic_fraction): Likewise.
510 (gfc_conv_intrinsic_nearest): Likewise.
511 (gfc_conv_intrinsic_spacing): Likewise.
512 (gfc_conv_intrinsic_rrspacing): Likewise.
513 (gfc_conv_intrinsic_scale): Likewise.
514 (gfc_conv_intrinsic_set_exponent): Likewise.
516 2010-06-11 Paul Thomas <pault@gcc.gnu.org>
520 * trans-expr.c (gfc_conv_derived_to_class): Handle array-valued
521 functions with CLASS formal arguments.
523 2010-06-10 Janus Weil <janus@gcc.gnu.org>
526 * resolve.c (conformable_arrays): Handle allocatable components.
528 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
531 * gfortran.texi: Document that Cray pointers cannot be function
534 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
537 * gfortran.texi: Document lack of support for syntax
538 "complex FUNCTION name*16()", and existence of alternative
539 legacy syntax "complex*16 FUNCTION name()".
541 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
544 * intrinsic.texi (FLUSH): Note the difference between FLUSH and
545 POSIX's fsync(), and how to call the latter from Fortran code.
547 2010-06-10 Daniel Franke <franke.daniel@gmail.com>
550 * interface.c (compare_actual_formal): Reject actual arguments with
551 array subscript passed to ASYNCHRONOUS dummys.
553 2010-06-10 Daniel Kraft <d@domob.eu>
556 * gfortran.h (enum gfc_statement): Add ST_ASSOCIATE, ST_END_ASSOCIATE.
557 (struct gfc_symbol): New field `assoc'.
558 (struct gfc_association_list): New struct.
559 (struct gfc_code): New struct `block' in union, move `ns' there
560 and add association list.
561 (gfc_free_association_list): New method.
562 (gfc_has_vector_subscript): Made public;
563 * match.h (gfc_match_associate): New method.
564 * parse.h (enum gfc_compile_state): Add COMP_ASSOCIATE.
565 * decl.c (gfc_match_end): Handle ST_END_ASSOCIATE.
566 * interface.c (gfc_has_vector_subscript): Made public.
567 (compare_actual_formal): Rename `has_vector_subscript' accordingly.
568 * match.c (gfc_match_associate): New method.
569 (gfc_match_select_type): Change reference to gfc_code's `ns' field.
570 * primary.c (match_variable): Don't allow names associated to expr here.
571 * parse.c (decode_statement): Try matching ASSOCIATE statement.
572 (case_exec_markers, case_end): Add ASSOCIATE statement.
573 (gfc_ascii_statement): Hande ST_ASSOCIATE and ST_END_ASSOCIATE.
574 (parse_associate): New method.
575 (parse_executable): Handle ST_ASSOCIATE.
576 (parse_block_construct): Change reference to gfc_code's `ns' field.
577 * resolve.c (resolve_select_type): Ditto.
578 (resolve_code): Ditto.
579 (resolve_block_construct): Ditto and add comment.
580 (resolve_select_type): Set association list in generated BLOCK to NULL.
581 (resolve_symbol): Resolve associate names.
582 * st.c (gfc_free_statement): Change reference to gfc_code's `ns' field
583 and free association list.
584 (gfc_free_association_list): New method.
585 * symbol.c (gfc_new_symbol): NULL new field `assoc'.
586 * trans-stmt.c (gfc_trans_block_construct): Change reference to
587 gfc_code's `ns' field.
589 2010-06-10 Kai Tietz <kai.tietz@onevision.com>
591 * error.c (error_print): Pre-initialize loc by NULL.
592 * openmp.c (resolve_omp_clauses): Add explicit
593 braces to avoid ambigous else.
594 * array.c (match_subscript): Pre-initialize m to MATCH_ERROR.
596 2010-06-10 Gerald Pfeifer <gerald@pfeifer.com>
598 * gfc-internals.texi: Move to GFDL 1.3.
599 * gfortran.texi: Ditto.
600 * intrinsic.texi: Ditto.
601 * invoke.texi: Ditto.
603 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
606 * check.c (gfc_check_selected_real_kind): Verify that the
607 actual arguments are scalar.
609 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
612 * intrinsic.c (gfc_convert_type_warn): Further improve -Wconversion.
614 2010-06-09 Janus Weil <janus@gcc.gnu.org>
617 * dump-parse-tree.c (show_symbol): Avoid infinite loop.
619 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
621 * fortran/symbol.c (check_conflict): Remove an invalid conflict check.
623 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
625 * fortran/intrinsic.c (add_functions): Change gfc_check_btest,
626 gfc_check_ibclr, and gfc_check_ibset to gfc_check_bitfcn.
627 * fortran/intrinsic.h: Remove prototypes for gfc_check_btest,
628 gfc_check_ibclr, and gfc_check_ibset. Add prototype for
630 * fortran/check.c (nonnegative_check, less_than_bitsize1,
631 less_than_bitsize2): New functions.
632 (gfc_check_btest): Renamed to gfc_check_bitfcn. Use
633 nonnegative_check and less_than_bitsize1.
634 (gfc_check_ibclr, gfc_check_ibset): Removed.
635 (gfc_check_ibits,gfc_check_mvbits): Use nonnegative_check and
638 2010-06-09 Janus Weil <janus@gcc.gnu.org>
641 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
644 2010-06-09 Kai Tietz <kai.tietz@onevision.com>
646 * resolve.c (resolve_deallocate_expr): Avoid warning
647 about possible use of iunitialized sym.
648 (resolve_allocate_expr): Pre-initialize sym by NULL.
650 2010-06-09 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
653 * f95-lang.c (gfc_init_builtin_functions): Remove comment.
655 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
657 * trans-types.c (gfc_get_nodesc_array_type): Use typed GC
659 (gfc_get_array_type_bounds): Likewise.
661 * trans-decl.c (gfc_allocate_lang_decl): Likewise.
662 (gfc_find_module): Likewise.
664 * f95-lang.c (pushlevel): Likewise.
666 * trans.h (struct lang_type): Add variable_size GTY option.
667 (struct lang_decl): Likewise.
669 2010-06-08 Tobias Burnus <burnus@net-b.de>
672 * symbol.c (check_conflict): Move protected--external/procedure check ...
673 * resolve.c (resolve_select_type): ... to the resolution stage.
675 2010-06-07 Tobias Burnus <burnus@net-b.de>
677 * options.c (gfc_handle_option): Fix -fno-recursive.
679 2010-06-07 Tobias Burnus <burnus@net-b.de>
681 * gfc-internals.texi (copyrights-gfortran): Fix copyright year format.
682 * gfortran.texi (copyrights-gfortran): Ditto.
684 2010-06-07 Joseph Myers <joseph@codesourcery.com>
686 * lang.opt (fshort-enums): Define using Var and VarExists.
687 * options.c (gfc_handle_option): Don't set flag_short_enums here.
689 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
690 Janus Weil <janus@gcc.gnu.org>
693 * resolve.c (get_declared_from_expr): Move to before
694 resolve_typebound_generic_call. Make new_ref and class_ref
695 ignorable if set to NULL.
696 (resolve_typebound_generic_call): Once we have resolved the
697 generic call, check that the specific instance is that which
698 is bound to the declared type.
699 (resolve_typebound_function,resolve_typebound_subroutine): Avoid
700 freeing 'class_ref->next' twice.
702 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
705 * trans-array.c (structure_alloc_comps): Dereference scalar
706 'decl' if it is a REFERENCE_TYPE. Tidy expressions containing
709 2010-06-04 Joseph Myers <joseph@codesourcery.com>
711 * gfortranspec.c (append_arg, lang_specific_driver): Use
712 GCC-specific formats in diagnostics.
714 2010-06-02 Tobias Burnus <burnus@net-b.de>
717 * parse.c (gfc_fixup_sibling_symbols): Do not "fix" use-associated
720 2010-06-01 Jerry DeLisle <jvdelisle@gcc.gnu.org>
723 * match.c (gfc_match_stopcode): Move gfc_match_eos call inside
726 2010-05-31 Steven G. Kargl <kargl@gcc.gnu.org>
728 * fortran/gfortran.texi: Fix typos in description of variable-format-
731 2010-05-31 Thomas Koenig <tkoenig@gcc.gnu.org>
734 * dependency.c (gfc_check_section_vs_section): Check
735 for interleaving array assignments without conflicts.
737 2010-05-30 Janus Weil <janus@gcc.gnu.org>
739 * gcc/fortran/gfortran.h (CLASS_DATA): New macro for accessing the
740 $data component of a class container.
741 * gcc/fortran/decl.c (attr_decl1): Use macro CLASS_DATA.
742 * gcc/fortran/expr.c (gfc_check_pointer_assign,gfc_check_assign_symbol,
743 gfc_has_ultimate_allocatable,gfc_has_ultimate_pointer): Ditto.
744 * gcc/fortran/interface.c (matching_typebound_op): Ditto.
745 * gcc/fortran/match.c (gfc_match_allocate, gfc_match_deallocate): Ditto.
746 * gcc/fortran/parse.c (parse_derived): Ditto.
747 * gcc/fortran/primary.c (gfc_match_varspec, gfc_variable_attr,
748 gfc_expr_attr): Ditto.
749 * gcc/fortran/resolve.c (resolve_structure_cons, find_array_spec,
750 resolve_deallocate_expr, resolve_allocate_expr, resolve_select_type,
751 resolve_fl_var_and_proc, resolve_typebound_procedure,
752 resolve_fl_derived): Ditto.
753 * gcc/fortran/symbol.c (gfc_type_compatible): Restructured.
754 * gcc/fortran/trans-array.c (structure_alloc_comps): Use macro
756 * gcc/fortran/trans-decl.c (gfc_get_symbol_decl,
757 gfc_trans_deferred_vars): Ditto.
758 * gcc/fortran/trans-stmt.c (gfc_trans_allocate): Ditto.
760 2010-05-28 Tobias Burnus <burnus@net-b.de>
762 * options.c (gfc_handle_option): Fix handling of -fno-whole-file.
764 2010-05-28 Joseph Myers <joseph@codesourcery.com>
766 * gfortranspec.c (append_arg, lang_specific_driver): Use
767 fatal_error instead of fatal. Use warning instead of fprintf for
770 2010-05-28 Joseph Myers <joseph@codesourcery.com>
772 * cpp.c (gfc_cpp_init_0): Use xstrerror instead of strerror.
773 * module.c (write_char, gfc_dump_module, gfc_use_module): Use
774 xstrerror instead of strerror.
776 2010-05-26 Joseph Myers <joseph@codesourcery.com>
778 * cpp.c (cb_cpp_error): Save and restore
779 global_dc->warn_system_headers, not variable warn_system_headers.
781 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
783 * fortran/f95-lang.c: Do not include libfuncs.h, expr.h, and except.h.
785 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
787 * trans-common.c: Do not include rtl.h, include output.h instead.
788 * trans-decl.c: Likewise.
790 2010-05-26 Paul Thomas <pault@gcc.gnu.org>
793 * resolve.c (resolve_global_procedure): Resolve the gsymbol's
794 namespace before trying to reorder the gsymbols.
796 2010-05-25 Daniel Franke <franke.daniel@gmail.com>
801 * resolve.c (resolve_global_procedure): Add check for global
802 procedures with implicit interfaces and assumed-shape or optional
803 dummy arguments. Verify that function return type, kind and string
806 2010-05-21 Tobias Burnus <burnus@net-b.de>
808 * gfortran.h: Do not include system.h.
809 * bbt.c: Include system.h.
811 * dependency.c: Ditto.
812 * dump-parse-tree.c: Ditto.
813 * arith.h: Do not include gfortran.h.
814 * constructor.h: Do not include gfortran.h and splay-tree.h.
815 * match.h: Do not include gfortran.h.
817 * target-memory.h: Ditto.
818 * openmp.c: Do not include toplev.h and target.h.
819 * trans-stmt.c: Ditto not include toplev.h.
821 * trans-common.c: Tell why toplev.h is needed. And
822 do not include target.h.
823 * trans-expr.c: Tell why toplev.h is needed.
824 * trans-array.c: Ditto.
825 * trans-openmp.c: Ditto.
826 * trans-const.c: Ditto.
828 * trans-types.c: Ditto.
830 * trans-decl.c: Ditto.
833 * trans-intrinsic.c: Ditto.
836 2010-05-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
839 * match.c (gfc_match_stopcode): Use gfc_match_init_expr. Go to cleanup
840 before returning MATCH_ERROR. Add check for scalar. Add check for
841 default integer kind.
843 2010-05-22 Janus Weil <janus@gcc.gnu.org>
846 * match.c (gfc_match_select_type): On error jump back out of the local
848 * parse.c (parse_derived): Defer creation of vtab symbols to resolution
849 stage, more precisely to ...
850 * resolve.c (resolve_fl_derived): ... this place.
852 2010-05-22 Janus Weil <janus@gcc.gnu.org>
855 * resolve.c (ensure_not_abstract): Allow abstract types with
856 non-abstract ancestors.
858 2010-05-21 Steven Bosscher <steven@gcc.gnu.org>
860 * trans-const.c: Include realmpfr.h.
861 * Make-lang.in: Update dependencies.
863 2010-05-21 Steven Bosscher <steven@gcc.gnu.org>
865 * trans-const.c, trans-types.c, trans-intrinsic.c:
866 Clean up redundant includes.
868 2010-05-20 Daniel Franke <franke.daniel@gmail.com>
871 * lang.opt (Wunused-dummy-argument): New option.
872 * gfortran.h (gfc_option_t): Add warn_unused_dummy_argument.
873 * options.c (gfc_init_options): Disable warn_unused_dummy_argument.
874 (set_Wall): Enable warn_unused_dummy_argument.
875 (gfc_handle_option): Set warn_unused_dummy_argument according to
877 * trans-decl.c (generate_local_decl): Separate warnings about
878 unused variables and unused dummy arguments.
879 * invoke.texi: Documented new option.
881 2010-05-20 Steven Bosscher <steven@gcc.gnu.org>
883 * trans-expr.c: Do not include convert.h, ggc.h, real.h, and gimple.h.
884 (gfc_conv_string_tmp): Do not assert type comparibilty.
885 * trans-array.c: Do not include gimple.h, ggc.h, and real.h.
886 (gfc_conv_expr_descriptor): Remove assert.
887 * trans-common.c: Clarify why rtl.h and tm.h are included.
888 * trans-openmp.c: Do not include ggc.h and real.h.
889 Explain why gimple.h is included.
890 * trans-const.c: Do not include ggc.h.
891 * trans-stmt.c: Do not include gimple.h, ggc.h, and real.h.
892 * trans.c: Do not include ggc.h and real.h.
893 Explain why gimple.h is included.
894 * trans-types.c: Do not include tm.h. Explain why langhooks.h
895 and dwarf2out.h are included.
896 * trans-io.c: Do not include gimple.h and real.h.
897 * trans-decl.c: Explain why gimple.h, tm.h, and rtl.h are included.
898 * trans-intrinsic.c: Do not include gimple.h. Explain why tm.h
901 2010-05-20 Tobias Burnus <burnus@net-b.de>
903 * options.c (gfc_init_options,gfc_post_options): Enable
904 flag_associative_math by default.
906 2010-05-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
909 * trans-stmt.c (gfc_trans_stop): Add generation of call to
910 gfortran_error_stop_numeric. Fix up some whitespace. Use stop_string for
911 blank STOP, handling a null expression. (gfc_trans_pause): Use
912 pause_string for blank PAUSE.
913 * trans.h: Add external function declaration for error_stop_numeric.
914 * trans-decl.c (gfc_build_builtin_function_decls): Add the building of
915 the declaration for the library call. Adjust whitespaces.
916 * match.c (gfc_match_stopcode): Remove use of the actual stop code to
917 signal no stop code. Match the expression following the stop and pass
918 that to the translators. Remove the old use of digit matching. Add
919 checks that the stop_code expression is INTEGER or CHARACTER, constant,
920 and if CHARACTER, default character KIND.
922 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
925 * lang.opt (Wconversion-extra): New option.
926 * gfortran.h (gfc_option_t): Add warn_conversion_extra.
927 * options.c (gfc_init_options): Disable -Wconversion-extra by default.
928 (set_Wall): Enable -Wconversion.
929 (gfc_handle_option): Set warn_conversion_extra.
930 * intrinsic.c (gfc_convert_type_warn): Ignore kind conditions
931 introduced for -Wconversion if -Wconversion-extra is present.
932 * invoke.texi: Add -Wconversion to -Wall; document new behaviour of
933 -Wconversion; document -Wconversion-extra.
935 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
938 * gfortran.h (gfc_has_default_initializer): New.
939 * expr.c (gfc_has_default_initializer): New.
940 * resolve.c (has_default_initializer): Removed, use
941 gfc_has_default_initializer() instead. Updated all callers.
942 * trans-array.c (has_default_initializer): Removed, use
943 gfc_has_default_initializer() instead. Updated all callers.
944 * trans-decl.c (generate_local_decl): Do not check the
945 first component only to check for initializers, but use
946 gfc_has_default_initializer() instead.
948 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
951 * primary.c (match_string_constant): Move start_locus just inside
953 * data.c (create_character_intializer): Clarified truncation warning.
955 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
958 * intrinsic.h (gfc_check_float): New prototype.
959 (gfc_check_sngl): New prototype.
960 * check.c (gfc_check_float): New.
961 (gfc_check_sngl): New.
962 * intrinsic.c (add_functions): Moved DFLOAT from aliasing DBLE
963 to be a specific for REAL. Added check routines for FLOAT, DFLOAT
965 * intrinsic.texi: Removed individual nodes of FLOAT, DFLOAT and SNGL,
966 added them to the list of specifics of REAL instead.
968 2010-05-17 Janus Weil <janus@gcc.gnu.org>
971 * trans-expr.c (gfc_conv_structure): Remove unneeded and buggy code.
972 This is now handled via 'gfc_class_null_initializer'.
974 2010-05-17 Janus Weil <janus@gcc.gnu.org>
976 * class.c (gfc_add_component_ref,gfc_class_null_initializer,
977 gfc_build_class_symbol,add_proc_component,add_proc_comps,
978 add_procs_to_declared_vtab1,copy_vtab_proc_comps,
979 add_procs_to_declared_vtab,add_generic_specifics,
980 add_generics_to_declared_vtab,gfc_find_derived_vtab,
981 find_typebound_proc_uop,gfc_find_typebound_proc,
982 gfc_find_typebound_user_op,gfc_find_typebound_intrinsic_op,
983 gfc_get_tbp_symtree): Moved here from other places.
984 * expr.c (gfc_add_component_ref,gfc_class_null_initializer): Move to
986 * gfortran.h (gfc_build_class_symbol,gfc_find_derived_vtab,
987 gfc_find_typebound_proc,gfc_find_typebound_user_op,
988 gfc_find_typebound_intrinsic_op,gfc_get_tbp_symtree,
989 gfc_add_component_ref, gfc_class_null_initializer): Moved to class.c.
990 * Make-lang.in: Add class.o.
991 * symbol.c (gfc_build_class_symbol,add_proc_component,add_proc_comps,
992 add_procs_to_declared_vtab1,copy_vtab_proc_comps,
993 add_procs_to_declared_vtab,add_generic_specifics,
994 add_generics_to_declared_vtab,gfc_find_derived_vtab,
995 find_typebound_proc_uop,gfc_find_typebound_proc,
996 gfc_find_typebound_user_op,gfc_find_typebound_intrinsic_op,
997 gfc_get_tbp_symtree): Move to class.c.
999 2010-05-17 Nathan Froyd <froydnj@codesourcery.com>
1001 * trans-types.c (gfc_init_types): Use build_function_type_list.
1002 (gfc_get_ppc_type): Likewise.
1003 * trans-decl.c (gfc_generate_constructors): Likewise.
1004 * f95-lang.c (build_builtin_fntypes): Likewise.
1005 (gfc_init_builtin_functions): Likewise.
1006 (DEF_FUNCTION_TYPE_0): Likewise.
1007 (DEF_FUNCTION_TYPE_1): Likewise.
1008 (DEF_FUNCTION_TYPE_2): Likewise.
1009 (DEF_FUNCTION_TYPE_3): Likewise.
1010 (DEF_FUNCTION_TYPE_4): Likewise.
1011 (DEF_FUNCTION_TYPE_5): Likewise.
1012 (DEF_FUNCTION_TYPE_6): Likewise.
1013 (DEF_FUNCTION_TYPE_7): Likewise. Use ARG7.
1014 (DEF_FUNCTION_TYPE_VAR_0): Use build_varags_function_type_list.
1016 2010-05-17 Nathan Froyd <froydnj@codesourcery.com>
1018 * trans-array.c (gfc_trans_array_constructor_value): Use
1019 build_constructor instead of build_constructor_from_list.
1020 (gfc_build_constant_array_constructor): Likewise.
1021 * trans-decl.c (create_main_function): Likewise.
1022 * trans-stmt.c (gfc_trans_character_select): Likewise.
1024 2010-05-17 Janus Weil <janus@gcc.gnu.org>
1027 * resolve.c (resolve_fl_var_and_proc): Move error messages here from ...
1028 (resolve_fl_variable_derived): ... this place.
1029 (resolve_symbol): Make sure function symbols (and their result
1030 variables) are not resolved twice.
1032 2010-05-16 Daniel Franke <franke.daniel@gmail.com>
1035 * array.c (match_array_list): Revert change from 2010-05-13.
1037 2010-05-16 Richard Guenther <rguenther@suse.de>
1039 * trans-decl.c (module_htab_decls_hash): Revert last change.
1041 2010-05-16 Richard Guenther <rguenther@suse.de>
1043 * trans-decl.c (module_htab_decls_hash): Use IDENTIFIER_HASH_VALUE.
1045 2010-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
1047 * options.c (set_Wall): Remove special logic for Wuninitialized
1050 2010-05-15 Janus Weil <janus@gcc.gnu.org>
1054 * trans-decl.c (gfc_trans_deferred_vars): Modify ordering of
1057 2010-05-15 Janus Weil <janus@gcc.gnu.org>
1061 * gfortran.h (gfc_class_null_initializer): New prototype.
1062 * expr.c (gfc_class_null_initializer): New function to build a NULL
1063 initializer for CLASS pointers.
1064 * symbol.c (gfc_build_class_symbol): Modify internal naming of class
1065 containers. Remove default NULL initialization of $data component.
1066 * trans.c (gfc_allocate_array_with_status): Fix wording of an error
1068 * trans-expr.c (gfc_conv_initializer,gfc_trans_subcomponent_assign):
1069 Use new function 'gfc_class_null_initializer'.
1070 * trans-intrinsic.c (gfc_conv_allocated): Handle allocatable scalar
1073 2010-05-14 Steven G. Kargl <kargl@gcc.gnu.org>
1076 * fortran/interface.c (get_sym_storage_size): Use signed instead of
1077 unsigned mpz_get_?i routines.
1079 2010-05-14 Jakub Jelinek <jakub@redhat.com>
1081 * trans.c (trans_code): Set backend locus early.
1082 * trans-decl.c (gfc_get_fake_result_decl): Use source location
1083 of the function instead of current input_location.
1085 2010-05-13 Daniel Franke <franke.daniel@gmail.com>
1088 * intrinsic.c (gfc_init_expr): Renamed to gfc_init_expr_flag.
1090 * expr.c (init_flag): Removed; use gfc_init_expr_flag everywhere.
1091 * array.c (match_array_list): Pass on gfc_init_expr_flag when matching
1094 2010-05-13 Jakub Jelinek <jakub@redhat.com>
1097 * openmp.c (resolve_omp_clauses): Allow procedure pointers in clause
1099 * trans-openmp.c (gfc_omp_privatize_by_reference): Don't privatize
1100 by reference dummy procedures or non-dummy procedure pointers.
1101 (gfc_omp_predetermined_sharing): Return
1102 OMP_CLAUSE_DEFAULT_FIRSTPRIVATE for dummy procedures.
1104 2010-05-11 Daniel Franke <franke.daniel@gmail.com>
1107 * openmp.c (gfc_match_omp_taskwait): Report unexpected characters
1108 after OMP statement.
1109 (gfc_match_omp_critical): Likewise.
1110 (gfc_match_omp_flush): Likewise.
1111 (gfc_match_omp_workshare): Likewise.
1112 (gfc_match_omp_master): Likewise.
1113 (gfc_match_omp_ordered): Likewise.
1114 (gfc_match_omp_atomic): Likewise.
1115 (gfc_match_omp_barrier): Likewise.
1116 (gfc_match_omp_end_nowait): Likewise.
1118 2010-05-11 Daniel Franke <franke.daniel@gmail.com>
1121 * resolve.c (validate_case_label_expr): Removed FIXME.
1122 (resolve_select): Raise default warning on case labels out of range
1123 of the case expression.
1125 2010-05-10 Daniel Franke <franke.daniel@gmail.com>
1130 * intrinsic.c (gfc_convert_type_warn): Be more discriminative
1131 about conversion warnings.
1133 2010-05-10 Janus Weil <janus@gcc.gnu.org>
1136 * match.c (gfc_match_select_type): Move error message to
1137 resolve_select_type.
1138 * resolve.c (resolve_select_type): Error message moved here from
1139 gfc_match_select_type. Correctly set type of temporary.
1141 2010-05-10 Richard Guenther <rguenther@suse.de>
1143 * trans-decl.c (gfc_build_library_function_decl): Split out
1145 (build_library_function_decl_1): ... this new function.
1146 Set a fnspec attribute if a specification was provided.
1147 (gfc_build_library_function_decl_with_spec): New function.
1148 (gfc_build_intrinsic_function_decls): Annotate internal_pack
1149 and internal_unpack.
1151 2010-05-07 Daniel Franke <franke.daniel@gmail.com>
1154 * intrinc.c (gfc_is_intrinsic): Do not prematurely mark symbol
1157 2010-05-07 Jason Merrill <jason@redhat.com>
1159 * trans-expr.c (gfc_conv_procedure_call): Rename nullptr to null_ptr
1160 to avoid -Wc++-compat warning.
1162 2010-05-06 Manuel López-Ibáñez <manu@gcc.gnu.org>
1165 * options.c (gfc_handle_option): Add argument kind.
1166 * gfortran.h (gfc_handle_option): Update declaration.
1168 2010-05-06 Tobias Burnus <burnus@net-b.de>
1171 * trans-types.c (gfc_sym_type): Mark Cray pointees as
1174 2010-05-05 Daniel Franke <franke.daniel@gmail.com>
1177 * resolve.c (traverse_data_list): Rephrase error message for
1178 non-constant bounds in data-implied-do.
1180 2010-05-05 Daniel Franke <franke.daniel@gmail.com>
1183 * gfortran.h: Removed repeat count from constructor, removed
1185 * data.h (gfc_assign_data_value_range): Changed return value from
1187 * data.c (gfc_assign_data_value): Add location to constructor element.
1188 (gfc_assign_data_value_range): Call gfc_assign_data_value()
1189 for each element in range. Return early if an error was generated.
1190 * resolve.c (check_data_variable): Stop early if range assignment
1193 2010-05-05 Janus Weil <janus@gcc.gnu.org>
1196 * resolve.c (resolve_fl_derived): Some fixes for class variables.
1197 * symbol.c (gfc_build_class_symbol): Add separate class container for
1200 2010-05-03 Steven G. Kargl <kargl@gcc.gnu.org>
1203 * fortran/parse.c (parse_interface): Do not dereference a NULL pointer.
1205 2010-05-02 Tobias Burnus <burnus@net-b.de>
1208 * intrinsic.c (add_functions): Fix GFC_STD and add gfc_resolve_ calls
1209 for lcobound, ucobound, image_index and this_image.
1210 * intrinsic.h (gfc_resolve_lcobound, gfc_resolve_this_image,
1211 gfc_resolve_image_index, gfc_resolve_ucobound): New prototypes.
1212 * iresolve.c (gfc_resolve_lcobound, gfc_resolve_this_image,
1213 gfc_resolve_image_index, gfc_resolve_ucobound, resolve_bound): New
1215 (gfc_resolve_lbound, gfc_resolve_ubound): Use resolve_bound.
1217 2010-04-30 Tobias Burnus <burnus@net-b.de>
1221 * trans-types.c (gfc_get_array_descriptor_base): Fix index
1222 calculation for array descriptor types.
1224 2010-04-29 Janus Weil <janus@gcc.gnu.org>
1227 * symbol.c (add_proc_component,copy_vtab_proc_comps): Remove
1228 initializers for PPC members of the vtabs.
1230 2010-04-29 Janus Weil <janus@gcc.gnu.org>
1233 * symbol.c (add_proc_component,add_proc_comps): Correctly set the 'ppc'
1234 attribute for all PPC members of the vtypes.
1235 (copy_vtab_proc_comps): Copy the correct interface.
1236 * trans.h (gfc_trans_assign_vtab_procs): Modified prototype.
1237 * trans-expr.c (gfc_trans_assign_vtab_procs): Pass the derived type as
1238 a dummy argument and make sure all PPC members of the vtab are
1239 initialized correctly.
1240 (gfc_conv_derived_to_class,gfc_trans_class_assign): Additional argument
1241 in call to gfc_trans_assign_vtab_procs.
1242 * trans-stmt.c (gfc_trans_allocate): Ditto.
1244 2010-04-29 Paul Thomas <pault@gcc.gnu.org>
1247 * resolve.c (resolve_typebound_function): Renamed
1248 resolve_class_compcall.Do all the detection of class references
1250 (resolve_typebound_subroutine): resolve_class_typebound_call
1251 renamed. Otherwise same as resolve_typebound_function.
1252 (gfc_resolve_expr): Call resolve_typebound_function.
1253 (resolve_code): Call resolve_typebound_subroutine.
1255 2010-04-29 Janus Weil <janus@gcc.gnu.org>
1258 * resolve.c (resolve_typebound_generic_call): For CLASS methods
1259 pass back the specific symtree name, rather than the target
1262 2010-04-29 Paul Thomas <pault@gcc.gnu.org>
1265 * resolve.c (resolve_structure_cons): Make the initializer of
1266 the vtab component 'extends' the same type as the component.
1268 2010-04-29 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1271 * interface.c (check_interface1): Pass symbol name rather than NULL to
1272 gfc_compare_interfaces.(gfc_compare_interfaces): Add assert to
1273 trap MULL. (gfc_compare_derived_types): Revert previous change
1274 incorporated incorrectly during merge from trunk, r155778.
1275 * resolve.c (check_generic_tbp_ambiguity): Pass symbol name rather
1276 than NULL to gfc_compare_interfaces.
1277 * symbol.c (add_generic_specifics): Likewise.
1279 2010-02-29 Janus Weil <janus@gcc.gnu.org>
1282 * interface.c (gfc_compare_derived_types): Add condition for vtype.
1283 * symbol.c (gfc_find_derived_vtab): Sey access to private.
1284 (gfc_find_derived_vtab): Likewise.
1285 * module.c (ab_attribute): Add enumerator AB_VTAB.
1286 (mio_symbol_attribute): Use new attribute, AB_VTAB.
1287 (check_for_ambiguous): Likewise.
1289 2010-04-29 Paul Thomas <pault@gcc.gnu.org>
1290 Janus Weil <janus@gcc.gnu.org>
1293 * trans-expr.c (select_class_proc): Remove function.
1294 (conv_function_val): Delete reference to previous.
1295 (gfc_conv_derived_to_class): Add second argument to the call to
1296 gfc_find_derived_vtab.
1297 (gfc_conv_structure): Exclude proc_pointer components when
1298 accessing $data field of class objects.
1299 (gfc_trans_assign_vtab_procs): New function.
1300 (gfc_trans_class_assign): Add second argument to the call to
1301 gfc_find_derived_vtab.
1302 * symbol.c (gfc_build_class_symbol): Add delayed_vtab arg and
1303 implement holding off searching for the vptr derived type.
1304 (add_proc_component): New function.
1305 (add_proc_comps): New function.
1306 (add_procs_to_declared_vtab1): New function.
1307 (copy_vtab_proc_comps): New function.
1308 (add_procs_to_declared_vtab): New function.
1309 (void add_generic_specifics): New function.
1310 (add_generics_to_declared_vtab): New function.
1311 (gfc_find_derived_vtab): Add second argument to the call to
1312 gfc_find_derived_vtab. Add the calls to
1313 add_procs_to_declared_vtab and add_generics_to_declared_vtab.
1314 * decl.c (build_sym, build_struct): Use new arg in calls to
1315 gfc_build_class_symbol.
1316 * gfortran.h : Add vtype bitfield to symbol_attr. Remove the
1317 definition of struct gfc_class_esym_list. Modify prototypes
1318 of gfc_build_class_symbol and gfc_find_derived_vtab.
1319 * trans-stmt.c (gfc_trans_allocate): Add second argument to the
1320 call to gfc_find_derived_vtab.
1321 * module.c : Add the vtype attribute.
1322 * trans.h : Add prototype for gfc_trans_assign_vtab_procs.
1323 * resolve.c (resolve_typebound_generic_call): Add second arg
1324 to pass along the generic name for class methods.
1325 (resolve_typebound_call): The same.
1326 (resolve_compcall): Use the second arg to carry the generic
1327 name from the above. Remove the reference to class_esym.
1328 (check_members, check_class_members, resolve_class_esym,
1329 hash_value_expr): Remove functions.
1330 (resolve_class_compcall, resolve_class_typebound_call): Modify
1331 to use vtable rather than member by member calls.
1332 (gfc_resolve_expr): Modify second arg in call to
1334 (resolve_select_type): Add second arg in call to
1335 gfc_find_derived_vtab.
1336 (resolve_code): Add second arg in call resolve_typebound_call.
1337 (resolve_fl_derived): Exclude vtypes from check for late
1338 procedure definitions. Likewise for checking of explicit
1339 interface and checking of pass arg.
1340 * iresolve.c (gfc_resolve_extends_type_of): Add second arg in
1341 calls to gfc_find_derived_vtab.
1342 * match.c (select_type_set_tmp): Use new arg in call to
1343 gfc_build_class_symbol.
1344 * trans-decl.c (gfc_get_symbol_decl): Complete vtable if
1346 * parse.c (endType): Finish incomplete classes.
1348 2010-04-28 Tobias Burnus <burnus@net-b.de>
1352 * simplify.c (simplify_cobound): Handle scalar coarrays.
1354 2010-04-27 Tobias Burnus <burnus@net-b.de>
1356 * gfc-internals.texi: Update copyright year.
1357 * gfortran.texi: Ditto.
1358 * invoke.texi: Ditto.
1360 2010-04-27 Tobias Burnus <burnus@net-b.de>
1363 * resolve.c (resolve_allocate_expr): Allow array coarrays.
1364 * trans-types.h (gfc_get_array_type_bounds): Update prototype.
1365 * trans-types.c (gfc_get_array_type_bounds,
1366 gfc_get_array_descriptor_base): Add corank argument.
1367 * trans-array.c (gfc_array_init_size): Handle corank.
1368 (gfc_trans_create_temp_array, gfc_array_allocate,
1369 gfc_conv_expr_descriptor): Add corank argument to call.
1370 * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Ditto.
1372 2010-04-24 Steven G. Kargl <kargl@gcc.gnu.org>
1376 * trans-array.c (gfc_trans_array_bound_check): Use TREE_CODE instead
1377 of mucking with a tree directly.
1379 2010-04-24 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1382 * io.c (gfc_match_open): Remove branch to syntax error. Add call to
1383 gfc_error with new error message.
1385 2010-04-24 Paul Thomas <pault@gcc.gnu.org>
1389 * trans-expr.c (gfc_conv_expr): Supply an address expression for
1391 (gfc_conv_expr_reference): Call gfc_conv_expr and return for
1393 * trans-array.c (gfc_add_loop_ss_code): Store the value rather
1394 than the address of a GFC_SS_REFERENCE.
1395 * trans.h : Change comment on GFC_SS_REFERENCE.
1397 2010-04-22 Richard Guenther <rguenther@suse.de>
1400 * resolve.c (gfc_resolve_index): Wrap around ...
1401 (gfc_resolve_index_1): ... this. Add parameter to allow
1402 any integer kind index type.
1403 (resolve_array_ref): Allow any integer kind for the start
1404 index of an array ref.
1406 2010-04-21 Jakub Jelinek <jakub@redhat.com>
1409 * f95-lang.c (gfc_define_builtin): Set TREE_NOTHROW on
1412 2010-04-20 Harald Anlauf <anlauf@gmx.de>
1414 * intrinsic.c (sort_actual): Remove 'is' in error message.
1416 2010-04-20 Paul Thomas <pault@gcc.gnu.org>
1419 * resolve.c (resolve_fl_derived): If a component character
1420 length has not been resolved, do so now.
1421 (resolve_symbol): The same as above for a symbol character
1423 * trans-decl.c (gfc_create_module_variable): A 'length' decl is
1424 not needed for a character valued, procedure pointer.
1427 * resolve.c (ensure_not_abstract_walker): If 'overriding' is
1428 not found, return FAILURE rather than ICEing.
1430 2010-04-19 Jakub Jelinek <jakub@redhat.com>
1433 * openmp.c (gfc_resolve_do_iterator): Only make iteration vars for
1434 sequential loops private in the innermost containing task region.
1436 2010-04-18 Eric Botcazou <ebotcazou@adacore.com>
1438 * f95-lang.c (gfc_init_decl_processing): Remove second argument in call
1439 to build_common_tree_nodes.
1441 2010-04-17 Steven G. Kargl <kargl@gcc.gnu.org>
1444 * fortran/trans-array.c (gfc_conv_ss_startstride): Remove the use of
1445 gfc_msg_bounds by using 'Array bound mismatch' directly.
1446 (gfc_trans_dummy_array_bias): Remove the use of gfc_msg_bounds. Reword
1447 error message to include the mismatch in the extent of array bound.
1448 * fortran/trans.c: Remove gfc_msg_bounds. It is only used in one place.
1449 * fortran/trans.h: Remove extern definition of gfc_msg_bounds.
1451 2010-04-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1453 * gfortran.texi: Update information on temporary file locations.
1455 2010-04-16 Jakub Jelinek <jakub@redhat.com>
1457 * trans-decl.c (gfc_build_qualified_array): Ensure
1458 ubound.N and lbound.N artificial variable names don't appear
1461 2010-04-15 Steven G. Kargl <kargl@gcc.gnu.org>
1464 * trans-array.c (gfc_trans_array_bound_check): Eliminate a redundant
1465 block of code. Set name to the variable associated with the descriptor.
1467 2010-04-15 Jakub Jelinek <jakub@redhat.com>
1469 * trans-decl.c (gfc_build_qualified_array): Clear DECL_IGNORED_P
1470 on VAR_DECL LBOUND and/or UBOUND, even for -O1.
1472 2010-04-14 Steven G. Kargl <kargl@gcc.gnu.org>
1474 * intrinsic.texi: Add the missing specific name of intrinsic
1475 procedure where the specific name is identical to the generic name.
1476 Fix inconsistent or mismatch in the argument names in intrinsic
1477 procedure descriptions. Add the SCALAR allocatable description to
1480 2010-04-14 Tobias Burnus <burnus@net-b.de>
1483 * array.c (gfc_find_array_ref): Handle codimensions.
1484 (gfc_match_array_spec,gfc_match_array_ref): Use gfc_fatal_error.
1485 * check.c (is_coarray, dim_corank_check, gfc_check_lcobound,
1486 gfc_check_image_index, gfc_check_this_image, gfc_check_ucobound):
1488 * gfortran.h (gfc_isym_id): Add GFC_ISYM_IMAGE_INDEX,
1489 GFC_ISYM_LCOBOUND, GFC_ISYM_THIS_IMAGE,
1491 * intrinsic.h (add_functions): Add this_image, image_index,
1492 lcobound and ucobound intrinsics.
1493 * intrinsic.c (gfc_check_lcobound,gfc_check_ucobound,
1494 gfc_check_image_index, gfc_check_this_image,
1495 gfc_simplify_image_index, gfc_simplify_lcobound,
1496 gfc_simplify_this_image, gfc_simplify_ucobound):
1497 New function prototypes.
1498 * intrinsic.texi (IMAGE_INDEX, LCOBOUND, THIS_IMAGE
1499 IMAGE_INDEX): Document new intrinsic functions.
1500 * match.c (gfc_match_critical, sync_statement): Make -fcoarray=none
1502 * simplify.c (simplify_bound_dim): Handle coarrays.
1503 (simplify_bound): Update simplify_bound_dim call.
1504 (gfc_simplify_num_images): Add -fcoarray=none check.
1505 (simplify_cobound, gfc_simplify_lcobound, gfc_simplify_ucobound,
1506 gfc_simplify_ucobound, gfc_simplify_ucobound): New functions.
1508 2010-04-14 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1511 * constructor.c: Fix typo in comment.
1512 * expr.c (find_array_section): Add check for max array limit.
1514 2010-04-13 Iain Sandoe <iains@gcc.gnu.org>
1517 * gfortranspec.c (lookup_option): Check for -static and return
1519 (lang_specific_driver): Break when OPTION_static is discovered.
1521 2010-04-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1523 * array.c (extract_element): Restore function from trunk.
1524 (gfc_get_array_element): Restore function from trunk.
1525 (gfc_expand_constructor): Restore check against
1526 flag_max_array_constructor.
1527 * constructor.c (node_copy_and_append): Delete unused.
1528 * gfortran.h: Delete comment and extra include.
1529 * constructor.h: Bump copyright and clean up TODO comments.
1530 * resolve.c: Whitespace.
1532 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
1534 * simplify.c (compute_dot_product): Replaced usage of ADVANCE macro
1535 with direct access access to elements. Adjusted prototype, fixed all
1537 (gfc_simplify_dot_product): Removed duplicate check for zero-sized
1539 (gfc_simplify_matmul): Removed usage of ADVANCE macro.
1540 (gfc_simplify_spread): Removed workaround, directly insert elements
1541 at a given array position.
1542 (gfc_simplify_transpose): Likewise.
1543 (gfc_simplify_pack): Replaced usage of ADVANCE macro with corresponding
1545 (gfc_simplify_unpack): Likewise.
1547 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
1549 * simplify.c (only_convert_cmplx_boz): Renamed to ...
1550 (convert_boz): ... this and moved to start of file.
1551 (gfc_simplify_abs): Whitespace fix.
1552 (gfc_simplify_acos): Whitespace fix.
1553 (gfc_simplify_acosh): Whitespace fix.
1554 (gfc_simplify_aint): Whitespace fix.
1555 (gfc_simplify_dint): Whitespace fix.
1556 (gfc_simplify_anint): Whitespace fix.
1557 (gfc_simplify_and): Replaced if-gate by more common switch-over-type.
1558 (gfc_simplify_dnint): Whitespace fix.
1559 (gfc_simplify_asin): Whitespace fix.
1560 (gfc_simplify_asinh): Moved creation of result-expr out of switch.
1561 (gfc_simplify_atan): Likewise.
1562 (gfc_simplify_atanh): Whitespace fix.
1563 (gfc_simplify_atan2): Whitespace fix.
1564 (gfc_simplify_bessel_j0): Removed ATTRIBUTE_UNUSED.
1565 (gfc_simplify_bessel_j1): Likewise.
1566 (gfc_simplify_bessel_jn): Likewise.
1567 (gfc_simplify_bessel_y0): Likewise.
1568 (gfc_simplify_bessel_y1): Likewise.
1569 (gfc_simplify_bessel_yn): Likewise.
1570 (gfc_simplify_ceiling): Reorderd statements.
1571 (simplify_cmplx): Use convert_boz(), check for constant arguments.
1573 (gfc_simplify_cmplx): Use correct default kind. Removed check for
1575 (gfc_simplify_complex): Replaced if-gate. Removed check for
1577 (gfc_simplify_conjg): Whitespace fix.
1578 (gfc_simplify_cos): Whitespace fix.
1579 (gfc_simplify_cosh): Replaced if-gate by more common switch-over-type.
1580 (gfc_simplify_dcmplx): Removed check for constant arguments.
1581 (gfc_simplify_dble): Use convert_boz() and gfc_convert_constant().
1582 (gfc_simplify_digits): Whitespace fix.
1583 (gfc_simplify_dim): Whitespace fix.
1584 (gfc_simplify_dprod): Reordered statements.
1585 (gfc_simplify_erf): Whitespace fix.
1586 (gfc_simplify_erfc): Whitespace fix.
1587 (gfc_simplify_epsilon): Whitespace fix.
1588 (gfc_simplify_exp): Whitespace fix.
1589 (gfc_simplify_exponent): Use convert_boz().
1590 (gfc_simplify_floor): Reorderd statements.
1591 (gfc_simplify_gamma): Whitespace fix.
1592 (gfc_simplify_huge): Whitespace fix.
1593 (gfc_simplify_iand): Whitespace fix.
1594 (gfc_simplify_ieor): Whitespace fix.
1595 (simplify_intconv): Use gfc_convert_constant().
1596 (gfc_simplify_int): Use simplify_intconv().
1597 (gfc_simplify_int2): Reorderd statements.
1598 (gfc_simplify_idint): Reorderd statements.
1599 (gfc_simplify_ior): Whitespace fix.
1600 (gfc_simplify_ishftc): Removed duplicate type check.
1601 (gfc_simplify_len): Use range_check() instead of manual range check.
1602 (gfc_simplify_lgamma): Removed ATTRIBUTE_UNUSED. Whitespace fix.
1603 (gfc_simplify_log): Whitespace fix.
1604 (gfc_simplify_log10): Whitespace fix.
1605 (gfc_simplify_minval): Whitespace fix.
1606 (gfc_simplify_maxval): Whitespace fix.
1607 (gfc_simplify_mod): Whitespace fix.
1608 (gfc_simplify_modulo): Whitespace fix.
1609 (simplify_nint): Reorderd statements.
1610 (gfc_simplify_not): Whitespace fix.
1611 (gfc_simplify_or): Replaced if-gate by more common switch-over-type.
1612 (gfc_simplify_radix): Removed unused result-variable. Whitespace fix.
1613 (gfc_simplify_range): Removed unused result-variable. Whitespace fix.
1614 (gfc_simplify_real): Use convert_boz() and gfc_convert_constant().
1615 (gfc_simplify_realpart): Whitespace fix.
1616 (gfc_simplify_selected_char_kind): Removed unused result-variable.
1617 (gfc_simplify_selected_int_kind): Removed unused result-variable.
1618 (gfc_simplify_selected_real_kind): Removed unused result-variable.
1619 (gfc_simplify_sign): Whitespace fix.
1620 (gfc_simplify_sin): Whitespace fix.
1621 (gfc_simplify_sinh): Replaced if-gate by more common switch-over-type.
1622 (gfc_simplify_sqrt): Avoided goto by inlining check. Whitespace fix.
1623 (gfc_simplify_tan): Replaced if-gate by more common switch-over-type.
1624 (gfc_simplify_tanh): Replaced if-gate by more common switch-over-type.
1625 (gfc_simplify_xor): Replaced if-gate by more common switch-over-type.
1627 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
1629 * gfortran.h (gfc_start_constructor): Removed.
1630 (gfc_get_array_element): Removed.
1631 * array.c (gfc_start_constructor): Removed, use gfc_get_array_expr
1632 instead. Fixed all callers.
1633 (extract_element): Removed.
1634 (gfc_expand_constructor): Temporarily removed check for
1635 max-array-constructor. Will be re-introduced later if still required.
1636 (gfc_get_array_element): Removed, use gfc_constructor_lookup_expr
1637 instead. Fixed all callers.
1638 * expr.c (find_array_section): Replaced manual lookup of elements
1639 by gfc_constructor_lookup.
1641 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
1643 * gfortran.h (gfc_get_null_expr): New prototype.
1644 (gfc_get_operator_expr): New prototype.
1645 (gfc_get_character_expr): New prototype.
1646 (gfc_get_iokind_expr): New prototype.
1647 * expr.c (gfc_get_null_expr): New.
1648 (gfc_get_character_expr): New.
1649 (gfc_get_iokind_expr): New.
1650 (gfc_get_operator_expr): Moved here from matchexp.c (build_node).
1651 * matchexp.c (build_node): Renamed and moved to
1652 expr.c (gfc_get_operator_expr). Reordered arguments to match
1653 other functions. Fixed all callers.
1654 (gfc_get_parentheses): Use specific function to build expr.
1655 * array.c (gfc_match_array_constructor): Likewise.
1656 * arith.c (eval_intrinsic): Likewise.
1657 (gfc_hollerith2int): Likewise.
1658 (gfc_hollerith2real): Likewise.
1659 (gfc_hollerith2complex): Likewise.
1660 (gfc_hollerith2logical): Likewise.
1661 * data.c (create_character_intializer): Likewise.
1662 * decl.c (gfc_match_null): Likewise.
1663 (enum_initializer): Likewise.
1664 * io.c (gfc_match_format): Likewise.
1665 (match_io): Likewise.
1666 * match.c (gfc_match_nullify): Likewise.
1667 * primary.c (match_string_constant): Likewise.
1668 (match_logical_constant): Likewise.
1669 (build_actual_constructor): Likewise.
1670 * resolve.c (build_default_init_expr): Likewise.
1671 * symbol.c (generate_isocbinding_symbol): Likewise.
1672 (gfc_build_class_symbol): Likewise.
1673 (gfc_find_derived_vtab): Likewise.
1674 * simplify.c (simplify_achar_char): Likewise.
1675 (gfc_simplify_adjustl): Likewise.
1676 (gfc_simplify_adjustr): Likewise.
1677 (gfc_simplify_and): Likewise.
1678 (gfc_simplify_bit_size): Likewise.
1679 (gfc_simplify_is_iostat_end): Likewise.
1680 (gfc_simplify_is_iostat_eor): Likewise.
1681 (gfc_simplify_isnan): Likewise.
1682 (simplify_bound): Likewise.
1683 (gfc_simplify_leadz): Likewise.
1684 (gfc_simplify_len_trim): Likewise.
1685 (gfc_simplify_logical): Likewise.
1686 (gfc_simplify_maxexponent): Likewise.
1687 (gfc_simplify_minexponent): Likewise.
1688 (gfc_simplify_new_line): Likewise.
1689 (gfc_simplify_null): Likewise.
1690 (gfc_simplify_or): Likewise.
1691 (gfc_simplify_precision): Likewise.
1692 (gfc_simplify_repeat): Likewise.
1693 (gfc_simplify_scan): Likewise.
1694 (gfc_simplify_size): Likewise.
1695 (gfc_simplify_trailz): Likewise.
1696 (gfc_simplify_trim): Likewise.
1697 (gfc_simplify_verify): Likewise.
1698 (gfc_simplify_xor): Likewise.
1699 * trans-io.c (build_dt): Likewise.
1700 (gfc_new_nml_name_expr): Removed.
1702 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
1704 * arith.h (gfc_constant_result): Removed prototype.
1705 * constructor.h (gfc_build_array_expr): Removed prototype.
1706 (gfc_build_structure_constructor_expr): Removed prototype.
1707 * gfortran.h (gfc_int_expr): Removed prototype.
1708 (gfc_logical_expr): Removed prototype.
1709 (gfc_get_array_expr): New prototype.
1710 (gfc_get_structure_constructor_expr): New prototype.
1711 (gfc_get_constant_expr): New prototype.
1712 (gfc_get_int_expr): New prototype.
1713 (gfc_get_logical_expr): New prototype.
1714 * arith.c (gfc_constant_result): Moved and renamed to
1715 expr.c (gfc_get_constant_expr). Fixed all callers.
1716 * constructor.c (gfc_build_array_expr): Moved and renamed to
1717 expr.c (gfc_get_array_expr). Split gfc_typespec argument to type
1718 and kind. Fixed all callers.
1719 (gfc_build_structure_constructor_expr): Moved and renamed to
1720 expr.c (gfc_get_structure_constructor_expr). Split gfc_typespec argument
1721 to type and kind. Fixed all callers.
1722 * expr.c (gfc_logical_expr): Renamed to ...
1723 (gfc_get_logical_expr): ... this. Added kind argument. Fixed all callers.
1724 (gfc_int_expr): Renamed to ...
1725 (gfc_get_int_expr): ... this. Added kind and where arguments. Fixed all
1727 (gfc_get_constant_expr): New.
1728 (gfc_get_array_expr): New.
1729 (gfc_get_structure_constructor_expr): New.
1730 * simplify.c (int_expr_with_kind): Removed, callers use gfc_get_int_expr
1733 2010-04-12 Daniel Franke <franke.daniel@gmail.com>
1735 * constructor.h: New.
1736 * constructor.c: New.
1737 * Make-lang.in: Add new files to F95_PARSER_OBJS.
1738 * arith.c (reducy_unary): Use constructor API.
1739 (reduce_binary_ac): Likewise.
1740 (reduce_binary_ca): Likewise.
1741 (reduce_binary_aa): Likewise.
1742 * check.c (gfc_check_pack): Likewise.
1743 (gfc_check_reshape): Likewise.
1744 (gfc_check_unpack): Likewise.
1745 * decl.c (add_init_expr_to_sym): Likewise.
1746 (build_struct): Likewise.
1747 * dependency.c (gfc_check_dependency): Likewise.
1748 (contains_forall_index_p): Likewise.
1749 * dump-parse-tree.c (show_constructor): Likewise.
1750 * expr.c (free_expr0): Likewise.
1751 (gfc_copy_expr): Likewise.
1752 (gfc_is_constant_expr): Likewise.
1753 (simplify_constructor): Likewise.
1754 (find_array_element): Likewise.
1755 (find_component_ref): Likewise.
1756 (find_array_section): Likewise.
1757 (find_substring_ref): Likewise.
1758 (simplify_const_ref): Likewise.
1759 (scalarize_intrinsic_call): Likewise.
1760 (check_alloc_comp_init): Likewise.
1761 (gfc_default_initializer): Likewise.
1762 (gfc_traverse_expr): Likewise.
1763 * iresolve.c (check_charlen_present): Likewise.
1764 (gfc_resolve_reshape): Likewise.
1765 (gfc_resolve_transfer): Likewise.
1766 * module.c (mio_constructor): Likewise.
1767 * primary.c (build_actual_constructor): Likewise.
1768 (gfc_match_structure_constructor): Likewise.
1769 * resolve.c (resolve_structure_cons): Likewise.
1770 * simplify.c (is_constant_array_expr): Likewise.
1771 (init_result_expr): Likewise.
1772 (transformational_result): Likewise.
1773 (simplify_transformation_to_scalar): Likewise.
1774 (simplify_transformation_to_array): Likewise.
1775 (gfc_simplify_dot_product): Likewise.
1776 (simplify_bound): Likewise.
1777 (simplify_matmul): Likewise.
1778 (simplify_minval_maxval): Likewise.
1779 (gfc_simplify_pack): Likewise.
1780 (gfc_simplify_reshape): Likewise.
1781 (gfc_simplify_shape): Likewise.
1782 (gfc_simplify_spread): Likewise.
1783 (gfc_simplify_transpose): Likewise.
1784 (gfc_simplify_unpack): Likewise.q
1785 (gfc_convert_constant): Likewise.
1786 (gfc_convert_char_constant): Likewise.
1787 * target-memory.c (size_array): Likewise.
1788 (encode_array): Likewise.
1789 (encode_derived): Likewise.
1790 (interpret_array): Likewise.
1791 (gfc_interpret_derived): Likewise.
1792 (expr_to_char): Likewise.
1793 (gfc_merge_initializers): Likewise.
1794 * trans-array.c (gfc_get_array_constructor_size): Likewise.
1795 (gfc_trans_array_constructor_value): Likewise.
1796 (get_array_ctor_strlen): Likewise.
1797 (gfc_constant_array_constructor_p): Likewise.
1798 (gfc_build_constant_array_constructor): Likewise.
1799 (gfc_trans_array_constructor): Likewise.
1800 (gfc_conv_array_initializer): Likewise.
1801 * trans-decl.c (check_constant_initializer): Likewise.
1802 * trans-expr.c (flatten_array_ctors_without_strlen): Likewise.
1803 (gfc_apply_interface_mapping_to_cons): Likewise.
1804 (gfc_trans_structure_assign): Likewise.
1805 (gfc_conv_structure): Likewise.
1806 * array.c (check_duplicate_iterator): Likewise.
1807 (match_array_list): Likewise.
1808 (match_array_cons_element): Likewise.
1809 (gfc_match_array_constructor): Likewise.
1810 (check_constructor_type): Likewise.
1811 (check_constructor): Likewise.
1813 (expand_constructor): Likewise.
1814 (extract_element): Likewise.
1815 (gfc_expanded_ac): Likewise.
1816 (resolve_array_list): Likewise.
1817 (gfc_resolve_character_array_constructor): Likewise.
1818 (copy_iterator): Renamed to ...
1819 (gfc_copy_iterator): ... this.
1820 (gfc_append_constructor): Removed.
1821 (gfc_insert_constructor): Removed unused function.
1822 (gfc_get_constructor): Removed.
1823 (gfc_free_constructor): Removed.
1824 (qgfc_copy_constructor): Removed.
1825 * gfortran.h (struct gfc_expr): Removed member 'con_by_offset'.
1826 Removed all references. Replaced constructor list by splay-tree.
1827 (struct gfc_constructor): Removed member 'next', moved 'offset' from
1828 the inner struct, added member 'base'.
1829 (gfc_append_constructor): Removed prototype.
1830 (gfc_insert_constructor): Removed prototype.
1831 (gfc_get_constructor): Removed prototype.
1832 (gfc_free_constructor): Removed prototype.
1833 (qgfc_copy_constructor): Removed prototype.
1834 (gfc_copy_iterator): New prototype.
1835 * trans-array.h (gfc_constant_array_constructor_p): Adjusted prototype.
1837 2010-04-10 Tobias Burnus <burnus@net-b.de>
1840 * expr.c (gfc_is_constant_expr, gfc_traverse_expr): Handle
1841 proc-pointers and type-bound procedures.
1842 (gfc_specification_expr): Check proc-pointers for pureness.
1844 2010-04-09 Iain Sandoe <iains@gcc.gnu.org>
1847 * gfortranspec.c (lang_specific_driver): Do not expose vars
1848 only used by HAVE_LD_STATIC_DYNAMIC targets unless compiling
1851 2010-04-09 Tobias Burnus <burnus@net-b.de>
1854 * decl.c (variable_decl, match_attr_spec): Fix setting the array
1856 * array.c (match_subscript,gfc_match_array_ref): Add coarray support.
1857 * data.c (gfc_assign_data_value): Ditto.
1858 * expr.c (gfc_check_pointer_assign): Add check for coarray constraint.
1859 (gfc_traverse_expr): Traverse also through codimension expressions.
1860 (gfc_is_coindexed, gfc_has_ultimate_allocatable,
1861 gfc_has_ultimate_pointer): New functions.
1862 * gfortran.h (gfc_array_ref_dimen_type): Add DIMEN_STAR for coarrays.
1863 (gfc_array_ref): Add codimen.
1864 (gfc_array_ref): Add in_allocate.
1865 (gfc_is_coindexed, gfc_has_ultimate_allocatable,
1866 gfc_has_ultimate_pointer): Add prototypes.
1867 * interface.c (compare_parameter, compare_actual_formal,
1868 check_intents): Add coarray constraints.
1869 * match.c (gfc_match_iterator): Add coarray constraint.
1870 * match.h (gfc_match_array_ref): Update interface.
1871 * primary.c (gfc_match_varspec): Handle codimensions.
1872 * resolve.c (coarray_alloc, inquiry_argument): New static variables.
1873 (check_class_members): Return gfc_try instead for error recovery.
1874 (resolve_typebound_function,resolve_typebound_subroutine,
1875 check_members): Handle return value of check_class_members.
1876 (resolve_structure_cons, resolve_actual_arglist, resolve_function,
1877 check_dimension, compare_spec_to_ref, resolve_array_ref,
1878 resolve_ref, resolve_variable, gfc_resolve_expr, conformable_arrays,
1879 resolve_allocate_expr, resolve_ordinary_assign): Add coarray
1881 * trans-array.c (gfc_conv_array_ref, gfc_walk_variable_expr):
1882 Skip over coarray refs.
1883 (gfc_array_allocate) Add support for references containing coindexes.
1884 * trans-expr.c (gfc_add_interface_mapping): Copy coarray attribute.
1885 (gfc_map_intrinsic_function): Ignore codimensions.
1887 2010-04-08 Bud Davis <bdavis9659@sbcglobal.net>
1890 * io.c (check_format_string): Added check for additional non
1891 blank characters after the format string was successfully
1893 * io.c (check_format): Changed the error messages for positive
1894 int required and period required to drop through the error logic
1895 and report with gfc_error instead of gfc_error_now. Corrected
1896 format postion for hollerith strings.
1898 2010-04-08 Tobias Burnus <burnus@net-b.de>
1900 * module.c (use_iso_fortran_env_module): Fix standard check.
1902 2010-04-07 Jakub Jelinek <jakub@redhat.com>
1904 * parse.c (parse_derived, parse_enum): Avoid set but not used
1907 2010-04-07 Janne Blomqvist <jb@gcc.gnu.org>
1910 * gfortran.texi: Add section about representation of
1913 2010-04-07 Simon Baldwin <simonb@google.com>
1915 * cpp.c (cb_cpp_error): Add warning reason argument, set a value
1916 for diagnostic_override_option_index if CPP_W_WARNING_DIRECTIVE.
1918 2010-04-07 Richard Guenther <rguenther@suse.de>
1920 * options.c (gfc_init_options): Do not set.
1922 2010-04-06 Tobias Burnus <burnus@net-b.de>
1925 * array.c (gfc_match_array_spec): Add error for -fcoarray=none.
1926 * match.c (gfc_match_critical, sync_statement): Ditto.
1927 * gfortran.h (gfc_fcoarray): New enum.
1928 (gfc_option_t): Use it.
1929 * lang.opt (fcoarray): Add new flag.
1930 * invoke.texi (fcoarray): Document it.
1931 * options.c (gfc_init_options,gfc_handle_option): Handle -fcoarray=.
1932 (gfc_handle_coarray_option): New function.
1934 2010-04-06 Tobias Burnus <burnus@net-b.de>
1937 * gfortran.h (gfc_array_spec): Add cotype.
1938 * array.c (gfc_match_array_spec,gfc_set_array_spec): Use it
1939 and defer error diagnostic.
1940 * resolve.c (resolve_fl_derived): Add missing check.
1941 (resolve_symbol): Add cotype/type check.
1942 * parse.c (parse_derived): Fix setting of coarray_comp.
1944 2010-04-06 Tobias Burnus <burnus@net-b.de>
1947 * array.c (gfc_free_array_spec,gfc_resolve_array_spec,
1948 match_array_element_spec,gfc_copy_array_spec,
1949 gfc_compare_array_spec): Include corank.
1950 (match_array_element_spec,gfc_set_array_spec): Support codimension.
1951 * decl.c (build_sym,build_struct,variable_decl,
1952 match_attr_spec,attr_decl1,cray_pointer_decl,
1953 gfc_match_volatile): Add codimension.
1954 (gfc_match_codimension): New function.
1955 * dump-parse-tree.c (show_array_spec,show_attr): Support codimension.
1956 * gfortran.h (symbol_attribute,gfc_array_spec): Ditto.
1957 (gfc_add_codimension): New function prototype.
1958 * match.h (gfc_match_codimension): New function prototype.
1959 (gfc_match_array_spec): Update prototype
1960 * match.c (gfc_match_common): Update gfc_match_array_spec call.
1961 * module.c (MOD_VERSION): Bump.
1962 (mio_symbol_attribute): Support coarray attributes.
1963 (mio_array_spec): Add corank support.
1964 * parse.c (decode_specification_statement,decode_statement,
1965 parse_derived): Add coarray support.
1966 * resolve.c (resolve_formal_arglist, was_declared,
1967 is_non_constant_shape_array, resolve_fl_variable,
1968 resolve_fl_derived, resolve_symbol): Add coarray support.
1969 * symbol.c (check_conflict, gfc_add_volatile, gfc_copy_attr,
1970 gfc_build_class_symbol): Add coarray support.
1971 (gfc_add_codimension): New function.
1973 2010-04-06 Tobias Burnus <burnus@net-b.de>
1976 * iso-fortran-env.def: Add the integer parameters atomic_int_kind,
1977 atomic_logical_kind, iostat_inquire_internal_unit, stat_locked,
1978 stat_locked_other_image, stat_stopped_image and stat_unlocked of
1980 * intrinsic.texi (iso_fortran_env): Ditto.
1981 * libgfortran.h (libgfortran_stat_codes): New enum.
1982 * module.c (use_iso_fortran_env_module): Honour -std= when loading
1983 constants from the intrinsic module.
1985 2010-04-06 Tobias Burnus <burnus@net-b.de>
1988 * intrinsic.c (add_functions): Add num_images.
1989 * decl.c (gfc_match_end): Handle END CRITICAL.
1990 * intrinsic.h (gfc_simplify_num_images): Add prototype.
1991 * dump-parse-tree.c (show_code_node): Dump CRITICAL, ERROR STOP,
1993 * gfortran.h (gfc_statement): Add enum items for those.
1994 (gfc_exec_op) Ditto.
1995 (gfc_isym_id): Add num_images.
1996 * trans-stmt.c (gfc_trans_stop): Handle ERROR STOP.
1997 (gfc_trans_sync,gfc_trans_critical): New functions.
1998 * trans-stmt.h (gfc_trans_stop,gfc_trans_sync,
1999 gfc_trans_critical): Add/update prototypes.
2000 * trans.c (gfc_trans_code): Handle CRITICAL, ERROR STOP,
2001 and SYNC statements.
2002 * trans.h (gfor_fndecl_error_stop_string) Add variable.
2003 * resolve.c (resolve_sync): Add function.
2004 (gfc_resolve_blocks): Handle CRITICAL.
2005 (resolve_code): Handle CRITICAL, ERROR STOP,
2006 (resolve_branch): Add CRITICAL constraint check.
2007 and SYNC statements.
2008 * st.c (gfc_free_statement): Add new statements.
2009 * trans-decl.c (gfor_fndecl_error_stop_string): Global variable.
2010 (gfc_build_builtin_function_decls): Initialize it.
2011 * match.c (gfc_match_if): Handle ERROR STOP and SYNC.
2012 (gfc_match_critical, gfc_match_error_stop, sync_statement,
2013 gfc_match_sync_all, gfc_match_sync_images, gfc_match_sync_memory):
2015 (match_exit_cycle): Handle CRITICAL constraint.
2016 (gfc_match_stopcode): Handle ERROR STOP.
2017 * match.h (gfc_match_critical, gfc_match_error_stop,
2018 gfc_match_sync_all, gfc_match_sync_images,
2019 gfc_match_sync_memory): Add prototype.
2020 * parse.c (decode_statement, gfc_ascii_statement,
2021 parse_executable): Handle new statements.
2022 (parse_critical_block): New function.
2023 * parse.h (gfc_compile_state): Add COMP_CRITICAL.
2024 * intrinsic.texi (num_images): Document new function.
2025 * simplify.c (gfc_simplify_num_images): Add function.
2027 2010-04-06 Tobias Burnus <burnus@net-b.de>
2030 * trans-array.c (gfc_conv_expr_descriptor): Update
2031 gfc_trans_scalar_assign call.
2032 (has_default_initializer): New function.
2033 (gfc_trans_deferred_array): Nullify less often.
2034 * trans-expr.c (gfc_conv_subref_array_arg,
2035 gfc_trans_subcomponent_assign): Update call to
2036 gfc_trans_scalar_assign.
2037 (gfc_trans_scalar_assign): Add parameter and pass it on.
2038 (gfc_trans_assignment_1): Optionally, do not dealloc before
2040 * trans-openmp.c (gfc_trans_omp_array_reduction): Update
2041 call to gfc_trans_scalar_assign.
2042 * trans-decl.c (gfc_get_symbol_decl): Do not always apply
2043 initializer to static variables.
2044 (gfc_init_default_dt): Add dealloc parameter and pass it on.
2045 * trans-stmt.c (forall_make_variable_temp,
2046 generate_loop_for_temp_to_lhs, generate_loop_for_rhs_to_temp,
2047 gfc_trans_forall_1, gfc_trans_where_assign, gfc_trans_where_3
2048 gfc_trans_allocate): Update gfc_trans_assignment call.
2049 * trans.h (gfc_trans_scalar_assign, gfc_init_default_dt,
2050 gfc_init_default_dt, gfc_trans_assignment): Add bool dealloc
2051 parameter to prototype.
2053 2010-03-31 Paul Thomas <pault@gcc.gnu.org>
2055 * ioparm.def : Update copyright.
2057 * trans-array.c : ditto
2058 * trans-array.h : ditto
2060 * trans-types.c: ditto
2061 * dependency.c : ditto
2062 * gfortran.h : ditto
2064 * trans-io.c : ditto
2065 * trans-intrinsic.c : ditto
2066 * libgfortran.h : ditto
2067 * invoke.texi : ditto
2068 * intrinsic.texi : ditto
2071 * intrinsic.c : ditto
2072 * interface.c : ditto
2073 * iresolve.c : ditto
2074 * trans-stmt.c : ditto
2075 * trans-stmt.h : ditto
2080 2010-03-20 Paul Thomas <pault@gcc.gnu.org>
2083 * trans-decl.c (gfc_create_module_variable): With -fwhole-file
2084 do not assert the context of derived types.
2086 2010-03-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2089 * ioparm.def: Change inquire size variable to type pointer to
2092 2010-03-18 Paul Thomas <pault@gcc.gnu.org>
2095 * trans-expr.c (conv_parent_component_references): Ensure that
2096 'dt' has a backend_decl.
2099 * trans-expr.c (gfc_conv_structure): Ensure that the derived
2100 type has a backend_decl.
2103 * resolve.c (resolve_global_procedure): Check that the 'cl'
2104 structure is not NULL.
2106 2010-03-18 Shujing Zhao <pearly.zhao@oracle.com>
2108 * lang.opt (-ffixed-line-length-, ffree-line-length-): Remove
2111 2010-03-17 Tobias Burnus <burnus@net-b.de>
2114 * trans-array.c (gfc_conv_array_index_offset,gfc_conv_array_ref,
2115 gfc_conv_ss_startstride): Remove no-longer-needed cp_was_assumed
2117 * decl.c (gfc_match_derived_decl): Don't mark assumed-size Cray
2118 pointees as having explizit size.
2119 * expr.c (gfc_check_assign): Remove now unreachable Cray pointee
2121 * trans-types.c (gfc_is_nodesc_array): Add cp_was_assumed to assert.
2122 (gfc_sym_type): Don't mark Cray pointees as restricted pointers.
2123 * resolve.c (resolve_symbol): Handle cp_was_assumed.
2124 * trans-decl.c (gfc_trans_deferred_vars): Ditto.
2125 (gfc_finish_var_decl): Don't mark Cray pointees as restricted
2128 2010-03-14 Tobias Burnus <burnus@net-b.de>
2131 * resolve.c (resolve_structure_cons): Add missing PURE constraint.
2132 (resolve_ordinary_assign): Add check to avoid segfault.
2134 2010-03-12 Paul Thomas <pault@gcc.gnu.org>
2138 * resolve.c (resolve_compcall): Add new boolean dummy argument
2139 'class_members'. Only resolve expression at end if false.
2140 Remove redundant, static variable 'class_object'.
2141 (check_class_members): Add extra argument to call of
2143 (resolve_typebound_function): Renamed resolve_class_compcall.
2144 Do all the detection of class references here. Correct calls to
2145 resolve_compcall for extra argument.
2146 (resolve_typebound_subroutine): resolve_class_typebound_call
2147 renamed. Otherwise same as resolve_typebound_function.
2148 (gfc_resolve_expr): Call resolve_typebound_function.
2149 (resolve_code): Call resolve_typebound_subroutine.
2151 2010-03-10 Tobias Burnus <burnus@net-b.de
2154 * symbol.c (get_iso_c_sym): Set sym->result.
2156 2010-03-08 Janus Weil <janus@gcc.gnu.org>
2159 * resolve.c (resolve_compcall): Don't set 'value.function.name' here
2160 for TBPs, otherwise they will not be resolved properly.
2161 (resolve_function): Use 'value.function.esym' instead of
2162 'value.function.name' to check if we're dealing with a TBP.
2163 (check_class_members): Set correct type of passed object for all TBPs,
2164 not only generic ones, except if the type is abstract.
2166 2010-03-04 Janus Weil <janus@gcc.gnu.org>
2169 * decl.c (gfc_match_final_decl): Make sure variable names starting with
2170 'final...' are not misinterpreted as FINAL statements.
2172 2010-03-03 Paul Thomas <pault@gcc.gnu.org>
2175 * trans-array.c (gfc_conv_array_parameter): Contiguous refs to
2176 allocatable ultimate components do not need temporaries, whilst
2177 ultimate pointer components do.
2179 2010-03-03 Janus Weil <janus@gcc.gnu.org>
2182 * resolve.c (resolve_code): Correctly set gfc_current_ns for
2184 (gfc_impure_variable): Make it work with sub-namespaces (BLOCK etc).
2187 2010-03-02 Paul Thomas <pault@gcc.gnu.org>
2190 * trans-array.c (gfc_conv_array_parameter): A full array of
2191 derived type need not be restricted to a symbol without an
2192 array spec to use the call to gfc_conv_expr_descriptor.
2195 * trans-array.c (gfc_conv_array_parameter): Contiguous refs to
2196 allocatable arrays do not need temporaries.
2198 2010-03-01 Tobias Burnus <burnus@net-b.de>
2201 * resolve.c (find_array_spec): Handle REF_COMPONENT with
2204 2010-02-28 Tobias Burnus <burnus@net-b.de>
2207 * trans-expr.c (is_zero_initializer_p): Move up in the file.
2208 (gfc_conv_initializer): Handle zero initializer as special case.
2210 2010-02-27 Tobias Burnus <burnus@net-b.de>
2213 * resolve.c (resolve_fl_variable_derived): Imply SAVE
2214 for module variables for Fortran 2008.
2216 2010-02-25 Jakub Jelinek <jakub@redhat.com>
2219 * trans-common.c (build_common_decl): Also update DECL_MODE,
2220 and DECL_SIZE when encountering a larger common block and call
2223 2010-02-24 Tobias Burnus <burnus@net-b.de>
2226 * trans-expr.c (gfc_conv_initializer): Call directly
2227 gfc_conv_constant for C_NULL_(FUN)PTR.
2229 2010-02-22 Paul Thomas <pault@gcc.gnu.org>
2232 * dependency.c (gfc_full_array_ref_p): Check for contiguous by
2233 checking the rest of the dimensions for elements.
2235 2010-02-21 Tobias Burnus <burnus@net-b.de>
2238 * gfortran.h (gfc_option_t): New flag -fprotect-parens.
2240 * option.c (gfc_init_options,gfc_handle_option): Ditto.
2241 * trans-expr.c (gfc_conv_expr_op): Use the flag.
2242 * invoke.texi: Document new -fno-protect-parens flag.
2244 2010-02-20 Paul Thomas <pault@gcc.gnu.org>
2250 * dependency.c (gfc_check_argument_var_dependency): Use enum
2251 value instead of arithmetic vaue for 'elemental'.
2252 (check_data_pointer_types): New function.
2253 (gfc_check_dependency): Call check_data_pointer_types.
2254 * trans-array.h : Change fourth argument of
2255 gfc_conv_array_parameter to boolean.
2256 * trans-array.c (gfc_conv_array_parameter): A contiguous array
2257 can be a dummy but it must not be assumed shape or deferred.
2258 Change fourth argument to boolean. Array constructor exprs will
2259 always be contiguous and do not need packing and unpacking.
2260 * trans-expr.c (gfc_conv_procedure_call): Clean up some white
2261 space and change fourth argument of gfc_conv_array_parameter
2263 (gfc_trans_arrayfunc_assign): Change fourth argument of
2264 gfc_conv_array_parameter to boolean.
2265 * trans-io.c (gfc_convert_array_to_string): The same.
2266 * trans-intrinsic.c (gfc_conv_intrinsic_loc): The same.
2268 2010-02-20 Tobias Burnus <burnus@net-b.de>
2271 * libgfortran.h: Add GFC_RTCHECK_MEM.
2272 * invoke.texi (-fcheck=): Document -fcheck=mem.
2273 * tranc.c (gfc_call_malloc): Remove negative-size run-time error
2274 and enable malloc-success check only with -fcheck=mem.
2275 * option.c (gfc_handle_runtime_check_option): Add -fcheck=mem.
2277 2010-02-16 Tobias Burnus <burnus@net-b.de>
2280 * gfortran.h (gfc_isym_id): Rename GFS_ISYM_GAMMA to GFS_ISYM_TGAMMA.
2281 * intrinsic.c (add_functions): Ditto.
2282 * iresolve.c (gfc_resolve_gamma): Call tgamma instead of gamma.
2283 * mathbuiltins.def: Use TGAMMA instead of GAMMA with "tgamma".
2285 2010-02-14 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2288 * trans-stmt.h: Add prototype for gfc_trans_code_cond. Add tree cond to
2289 gfc_trans_do prototype.
2290 * trans-stmt.c (gfc_trans_simple_do): Add optional argument to pass in
2291 a loop exit condition. If exit condition is given, build the loop exit
2292 code, checking IO results of implied do loops in READ and WRITE.
2293 (gfc_trans_do): Likewise.
2294 * trans.c (trans_code): New static work function, previously
2295 gfc_trans_code. Passes exit condition to gfc_trans_do.
2296 (gfc_trans_code): Calls trans_code with NULL_TREE condition.
2297 (gfc_trans_code_cond): Calls trans_code with loop exit condition.
2298 * trans-io.c (build_dt): Build an exit condition to allow checking IO
2299 result status bits in the dtparm structure. Use this condition in call
2300 to gfc_trans_code_cond.
2302 2010-02-13 Paul Thomas <pault@gcc.gnu.org>
2306 * trans-array.c (gfc_conv_array_parameter): Use
2307 gfc_full_array_ref_p to detect full and contiguous variable
2308 arrays. Full array components and contiguous arrays do not need
2309 internal_pack and internal_unpack.
2311 2010-02-11 Jakub Jelinek <jakub@redhat.com>
2314 * resolve.c (gfc_resolve_dim_arg): Call gfc_clear_ts.
2317 * decl.c (enumerator_decl): Don't call gfc_free_enum_history
2319 (gfc_match_enumerator_def): But here whenever enumerator_decl returns
2322 2010-02-10 Joost VandeVondele <jv244@cam.ac.uk>
2323 Tobias Burnus <burnus@net-b.de>
2326 * decl.c (gfc_match_subroutine): Explicitly set sym->declared_at.
2328 2010-02-10 Tobias Burnus <burnus@net-b.de>
2331 * trans-decl.c (gfc_generate_function_code): Only check
2332 actual-vs.-dummy character bounds if not bind(C).
2334 2010-02-10 Jakub Jelinek <jakub@redhat.com>
2337 * trans-expr.c (gfc_conv_subref_array_arg): Avoid accessing
2338 info->dimen after info has been freed.
2340 2010-02-09 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2343 * array.c (gfc_constant_ac): Do not prevent expansion of constructors
2346 2010-02-09 Jakub Jelinek <jakub@redhat.com>
2348 * module.c (fix_mio_expr): Declare sym.
2350 2010-02-09 Paul Thomas <pault@gcc.gnu.org>
2353 * module.c (fix_mio_expr): Fix for private generic procedures.
2355 2010-02-09 Daniel Kraft <d@domob.eu>
2358 * resolve.c (resolve_charlen): Change warning about negative CHARACTER
2359 length to be correct and issue only with -Wsurprising.
2360 * invoke.texi (Wsurprising): Mention this new warning that is
2361 turned on by -Wsurprising.
2363 2010-02-09 Daniel Kraft <d@domob.eu>
2366 * intrinsic.texi (MAXVAL): Remove wrong claim that array argument
2367 can be CHARACTER type.
2368 (MINVAL), (MAXLOC), (MINLOC): Ditto.
2370 2010-02-05 Paul Thomas <pault@gcc.gnu.org>
2373 * trans-expr.c (gfc_conv_subref_array_arg): Add new argument
2374 'formal_ptr'. If this is true, give returned descriptor unity
2375 lbounds, in all dimensions, and the appropriate offset.
2376 (gfc_conv_procedure_call); If formal is a pointer, set the last
2377 argument of gfc_conv_subref_array_arg to true.
2378 * trans.h : Add last argument for gfc_conv_subref_array_arg.
2379 * trans-io.c (set_internal_unit, gfc_trans_transfer): Set the
2380 new arg of gfc_conv_subref_array_arg to false.
2381 * trans-stmt.c (forall_make_variable_temp): The same.
2383 2010-02-03 Tobias Burnus <burnus@net-b.de>
2386 * interface.c (compare_parameter): Disable rank-checking
2389 2010-02-02 Tobias Burnus <burnus@net-b.de>
2392 * parse.c (decode_specification_statement): Use sym->result not sym.
2394 2010-02-01 Tobias Burnus <burnus@net-b.de>
2397 * decl.c (variable_decl): Allow default initializer in
2398 TYPE declarations in PURE functions.
2400 2010-01-31 Janus Weil <janus@gcc.gnu.org>
2403 * resolve.c (resolve_allocate_expr): Move default initialization code
2404 here from gfc_trans_allocate.
2405 * trans.c (gfc_trans_code): Call gfc_trans_class_assign also for
2407 * trans-expr.c (gfc_trans_class_assign): Handle default initialization
2408 of CLASS variables via memcpy.
2409 * trans-stmt.c (gfc_trans_allocate): Move default initialization code
2410 to resolve_allocate_expr.
2412 2010-01-31 Paul Thomas <pault@gcc.gnu.org>
2415 * expr.c (gfc_get_full_arrayspec_from_expr): New function.
2416 * gfortran.h : Add prototype for above.
2417 * trans-expr.c (gfc_trans_alloc_subarray_assign): New function.
2418 (gfc_trans_subcomponent_assign): Call new function to replace
2419 the code to deal with allocatable components.
2420 * trans-intrinsic.c (gfc_conv_intrinsic_bound): Call
2421 gfc_get_full_arrayspec_from_expr to replace existing code.
2423 2010-01-25 Tobias Burnus <burnus@net-b.de>
2426 * array.c (gfc_array_dimen_size): Fix intrinsic procedure
2429 2010-01-24 Paul Thomas <pault@gcc.gnu.org>
2433 * expr.c (remove_subobject_ref): If the constructor is NULL use
2434 the expression as the source.
2435 (simplify_const_ref): Change the type of expression if
2436 there are component references. Allow for substring to be at
2437 the end of an arbitrarily long chain of references. If an
2438 element is found that is not in an EXPR_ARRAY, assume that this
2439 is scalar initialization of array. Call remove_subobject_ref in
2440 this case with NULL second argument.
2442 2010-01-24 Tobias Burnus <burnus@net-b.de>
2445 * array.c (gfc_array_dimen_size): Use correct specific
2446 function in the check.
2448 2010-01-21 Paul Thomas <pault@gcc.gnu.org>
2451 * trans-stmt.c (gfc_conv_elemental_dependencies): If temporary
2452 is required, turn any trailing array elements after a range
2453 into ranges so that offsets can be calculated.
2455 2010-01-20 Joern Rennecke <amylaar@spamcop.net>
2457 * module.c (mio_f2k_derived): Use enumerator as initializer of
2461 * gfortran.h (struct gfc_namespace) <resolved>: Change to signed
2462 bitfield of width 2.
2464 2010-01-19 Janus Weil <janus@gcc.gnu.org>
2467 * resolve.c (extract_compcall_passed_object): Set locus for
2468 passed-object argument.
2469 (extract_ppc_passed_object): Set locus and correctly remove PPC
2472 2010-01-19 Paul Thomas <pault@gcc.gnu.org>
2475 * trans-decl.c (add_argument_checking): Do not use the backend
2476 decl directly to test for the presence of an optional dummy
2477 argument. Use gfc_conv_expr_present, remembering to set the
2481 * trans-decl.c (gfc_generate_function_code): Small white space
2482 changes. If 'recurcheckvar' is NULL do not try to reset it.
2484 2010-01-19 Janus Weil <janus@gcc.gnu.org>
2487 * resolve.c (resolve_fl_derived): Set the accessibility of the parent
2488 component for extended types.
2489 * symbol.c (gfc_find_component): Remove a wrongly-worded error message
2490 and take care of parent component accessibility.
2492 2010-01-17 Janus Weil <janus@gcc.gnu.org>
2495 * gfortran.h (symbol_attribute): Remove 'ambiguous_interfaces'.
2496 * interface.c (check_interface1): Move a warning message here from
2497 resolve_fl_procedure.
2498 (check_sym_interfaces): Removed 'attr.ambiguous_interfaces'.
2499 * module.c (read_module): Remove call to gfc_check_interfaces, since
2500 this comes too early here.
2501 * resolve.c (resolve_fl_procedure): Move warning message to
2504 2010-01-14 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2507 * interface.c (check_interface1): Pass symbol name rather than NULL to
2508 gfc_compare_interfaces. (gfc_compare_interfaces): Add assert to
2510 * resolve.c (check_generic_tbp_ambiguity): Pass symbol name rather
2511 than NULL to gfc_compare_interfaces.
2513 2010-01-14 Paul Thomas <pault@gcc.gnu.org>
2516 * trans-array.c (duplicate_allocatable): Static version of
2517 gfc_duplicate_allocatable with provision to handle scalar
2518 components. New boolean argument to switch off call to malloc
2520 (gfc_duplicate_allocatable): New function to call above with
2522 (gfc_copy_allocatable_data): New function to call above with
2524 (structure_alloc_comps): Do not apply indirect reference to
2525 scalar pointers. Add new section to copy allocatable components
2526 of arrays. Extend copying of allocatable components to include
2528 (gfc_copy_only_alloc_comp): New function to copy allocatable
2529 component derived types, without allocating the base structure.
2530 * trans-array.h : Add primitive for gfc_copy_allocatable_data.
2531 Add primitive for gfc_copy_only_alloc_comp.
2532 * trans-expr.c (gfc_conv_procedure_call): After calls to
2533 transformational functions with results that are derived types
2534 with allocatable components, copy the components in the result.
2535 (gfc_trans_arrayfunc_assign): Deallocate allocatable components
2536 of lhs derived types before allocation.
2538 2010-01-14 Paul Thomas <pault@gcc.gnu.org>
2541 * module.c (load_generic_interfaces): If a procedure that is
2542 use associated but not generic is given an interface that
2543 includes itself, then make it generic.
2545 2010-01-11 Joseph Myers <joseph@codesourcery.com>
2546 Shujing Zhao <pearly.zhao@oracle.com>
2548 PR translation/42469
2549 * lang.opt (fblas-matmul-limit=, finit-character=, finit-integer=,
2550 finit-logical=, finit-real=, fmax-array-constructor=): Use tab
2551 character between option name and help text.
2553 2010-01-09 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2557 * trans-array.c (gfc_conv_array_initializer): Change call to
2558 gfc_error_now to call to gfc_fatal_error.
2559 * array.c (count_elements): Whitespace. (extract_element): Whitespace.
2560 (is_constant_element): Changed name from constant_element.
2561 (gfc_constant_ac): Only use expand_construuctor for expression
2562 types of EXPR_ARRAY. If expression type is EXPR_CONSTANT, no need to
2563 call gfc_is_constant_expr.
2564 * expr.c (gfc_reduce_init_expr): Adjust conditionals and delete error
2566 * resolve.c (gfc_is_expandable_expr): New function that determiners if
2567 array expressions should have their constructors expanded.
2568 (gfc_resolve_expr): Use new function to determine whether or not to call
2569 gfc_expand_constructor.
2571 2010-01-09 Tobias Burnus <burnus@net-b.de>
2574 * trans-expr.c (gfc_trans_structure_assign): Handle
2576 * symbol.c (gen_special_c_interop_ptr): Add NULL_EXPR
2577 to the constructor for c_null_(fun)ptr.
2578 * resolve.c (resolve_structure_cons): Add special case
2579 for c_null_(fun)ptr.
2581 2010-01-09 Jakub Jelinek <jakub@redhat.com>
2583 * gfortranspec.c (lang_specific_driver): Update copyright notice
2586 2010-01-08 Tobias Burnus <burnus@net-b.de>
2589 * symbol.c (check_conflict, gfc_copy_attr): Add
2590 ASYNCHRONOUS support.
2591 (gfc_add_asynchronous): New function.
2592 * decl.c (match_attr_spec): Add ASYNCHRONOUS support.
2593 (gfc_match_asynchronous): New function.
2594 * dump-parse-tree.c (show_attr): Add ASYNCHRONOUS support.
2595 * gfortran.h (symbol_attribute): New ASYNCHRONOUS bit.
2596 (gfc_add_asynchronous): New Prototype.
2597 * module.c (ab_attribute, mio_symbol_attribute): Add
2598 ASYNCHRONOUS support.
2599 * resolve.c (was_declared): Ditto.
2600 * match.h (gfc_match_asynchronous): New prototype.
2601 * parse.c (decode_specification_statement,decode_statement):
2602 Add ASYNCHRONOUS support.
2604 2010-01-07 Tobias Burnus <burnus@net-b.de>
2607 * trans-decl.c (get_proc_pointer_decl): Fix call to
2608 gfc_conv_initializer for array-valued proc-pointer funcs.
2610 2010-01-07 Tobias Burnus <burnus@net-b.de>
2613 * trans-decl.c (gfc_trans_deferred_vars): Don't initialize
2614 allocatable scalars with SAVE attribute.
2616 2010-01-05 Tobias Burnus <burnus@net-b.de>
2619 * options.c (gfc_post_options): Set -frecursion
2620 when -fopenmp is used.
2622 2010-01-05 Tobias Burnus <burnus@net-b.de>
2625 * trans-expr.c (gfc_conv_procedure_call): Nullify
2626 return value for allocatable-scalar character functions.
2628 2010-01-04 Tobias Burnus <burnus@net-b.de>
2631 * error.c (error_printf, gfc_warning, gfc_notify_std,
2632 gfc_warning_now, gfc_error, gfc_error_now,
2633 gfc_fatal_error): Change argument name from nocmsgid to
2634 gmsgid to enable (x)gettext's % checking.
2636 2010-01-04 Tobias Burnus <burnus@net-b.de>
2638 * trans-decl.c (gfc_trans_deferred_vars): Fix spelling.
2640 2010-01-04 Tobias Burnus <burnus@net-b.de>
2643 * trans-expr.c (gfc_conv_procedure_call): Add indirect ref
2644 for functions returning allocatable scalars.
2645 * trans-stmt.c (gfc_trans_allocate): Emmit error when
2646 reallocating an allocatable scalar.
2647 * trans.c (gfc_allocate_with_status): Fix pseudocode syntax
2649 * trans-decl.c (gfc_trans_deferred_vars): Nullify local
2650 allocatable scalars.
2651 (gfc_generate_function_code): Nullify result variable for
2652 allocatable scalars.
2655 * module.c (gfc_use_module): Fix warning string to allow
2659 * invoke.texi (-fcheck=recursion): Mention that the checking
2660 is also disabled for -frecursive.
2661 * trans-decl.c (gfc_generate_function_code): Disable
2662 -fcheck=recursion when -frecursive is used.
2664 * intrinsic.texi (iso_c_binding): Improve wording.
2667 Copyright (C) 2010 Free Software Foundation, Inc.
2669 Copying and distribution of this file, with or without modification,
2670 are permitted in any medium without royalty provided the copyright
2671 notice and this notice are preserved.