1 2010-11-09 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2 Mikael Morin <mikael@gcc.gnu.org>
5 * intrinsic.c: Correctly set the pure attributes for intrinsic
7 * expr.c (check_specification_function): Remove this function and move
8 its code into gfc_is_constant_expr. (gfc_is_constant_expr): Change the
9 order of checks by checking for non-constant arguments first. Then,
10 check for initialization functions, followed by intrinsics.
12 2010-11-09 Janus Weil <janus@gcc.gnu.org>
15 * gfortran.h (gfc_add_data_component,gfc_add_vptr_component,
16 gfc_add_hash_component,gfc_add_size_component,
17 gfc_add_def_init_component): New macros.
18 * class.c (gfc_add_component_ref): Renamed data component.
19 (get_unique_type_string): New function.
20 (gfc_build_class_symbol): Use 'get_unique_type_string' to construct
21 uniques names for the class containers. Rename components.
22 (gfc_find_derived_vtab): Use 'get_unique_type_string' to construct
23 uniques names for the vtab symbols. Rename components.
24 * decl.c (attr_decl1): Renamed class container components.
25 * iresolve.c (gfc_resolve_extends_type_of): Ditto.
26 * match.c (select_type_set_tmp): Renamed temporaries.
27 * module.c (read_module): Renamed vtab and vtype symbols.
28 * resolve.c (resolve_structure_cons,resolve_typebound_function,
29 resolve_typebound_subroutine,resolve_deallocate_expr,
30 resolve_select_type,resolve_fl_derived): Renamed class container and
32 * trans-array.c (structure_alloc_comps): Ditto.
33 * trans-decl.c (gfc_trans_deferred_vars): Ditto.
34 * trans-expr.c (gfc_conv_derived_to_class,gfc_conv_structure,
35 gfc_trans_class_init_assign,gfc_trans_class_assign): Ditto.
36 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof,
37 gfc_conv_intrinsic_storage_size,gfc_conv_allocated,gfc_conv_associated,
38 gfc_conv_same_type_as): Ditto.
39 * trans-stmt.c (gfc_trans_allocate): Ditto.
41 2010-11-08 Jerry DeLisle <jvdelisle@gcc.gnu.org>
44 * trans-decl.c (generate_local_decl): Do not generate unused warning
45 for variables in namelists.
47 2010-11-08 Janus Weil <janus@gcc.gnu.org>
50 * decl.c (build_struct): Build vtab immediately if derived type
51 has already been declared.
53 2010-11-08 Janus Weil <janus@gcc.gnu.org>
56 * trans-types.c (gfc_copy_dt_decls_ifequal): Handle CLASS components.
58 2010-11-06 Janus Weil <janus@gcc.gnu.org>
61 * trans-expr.c (gfc_trans_class_assign): Find 'vtab' symbol in correct
64 2010-11-05 Janus Weil <janus@gcc.gnu.org>
68 * class.c (gfc_find_derived_vtab): Improved search for existing vtab.
69 Add component '$copy' to vtype symbol for polymorphic deep copying.
70 * expr.c (gfc_check_pointer_assign): Make sure the vtab is generated
71 during resolution stage.
72 * resolve.c (resolve_codes): Don't resolve code if namespace is already
74 * trans-stmt.c (gfc_trans_allocate): Call '$copy' procedure for
75 polymorphic ALLOCATE statements with SOURCE.
77 2010-11-03 Thomas Koenig <tkoenig@gcc.gnu.org>
78 Paul Thomas <pault@gcc.gnu.org>
80 * dump-parse-tree.c (code_indent): Take label into acount
81 when calculating indent.
82 (show_typespec): Also display class.
83 (show_attr): Add module name to argument.
84 Don't show UNKNOWN for flavor, access and save. Don't show
85 SAVE_NONE. Don't show INTENT_UNKNOWN. Show module for use
86 association. Show intent only for dummy arguments.
87 Set length of shown symbol names to minimum of 12.
88 Show attributes header.
89 (show_symbol): Adjust show_level.
90 (show_symtree): Clear up display for ambiguous. Show if symbol
91 was imported from namespace.
92 (show_code_node): Clear up indenting. Traverse symtree and
93 show code directly instead of calling show_namespace.
95 2010-11-02 Nathan Froyd <froydnj@codesourcery.com>
97 * trans-decl.c (add_argument_checking): Use build_zero_cst instead of
99 * trans-expr.c (gfc_conv_missing_dummy, fill_with_spaces): Likewise.
100 * trans-stmt.c (gfc_trans_do): Likewise.
102 2010-11-02 Steven G. Kargl < kargl@gcc.gnu.org>
103 Tobias Burnus <burnus@net-b.de>
106 * array.c (gfc_match_array_constructor): Reject deferred type
107 parameter (DTP) in type-spec.
108 * decl.c (char_len_param_value, match_char_length,
109 gfc_match_char_spec, build_sym, variable_decl,
110 enumerator_decl): Support DTP.
111 * expr.c (check_inquiry): Fix check due to support for DTP.
112 * gfortran.h (gfc_typespec): Add Boolean 'deferred'.
113 * misc.c (gfc_clear_ts): Set it to false.
114 * match.c (gfc_match_allocate): Support DTP.
115 * resolve.c (resolve_allocate_expr): Not-implemented error for DTP.
116 (resolve_fl_variable): Add DTP constraint check.
117 * trans-decl.c (gfc_trans_deferred_vars): Add not-implemented
120 2010-11-01 Steven G. Kargl <kargl@gcc.gnu.org>
123 * fortran/match.c (match_derived_type_spec): Reoplace gfc_match_symbol
124 with a gfc_find_symbol to prevent namespace pollution. Remove dead
126 (match_type_spec): Remove parsing of '::'. Collapse character
127 kind checking to one location.
128 (gfc_match_allocate): Use correct locus in error message.
130 2010-10-30 Thomas Koenig <tkoenig@gcc.gnu.org>
132 * gfortran.h (gfc_option_t): Replace dump_parse_tree by
133 dump_fortran_original and add dump_fortran_optimized.
134 * lang.opt: Add fdump-fortran-original and
135 fdump-fortran-optimized. Document that fdump-parse-tree is
137 * gfortran.texi: Add -fdump-fortran-original and
138 -fdump-fortran-optimized. -fdump-parse-tree is deprecated.
139 * frontend-passes.c (gfc_run_passes): If optimizing and
140 if gfc_option.dump_fortran_optimized is set, dump the parse tree
142 * parse.c: Rename gfc_option.dump_parse_tree to
143 gfc_option.dump_fortran_original.
144 * options.c (gfc_init_options): Rename gfc_option.dump_parse_tree
145 to gfc_option.dump_fortran_original and handle
146 gfc_option.dump_fortran_optimize.
147 (gfc_post_options): Rename gfc_option.dump_parse_tree
148 to gfc_option.dump_fortran_original.
149 (gfc_handle_option): Rename OPT_fdump_parse_tree to
150 OPT_fdump_fortran_original and gfc_option.dump_parse_tree
151 to gfc_option.dump_fortran_original. Handle
152 OPT_fdump_fortran_optimized.
154 2010-10-30 Janus Weil <janus@gcc.gnu.org>
159 * interface.c (count_types_test): Symmetrize type check.
160 (generic_correspondence): Ditto.
162 2010-10-27 Janus Weil <janus@gcc.gnu.org>
165 * interface.c (compare_allocatable): Handle polymorphic allocatables.
166 (compare_parameter): Add two error messages for polymorphic dummies.
168 2010-10-26 Janus Weil <janus@gcc.gnu.org>
171 * trans.h (gfc_deallocate_scalar_with_status): New prototype.
172 * trans.c (gfc_deallocate_scalar_with_status): New function for
173 deallocation of allocatable scalars.
174 * trans-array.c (structure_alloc_comps): Call it here ...
175 * trans-decl.c (gfc_trans_deferred_vars): ... here ...
176 * trans-stmt.c (gfc_trans_deallocate): ... and here.
178 2010-10-26 Tobias Burnus <burnus@net-b.de>
181 * trans-stmt.c (gfc_trans_allocate): Do a deep-copy for SOURCE=.
184 * trans-array.c (duplicate_allocatable): Use size of type and not
185 the size of the pointer to the type.
187 2010-10-25 Steven G. Kargl <kargl@gcc.gnu.org>
190 * fortran/scanner.c (include_line): Check return value of load_file.
192 2010-10-23 Tobias Burnus <burnus@net-b.de>
195 * expr.c (gfc_check_vardef_context): Fix PROTECTED check.
197 2010-10-21 Janus Weil <janus@gcc.gnu.org>
200 * match.h (gfc_matching_ptr_assignment): New global variable to indicate
201 we're currently matching a (non-proc-)pointer assignment.
202 * decl.c (match_pointer_init): Set it.
203 * match.c (gfc_match_pointer_assignment): Ditto.
204 * primary.c (matching_actual_arglist): New global variable to indicate
205 we're currently matching an actual argument list.
206 (gfc_match_actual_arglist): Set it.
207 (gfc_match_varspec): Reject procedure pointer component calls with
208 missing argument list.
210 2010-10-21 Janus Weil <janus@gcc.gnu.org>
213 * interface.c (gfc_compare_interfaces): Switch arguments of type
214 comparison (important for polymorphic variables).
216 2010-10-21 Tobias Burnus <burnus@net-b.de>
219 * expr.c (gfc_check_vardef_context): Treat pointer functions
222 2010-10-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
225 * trans_stmt.c (gfc_trans_stop): Fix whitespace. Build a call to new
226 F08 numeric stop function.
227 * trans.h: Add declaration for gfor_fndecl_stop_numeric_f08.
228 * trans-decl.c (gfc_build_builtin_function_decls): Build declaration
229 for stop_numeric_f08.
231 2010-10-18 Jerry DeLisle <jvdelisle@gcc.gnu.org>
233 * gfortran.h: Remove definition of bt enumerator.
234 * libgfortran.h: Add bt enumerator type alighned with defintion.
235 Remove the dtype enumerator, no longer used.
236 previously given in libgfortran/io.h
237 * trans-types.c: Use new bt enumerator.
238 * trans-io.c: Likewise.
240 2010-10-16 Thomas Koenig <tkoenig@gcc.gnu.org>
242 * trans-io.c (gfc_build_io_library_fndecls):
243 Array descriptor arguments to transfer_array can be
244 dereferenced recursively.
246 2010-10-16 Thomas Koenig <tkoenig@gcc.gnu.org>
251 * trans-io.c (enum iocall): Add IOCALL_X_INTEGER_WRITE,
252 IOCALL_X_LOGICAL_WRITE, IOCALL_X_CHARACTER_WRITE,
253 IOCALL_X_CHARACTER_WIDE_WRIE, IOCALL_X_REAL_WRITE,
254 IOCALL_X_COMPLEX_WRITE and IOCALL_X_ARRAY_WRITE.
255 (gfc_build_io_library_fndecls): Add corresponding function
257 (transfer_expr): If the current transfer is a READ, use
258 the iocall with the original version, otherwise the version
260 (transfer_array_desc): Likewise.
262 2010-10-15 Tobias Burnus <burnus@net-b.de>
265 * trans.h (gfc_add_modify_loc, gfc_evaluate_now_loc): New prototypes.
266 (gfc_trans_runtime_error_vararg): Remove prototype.
267 * trans.c (gfc_add_modify_loc, gfc_evaluate_now_loc): New functions.
268 (gfc_add_modify, gfc_evaluate_now): Use them.
269 (trans_runtime_error_vararg): Renamed from
270 gfc_trans_runtime_error_vararg, made static and use locus.
271 (gfc_trans_runtime_error): Use it.
272 (gfc_trans_runtime_check): Ditto and make use of locus.
273 * trans-stmt.c (gfc_trans_if_1, gfc_trans_simple_do,
274 gfc_trans_do, gfc_trans_do_while): Improve line number
275 associated with generated expressions.
277 2010-10-12 Daniel Kraft <d@domob.eu>
280 * parse.c (parse_associate): Set typespec of associate-name if that of
281 the target is already available.
283 2010-10-10 Janus Weil <janus@gcc.gnu.org>
286 * resolve.c (resolve_typebound_function): Bugfix for type-bound
289 2010-10-09 Thomas Koenig <tkoenig@gcc.gnu.org>
291 * frontend-passes.c: Include opts.h.
292 (optimize_comparison): Renamed from optimize_equality.
293 Change second argument to operation to be compared.
294 Use flag_finite_math_only to avoid comparing REAL and
295 COMPLEX only when NANs are honored. Simplify comparing
296 of string concatenations where left or right operands are
297 equal. Simplify all comparison operations, based on the result
298 of gfc_dep_compare_expr.
299 * dependency.c: Include arith.h.
300 (gfc_are_identical_variables): Volatile variables should not
301 compare equal to themselves.
302 (gfc_dep_compare_expr): Handle string constants and string
305 2010-10-08 Joseph Myers <joseph@codesourcery.com>
307 * f95-lang.c (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
308 * gfortran.h (gfc_init_options_struct): Declare.
309 * options.c (gfc_init_options_struct): New. Split out from
312 2010-10-07 Janus Weil <janus@gcc.gnu.org>
315 * resolve.c (resolve_typebound_function): Use correct declared type
316 for type-bound operators.
318 2010-10-07 Mikael Morin <mikael@gcc.gnu.org>
321 Revert revision 165026:
322 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
324 * decl.c (match_procedure_in_type): Assertify if conditions.
326 2010-10-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
329 * resolve.c (resolve_transfer): Use expression inside parenthesis to
330 find acutal component to be transgferred.
332 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
334 * trans-stmt.c (gfc_trans_allocate): free lhs expr.
336 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
338 * trans-array.c (gfc_free_ss_chain): Made non-static.
339 * trans-array.h (gfc_free_ss_chain): New prototype.
340 * trans-stmt.c (gfc_trans_where_2): Free ss chains.
342 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
344 * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Also free symbol's
347 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
349 * trans-stmt.c (gfc_trans_forall_1): Free forall struct at the end.
351 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
353 * trans-expr.c (get_proc_ptr_comp): Restore initial expression type
354 before calling gfc_free_expr.
356 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
358 * trans-array.c (gfc_conv_tmp_array_ref): Add factorized call to
359 gfc_advance_se_ss_chain.
360 * trans-expr.c (gfc_conv_subref_array_ref, gfc_conv_procedure_call,
361 gfc_conv_array_constructor_expr, gfc_trans_assignment_1): Remove
362 calls to gfc_advance_se_ss_chain after gfc_conv_tmp_array_ref.
363 * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
364 * trans-stmt.c (gfc_trans_where_assign, gfc_trans_where_3): Ditto.
366 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
368 * trans.c (gfc_restore_backend_locus): New function.
369 (gfc_get_backend_locus): Renamed to ...
370 (gfc_save_backend_locus): ... this.
371 * trans.h (gfc_restore_backend_locus, gfc_get_backend_locus,
372 gfc_save_backend_locus): Same.
373 * trans-array.c (gfc_trans_g77_array, gfc_trans_dummy_array_bias,
374 gfc_trans_deferred_array): Rename gfc_get_backend_locus to
375 gfc_save_backend_locus.
376 (gfc_trans_dummy_array_bias): Call gfc_restore_backend_locus at the
378 (gfc_trans_g77_array, gfc_trans_deferred_array): Use
379 gfc_restore_backend_locus instead of gfc_set_backend_locus.
380 (gfc_trans_deferred_array): Call gfc_restore_backend_locus on early
382 * trans-decl.c (gfc_get_extern_function_decl, build_entry_thunks,
383 gfc_trans_deferred_vars):
384 Rename gfc_get_backend_locus to gfc_save_backend_locus.
385 Use gfc_restore_backend_locus insted of gfc_set_backend_locus.
387 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
389 * trans-array.c (gfc_build_constant_array_constructor): Free array
392 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
394 * symbol.c (gfc_copy_formal_args_ppc): Free previous formal arg list
395 before overwriting it.
397 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
399 * array.c (gfc_match_array_spec): Don't re-initialize cleared struct.
400 * symbol.c (gen_shape_param): Ditto.
402 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
404 * symbol.c (free_entry_list): New function.
405 (gfc_free_namespace): Free list of entries.
407 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
409 * symbol.c (free_components): Free list of formal args and formal
412 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
414 * simplify.c (gfc_simplify_size): Clear temporary mpz int before
417 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
419 * resolve.c (add_dt_to_dt_list): Remove unneeded if.
421 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
423 * resolve.c (check_typebound_baseobject): Free local expr before
426 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
428 * primary.c (gfc_match_structure_constructor): Invert the assert logic.
430 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
432 * primary.c (gfc_free_structure_ctor_component): Also free the
433 component structure itself.
435 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
437 * module.c (gfc_use_module): Free atom_string when done with it.
439 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
441 * module.c (read_module): Remove useless string duplication.
443 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
445 * gfortranspec.c (append_arg): Remove commented code.
447 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
449 * decl.c (match_procedure_in_type): Assertify if conditions.
451 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
453 * cpp.c (gfc_cpp_post_options): Don't create a cpp reader if
454 preprocessing is disabled.
456 2010-10-06 Jakub Jelinek <jakub@redhat.com>
459 * f95-lang.c (ATTR_NOTHROW_LEAF_LIST, ATTR_CONST_NOTHROW_LEAF_LIST,
460 ATTR_NOTHROW_LIST, ATTR_CONST_NOTHROW_LIST): Define.
461 (gfc_define_builtin): Change last argument to int bitmask from bool,
462 control addition of TREE_NOTHROW and leaf attribute as well.
463 (DO_DEFINE_MATH_BUILTIN): Adjust callers.
464 (gfc_init_builtin_functions): Likewise. Remove
465 ATTR_{,CONST_}NOTHROW_LIST enum.
467 2010-10-04 Andi Kleen <ak@linux.intel.com>
469 * Make-lang.in (gfortran, f951): Add + to build rule.
471 2010-10-04 Richard Guenther <rguenther@suse.de>
473 * f95-lang.c (current_translation_unit): New global variable.
474 (gfc_create_decls): Build a translation-unit decl.
475 (pushdecl): In the global binding-level use the
476 translation-unit decl as DECL_CONTEXT.
477 * trans-decl.c (gfc_get_symbol_decl): Use DECL_FILE_SCOPE_P.
478 (build_function_decl): Likewise. Delay setting the assembler
479 name, leave setting of DECL_CONTEXT to pushdecl.
480 (trans_function_start): Use DECL_FILE_SCOPE_P.
481 (gfc_create_module_variable): Likewise. Remove questionable
483 * trans.c (gfc_generate_module_code): Likewise.
485 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
487 * cpp.c (cpp_define_builtins): Call functions from cppbuiltin.c
488 instead of duplicating code.
489 * Make-lang.in: Add dependency on cppbuiltin.h. Don't define
492 2010-10-02 Janus Weil <janus@gcc.gnu.org>
495 * resolve.c (resolve_formal_arglist): Avoid setting default type for
496 formal arguments of intrinsic procedures.
498 2010-09-30 Janus Weil <janus@gcc.gnu.org>
501 * resolve.c (resolve_allocate_expr): Do not use
502 'gfc_has_default_initializer'.
504 2010-09-30 Tobias Burnus <burnus@net-b.de>
506 * gfortran.tex (Fortran 2008 status): Update list of
507 implemented features.
509 2010-09-29 Joseph Myers <joseph@codesourcery.com>
511 * lang.opt: Don't use VarExists.
513 2010-09-29 Joseph Myers <joseph@codesourcery.com>
515 * cpp.c (cpp_define_builtins): Update names of gfc_option_t
517 (gfc_cpp_post_options): Update names of cpp_options members.
518 (cb_cpp_error): Update names of diagnostic_context members.
519 * f95-lang.c (gfc_init_builtin_functions): Update names of
520 gfc_option_t members.
521 * gfortran.h (gfc_option_t): Rename warn_conversion and
523 * intrinsic.c (gfc_convert_type_warn): Update names of
524 gfc_option_t members.
525 * options.c (gfc_init_options, gfc_post_options, set_Wall,
526 gfc_handle_option): Update names of gfc_option_t members.
527 * parse.c (next_free, next_fixed): Update names of gfc_option_t
529 * scanner.c (pedantic): Remove extern declaration.
530 (skip_free_comments, skip_fixed_comments, include_line): Update
531 names of gfc_option_t members.
532 * trans-decl.c (gfc_generate_function_code): Update names of
533 gfc_option_t members.
535 2010-09-28 Tobias Burnus <burnus@net-b.de>
539 * intrinsic.c (add_functions): Make compiler_version and
540 compiler_options CLASS_INQUIRY.
541 * gfortran.h (gfc_get_option_string): New prototype.
542 * intrinsic.texi (COMPILER_VERSION, COMPILER_OPTIONS):
544 (C_SIZEOF): Mark as inquiry function of ISO_C_BINDING.
545 (ISO_FORTRAN_ENV): Refer to COMPILER_VERSION and COMPILER_OPTIONS.
546 (ISO_C_BINDING): Refer to C_SIZEOF.
547 * options.c (gfc_get_option_string): New function.
548 * simplify.c (gfc_simplify_compiler_options): Use it.
549 (gfc_simplify_compiler_version): Include compiler name.
551 2010-09-28 Jan Hubicka <jh@suse.cz>
553 * f95-lang.c (gfc_define_builtin): Make leaf.
554 (gfc_init_builtin_functions): Handle only ATTR_CONST_NOTHROW_LEAF_LIST
555 and ATTR_NOTHROW_LEAF_LIST.
556 (DEF_SYNC_BUILTIN): Check ATTR_CONST_NOTHROW_LEAF_LIST.
557 (DEF_GOMP_BUILTIN): Likewise.
559 2010-09-28 Tobias Burnus <burnus@net-b.de>
562 * trans-decl.c (gfc_get_symbol_decl): Use gsym for decl of
565 2010-09-27 Tobias Burnus <burnus@net-b.de>
569 * intrinsic.h (gfc_simplify_compiler_options,
570 gfc_simplify_compiler_version): New prototypes.
571 * intrinsic.c (gfc_intrinsic_function_by_id,
572 make_from_module): New functions.
573 (gfc_find_function, gfc_find_subroutine, gfc_generic_intrinsic,
574 gfc_specific_intrinsic): Don't return module intrinsics.
575 (add_functions): Add compiler_options, compiler_version.
576 (gfc_intrinsic_func_interface): Also lookup symbol by ISYM ID.
577 * symbol.c (std_for_isocbinding_symbol): Add version check for
579 * iso-fortran-env.def: Add compiler_options, compiler_version.
580 * iso-c-binding.def: Add c_sizeof.
581 * gfortran.h (gfc_intrinsic_sym): Add from_module:1.
582 (iso_c_binding_symbol, iso_fortran_env_symbol): Add NAMED_FUNCTIONS.
583 (gfc_intrinsic_function_by_id): New prototype.
584 * module.c (create_intrinsic_function): New function.
585 (import_iso_c_binding_module, use_iso_fortran_env_module): Use it.
586 * trans-types.c (init_c_interop_kinds): Add NAMED_FUNCTIONS.
587 * resolve.c (resolve_intrinsic): Try also to resolve intrinsics
589 * simplify.c (gfc_simplify_compiler_options,
590 gfc_simplify_compiler_version): New functions.
592 2010-09-26 Daniel Kraft <d@domob.eu>
596 * resolve.c (resolve_select_type): Clarify code.
597 (resolve_assoc_var): Only set typespec if it is currently unknown.
599 2010-09-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
602 * module.c (create_int_parameter_array): Set the array value shape.
604 2010-09-25 Tobias Burnus <burnus@net-b.de>
606 * gfortran.texi: Re-add accidently removed \input line.
608 2010-09-25 Daniel Kraft <d@domob.eu>
611 * gfortran.h (struct gfc_dt): New member `dt_io_kind'.
612 * io.c (resolve_tag): F2008 check for NEWUNIT and variable
613 definition checks for NEWUNIT, IOSTAT, SIZE and IOMSG.
614 (gfc_free_dt): Correctly handle freeing of `dt_io_kind' and
615 `extra_comma' with changed semantics.
616 (gfc_resolve_dt): Check variable definitions.
617 (match_io_element): Remove INTENT and PURE checks here and
618 initialize code->ext.dt member.
619 (match_io): Set dt->dt_io_kind.
620 (gfc_resolve_inquire): Check variable definition for all tags
621 except UNIT, FILE and ID.
622 * resolve.c (resolve_transfer): Variable definition check.
624 2010-09-25 Tobias Burnus <burnus@net-b.de>
626 * interface.c (gfc_match_end_interface): Constify char pointer
629 2010-09-24 Steven G. Kargl < kargl@gcc.gnu.org>
631 * interface.c (gfc_match_end_interface): Deal with user defined
632 operators that overload rational operators and C1202.
634 2010-09-24 Tobias Burnus <burnus@net-b.de>
636 * gfortran.texi: Add second space after end-of-sentence period;
637 change / to /@/ to allow hyphenation of URLs.
638 (Standards): Remove duplicated OpenMP, update wording given that
639 Fortran 2008 now released.
640 (Fortran 2008 status): Update and add list of implemented features.
642 2010-09-24 Tobias Burnus <burnus@net-b.de>
645 * iso-fortran-env.def: Add NAMED_KINDARRAY with
646 character_kinds, integer_kinds, logical_kinds and
648 * gfortran.h: Add them to iso_fortran_env_symbol.
649 * libgfortran.h: Rename GFC_INQUIRE_INTERNAL_UNIT to
650 LIBERROR_INQUIRE_INTERNAL_UNIT and move it from
651 libgfortran_stat_codes to libgfortran_error_codes.
652 * module.c (create_int_parameter_array): New function.
653 (use_iso_fortran_env_module): Use it for
654 NAMED_KINDARRAY of iso-fortran-env.def.
655 * trans-decl.c (gfc_get_symbol_decl): Parameter
656 arrays of intrinsics modules become local static variables.
657 * intrinsic.texi (ISO_FORTRAN_ENV): Add character_kinds,
658 integer_kinds, logical_kinds and real_kinds.
660 2010-09-23 Thomas Koenig <tkoenig@gcc.gnu.org>
663 * frontend-passes.c (optimize_binop_array_assignment):
664 Only re-use lhs as intermediate storage if kind and type
667 2010-09-23 Mikael Morin <mikael@gcc.gnu.org>
671 * trans-array.c (gfc_conv_expr_descriptor): Handle
672 ss->type == GFC_SS_INTRINSIC (for {l,u}bound intrinsics) case.
674 2010-09-23 Tobias Burnus <burnus@net-b.de>
676 * intrinsic.texi (OpenMP modules): Add named constants of
679 2010-09-23 Daniel Kraft <d@domob.eu>
684 * gfortran.h (gfc_check_vardef_context): New method.
685 (struct symbol_attribute): New flag `select_type_temporary'.
686 * primary.c (gfc_variable_attr): Clarify initialization of ref.
687 (match_variable): Remove PROTECTED check and assignment check
688 for PARAMETERs (this is now done later).
689 * match.c (gfc_match_iterator): Remove INTENT(IN) check.
690 (gfc_match_associate): Defer initialization of newAssoc->variable.
691 (gfc_match_nullify): Remove PURE definability check.
692 (select_type_set_tmp): Set new `select_type_temporary' flag.
693 * expr.c (gfc_check_assign): Remove INTENT(IN) check here.
694 (gfc_check_pointer_assign): Ditto (and other checks removed).
695 (gfc_check_vardef_context): New method.
696 * interface.c (compare_parameter_protected): Removed.
697 (compare_actual_formal): Use `gfc_check_vardef_context' for checks
698 related to INTENT([IN]OUT) arguments.
699 * intrinsic.c (check_arglist): Check INTENT for intrinsics.
700 * resolve.c (gfc_resolve_iterator): Use `gfc_check_vardef_context'.
701 (remove_last_array_ref): New method.
702 (resolve_deallocate_expr), (resolve_allocate_expr): Ditto.
703 (resolve_allocate_deallocate): Ditto (for STAT and ERRMSG).
704 (resolve_assoc_var): Remove checks for definability here.
705 (resolve_select_type): Handle resolving of code->block here.
706 (resolve_ordinary_assign): Remove PURE check.
707 (resolve_code): Do not resolve code->blocks for SELECT TYPE here.
708 Use `gfc_check_vardef_context' for assignments and pointer-assignments.
710 2010-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
712 * gfortran.texi (Argument list functions): Allow URL to wrap.
713 * intrinsic.texi (GETGID, GETPID, GETUID, IMAGE_INDEX)
714 (IS_IOSTAT_END, IS_IOSTAT_EOR, NUM_IMAGES, THIS_IMAGE)
715 (ISO_FORTRAN_ENV): Fix markup in index entries, and a couple of
716 code markups in the text.
717 * invoke.texi (Fortran Dialect Options)
718 (Error and Warning Options, Directory Options, Code Gen Options):
719 Likewise. Remove @code inside @smallexample.
721 2010-09-22 Joseph Myers <joseph@codesourcery.com>
723 * gfortranspec.c (lang_specific_driver): Handle OPT__version and
724 OPT__help instead of OPT_fversion and OPT_fhelp.
725 * lang.opt (-all-warnings, -assert, -assert=, -comments,
726 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
727 -dump, -dump=, -include-barrier, -include-directory,
728 -include-directory=, -include-directory-after,
729 -include-directory-after=, -include-prefix, -include-prefix=,
730 -no-line-commands, -no-standard-includes, -output, -output=,
731 -preprocess, -print-missing-file-dependencies, -trace-includes,
732 -undefine-macro, -undefine-macro=, -user-dependencies, -verbose,
733 -write-dependencies, -write-user-dependencies): New.
735 2010-09-21 Jason Blevins <jrblevin@sdf.org>
737 * intrinsics.texi (HYPOT, IMAGE_INDEX, BESSEL_JN, BESSEL_YN,
738 execute_command_line, IEOR, IOR, NORM2, NOT, NULL, PARITY):
741 2010-09-21 Mikael Morin <mikael@gcc.gnu.org>
744 * trans-array.c (gfc_conv_expr_descriptor): Calculate dim out of n and
748 * trans-array.c (gfc_conv_expr_descriptor): Unset full if we are
749 accessing dimensions in reversed order.
752 * trans-array.c (gfc_conv_expr_descriptor): Special case noncopying
753 intrinsic function call.
755 * trans-array.c (gfc_conv_expr_descriptor): Remove ss lookup.
756 Update asserts accordingly.
759 * trans.h (gfc_se): New field force_tmp.
760 * trans-expr.c (gfc_conv_procedure_call): Check for argument alias
761 and set parmse.force_tmp if some alias is found.
762 * trans-array.c (gfc_conv_expr_descriptor): Force a temporary creation
763 if se->force_tmp is set.
765 2010-09-20 Janus Weil <janus@gcc.gnu.org>
768 * trans-expr.c (gfc_conv_procedure_call): Fix pointer checking for
769 TBPs, PPCs and pointer/allocatable components.
771 2010-09-20 Paul Thomas <pault@gcc.gnu.org>
774 * simplify.c (is_constant_array_expr): Allow structure array
775 elements as well as constants.
776 (gfc_simplify_pack, gfc_simplify_reshape, gfc_simplify_spread,
777 gfc_simplify_transpose, gfc_simplify_unpack): Copy the derived
778 type of source to the result.
780 2010-09-19 Thomas Koenig <tkoenig@gcc.gnu.org>
782 * frontend-passes.c (gfc_expr_walker): Also
783 handle EXPR_SUBSTRING.
785 2010-09-19 Thomas Koenig <tkoenig@gcc.gnu.org>
787 * frontend-passes.c (gfc_expr_walker): Handle
788 constructors and references.
790 2010-09-16 Tobias Burnus <burnus@net-b.de>
793 * trans-types.c (create_fn_spec): New function.
794 (gfc_get_function_type): Call it.
796 2010-09-16 Jakub Jelinek <jakub@redhat.com>
798 * gfortran.h (walk_code_fn_t, walk_expr_fn_t): New types.
799 (gfc_expr_walker, gfc_code_walker): New prototypes.
800 * frontend-passes.c (gfc_expr_walker, gfc_code_walker): New functions.
801 (WALK_SUBEXPR, WALK_SUBEXPR_TAIL, WALK_SUBCODE): Define.
802 (optimize_namespace): Use gfc_code_walker.
803 (optimize_code, optimize_expr): Rewritten as gfc_code_walker hooks.
804 (optimize_expr_0, optimize_code_node,
805 optimize_actual_arglist): Removed.
806 (optimize_assignment): Don't call optimize_expr_0.
808 2010-09-16 Janus Weil <janus@gcc.gnu.org>
811 * interface.c (compare_parameter): Create vtab for actual argument,
812 instead of formal (if needed).
814 2010-09-15 Janus Weil <janus@gcc.gnu.org>
817 * resolve.c (resolve_allocate_expr): Do default initialization via
820 2010-09-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
822 * mathbuiltins.def: Do not defined huge_val built-in.
823 * trans-const.c (gfc_build_inf_or_huge): New function.
824 * trans-const.h (gfc_build_inf_or_huge): New prototype.
825 * f95-lang.c (gfc_init_builtin_functions): Don't defined
827 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): We don't
828 have functions of type (*) (void) anymore.
829 (gfc_conv_intrinsic_minmaxloc): Call gfc_build_inf_or_huge.
830 (gfc_conv_intrinsic_nearest): Call gfc_build_inf_or_huge instead
831 of generating a call to huge_val().
833 2010-09-11 Mikael Morin <mikael@gcc.gnu.org>
835 * gfortran.h (gfc_expr): Remove inline_noncopying_intrinsic attribute.
836 * dependency.c (gfc_check_dependency): Don't depend on
837 expr's inline_noncopying_intrinsic_attribute.
838 * dependency.c (gfc_check_argument_var_dependency,
839 gfc_check_argument_dependency): Ditto. Recursively check dependency
840 as NOT_ELEMENTAL in the non-copying (=transpose) case.
841 * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
842 * resolve.c (find_noncopying_intrinsics): Remove.
843 (resolve_function, resolve_call): Remove call to
844 find_noncopying_intrinsics.
846 * trans-array.c (gfc_conv_array_transpose): Remove.
847 (gfc_walk_subexpr): Make non-static. Move prototype...
848 * trans-array.h (gfc_walk_subexpr): ... here.
849 * trans-intrinsic.c (gfc_conv_intrinsic_function): Update transpose
851 (walk_inline_intrinsic_transpose, walk_inline_intrinsic_function,
852 gfc_inline_intrinsic_function_p): New.
853 (gfc_is_intrinsic_libcall): Return early in inline intrinsic case.
854 Remove transpose from the libcall list.
855 (gfc_walk_intrinsic_function): Special case inline intrinsic.
856 * trans.h (gfc_inline_intrinsic_function_p): New prototype.
858 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
860 * trans-expr.c (expr_is_variable): New function taking non-copying
861 intrinsic functions into account.
862 (gfc_trans_assignment_1): Use expr_is_variable.
864 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
866 * trans-array.c (gfc_conv_loop_setup): Access the shape along the
867 real array dimension instead of the scalarizer (loop) dimension.
869 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
871 * trans-array.c (gfc_conv_resolve_dependencies): Handle same-array
872 transposed references.
874 2010-09-10 Tobias Burnus <burnus@net-b.de>
877 * trans.h (build1_stat_loc, build2_stat_loc, build3_stat_loc,
878 build4_stat_loc): New inline functions.
879 (build1_loc, build2_loc, build3_loc, build4_loc): New macros.
880 (build1_v, build2_v, build3_v, build4_v): Use input_location
882 * trans-array.c (gfc_trans_scalarized_loop_end,
883 gfc_conv_array_parameter): Replace build[1-4] by build[1-4]_loc.
884 * trans.c (gfc_build_addr_expr, gfc_build_array_ref,
885 gfc_finish_wrapped_block): Ditto.
886 * trans-decl.c (gfc_init_default_dt, init_intent_out_dt): Ditto.
887 * trans-expr.c (gfc_conv_missing_dummy,
888 gfc_trans_alloc_subarray_assign, gfc_trans_zero_assign): Ditto.
889 * trans-openmp.c (gfc_omp_clause_default_ctor,
890 gfc_trans_omp_critical, gfc_trans_omp_parallel,
891 gfc_trans_omp_parallel_do, gfc_trans_omp_parallel_sections,
892 gfc_trans_omp_parallel_workshare, gfc_trans_omp_sections
893 gfc_trans_omp_single, gfc_trans_omp_task,
894 gfc_trans_omp_workshare): Ditto.
896 2010-09-09 Steven G. Kargl <kargl@gcc.gnu.org>
898 * fortran/expr.c (check_inquiry): OPTIONAL attribute is not allowed
899 for dummy argument that appears in a specification statement.
901 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
903 * trans-array.c (gfc_get_array_ref_dim): New function.
904 (gfc_trans_create_temp_array): Reconstruct array
905 bounds from loop bounds. Use array bounds instead of loop bounds.
907 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
909 * trans-array.c (gfc_set_loop_bounds_from_array_spec):
910 Get the array dimension from the dim array.
912 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
914 * trans-array.c (gfc_trans_preloop_setup): Unconditionally use the
915 dim array to get the stride in the innermost loop.
917 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
919 * trans-array.c (gfc_trans_create_temp_array): Don't set dim array.
920 (gfc_conv_loop_setup, gfc_walk_function_expr): Set dim array.
921 * trans-intrinsic.c (gfc_walk_intrinsic_libfunc): Ditto.
923 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
925 * trans-array.c (gfc_trans_create_temp_array): Assert loop dimension
926 and info dimension are the same. Loop over loop dimension.
927 * trans-stmt.c (gfc_conv_elemental_dependencies): Set loop dimension
929 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
931 * trans-array.c (gfc_conv_array_transpose): Change generated descriptor
934 2010-09-09 Tobias Burnus <burnus@net-b.de>
937 * intrincic.texi (FGET, FGETC, FPUT, FPUTC, FSTAT, GETCWD, KILL,
938 STAT): Show also syntax for the function version.
939 * intrinsic.c (add_sym_1s_intent, add_sym_2s_intent,
940 add_sym_3s_intent): Remove function.
941 (add_sym_1s, add_sym_2s, add_sym_3s): Take always the intent
943 (add_sym_2_intent): New function.
944 (add_functions): Set intent for functions which modify
945 the argument: fstat, fgetc, fget, hostnm, lstat, stat. Change
946 argument name of hostnm from "a" to "c"
947 (add_subroutines): Change add_sym_*s_intent to
948 add_sym_*s and add intent to the add_sym_*s calls.
950 2010-09-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
953 * intrinsic.c (add_functions): Add B{G,L}{E,T}, DSHIFT{L,R},
954 MASK{L,R}, MERGE_BITS and SHIFT{A,L,R}.
955 * gfortran.h: Define ISYM values for above intrinsics.
956 * intrinsic.h (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
957 gfc_check_mask, gfc_check_merge_bits, gfc_check_shift,
958 gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
959 gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
960 gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
961 gfc_simplify_merge_bits, gfc_simplify_rshift,
962 gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr,
963 gfc_resolve_dshift, gfc_resolve_mask, gfc_resolve_merge_bits,
964 gfc_resolve_shift): New prototypes.
965 * iresolve.c (gfc_resolve_dshift, gfc_resolve_mask,
966 gfc_resolve_merge_bits, gfc_resolve_shift): New functions.
967 * check.c (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
968 gfc_check_mask, gfc_check_merge_bits, gfc_check_shift): New
970 * trans-intrinsic.c (gfc_conv_intrinsic_dshift,
971 gfc_conv_intrinsic_bitcomp, gfc_conv_intrinsic_shift,
972 gfc_conv_intrinsic_merge_bits, gfc_conv_intrinsic_mask): New
974 (gfc_conv_intrinsic_function): Call above static functions.
975 * intrinsic.texi: Document new intrinsics.
976 * simplify.c (gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
977 gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
978 gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
979 gfc_simplify_merge_bits, gfc_simplify_rshift,
980 gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr):
983 2010-09-08 Jakub Jelinek <jakub@redhat.com>
985 * frontend-passes.c (optimize_code_node): Walk block chain by default.
988 * trans-openmp.c (gfc_trans_omp_do): Store exit/cycle labels on code
989 instead of code->block.
992 * openmp.c (resolve_omp_do): Report not enough do loops for
993 collapse even if block->next is NULL.
995 2010-09-07 Thomas Koenig <tkoenig@gcc.gnu.org>
998 * dependency.c (gfc_deb_compare_expr): Take missing optional
999 arguments into account.
1001 2010-09-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1003 * trans.h (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
1004 * trans-decl.c (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
1005 (gfc_build_intrinsic_function_decls): Don't build the
1006 gfor_fndecl_clz128 and gfor_fndecl_ctz128.
1007 * trans-intrinsic.c (gfc_conv_intrinsic_leadz,
1008 gfc_conv_intrinsic_trailz): Generate inline arithmetic instead
1009 of calling clz128/ctz128 library functions.
1011 2010-09-07 Jan Hubicka <jh@suse.cz>
1013 * trans-expr.c (gfc_conv_initializer): Set STATIC flags for
1016 2010-09-07 Tobias Burnus <burnus@net-b.de>
1019 * intrinsic.texi (COS): Remove superfluous "n".
1021 2010-09-07 Tobias Burnus <burnus@net-b.de>
1024 * trans-array.c (gfc_conv_descriptor_data_get,
1025 gfc_conv_descriptor_data_set, gfc_conv_descriptor_data_addr,
1026 gfc_conv_descriptor_offset, gfc_conv_descriptor_dtype,
1027 gfc_conv_descriptor_dimension, gfc_conv_descriptor_stride,
1028 gfc_conv_descriptor_lbound, gfc_conv_descriptor_ubound,
1029 gfc_conv_shift_descriptor_lbound,
1030 gfc_set_loop_bounds_from_array_spec,
1031 gfc_trans_allocate_array_storage, gfc_trans_create_temp_array,
1032 gfc_conv_array_transpose, gfc_get_iteration_count,
1033 gfc_grow_array, gfc_trans_array_ctor_element,
1034 gfc_trans_array_constructor_subarray,
1035 gfc_trans_array_constructor_value,
1036 constant_array_constructor_loop_size, gfc_trans_array_constructor,
1037 gfc_set_vector_loop_bounds, gfc_trans_array_bound_check,
1038 gfc_conv_array_index_offset, gfc_conv_scalarized_array_ref,
1039 gfc_conv_array_ref, gfc_trans_preloop_setup,
1040 gfc_trans_scalarized_loop_end, gfc_conv_ss_startstride,
1041 gfc_conv_loop_setup, gfc_conv_array_extent_dim,
1042 gfc_conv_descriptor_size, gfc_array_init_size,
1043 gfc_array_allocate, gfc_array_deallocate,
1044 gfc_trans_array_bounds, gfc_trans_auto_array_allocation,
1045 gfc_trans_dummy_array_bias, gfc_get_dataptr_offset,
1046 get_array_charlen, gfc_conv_expr_descriptor,
1047 array_parameter_size, gfc_conv_array_parameter,
1048 gfc_trans_dealloc_allocated, get_full_array_size,
1049 duplicate_allocatable,
1050 structure_alloc_comps): Change fold_build[0-9] to
1051 fold_build[0-9]_loc.
1052 (duplicate_allocatable, structure_alloc_comps,
1053 gfc_duplicate_allocatable): Add space after function name.
1055 2010-09-07 Mikael Morin <mikael@gcc.gnu.org>
1057 * trans-stmt.c (gfc_trans_character_select): Be conversion-safe while
1058 checking string length value.
1059 * trans-intrinsic.c (gfc_conv_intrinsic_char): Build integer using
1060 gfc_charlen_type_node type.
1063 * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Convert string
1064 length to gfc_charlen_type_node.
1066 2010-09-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1069 * frontend-passes.c (optimize_binop_array_assignment): New
1071 (optimize_assignment): Call it.
1073 2010-09-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1076 * trans-expr.c (gfc_conv_substring): If start and end
1077 of the string reference are equal, set the length to one.
1079 2010-09-06 Tobias Burnus <burnus@net-b.de>
1082 * dump-parse-tree.c (gfc_debug_expr): Use stderr instead of stdout.
1084 2010-09-06 Tobias Burnus <burnus@net-b.de>
1087 * dump-parse-tree.c (gfc_debug_expr): New function.
1089 2010-09-06 Tobias Burnus <burnus@net-b.de>
1092 * intrinsic.c (add_functions): Support IALL, IANY, IPARITY.
1093 (check_specific): Special case for those intrinsics.
1094 * gfortran.h (gfc_isym_id): Add new intrinsics
1095 * intrinsic.h (gfc_check_transf_bit_intrins,
1096 gfc_simplify_iall, gfc_simplify_iany, gfc_simplify_iparity,
1097 gfc_resolve_iall, gfc_resolve_iany, gfc_resolve_iparity):
1099 * iresolve.c (gfc_resolve_iall, gfc_resolve_iany,
1100 gfc_resolve_iparity, resolve_transformational): New functions.
1101 (gfc_resolve_product, gfc_resolve_sum,
1102 gfc_resolve_parity): Use resolve_transformational.
1103 * check.c (gfc_check_transf_bit_intrins): New function.
1104 * simplify.c (gfc_simplify_iall, gfc_simplify_iany,
1105 gfc_simplify_iparity, do_bit_any, do_bit_ior,
1106 do_bit_xor, simplify_transformation): New functions.
1107 (gfc_simplify_all, gfc_simplify_any, gfc_simplify_parity,
1108 gfc_simplify_sum, gfc_simplify_product): Use simplify_transformation.
1109 * trans-intrinsic.c (gfc_conv_intrinsic_arith,
1110 gfc_conv_intrinsic_function, gfc_is_intrinsic_libcall):
1111 Handle IALL, IANY and IPARITY intrinsics.
1112 * intrinsic.texi (IMAGE_INDEX): Move up to fix alphabetic
1114 (IALL, IANY, IPARITY): Document new intrinsics.
1116 2010-09-05 Tobias Burnus <burnus@net-b.de>
1119 * f95-lang.c (gfc_truthvalue_conversion): Use
1120 fold_build[0-9]_loc instead of fold_build[0-9].
1121 * convert.c (convert): Ditto.
1122 * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
1123 build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
1124 gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
1125 gfc_conv_intrinsic_conjg, gfc_trans_same_strlen_check,
1126 gfc_conv_intrinsic_bound, gfc_conv_intrinsic_abs,
1127 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
1128 gfc_conv_intrinsic_dim, gfc_conv_intrinsic_sign,
1129 gfc_conv_intrinsic_dprod, gfc_conv_intrinsic_char,
1130 gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
1131 gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
1132 gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_anyall,
1133 gfc_conv_intrinsic_count, gfc_conv_intrinsic_arith,
1134 gfc_conv_intrinsic_dot_product, gfc_conv_intrinsic_minmaxloc,
1135 gfc_conv_intrinsic_minmaxval, gfc_conv_intrinsic_btest,
1136 gfc_conv_intrinsic_bitop, gfc_conv_intrinsic_not,
1137 gfc_conv_intrinsic_singlebitop, gfc_conv_intrinsic_ibits,
1138 gfc_conv_intrinsic_rlshift, gfc_conv_intrinsic_ishft,
1139 gfc_conv_intrinsic_ishftc, gfc_conv_intrinsic_leadz,
1140 gfc_conv_intrinsic_trailz, gfc_conv_intrinsic_popcnt_poppar,
1141 gfc_conv_intrinsic_ichar, gfc_conv_has_intvalue,
1142 gfc_conv_intrinsic_merge, gfc_conv_intrinsic_spacing,
1143 gfc_conv_intrinsic_rrspacing, gfc_conv_intrinsic_size,
1144 size_of_string_in_bytes, gfc_conv_intrinsic_sizeof,
1145 gfc_conv_intrinsic_storage_size, gfc_conv_intrinsic_strcmp,
1146 gfc_conv_intrinsic_transfer, gfc_conv_allocated,
1147 gfc_conv_associated, gfc_conv_same_type_as,
1148 gfc_conv_intrinsic_trim, gfc_conv_intrinsic_repeat): Ditto.
1150 2010-09-04 Tobias Burnus <burnus@net-b.de>
1153 * resolve.c (resolve_fl_namelist): Change constraint checking
1154 order to prevent endless loop.
1156 2010-09-04 Janus Weil <janus@gcc.gnu.org>
1159 * resolve.c (resolve_allocate_expr): Generate default initializers
1160 already at this point, resolve them and put them into expr3, ...
1161 * trans-stmt.c (gfc_trans_allocate): ... instead of waiting until
1164 2010-09-03 Tobias Burnus <burnus@net-b.de>
1167 * trans-intrinsic.c (gfc_conv_intrinsic_sign,
1168 gfc_conv_intrinsic_leadz): Use build_call_expr_loc instead
1170 * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
1171 gfc_conv_string_length, gfc_conv_substring,
1172 gfc_conv_component_ref, gfc_conv_unary_op, gfc_conv_powi,
1173 gfc_conv_cst_int_power, gfc_conv_string_tmp, gfc_conv_concat_op,
1174 gfc_conv_expr_op, gfc_build_compare_string,
1175 gfc_set_interface_mapping_bounds, gfc_conv_subref_array_arg,
1176 gfc_conv_derived_to_class, conv_isocbinding_procedure,
1177 gfc_conv_procedure_call, fill_with_spaces,
1178 gfc_trans_string_copy, gfc_trans_alloc_subarray_assign,
1179 gfc_trans_structure_assign, gfc_trans_pointer_assignment,
1180 gfc_trans_scalar_assign, gfc_trans_zero_assign,
1181 gfc_trans_array_copy, gfc_trans_array_constructor_copy): Change
1182 fold_build[0-9] to fold_build[0-9]_loc.
1183 * trans-io.c (set_parameter_const, set_parameter_value,
1184 set_parameter_ref, gfc_convert_array_to_string, set_string,
1185 set_internal_unit, io_result, set_error_locus,
1186 nml_get_addr_expr, build_dt): Ditto.
1187 * trans-openmp.c (gfc_omp_clause_default_ctor,
1188 gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
1189 gfc_trans_omp_array_reduction, gfc_trans_omp_atomic,
1190 gfc_trans_omp_do): Ditto.
1191 * trans.c (gfc_add_modify, gfc_build_addr_expr,
1192 gfc_build_array_ref, gfc_trans_runtime_error_vararg,
1193 gfc_trans_runtime_check, gfc_call_malloc,
1194 gfc_allocate_with_status, gfc_allocate_array_with_status,
1195 gfc_call_free, gfc_deallocate_with_status,
1196 gfc_call_realloc): Ditto.
1198 2010-09-03 Thomas Koenig <tkoenig@gcc.gnu.org>
1201 * dependency.c (gfc_deb_compare_expr): Compare equal for equal
1202 arglists for pure user functions, or for those intrinsic
1203 functions which are also pure.
1204 * intrinsics.c (add_conv): Mark conversion functions as pure.
1205 (add_char_conversions): Likewise.
1207 2010-09-03 Daniel Kraft <d@domob.eu>
1210 * resolve.c (resolve_actual_arglist): Allow internal procedure
1211 as actual argument with Fortran 2008.
1213 2010-09-03 Daniel Kraft <d@domob.eu>
1216 * gfortran.h (struct gfc_code): Renamed `whichloop' to
1217 `which_construct' as this is no longer restricted to loops.
1218 * parse.h (struct gfc_state_data): New field `construct'.
1219 * match.c (match_exit_cycle): Handle EXIT from non-loops.
1220 * parse.c (push_state): Set `construct' field.
1221 * resolve.c (resolve_select_type): Extend comment.
1222 * trans-stmt.c (gfc_trans_if): Add exit label.
1223 (gfc_trans_block_construct), (gfc_trans_select): Ditto.
1224 (gfc_trans_simple_do): Store exit/cycle labels on the gfc_code itself.
1225 (gfc_trans_do), (gfc_trans_do_while): Ditto.
1226 (gfc_trans_exit): Use new name `which_construct' instead of `whichloop'.
1227 (gfc_trans_cycle): Ditto.
1228 (gfc_trans_if_1): Use fold_build3_loc instead of fold_build3.
1230 2010-09-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1232 * trans-intrinsic.c (gfc_conv_intrinsic_aint): Fix whitespace.
1233 (gfc_conv_intrinsic_ishft): Only evaluate arguments once.
1234 (gfc_conv_intrinsic_ishftc): Only evaluate arguments once.
1235 * intrinsic.texi (RSHIFT): Fix documentation.
1237 2010-09-02 Tobias Burnus <burnus@net-b.de>
1240 * trans-common.c (create_common): Change build[0-9] to
1242 * trans-const.c (gfc_conv_constant_to_tree,
1243 gfc_conv_constant_to_tree): Ditto.
1244 * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
1245 gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
1246 add_argument_checking, create_main_function,
1247 gfc_generate_return): Ditto.
1248 * trans-types.c (gfc_get_dtype, gfc_get_array_type_bounds): Ditto.
1249 * trans-stmt.c (allocate_temp_for_forall_nest_1,
1250 compute_inner_temp_size, compute_overall_iter_number,
1251 generate_loop_for_rhs_to_temp, generate_loop_for_temp_to_lhs,
1252 gfc_conv_elemental_dependencies, gfc_do_allocate,
1253 gfc_evaluate_where_mask, gfc_trans_allocate,
1254 gfc_trans_arithmetic_if, gfc_trans_call,
1255 gfc_trans_character_select, gfc_trans_deallocate,
1256 gfc_trans_do, gfc_trans_do_while, gfc_trans_forall_1,
1257 gfc_trans_forall_loop, gfc_trans_goto, gfc_trans_if_1,
1258 gfc_trans_integer_select, gfc_trans_logical_select,
1259 gfc_trans_pointer_assign_need_temp, gfc_trans_return,
1260 gfc_trans_simple_do, gfc_trans_sync, gfc_trans_where_2,
1261 gfc_trans_where_assign) Ditto.
1263 2010-09-02 Janus Weil <janus@gcc.gnu.org>
1266 * resolve.c (resolve_symbol): Correct check for attributes of CLASS
1269 2010-09-02 Tobias Burnus <burnus@net-b.de>
1272 * resolve.c (apply_default_init): Mark symbol as referenced,
1273 if it is initialized.
1274 (resolve_symbol): Change intialized check for BT_DERIVED such
1275 that also function results get initialized; remove now obsolete
1276 gfc_set_sym_referenced for BT_CLASS.
1278 2010-09-01 Janus Weil <janus@gcc.gnu.org>
1281 * class.c (gfc_find_derived_vtab): Add component '$def_init'.
1282 * resolve.c (resolve_allocate_expr): Defer handling of default
1283 initialization to 'gfc_trans_allocate'.
1284 (apply_default_init,resolve_symbol): Handle polymorphic dummies.
1285 (resolve_fl_derived): Suppress error messages for vtypes.
1286 * trans-stmt.c (gfc_trans_allocate): Handle initialization via
1287 polymorphic MOLD expression.
1288 * trans-expr.c (gfc_trans_class_init_assign): Now only used for
1289 dummy initialization.
1291 2010-09-01 Tobias Burnus <burnus@net-b.de>
1293 * gfortran.texi (preprocessing): Update URL to COCO.
1295 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1297 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Resize
1298 array quad_decls. Remove unnecessary assignment.
1300 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1302 * trans-expr.c (gfc_conv_power_op): Handle floating-point types
1303 other than long double.
1304 * mathbuiltins.def: Add builtins from the POW and CPOW family.
1305 * trans.h (gfc_builtin_decl_for_float_kind): New prototype.
1306 * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Add gfc_
1307 prefix to function name.
1308 (gfc_build_intrinsic_lib_fndecls): Add cpow prototype.
1309 (gfc_conv_intrinsic_aint): Use gfc_builtin_decl_for_float_kind
1311 (gfc_conv_intrinsic_exponent): Likewise.
1312 (gfc_conv_intrinsic_abs): Likewise.
1313 (gfc_conv_intrinsic_mod): Likewise.
1314 (gfc_conv_intrinsic_sign): Likewise.
1315 (gfc_conv_intrinsic_arith): Likewise.
1316 (gfc_conv_intrinsic_fraction): Likewise.
1317 (gfc_conv_intrinsic_nearest): Likewise.
1318 (gfc_conv_intrinsic_spacing): Likewise.
1319 (gfc_conv_intrinsic_rrspacing): Likewise.
1320 (gfc_conv_intrinsic_scale): Likewise.
1321 (gfc_conv_intrinsic_set_exponent): Likewise.
1323 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1325 * intrinsic.c: Add EXECUTE_COMMAND_LINE intrinsic.
1326 * intrinsic.h (gfc_resolve_execute_command_line): New function.
1327 * iresolve.c (gfc_resolve_execute_command_line): New function.
1328 * gfortran.h (GFC_ISYM_EXECUTE_COMMAND_LINE): New value.
1329 * intrinsic.texi: Document EXECUTE_COMMAND_LINE.
1331 2010-08-31 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1334 * f95-lang.c (gfc_init_builtin_functions): Define popcount{,l,ll}
1335 and parity{,l,ll} builtins.
1336 * trans-intrinsic.c (gfc_conv_intrinsic_popcnt_poppar): New function.
1337 (gfc_conv_intrinsic_function): Call above new functions.
1338 * simplify.c (gfc_simplify_popcnt, gfc_simplify_poppar): New
1340 * intrinsic.texi: Document POPCNT and POPPAR.
1342 2010-08-30 Janus Weil <janus@gcc.gnu.org>
1345 * resolve.c (resolve_structure_cons): Handle pointer-valued PPCs.
1347 2010-08-30 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1349 * Make-lang.in: Add frontend-passes.o dependencies.
1351 2010-08-29 Janus Weil <janus@gcc.gnu.org>
1354 * resolve.c (resolve_structure_cons): For derived types, make sure the
1355 type has been resolved.
1356 (resolve_typebound_procedures): Make sure the vtab has been generated.
1358 2010-08-29 Janus Weil <janus@gcc.gnu.org>
1361 * match.c (gfc_match_select_type): Give the associate-name the
1362 FL_VARIABLE attribute.
1364 2010-08-28 Steven G. Kargl <kargl@gcc.gnu.org>
1366 * simplify.c (gfc_simplify_bessel_n2): Fix indention
1369 2010-08-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1372 * trans-types.c (gfc_init_kinds): Disable TFmode.
1374 2010-08-27 Janus Weil <janus@gcc.gnu.org>
1377 * match.c (gfc_match_allocate): Avoid double free on error.
1379 2010-08-27 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1382 * gfortran.h (gfc_real_info): Add c_float128 field.
1383 * mathbuiltins.def: Indicate which builtins are const.
1384 * trans-types.h (float128_type_node, complex_float128_type_node,
1385 gfc_real16_is_float128): New variables.
1386 * trans-types.c (float128_type_node, complex_float128_type_node,
1387 gfc_real16_is_float128): New variables.
1388 (gfc_init_kinds): Allow TFmode.
1389 (gfc_build_real_type): Mark __float128 types as such.
1390 (gfc_init_types): Initialize float128_type_node and
1391 complex_float128_type_node
1392 * f95-lang.c (gfc_init_builtin_functions): Adjust for new
1393 argument of OTHER_BUILTIN macro.
1394 * trans-intrinsic.c (gfc_intrinsic_map_t): Likewise.
1395 (builtin_decl_for_precision): Special case for __float128.
1396 (builtin_decl_for_float_kind): Likewise.
1397 (define_quad_builtin): New function.
1398 (gfc_build_intrinsic_lib_fndecls): Create all __float128
1399 library decls if necessary. Store them in the real16_decl and
1400 complex16_decl builtin map fields.
1401 (gfc_get_intrinsic_lib_fndecl): Handle q-suffixed __float128
1402 library function names.
1404 2010-08-27 Tobias Burnus <burnus@net-b.de>
1407 * gcc/fortran/intrinsic.c (add_functions): Add norm2 and parity.
1408 * gcc/fortran/intrinsic.h (gfc_check_norm2, gfc_check_parity):
1409 gfc_simplify_norm2, gfc_simplify_parity, gfc_resolve_norm2,
1410 gfc_resolve_parity): New prototypes.
1411 * gcc/fortran/gfortran.h (gfc_isym_id): New enum items
1412 GFC_ISYM_NORM2 and GFC_ISYM_PARITY.
1413 * gcc/fortran/iresolve.c (gfc_resolve_norm2,
1414 gfc_resolve_parity): New functions.
1415 * gcc/fortran/check.c (gfc_check_norm2, gfc_check_parity):
1417 * gcc/fortran/trans-intrinsic.c (gfc_conv_intrinsic_arith,
1418 gfc_conv_intrinsic_function): Handle NORM2 and PARITY.
1419 * gcc/fortran/intrinsic.texi (NORM2, PARITY): Add.
1420 * gcc/fortran/simplify.c (simplify_transformation_to_array):
1421 Add post-processing opterator.
1422 (gfc_simplify_all, gfc_simplify_any, gfc_simplify_count,
1423 gfc_simplify_product, gfc_simplify_sum): Update call.
1424 (add_squared, do_sqrt, gfc_simplify_norm2, do_xor,
1425 gfc_simplify_parity): New functions.
1427 2010-08-27 Janus Weil <janus@gcc.gnu.org>
1430 * match.c (select_type_set_tmp): Add the possibility to reset the
1432 (gfc_match_class_is): Reset the temporary in CLASS DEFAULT clauses.
1434 2010-08-27 Thomas Koenig <tkoenig@gcc.gnu.org>
1437 * dependency.c (check_section_vs_section): Single test for
1438 identical strides which takes into account that only one
1439 of the strides may be NULL.
1441 2010-08-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1444 * primary.c (match_hollerith_constant): Calculate padding needed to
1445 fill default integer and allocate string for that size. Set pad bytes
1447 * gfortran.h: Add hollerith pad value to type spec union.
1448 * data.c (create_character_initializer): Fix spelling of function name.
1449 Use hollerith pad value to calculate length.
1450 * arith.c (hollerith2representation); Use hollerith pad value to
1453 2010-08-26 Daniel Kraft <d@domob.eu>
1458 * gfortran.h (struct gfc_association_list): New flag `dangling'.
1459 (gfc_build_block_ns): Declared here...
1460 * parse.h (gfc_build_block_ns): ...instead of here.
1461 * trans.h (gfc_process_block_locals): Expect additionally the
1462 gfc_association_list of BLOCK (if present).
1463 * match.c (select_type_set_tmp): Create sym->assoc for temporary.
1464 * resolve.c (resolve_variable): Only check for invalid *array*
1465 references on associate-names.
1466 (resolve_assoc_var): New method with code previously in resolve_symbol.
1467 (resolve_select_type): Use association to give the selector and
1468 temporaries their values instead of ordinary assignment.
1469 (resolve_fl_var_and_proc): Allow CLASS associate-names.
1470 (resolve_symbol): Use new `resolve_assoc_var' instead of inlining here.
1471 * trans-stmt.c (gfc_trans_block_construct): Pass association-list
1472 to `gfc_process_block_locals' to match new interface.
1473 * trans-decl.c (gfc_get_symbol_decl): Don't defer associate-names
1475 (gfc_process_block_locals): Defer them rather here when linked to
1476 from the BLOCK's association list.
1478 2010-08-25 Jakub Jelinek <jakub@redhat.com>
1480 * trans-decl.c (gfc_build_intrinsic_function_decls): Set
1481 TREE_NOTHROW on fndecls that can't throw. Set
1482 TREE_READONLY on gfor_fndecl_math_ishftc{4,8,16}.
1483 (gfc_build_builtin_function_decls): Set TREE_NOTHROW on
1484 gfor_fndecl_associated.
1486 2010-08-23 Mikael Morin <mikael@gcc.gnu.org>
1489 * frontend-passes.c (optimize_equality): Don't optimize array equality
1491 2010-08-23 Janus Weil <janus@gcc.gnu.org>
1494 * resolve.c (resolve_procedure_interface): New function split off from
1496 (resolve_formal_arglist): Call it here ...
1497 (resolve_symbol): ... and here.
1499 2010-08-22 Joseph Myers <joseph@codesourcery.com>
1501 * Make-lang.in (gfortranspec.o): Update dependencies.
1502 * gfortranspec.c: Include coretypes.h before gcc.h. Include
1504 (MATH_LIBRARY, FORTRAN_LIBRARY): Remove initial "-l".
1505 (ADD_ARG_LIBGFORTRAN, Option, lookup_option): Remove.
1506 (g77_xargc): Make unsigned.
1507 (g77_xargv): Change to g77_x_decoded_options.
1508 (g77_newargc): Make unsigned.
1509 (g77_newargv): Change to g77_new_decoded_options.
1510 (strings_same, options_same): New.
1511 (append_arg): Use cl_decoded_option structures.
1512 (append_option): New.
1513 (add_arg_libgfortran): New.
1514 (lang_specific_driver): Use cl_decoded_option structures.
1516 2010-08-21 Janus Weil <janus@gcc.gnu.org>
1520 * class.c (add_proc_comp): Add static initializer for PPCs.
1521 (add_procs_to_declared_vtab): Modified comment.
1522 * module.c (mio_component): Add argument 'vtype'. Don't read/write the
1523 initializer if the component is part of a vtype.
1524 (mio_component_list): Add argument 'vtype', pass it on to
1526 (mio_symbol): Modified call to 'mio_component_list'.
1527 * trans.h (gfc_conv_initializer): Modified prototype.
1528 (gfc_trans_assign_vtab_procs): Removed.
1529 * trans-common.c (create_common): Modified call to
1530 'gfc_conv_initializer'.
1531 * trans-decl.c (gfc_get_symbol_decl,get_proc_pointer_decl,
1532 gfc_emit_parameter_debug_info): Modified call to
1533 'gfc_conv_initializer'.
1534 (build_function_decl): Remove assertion.
1535 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
1536 Removed call to 'gfc_trans_assign_vtab_procs'.
1537 (gfc_conv_initializer): Add argument 'procptr'.
1538 (gfc_conv_structure): Modified call to 'gfc_conv_initializer'.
1539 (gfc_trans_assign_vtab_procs): Removed.
1540 * trans-stmt.c (gfc_trans_allocate): Removed call to
1541 'gfc_trans_assign_vtab_procs'.
1543 2010-08-21 Tobias Burnus <burnus@net-b.de>
1547 * intrinsic.c (add_sym): Init value attribute.
1548 (set_attr_value): New function.
1549 (add_functions) Use it and add JN/YN resolvers.
1550 * symbol.c (gfc_copy_formal_args_intr): Copy value attr.
1551 * intrinsic.h (gfc_resolve_bessel_n2): New prototype.
1552 * gfortran.h (gfc_intrinsic_arg): Add value attribute.
1553 * iresolve.c (gfc_resolve_bessel_n2): New function.
1554 * trans-intrinsic.c (gfc_get_symbol_for_expr): Create
1556 (gfc_conv_intrinsic_function,gfc_is_intrinsic_libcall):
1557 Add GFC_ISYM_JN2/GFC_ISYM_YN2 as case value.
1558 * simplify.c (): For YN set to -INF if previous values
1560 * trans-expr.c (gfc_conv_procedure_call): Don't crash
1562 * iresolve.c (gfc_resolve_extends_type_of): Set the
1563 type of the dummy argument to the one of the actual.
1565 2010-08-20 Joseph Myers <joseph@codesourcery.com>
1567 * lang.opt (MD, MMD): Use NoDriverArg instead of NoArgDriver.
1569 2010-08-20 Joseph Myers <joseph@codesourcery.com>
1571 * gfortranspec.c (lang_specific_driver): Refer to -lgfortran in
1574 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
1576 * trans-openmp.c: Use FOR_EACH_VEC_ELT.
1578 2010-08-19 Daniel Kraft <d@domob.eu>
1582 * trans.h (struct gfc_se): New flag `byref_noassign'.
1583 * trans-array.h (gfc_conv_shift_descriptor_lbound): New method.
1584 (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
1585 * expr.c (gfc_check_pointer_assign): Allow bounds and rank remapping
1586 and check for compile-time errors with those.
1587 * trans-decl.c (trans_associate_var): Use new routine
1588 `gfc_conv_shift_descriptor_lbound' instead of doing it manually.
1589 * trans-array.c (gfc_conv_shift_descriptor_lbound): New method.
1590 (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
1591 (gfc_array_init_size): Use new `gfc_conv_array_extent_dim'.
1592 (gfc_conv_expr_descriptor): Handle new flag `byref_noassign'.
1593 * trans-expr.c (gfc_trans_pointer_assignment): Handle bounds and
1594 rank remapping for assignment.
1596 2010-08-19 Tobias Burnus <burnus@net-b.de>
1598 * intrinsic.texi (Bessel_jn, Bessel_yn): Fix typo.
1599 * * simplify.c (gfc_simplify_bessel_yn): Change recursive
1602 2010-08-19 Tobias Burnus <burnus@net-b.de>
1606 * check.c (gfc_check_bessel_n2): New function.
1607 * gfortran.h (gfc_isym_id): Add GFC_ISYM_JN2 and GFC_ISYM_YN2.
1608 * intrinsic.c (add_functions): Add transformational version
1609 of the Bessel_jn/yn intrinsics.
1610 * intrinsic.h (gfc_check_bessel_n2,gfc_simplify_bessel_jn2,
1611 gfc_simplify_bessel_yn2): New prototypes.
1612 * intrinsic.texi (Bessel_jn, Bessel_yn): Document
1613 transformational variant.
1614 * simplify.c (gfc_simplify_bessel_jn, gfc_simplify_bessel_yn):
1615 Check for negative order.
1616 (gfc_simplify_bessel_n2,gfc_simplify_bessel_jn2,
1617 gfc_simplify_bessel_yn2): New functions.
1619 2010-08-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1622 * resolve.c (resolve_transfer): Traverse operands and set expression
1623 to be checked to a non EXPR_OP type.
1625 2010-08-19 Janus Weil <janus@gcc.gnu.org>
1628 * gfortran.h (gfc_add_save): Modified prototype.
1629 * decl.c (add_init_expr_to_sym): Defer checking of proc pointer init.
1630 (match_pointer_init): New function to match F08 pointer initialization.
1631 (variable_decl,match_procedure_decl,match_ppc_decl): Use
1632 'match_pointer_init'.
1633 (match_attr_spec): Module variables are implicitly SAVE.
1634 (gfc_match_save): Modified call to 'gfc_add_save'.
1635 * expr.c (gfc_check_assign_symbol): Extra checks for pointer
1637 * primary.c (gfc_variable_attr): Handle SAVE attribute.
1638 * resolve.c (resolve_structure_cons): Add new argument and do pointer
1639 initialization checks.
1640 (gfc_resolve_expr): Modified call to 'resolve_structure_cons'.
1641 (resolve_values): Call 'resolve_structure_cons' directly with init arg.
1642 (resolve_fl_variable): Handle SAVE_IMPLICIT.
1643 * symbol.c (gfc_add_save,gfc_copy_attr,save_symbol): Handle
1645 * trans-decl.c (gfc_create_module_variable): Module variables with
1646 TARGET can already exist.
1647 * trans-expr.c (gfc_conv_variable): Check for 'current_function_decl'.
1648 (gfc_conv_initializer): Implement non-NULL pointer
1651 2010-08-18 Tobias Burnus <burnus@net-b.de>
1654 * intrinsic.texi (selected_char_kind): Document ISO_10646
1657 2010-08-17 Jakub Jelinek <jakub@redhat.com>
1660 * trans-decl.c (build_library_function_decl_1): Chain on
1661 void_list_node instead of creating a new TREE_LIST.
1662 * trans-intrinsic.c (gfc_get_intrinsic_lib_fndecl): Likewise.
1663 * trans-types.c (gfc_get_function_type): Likewise. Set
1664 typelist to void_list_node for the main program.
1666 2010-08-17 Daniel Kraft <d@domob.eu>
1669 * gfortran.h (struct gfc_association_list): New member `where'.
1670 (gfc_is_associate_pointer) New method.
1671 * match.c (gfc_match_associate): Remember locus for each associate
1672 name matched and do not try to set variable flag.
1673 * parse.c (parse_associate): Use remembered locus for symbols.
1674 * primary.c (match_variable): Instead of variable-flag check for
1675 associate names set it for all such names used.
1676 * symbol.c (gfc_is_associate_pointer): New method.
1677 * resolve.c (resolve_block_construct): Don't generate assignments
1678 to give associate-names their values.
1679 (resolve_fl_var_and_proc): Allow associate-names to be deferred-shape.
1680 (resolve_symbol): Set some more attributes for associate variables,
1681 set variable flag here and check it and don't try to build an
1682 explicitely shaped array-spec for array associate variables.
1683 * trans-expr.c (gfc_conv_variable): Dereference in case of association
1685 * trans-types.c (gfc_is_nodesc_array): Handle array association symbols.
1686 (gfc_sym_type): Return pointer type for association to scalar vars.
1687 * trans-decl.c (gfc_get_symbol_decl): Defer association symbols.
1688 (trans_associate_var): New method.
1689 (gfc_trans_deferred_vars): Handle association symbols.
1691 2010-08-16 Joseph Myers <joseph@codesourcery.com>
1693 * lang.opt (MDX): Change back to MD. Mark NoDriverArg instead of
1695 (MMDX): Change back to MMD. Mark NoDriverArg instead of
1697 * cpp.c (gfc_cpp_handle_option): Use OPT_MD and OPT_MMD instead of
1698 OPT_MDX and OPT_MMDX.
1700 2010-08-16 Joseph Myers <joseph@codesourcery.com>
1702 * lang.opt (MDX, MMDX): Mark RejectDriver.
1704 2010-08-15 Janus Weil <janus@gcc.gnu.org>
1706 * trans-expr.c (gfc_trans_assign_vtab_procs): Clean up (we don't have
1707 vtabs for generics any more).
1709 2010-08-15 Daniel Kraft <d@domob.eu>
1712 * gfortran.h (gfc_find_proc_namespace): New method.
1713 * expr.c (gfc_build_intrinsic_call): No need to build symtree messing
1714 around with namespace.
1715 * symbol.c (gfc_find_proc_namespace): New method.
1716 * trans-decl.c (gfc_build_qualified_array): Use it for correct
1718 * primary.c (gfc_match_varspec): Handle associate-names as arrays.
1719 * parse.c (parse_associate): Removed assignment-generation here...
1720 * resolve.c (resolve_block_construct): ...and added it here.
1721 (resolve_variable): Handle names that are arrays but were not parsed
1722 as such because of association.
1723 (resolve_code): Fix BLOCK resolution.
1724 (resolve_symbol): Generate array-spec for associate-names.
1726 2010-08-15 Tobias Burnus <burnus@net-b.de>
1729 * decl.c (verify_c_interop_param): Remove superfluous space (" ").
1730 (verify_c_interop): Handle unresolved DT with bind(C).
1732 2010-08-15 Tobias Burnus <burnus@net-b.de>
1734 * trans-expr.c (gfc_conv_expr_present): Regard nullified
1735 pointer arrays as absent.
1736 (gfc_conv_procedure_call): Handle EXPR_NULL for non-pointer
1737 dummys as absent argument.
1738 * interface.c (compare_actual_formal,compare_parameter):
1741 2010-08-15 Tobias Burnus <burnus@net-b.de>
1743 * interface.c (compare_pointer, ): Allow passing TARGETs to pointers
1744 dummies with intent(in).
1746 2010-08-15 Daniel Kraft <d@domob.eu>
1749 * decl.c (gfc_match_prefix): Match IMPURE prefix and mark ELEMENTAL
1750 routines not IMPURE also as PURE.
1751 * intrinsic.c (enum klass): New class `CLASS_PURE' and renamed
1752 `NO_CLASS' in `CLASS_IMPURE'.
1753 (add_sym): Set symbol-attributes `pure' and `elemental' correctly.
1754 (add_sym_0s): Renamed `NO_CLASS' in `CLASS_IMPURE'.
1755 (add_functions): Ditto.
1756 (add_subroutines): Ditto and mark `MOVE_ALLOC' as CLASS_PURE.
1757 * resolve.c (gfc_pure): Do not treat ELEMENTAL as automatically PURE.
1758 (resolve_formal_arglist): Check that arguments to ELEMENTAL procedures
1759 are not ALLOCATABLE and have their INTENT specified.
1761 2010-08-13 Daniel Kraft <d@domob.eu>
1763 * gfortran.h (array_type): New type `AS_IMPLIED_SHAPE'.
1764 * array.c (gfc_match_array_spec): Match implied-shape specification and
1765 handle AS_IMPLIED_SHAPE correctly otherwise.
1766 * decl.c (add_init_expr_to_sym): Set upper bounds for implied-shape.
1767 (variable_decl): Some checks for implied-shape declaration.
1768 * resolve.c (resolve_symbol): Assert that array-spec is no longer
1769 AS_IMPLIED_SHAPE in any case.
1771 2010-08-12 Joseph Myers <joseph@codesourcery.com>
1773 * lang.opt (MD, MMD): Change to MDX and MMDX.
1774 * cpp.c (gfc_cpp_handle_option): Use OPT_MMD and OPT_MMDX.
1776 2010-08-11 Janus Weil <janus@gcc.gnu.org>
1779 * intrinsic.c (gfc_current_intrinsic_arg): Change type from 'char' to
1780 'gfc_intrinsic_arg'.
1781 (check_arglist,check_specific): Add reference to 'name' field.
1782 (init_arglist): Remove reference to 'name' field.
1783 * intrinsic.h (gfc_current_intrinsic_arg): Modify prototype.
1784 * check.c (variable_check): Reverse order of checks. Respect intent of
1786 (int_or_proc_check): New function.
1787 (coarray_check): New function.
1788 (allocatable_check): New function.
1789 (gfc_check_allocated,gfc_check_move_alloc): Use 'allocatable_check'.
1790 (gfc_check_complex): Use 'int_or_real_check'.
1791 (gfc_check_lcobound,gfc_check_image_index,gfc_check_this_image,
1792 gfc_check_ucobound): Use 'coarray_check'.
1793 (gfc_check_pack): Use 'real_or_complex_check'.
1794 (gfc_check_alarm_sub,gfc_check_signal,gfc_check_signal_sub): Use
1795 'int_or_proc_check'.
1796 (scalar_check,type_check,numeric_check,int_or_real_check,
1797 real_or_complex_check,kind_check,double_check,logical_array_check,
1798 array_check,same_type_check,rank_check,nonoptional_check,
1799 kind_value_check,gfc_check_a_p,gfc_check_associated,gfc_check_cmplx,
1800 gfc_check_cshift,gfc_check_dcmplx,gfc_check_dot_product,gfc_check_dprod,
1801 gfc_check_eoshift,gfc_check_fn_rc2008,gfc_check_index,gfc_check_kind,
1802 gfc_check_matmul,gfc_check_minloc_maxloc,check_reduction,gfc_check_null,
1803 gfc_check_present,gfc_check_reshape,gfc_check_same_type_as,
1804 gfc_check_spread,gfc_check_unpack,gfc_check_random_seed,
1805 gfc_check_getarg,gfc_check_and,gfc_check_storage_size): Add reference
1808 2010-08-10 Daniel Kraft <d@domob.eu>
1810 * gfortran.texi (Interoperability with C): Fix ordering in menu
1811 and add new subsection about pointers.
1812 (Interoperable Subroutines and Functions): Split off the pointer part.
1813 (working with Pointers): New subsection with extended discussion
1814 of pointers (especially procedure pointers).
1816 2010-08-09 Thomas Koenig <tkoenig@gcc.gnu.org>
1819 * array.c (gfc_ref_dimen_size): Add end argument.
1820 If end is non-NULL, calculate it.
1821 (ref_size): Adjust call to gfc_ref_dimen_size.
1822 (gfc_array_dimen_size): Likewise.
1823 (gfc_array_res_shape): Likewise.
1824 * gfortran.h: Adjust prototype for gfc_ref_dimen_size.
1825 * resolve.c (resolve_array_ref): For stride not equal to -1,
1826 fill in the lowest possible end.
1828 2010-08-09 Janus Weil <janus@gcc.gnu.org>
1830 * intrinsic.texi: Correct documentation of ASINH, ACOSH and ATANH.
1832 2010-08-07 Nathan Froyd <froydnj@codesourcery.com>
1834 * interface.c (compare_actual_formal): Use XALLOCAVEC instead of
1836 (check_some_aliasing): Likewise.
1837 * trans-intrinsic.c (gfc_conv_intrinsic_conversion): Likewise.
1838 (gfc_conv_intrinsic_int): Likewise.
1839 (gfc_conv_intrinsic_lib_function): Likewise.
1840 (gfc_conv_intrinsic_cmplx): Likewise.
1841 (gfc_conv_intrinsic_ctime): Likewise.
1842 (gfc_conv_intrinsic_fdate): Likewise.
1843 (gfc_conv_intrinsic_ttynam): Likewise.
1844 (gfc_conv_intrinsic_minmax): Likewise.
1845 (gfc_conv_intrinsic_minmax_char): Likewise.
1846 (gfc_conv_intrinsic_ishftc): Likewise.
1847 (gfc_conv_intrinsic_index_scan_verify): Likewise.
1848 (gfc_conv_intrinsic_merge): Likewise.
1849 (gfc_conv_intrinsic_trim): Likewise.
1850 * trans.c (gfc_trans_runtime_error_vararg): Likewise.
1852 2010-08-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1855 * dependency.c (check_section_vs_section): Handle cases where
1856 the start expression coincides with the lower or upper
1859 2010-08-04 Janus Weil <janus@gcc.gnu.org>
1864 * class.c (gfc_find_derived_vtab): Do not generate vtabs for class
1865 container types. Do not artificially increase refs. Commit symbols one
1867 * interface.c (compare_parameter): Make sure vtabs are present before
1868 generating module variables.
1869 * resolve.c (resolve_allocate_expr): Ditto.
1871 2010-08-04 Tobias Burnus <burnus@net-b.de>
1875 * resolve.c (resolve_structure_cons): Fix
1878 2010-08-04 Mikael Morin <mikael@gcc.gnu.org>
1882 * symbol.c (changed_syms): Made static again.
1883 (gfc_symbol_state): Don't conditionalize on GFC_DEBUG.
1884 Changed conditional internal error into assert.
1885 Rename function to ...
1886 (gfc_enforce_clean_symbol_state): ... this.
1887 * gfortran.h (gfc_symbol_state, gfc_enforce_clean_symbol_state):
1888 Rename the former to the latter.
1889 * parse.c (decode_statement, decode_omp_directive,
1890 decode_gcc_attribute): Update callers accordingly. Don't conditionalize
1892 (changed_syms): Remove declaration.
1893 (next_statement): Use gfc_enforce_clean_symbol_state.
1895 2010-08-04 Tobias Burnus <burnus@net-b.de>
1898 * resolve.c (resolve_structure_cons): Fix handling of
1899 initialization structure constructors with character
1900 elements of the wrong length.
1901 * array.c (gfc_check_iter_variable): Add NULL check.
1902 (gfc_resolve_character_array_constructor): Also truncate
1905 2010-08-04 Tobias Burnus <burnus@net-b.de>
1907 * trans-io.c (gfc_build_io_library_fndecls): Fix return
1908 value of some libgfortran functions.
1910 2010-08-03 Thomas Koenig <tkoenig@gcc.gnu.org>
1913 * dependency.c (gfc_deb_compare_expr): Remove any integer
1914 conversion functions to larger types from both arguments.
1915 Remove handling these functions futher down.
1917 2010-08-03 Janus Weil <janus@gcc.gnu.org>
1921 * class.c (add_procs_to_declared_vtab1): Don't add erroneous procedures.
1922 * resolve.c (resolve_tb_generic_targets): Check for errors.
1924 2010-08-02 Thomas Koenig <tkoenig@gcc.gnu.org>
1927 * depencency.c (gfc_dep_resolver): Fix logic for when a loop
1930 2010-08-02 Thomas Koenig <tkoenig@gcc.gnu.org>
1933 * dependency.h: Add prototype for gfc_are_identical_variables.
1934 * frontend-passes.c: Include depencency.h.
1935 (optimimize_equality): Use gfc_are_identical_variables.
1936 * dependency.c (identical_array_ref): New function.
1937 (gfc_are_identical_variables): New function.
1938 (gfc_deb_compare_expr): Use gfc_are_identical_variables.
1939 * dependency.c (gfc_check_section_vs_section). Rename gfc_
1940 prefix from statc function.
1941 (check_section_vs_section): Change arguments to gfc_array_ref,
1942 adjust function body accordingly.
1944 2010-08-02 Mikael Morin <mikael@gcc.gnu.org>
1945 Janus Weil <janus@gcc.gnu.org>
1950 * intrinsic.c (gfc_get_intrinsic_sub_symbol): Commit changed symbol.
1951 * symbol.c (gen_cptr_param, gen_fptr_param, gen_shape_param,
1952 gfc_copy_formal_args, gfc_copy_formal_args_intr,
1953 gfc_copy_formal_args_ppc, generate_isocbinding_symbol): Ditto.
1954 * parse.c (parse_derived_contains, parse_spec, parse_progunit):
1955 Call reject_statement in case of error.
1956 (match_deferred_characteritics): Call gfc_undo_symbols in case match
1959 2010-08-01 Janus Weil <janus@gcc.gnu.org>
1962 * class.c (gfc_build_class_symbol): Make '$vptr' component private.
1963 (gfc_find_derived_vtab): Make vtabs and vtypes public.
1964 * module.c (read_module): When reading module files, always import
1965 vtab and vtype symbols.
1967 2010-07-31 Mikael Morin <mikael@gcc.gnu.org>
1971 * symbol.c (changed_syms): Made non-static.
1972 * parse.c (changed_syms): Declare new external.
1973 (next_statement): Assert changed_syms is NULL at the beginning.
1975 2010-07-30 Janus Weil <janus@gcc.gnu.org>
1976 Steven G. Kargl <kargl@gcc.gnu.org>
1979 * match.c (match_type_spec): Try to parse derived types before
1982 2010-07-30 Mikael Morin <mikael@gcc.gnu.org>
1984 * gfortran.h (gfc_release_symbol): New prototype.
1985 * symbol.c (gfc_release_symbol): New. Code taken from free_sym_tree.
1986 (gfc_undo_symbols, free_sym_tree, gfc_free_finalizer):
1987 Use gfc_release_symbol.
1988 * parse.c (gfc_fixup_sibling_symbols): Ditto.
1989 * resolve.c (resolve_symbol): Ditto.
1991 2010-07-29 Tobias Burnus <burnus@net-b.de>
1995 * trans-decl.c (gfc_get_extern_function_decl): Correctly handle
1996 external procedure declarations in modules.
1997 (gfc_get_symbol_decl): Modify assert.
1999 2010-07-29 Janus Weil <janus@gcc.gnu.org>
2002 * resolve.c (resolve_fl_derived): Call gfc_resolve_array_spec.
2004 2010-07-29 Janus Weil <janus@gcc.gnu.org>
2007 * trans-stmt.h (gfc_trans_class_init_assign): New prototype.
2008 (gfc_trans_class_assign): Modified prototype.
2009 * trans.h (gfc_conv_intrinsic_move_alloc): New prototype.
2010 * trans-expr.c (gfc_trans_class_init_assign): Split off from ...
2011 (gfc_trans_class_assign): ... here. Modified actual arguments.
2012 * trans-intrinsic.c (gfc_conv_intrinsic_move_alloc): New function to
2013 handle the MOVE_ALLOC intrinsic with scalar and class arguments.
2014 * trans.c (trans_code): Call 'gfc_conv_intrinsic_move_alloc'.
2016 2010-07-29 Mikael Morin <mikael@gcc.gnu.org>
2020 * class.c (gfc_find_derived_vtab): Accept or discard newly created
2021 symbols before returning.
2023 2010-07-29 Joseph Myers <joseph@codesourcery.com>
2025 * lang.opt (cpp): Remove Joined and Separate markers.
2026 (cpp=): New internal option.
2027 * lang-specs.h (F951_CPP_OPTIONS): Generate -cpp= option.
2028 * cpp.c (gfc_cpp_handle_option): Handle OPT_cpp_ instead of
2031 2010-07-29 Daniel Kraft <d@domob.eu>
2034 * array.c (resolve_array_bound): Fix error message to properly handle
2035 non-variable expressions.
2037 2010-07-28 Mikael Morin <mikael@gcc.gnu.org>
2039 * decl.c (free_value): Also free repeat field.
2040 * data.c (gfc_assign_data_value): Always free offset before returning.
2042 2010-07-28 Daniel Kraft <d@domob.eu>
2044 * gfortran.h (gfc_build_intrinsic_call): New method.
2045 * expr.c (gfc_build_intrinsic_call): New method.
2046 * simplify.c (range_check): Ignore non-constant value.
2047 (simplify_bound_dim): Handle non-variable expressions and
2048 fix memory leak with non-free'ed expression.
2049 (simplify_bound): Handle non-variable expressions.
2050 (gfc_simplify_shape): Ditto.
2051 (gfc_simplify_size): Ditto, but only in certain cases possible.
2053 2010-07-28 Joseph Myers <joseph@codesourcery.com>
2055 * gfortranspec.c (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
2058 2010-07-28 Tobias Burnus <burnus@net-b.de>
2061 * trans-types.c (gfc_get_derived_type): Fix DT declaration
2062 from modules for whole-file mode.
2064 2010-07-27 Joseph Myers <joseph@codesourcery.com>
2066 * gfortran.h (gfc_handle_option): Update prototype and return
2068 * options.c (gfc_handle_option): Update prototype and return value
2071 2010-07-27 Joseph Myers <joseph@codesourcery.com>
2073 * cpp.c (gfc_cpp_init_options): Update prototype. Use number of
2074 decoded options in allocating deferred_opt.
2075 * cpp.h (gfc_cpp_init_options): Update prototype.
2076 * f95-lang.c (LANG_HOOKS_OPTION_LANG_MASK): Define.
2077 * gfortran.h (gfc_option_lang_mask): New.
2078 (gfc_init_options): Update prototype.
2079 * options.c (gfc_option_lang_mask): New.
2080 (gfc_init_options): Update prototype. Pass new arguments to
2081 gfc_cpp_init_options.
2083 2010-07-26 Tobias Burnus <burnus@net-b.de>
2086 * trans-decl.c (gfc_get_extern_function_decl): Fix generation
2087 for functions which are later in the same file.
2088 (gfc_create_function_decl, build_function_decl,
2089 build_entry_thunks): Add global argument.
2090 * trans.c (gfc_generate_module_code): Update
2091 gfc_create_function_decl call.
2092 * trans.h (gfc_create_function_decl): Update prototype.
2093 * resolve.c (resolve_global_procedure): Also resolve for
2096 2010-07-26 Richard Henderson <rth@redhat.com>
2099 * f95-lang.c (LANG_HOOKS_WRITE_GLOBALS): New.
2100 (gfc_write_global_declarations): New.
2102 2010-07-26 Tobias Burnus <burnus@net-b.de>
2105 * trans-io.c (build_dt): Use NULL_TREE rather than NULL
2106 for call to transfer_namelist_element.
2107 * trans-decl.c (gfc_get_symbol_decl): Also set sym->backend_decl
2110 2010-07-25 Thomas Koenig <tkoenig@gcc.gnu.org>
2113 * Make-lang.in: Add fortran/frontend-passes.o.
2114 * gfortran.h: Add prototype for gfc_run_passes.
2115 * resolve.c (gfc_resolve): Call gfc_run_passes.
2116 * frontend-passes.c: New file.
2118 2010-07-25 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2121 * scanner.c (gfc_next_char_literal): Enable truncation warning for
2124 2010-07-25 Mikael Morin <mikael@gcc.gnu.org>
2127 * gfortran.h (gfc_namespace): New field old_equiv.
2128 (gfc_free_equiv_until): New prototype.
2129 * match.c (gfc_free_equiv_until): New, renamed from gfc_free_equiv with
2130 a parameterized stop condition.
2131 (gfc_free_equiv): Use gfc_free_equiv_until.
2132 * parse.c (next_statement): Save equivalence list.
2133 (reject_statement): Restore equivalence list.
2135 2010-07-25 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2138 * scanner.c (gfc_next_char_literal): Move check for truncation earlier
2139 in the function so that it does not get missed by early exits.
2140 (load_line): Add checks for quoted strings and free form comments to
2141 disable warnings on comments. Add check for ampersand as first
2142 character after truncation and don't warn for this case, but warn if
2143 there are subsequent non-whitespace characters.
2145 2010-07-24 Tobias Burnus <burnus@net-b.de>
2148 * parse.c (gfc_parse_file): Do not override
2149 gfc_global_ns_list items.
2151 2010-07-24 Tobias Burnus <burnus@net-b.de>
2153 * options.c (gfc_init_options): Enable -fwhole-file by default.
2154 * interface.c (compare_parameter): Assume a Hollerith constant is
2155 compatible with all other argument types.
2157 2010-07-23 Tobias Burnus <burnus@net-b.de>
2160 * trans-decl.c (gfc_get_symbol_decl): Use module decl with
2161 -fwhole-file also for derived types.
2162 * trans-types.c (copy_dt_decls_ifequal): Remove static and
2163 rename to gfc_copy_dt_decls_ifequal.
2164 (gfc_get_derived_type): Update call.
2165 * trans-types.h (gfc_copy_dt_decls_ifequal): Add prototype.
2167 2010-07-23 Tobias Burnus <burnus@net-b.de>
2170 * resolve.c (resolve_global_procedure): Properly handle ENTRY.
2172 2010-07-23 Jakub Jelinek <jakub@redhat.com>
2174 * trans-types.c (gfc_get_array_descriptor_base,
2175 gfc_get_array_type_bounds): Set TYPE_NAMELESS.
2176 * trans-decl.c (gfc_build_qualified_array): Set DECL_NAMELESS
2177 instead of clearing DECL_NAME.
2178 (gfc_build_dummy_array_decl): Set DECL_NAMELESS.
2180 2009-07-23 Paul Thomas <pault@gcc.gnu.org>
2183 * trans-array.c (gfc_init_loopinfo): Initialize the reverse
2185 gfc_trans_scalarized_loop_end: If reverse set in dimension n,
2186 reverse the scalarization loop.
2187 gfc_conv_resolve_dependencies: Pass the reverse field of the
2188 loopinfo to gfc_dep_resolver.
2189 trans-expr.c (gfc_trans_assignment_1): Enable loop reversal for
2190 assignment by resetting loop.reverse.
2191 gfortran.h : Add the gfc_reverse enum.
2192 trans.h : Add the reverse field to gfc_loopinfo.
2193 dependency.c (gfc_check_dependency): Pass null to the new arg
2194 of gfc_dep_resolver.
2195 (gfc_check_section_vs_section): Check for reverse dependencies.
2196 (gfc_dep_resolver): Add reverse argument and deal with the loop
2198 dependency.h : Modify prototype for gfc_dep_resolver to include
2201 2010-07-23 Daniel Kraft <d@domob.eu>
2204 * gfortran.h (gfc_find_symtree_in_proc): New method.
2205 * symbol.c (gfc_find_symtree_in_proc): New method.
2206 * match.c (match_exit_cycle): Look for loop name also in parent
2207 namespaces within current procedure.
2209 2010-07-22 Tobias Burnus <burnus@net-b.de>
2212 * dependency.c (gfc_check_dependency): Add argument alising check.
2213 * symbol.c (gfc_symbols_could_alias): Add argument alising check.
2215 2010-07-22 Daniel Kraft <d@domob.eu>
2217 * trans-stmt.c (gfc_trans_return): Put back in the handling of se.post,
2218 now in the correct place.
2220 2010-07-21 Steven G. Kargl <kargl@gcc.gnu.org>
2223 * Revert my commit r162325.
2225 2010-07-21 Daniel Kraft <d@domob.eu>
2227 * trans.h (gfc_get_return_label): Removed.
2228 (gfc_generate_return): New method.
2229 (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
2230 returning a tree directly.
2231 * trans-stmt.c (gfc_trans_return): Use `gfc_generate_return'.
2232 (gfc_trans_block_construct): Update for new interface to
2233 `gfc_trans_deferred_vars'.
2234 * trans-decl.c (current_function_return_label): Removed.
2235 (current_procedure_symbol): New variable.
2236 (gfc_get_return_label): Removed.
2237 (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
2238 returning a tree directly.
2239 (get_proc_result), (gfc_generate_return): New methods.
2240 (gfc_generate_function_code): Clean up and do init/cleanup here
2241 also with gfc_wrapped_block. Remove return-label but rather
2244 2010-07-19 Steven G. Kargl <kargl@gcc.gnu.org>
2247 * fortran/match.c (match_type_spec): Check for derived type before
2250 2010-07-19 Paul Thomas <pault@gcc.gnu.org>
2253 * interface.c (matching_typebound_op): Add argument for the
2254 return of the generic name for the procedure.
2255 (build_compcall_for_operator): Add an argument for the generic
2256 name of an operator procedure and supply it to the expression.
2257 (gfc_extend_expr, gfc_extend_assign): Use the generic name in
2258 calls to the above procedures.
2259 * resolve.c (resolve_typebound_function): Catch procedure
2260 component calls for CLASS objects, check that the vtable is
2261 complete and insert the $vptr and procedure components, to make
2263 (resolve_typebound_function): The same.
2264 * trans-decl.c (gfc_trans_deferred_vars): Do not deallocate
2265 an allocatable scalar if it is a result.
2267 2010-07-19 Paul Thomas <pault@gcc.gnu.org>
2270 * match.c (gfc_match_iterator): Reverted.
2272 2010-07-18 Paul Thomas <pault@gcc.gnu.org>
2275 * match.c (gfc_match_iterator): Remove error that iterator
2276 cannot be INTENT(IN).
2278 2010-07-17 Mikael Morin <mikael@gcc.gnu.org>
2280 * trans-array.c (gfc_free_ss): Don't free beyond ss rank.
2281 Access subscript through the "dim" field index.
2282 (gfc_trans_create_temp_array): Access ss info through the "dim" field
2284 (gfc_conv_array_index_offset): Ditto.
2285 (gfc_conv_loop_setup): Ditto.
2286 (gfc_conv_expr_descriptor): Ditto.
2287 (gfc_conv_ss_startstride): Ditto. Update call to
2288 gfc_conv_section_startstride.
2289 (gfc_conv_section_startstride): Set values along the array dimension.
2290 Get array dimension directly from the argument.
2292 2010-07-15 Jakub Jelinek <jakub@redhat.com>
2294 * trans.h (gfc_string_to_single_character): New prototype.
2295 * trans-expr.c (string_to_single_character): Renamed to ...
2296 (gfc_string_to_single_character): ... this. No longer static.
2297 (gfc_conv_scalar_char_value, gfc_build_compare_string,
2298 gfc_trans_string_copy): Adjust callers.
2299 * config-lang.in (gtfiles): Add fortran/trans-stmt.c.
2300 * trans-stmt.c: Include ggc.h and gt-fortran-trans-stmt.h.
2301 (select_struct): Move to toplevel, add GTY(()).
2302 (gfc_trans_character_select): Optimize SELECT CASE
2303 with character length 1.
2305 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
2307 * f95-lang.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
2308 * trans-common.c: Likewise.
2309 * trans-decl.c: Likewise.
2310 * trans-types.c: Likewise.
2311 * trans.c: Likewise.
2313 2010-07-15 Janus Weil <janus@gcc.gnu.org>
2316 * resolve.c (resolve_typebound_generic_call): Resolve generic
2317 non-polymorphic type-bound procedure calls to the correct specific
2319 (resolve_typebound_subroutine): Remove superfluous code.
2321 2010-07-15 Daniel Kraft <d@domob.eu>
2324 * trans.h (struct gfc_wrapped_block): New struct.
2325 (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
2326 (gfc_finish_wrapped_block): New method.
2327 (gfc_init_default_dt): Add new init code to block rather than
2329 * trans-array.h (gfc_trans_auto_array_allocation): Use gfc_wrapped_block
2330 (gfc_trans_dummy_array_bias): Ditto.
2331 (gfc_trans_g77_array): Ditto.
2332 (gfc_trans_deferred_array): Ditto.
2333 * trans.c (gfc_add_expr_to_block): Call add_expr_to_chain.
2334 (add_expr_to_chain): New method based on old gfc_add_expr_to_block.
2335 (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
2336 (gfc_finish_wrapped_block): New method.
2337 * trans-array.c (gfc_trans_auto_array_allocation): use gfc_wrapped_block
2338 (gfc_trans_g77_array), (gfc_trans_dummy_array_bias): Ditto.
2339 (gfc_trans_deferred_array): Ditto.
2340 * trans-decl.c (gfc_trans_dummy_character): Ditto.
2341 (gfc_trans_auto_character_variable), (gfc_trans_assign_aux_var): Ditto.
2342 (init_intent_out_dt): Ditto.
2343 (gfc_init_default_dt): Add new init code to block rather than
2345 (gfc_trans_deferred_vars): Use gfc_wrapped_block to collect all init
2346 and cleanup code and put it all together.
2348 2010-07-15 Jakub Jelinek <jakub@redhat.com>
2350 * trans.h (gfc_build_compare_string): Add CODE argument.
2351 * trans-intrinsic.c (gfc_conv_intrinsic_strcmp): Pass OP to
2352 gfc_build_compare_string.
2353 * trans-expr.c (gfc_conv_expr_op): Pass CODE to
2354 gfc_build_compare_string.
2355 (string_to_single_character): Rename len variable to length.
2356 (gfc_optimize_len_trim): New function.
2357 (gfc_build_compare_string): Add CODE argument. If it is EQ_EXPR
2358 or NE_EXPR and one of the strings is string literal with LEN_TRIM
2359 bigger than the length of the other string, they compare unequal.
2362 * trans-stmt.c (gfc_trans_character_select): Always use NULL for high
2363 in CASE_LABEL_EXPR and use NULL for low for the default case.
2365 2010-07-14 Mikael Morin <mikael@gcc.gnu.org>
2367 * trans-array.c (gfc_conv_section_upper_bound): Remove
2368 (gfc_conv_section_startstride): Don't set the upper bound in the
2369 vector subscript case.
2370 (gfc_conv_loop_setup): Don't use gfc_conv_section_upper_bound
2372 2010-07-14 Janus Weil <janus@gcc.gnu.org>
2375 * gfortran.h (gfc_is_data_pointer): Remove prototype.
2376 * dependency.c (gfc_is_data_pointer): Make it static.
2377 * intrinsic.texi: Update documentation on C_LOC.
2378 * resolve.c (gfc_iso_c_func_interface): Fix pointer and target checks
2379 and add a check for polymorphic variables.
2381 2010-07-14 Jakub Jelinek <jakub@redhat.com>
2383 * trans-expr.c (string_to_single_character): Also optimize
2384 string literals containing a single char followed only by spaces.
2385 (gfc_trans_string_copy): Remove redundant string_to_single_character
2388 * trans-decl.c (gfc_build_intrinsic_function_decls,
2389 gfc_build_builtin_function_decls): Mark functions as
2390 DECL_PURE_P or TREE_READONLY.
2392 2010-07-13 Nathan Froyd <froydnj@codesourcery.com>
2394 * trans-decl.c (build_entry_thunks): Call build_call_expr_loc_vec
2395 instead of build_function_call_expr.
2396 * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Likewise.
2398 2010-07-13 Tobias Burnus <burnus@net-b.de>
2399 Daniel Franke <franke.daniel@gmail.com>
2402 * trans.h (gfc_build_library_function_decl_with_spec): New prototype.
2403 * trans-decl.c (gfc_build_library_function_decl_with_spec): Removed
2405 * trans-io (gfc_build_io_library_fndecls): Add "fn spec" annotations.
2407 2010-07-13 Daniel Franke <franke.daniel@gmail.com>
2408 Tobias Burnus <burnus@net-b.de>
2411 * trans-decl.c (gfc_build_intrinsic_function_decls): Add
2412 noclobber/noescape annotations to function calls.
2413 (gfc_build_builtin_function_decls): Likewise.
2415 2010-07-13 Janus Weil <janus@gcc.gnu.org>
2421 * gfortran.h (gfc_find_derived_vtab): Modified prototype.
2422 * class.c (gfc_build_class_symbol): Modified call to
2423 'gfc_find_derived_vtab'.
2424 (add_proc_component): Removed, moved code into 'add_proc_comp'.
2425 (add_proc_comps): Renamed to 'add_proc_comp', removed treatment of
2427 (add_procs_to_declared_vtab1): Removed unnecessary argument 'resolved'.
2428 Removed treatment of generics.
2429 (copy_vtab_proc_comps): Removed unnecessary argument 'resolved'.
2430 Call 'add_proc_comp' instead of duplicating code.
2431 (add_procs_to_declared_vtab): Removed unnecessary arguments 'resolved'
2433 (add_generic_specifics,add_generics_to_declared_vtab): Removed.
2434 (gfc_find_derived_vtab): Removed unnecessary argument 'resolved'.
2435 Removed treatment of generics.
2436 * iresolve.c (gfc_resolve_extends_type_of): Modified call to
2437 'gfc_find_derived_vtab'.
2438 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
2439 Removed treatment of generics.
2440 (resolve_select_type,resolve_fl_derived): Modified call to
2441 'gfc_find_derived_vtab'.
2442 * trans-decl.c (gfc_get_symbol_decl): Ditto.
2443 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
2445 * trans-stmt.c (gfc_trans_allocate): Ditto.
2447 2010-07-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2450 * trans-io.c (build_dt): Set common.unit to flag chracter(kind=4)
2453 2010-07-12 Mikael Morin <mikael@gcc.gnu.org>
2455 * expr.c (gfc_get_int_expr): Don't initialize mpfr data twice.
2456 * resolve.c (build_default_init_expr): Ditto.
2458 2010-07-11 Tobias Burnus <burnus@net-b.de>
2461 * module.c (sort_iso_c_rename_list): Remove.
2462 (import_iso_c_binding_module,use_iso_fortran_env_module):
2463 Allow multiple imports of the same symbol.
2465 2010-07-11 Mikael Morin <mikael@gcc.gnu.org>
2467 * arith.c (gfc_arith_done_1): Release mpfr internal caches.
2469 2010-07-11 Janus Weil <janus@gcc.gnu.org>
2472 * decl.c (build_sym,attr_decl1): Only build the class container if the
2473 symbol has sufficient attributes.
2474 * expr.c (gfc_check_pointer_assign): Use class_pointer instead of
2475 pointer attribute for classes.
2476 * match.c (gfc_match_allocate,gfc_match_deallocate): Ditto.
2477 * module.c (MOD_VERSION): Bump.
2478 (enum ab_attribute,attr_bits): Add AB_CLASS_POINTER.
2479 (mio_symbol_attribute): Handle class_pointer attribute.
2480 * parse.c (parse_derived): Use class_pointer instead of pointer
2481 attribute for classes.
2482 * primary.c (gfc_variable_attr,gfc_expr_attr): Ditto.
2483 * resolve.c (resolve_structure_cons,resolve_deallocate_expr,
2484 resolve_allocate_expr,resolve_fl_derived): Ditto.
2485 (resolve_fl_var_and_proc): Check for class_ok attribute.
2487 2010-07-10 Mikael Morin <mikael@gcc.gnu.org>
2489 * trans-io.c (gfc_build_st_parameter): Update calls to
2490 gfc_add_field_to_struct.
2491 * trans-stmt.c (ADD_FIELD): Ditto.
2493 (gfc_get_derived_type): Ditto. Don't create backend_decl for C_PTR's
2495 (gfc_add_field_to_struct_1): Set TYPE_FIELDS(context) instead of
2496 fieldlist, remove fieldlist from argument list.
2497 (gfc_add_field_to_struct): Update call to gfc_add_field_to_struct_1
2498 and remove fieldlist from argument list.
2499 (gfc_get_desc_dim_type, gfc_get_array_descriptor_base,
2500 gfc_get_mixed_entry_union): Move setting
2501 TYPE_FIELDS to gfc_add_field_to_struct_1 and update calls to it.
2502 * trans-types.h (gfc_add_field_to_struct): Update prototype.
2504 2010-07-10 Paul Thomas <pault@gcc.gnu.org>
2507 * trans-expr.c (arrayfunc_assign_needs_temporary): No temporary
2508 if the lhs has never been host associated, as well as not being
2509 use associated, a pointer or a target.
2510 * resolve.c (resolve_variable): Mark variables that are host
2512 * gfortran.h: Add the host_assoc bit to the symbol_attribute
2515 2010-07-09 Janus Weil <janus@gcc.gnu.org>
2517 * intrinsic.texi: Add documentation for SAME_TYPE_AS, EXTENDS_TYPE_OF,
2518 STORAGE_SIZE, C_NULL_PTR and C_NULL_FUNPTR. Modify documentation of
2519 SIZEOF and C_SIZEOF.
2521 2010-07-08 Janus Weil <janus@gcc.gnu.org>
2524 * gfortran.h (gfc_isym_id): Add GFC_ISYM_C_SIZEOF,GFC_ISYM_STORAGE_SIZE.
2525 * intrinsic.h (gfc_check_c_sizeof,gfc_check_storage_size,
2526 gfc_resolve_storage_size): New prototypes.
2527 * check.c (gfc_check_c_sizeof,gfc_check_storage_size): New functions.
2528 * intrinsic.c (add_functions): Add STORAGE_SIZE.
2529 * iresolve.c (gfc_resolve_storage_size): New function.
2530 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Handle polymorphic
2532 (gfc_conv_intrinsic_storage_size): New function.
2533 (gfc_conv_intrinsic_function): Handle STORAGE_SIZE.
2535 2010-07-08 Jakub Jelinek <jakub@redhat.com>
2538 * match.c (match_exit_cycle): Error on EXIT also from collapsed
2539 !$omp do loops. Error on CYCLE to non-innermost collapsed
2542 2010-07-08 Tobias Burnus <burnus@net-b.de>
2545 * array.c (gfc_match_array_ref): Better error message for
2546 coarrays with too few ranks.
2547 (match_subscript): Move one diagnostic to caller.
2548 * gfortran.h (gfc_get_corank): Add prottype.
2549 * expr.c (gfc_get_corank): New function.
2550 * iresolve.c (resolve_bound): Fix rank for cobounds.
2551 (gfc_resolve_lbound,gfc_resolve_lcobound, gfc_resolve_ubound,
2552 gfc_resolve_ucobound, gfc_resolve_this_image): Update
2555 2010-07-06 Tobias Burnus <burnus@net-b.de>
2558 * array.c (gfc_expand_constructor): Add optional diagnostic.
2559 * gfortran.h (gfc_expand_constructor): Update prototype.
2560 * expr.c (gfc_simplify_expr, check_init_expr,
2561 gfc_reduce_init_expr): Update gfc_expand_constructor call.
2562 * resolve.c (gfc_resolve_expr): Ditto.
2564 2010-07-06 Tobias Burnus <burnus@net-b.de>
2566 * trans-decl.c: Include diagnostic-core.h besides toplev.h.
2567 * trans-intrinsic.c: Ditto.
2568 * trans-types.c: Ditto.
2569 * convert.c: Include diagnostic-core.h instead of toplev.h.
2571 * trans-array.c: Ditto.
2572 * trans-const.c: Ditto.
2573 * trans-expr.c: Ditto.
2574 * trans-io.c: Ditto.
2575 * trans-openmp.c: Ditto.
2578 2010-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
2581 * check.c (dim_rank_check): Also check intrinsic functions.
2582 Adjust permissible rank for functions which reduce the rank of
2583 their argument. Spread is an exception, where DIM can
2584 be one larger than the rank of array.
2586 2010-07-05 Steven G. Kargl <kargl@gcc.gnu.org>
2589 * fortran/io.c (resolve_tag): Check EXIST tag is a default logical.
2591 2010-07-05 Paul Thomas <pault@gcc.gnu.org>
2594 * trans-types.c (gfc_get_derived_type): Derived type fields
2595 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set
2596 but build_pointer_type_for_mode must be used for this.
2598 2010-07-05 Nathan Froyd <froydnj@codesourcery.com>
2600 * trans.h (gfc_conv_procedure_call): Take a VEC instead of a tree.
2601 * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Adjust for new
2602 type of gfc_conv_procedure_call.
2603 (conv_generic_with_optional_char_arg): Likewise.
2604 * trans-stmt.c (gfc_trans_call): Likewise.
2605 * trans-expr.c (gfc_conv_function_expr): Likewise.
2606 (gfc_conv_procedure_call): Use build_call_vec instead of
2609 2010-07-04 Daniel Kraft <d@domob.eu>
2611 * gfc-internals.texi (gfc_code): Document BLOCK and ASSOCIATE.
2613 2010-07-04 Paul Thomas <pault@gcc.gnu.org>
2617 * trans-types.c (gfc_get_derived_type): Derived type fields
2618 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set.
2620 2010-07-02 Mikael Morin <mikael@gcc.gnu.org>
2623 * decl.c (match_procedure_in_type): Clear structure before using.
2624 (gfc_match_generic): Ditto.
2626 2010-07-02 Nathan Froyd <froydnj@codesourcery.com>
2628 * trans-types.h (gfc_add_field_to_struct): Add tree ** parameter.
2629 * trans-types.c (gfc_add_field_to_struct_1): New function, most
2630 of which comes from...
2631 (gfc_add_field_to_struct): ...here. Call it. Add new parameter.
2632 (gfc_get_desc_dim_type): Call gfc_add_field_to_struct_1 for
2634 (gfc_get_array_descriptor_base): Likewise.
2635 (gfc_get_mixed_entry_union): Likewise.
2636 (gfc_get_derived_type): Add extra chain parameter for
2637 gfc_add_field_to_struct.
2638 * trans-stmt.c (gfc_trans_character_select): Likewise.
2639 * trans-io.c (gfc_build_st_parameter): Likewise.
2641 2010-06-29 Janus Weil <janus@gcc.gnu.org>
2644 * resolve.c (is_external_proc): Prevent procedure pointers from being
2645 regarded as external procedures.
2647 2010-06-29 Janus Weil <janus@gcc.gnu.org>
2650 * trans-intrinsic.c (gfc_conv_associated): Handle polymorphic variables
2651 passed as second argument of ASSOCIATED.
2653 2010-06-29 Paul Thomas <pault@gcc.gnu.org>
2656 * trans-expr.c (arrayfunc_assign_needs_temporary): New function
2657 to determine if a function assignment can be made without a
2659 (gfc_trans_arrayfunc_assign): Move all the conditions that
2660 suppress the direct function call to the above new functon and
2663 2010-06-28 Paul Thomas <pault@gcc.gnu.org>
2666 * interface.c (argument_rank_mismatch): New function.
2667 (compare_parameter): Call new function instead of generating
2670 2010-06-28 Nathan Froyd <froydnj@codesourcery.com>
2672 * trans-openmp.c (dovar_init): Define. Define VECs containing it.
2673 (gfc_trans_omp_do): Use a VEC to accumulate variables and their
2676 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
2678 * Make-lang.in: Update dependencies.
2680 2010-06-27 Nathan Froyd <froydnj@codesourcery.com>
2682 * gfortran.h (gfc_code): Split backend_decl field into cycle_label
2683 and exit_label fields.
2684 * trans-openmp.c (gfc_trans_omp_do): Assign to new fields
2686 * trans-stmt.c (gfc_trans_simple_do): Likewise.
2687 (gfc_trans_do): Likewise.
2688 (gfc_trans_do_while): Likewise.
2689 (gfc_trans_cycle): Use cycle_label directly.
2690 (gfc_trans_exit): Use exit_label directly.
2692 2010-06-27 Daniel Kraft <d@domob.eu>
2694 * dump-parse-tree.c (show_symbol): Dump target-expression for
2696 (show_code_node): Make distinction between BLOCK and ASSOCIATE.
2697 (show_namespace): Use show_level for correct indentation of
2698 "inner namespaces" (contained procedures or BLOCK).
2700 2010-06-27 Thomas Koenig <tkoenig@gcc.gnu.org>
2703 * dump-parse-tree.c (show_code_node): Show namespace for
2706 2010-06-26 Tobias Burnus <burnus@net-b.de>
2708 * decl.c (gfc_match_decl_type_spec): Support
2709 TYPE(intrinsic-type-spec).
2711 2010-06-25 Tobias Burnus <burnus@net-b.de>
2713 * intrinsic.h (gfc_check_selected_real_kind,
2714 gfc_simplify_selected_real_kind): Update prototypes.
2715 * intrinsic.c (add_functions): Add radix support to
2717 * check.c (gfc_check_selected_real_kind): Ditto.
2718 * simplify.c (gfc_simplify_selected_real_kind): Ditto.
2719 * trans-decl.c (gfc_build_intrinsic_function_decls):
2720 Change call from selected_real_kind to selected_real_kind2008.
2721 * intrinsic.texi (SELECTED_REAL_KIND): Update for radix.
2722 (PRECISION, RANGE, RADIX): Add cross @refs.
2724 2010-06-25 Tobias Burnus <burnus@net-b.de>
2726 * decl.c (gfc_match_entry): Mark ENTRY as GFC_STD_F2008_OBS.
2727 * gfortran.texi (_gfortran_set_options): Update for
2728 GFC_STD_F2008_OBS addition.
2729 * libgfortran.h: Add GFC_STD_F2008_OBS.
2730 * options.c (set_default_std_flags, gfc_handle_option): Handle
2732 io.c (check_format): Fix allow_std check.
2734 2010-06-25 Tobias Burnus <burnus@net-b.de>
2736 * decl.c (gfc_match_entry): Allow END besides
2737 END SUBROUTINE/END FUNCTION for contained procedures.
2739 2010-06-25 Tobias Burnus <burnus@net-b.de>
2741 * parse.c (next_free, next_fixed): Allow ";" as first character.
2743 2010-06-24 Tobias Burnus <burnus@net-b.de>
2746 * decl.c (variable_decl): Fix IMPORT diagnostic for CLASS.
2748 2010-06-22 Janus Weil <janus@gcc.gnu.org>
2751 * resolve.c (resolve_fl_derived): Avoid checking for abstract on class
2754 2010-06-21 Tobias Burnus <burnus@net-b.de>
2757 * interface.c (compare_parameter): Add gfc_is_simply_contiguous
2759 * symbol.c (gfc_add_contiguous): New function.
2760 (gfc_copy_attr, check_conflict): Handle contiguous attribute.
2761 * decl.c (match_attr_spec): Ditto.
2762 (gfc_match_contiguous): New function.
2763 * resolve.c (resolve_fl_derived, resolve_symbol): Handle
2765 * gfortran.h (symbol_attribute): Add contiguous.
2766 (gfc_is_simply_contiguous): Add prototype.
2767 (gfc_add_contiguous): Add prototype.
2768 * match.h (gfc_match_contiguous): Add prototype.
2769 * parse.c (decode_specification_statement,
2770 decode_statement): Handle contiguous attribute.
2771 * expr.c (gfc_is_simply_contiguous): New function.
2772 * dump-parse-tree.c (show_attr): Handle contiguous.
2773 * module.c (ab_attribute, attr_bits, mio_symbol_attribute):
2775 * trans-expr.c (gfc_add_interface_mapping): Copy
2777 * trans-array.c (gfc_conv_descriptor_stride_get,
2778 gfc_conv_array_parameter): Handle contiguous arrays.
2779 * trans-types.c (gfc_build_array_type, gfc_build_array_type,
2780 gfc_sym_type, gfc_get_derived_type, gfc_get_array_descr_info):
2782 * trans.h (gfc_array_kind): Ditto.
2783 * trans-decl.c (gfc_get_symbol_decl): Ditto.
2785 2010-06-20 Joseph Myers <joseph@codesourcery.com>
2787 * options.c (gfc_handle_option): Don't handle N_OPTS.
2789 2010-06-19 Janus Weil <janus@gcc.gnu.org>
2792 * resolve.c (resolve_fl_derived): Reverse ordering of conditions
2795 2010-06-18 Tobias Burnus <burnus@net-b.de>
2798 * resolve.c (resolve_allocate_deallocate): Properly check
2799 part-refs in stat=/errmsg= for invalid use.
2801 2010-06-17 Janus Weil <janus@gcc.gnu.org>
2804 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
2805 Return directly in case of an error.
2807 2010-06-16 Janus Weil <janus@gcc.gnu.org>
2810 * gfortran.h (gfc_get_typebound_proc): Modified Prototype.
2811 * decl.c (match_procedure_in_type): Give a unique gfc_typebound_proc
2812 structure to each procedure in a procedure list.
2813 * module.c (mio_typebound_proc): Add NULL argument to
2814 'gfc_get_typebound_proc'.
2815 * symbol.c (gfc_get_typebound_proc): Add a new argument, which is used
2816 to initialize the new structure.
2818 2010-06-15 Janus Weil <janus@gcc.gnu.org>
2821 * gfortran.h (gfc_expr): Add new member 'mold'.
2822 * match.c (gfc_match_allocate): Implement the MOLD tag.
2823 * resolve.c (resolve_allocate_expr): Ditto.
2824 * trans-stmt.c (gfc_trans_allocate): Ditto.
2826 2010-06-15 Jakub Jelinek <jakub@redhat.com>
2829 * trans-openmp.c (gfc_omp_predetermined_sharing): Don't return
2830 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with
2831 GFC_DECL_SAVED_DESCRIPTOR set.
2832 (gfc_omp_report_decl): New function.
2833 * trans.h (gfc_omp_report_decl): New prototype.
2834 * f95-lang.c (LANG_HOOKS_OMP_REPORT_DECL): Redefine.
2836 2010-06-13 Daniel Franke <franke.daniel@gmail.com>
2840 * gfortranspec.c (lang_specific_driver): Removed deprecation
2842 * lang.opt: Add options -M, -MM, -MD, -MMD, -MF, -MG, -MP, -MT, -MQ.
2843 * lang-specs.h (CPP_FORWARD_OPTIONS): Add -M* options.
2844 * cpp.h (gfc_cpp_makedep): New.
2845 (gfc_cpp_add_dep): New.
2846 (gfc_cpp_add_target): New.
2847 * cpp.c (gfc_cpp_option): Add deps* members.
2848 (gfc_cpp_makedep): New.
2849 (gfc_cpp_add_dep): New.
2850 (gfc_cpp_add_target): New.
2851 (gfc_cpp_init_options): Initialize new options.
2852 (gfc_cpp_handle_option): Handle new options.
2853 (gfc_cpp_post_options): Map new options to libcpp-options.
2854 (gfc_cpp_init): Handle deferred -MQ and -MT options.
2855 (gfc_cpp_done): If requested, write dependencies to file.
2856 * module.c (gfc_dump_module): Add a module filename as target.
2857 * scanner.c (open_included_file): New parameter system; add the
2858 included file as dependency.
2859 (gfc_open_included_file): Add the included file as dependency.
2860 (gfc_open_intrinsic_module): Likewise.
2861 * invoke.texi: Removed deprecation warning for -M.
2862 * gfortran.texi: Removed Makefile-dependencies project.
2864 2010-06-12 Daniel Franke <franke.daniel@gmail.com>
2866 * resolve.c (resolve_global_procedure): Improved checking if an
2867 explicit interface is required.
2869 2010-06-12 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2871 * trans-decl.c (gfc_build_intrinsic_function_decls): Fix
2873 * trans-intrinsic.c (gfc_conv_intrinsic_fdate): Fix argument type.
2874 (gfc_conv_intrinsic_ttynam): Likewise.
2875 (gfc_conv_intrinsic_trim): Likewise.
2877 2010-06-12 Janus Weil <janus@gcc.gnu.org>
2880 * decl.c (match_procedure_in_type): Allow procedure lists (F08).
2882 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2884 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Fix comment.
2886 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2888 * mathbuiltins.def: Add builtins that do not directly correspond
2889 to a Fortran intrinsic, with new macro OTHER_BUILTIN.
2890 * f95-lang.c (gfc_init_builtin_functions): Define OTHER_BUILTIN.
2891 * trans-intrinsic.c (gfc_intrinsic_map_t): Remove
2892 code_{r,c}{4,8,10,16} fields. Add
2893 {,complex}{float,double,long_double}_built_in fields.
2894 (gfc_intrinsic_map): Adjust definitions of DEFINE_MATH_BUILTIN,
2895 DEFINE_MATH_BUILTIN_C and LIB_FUNCTION accordingly. Add
2896 definition of OTHER_BUILTIN.
2897 (real_compnt_info): Remove unused struct.
2898 (builtin_decl_for_precision, builtin_decl_for_float_kind): New
2900 (build_round_expr): Call builtin_decl_for_precision instead of
2902 (gfc_conv_intrinsic_aint): Call builtin_decl_for_float_kind
2903 instead of a switch.
2904 (gfc_build_intrinsic_lib_fndecls): Match
2905 {real,complex}{4,8,10,16}decl into the C-style built_in_decls.
2906 (gfc_get_intrinsic_lib_fndecl): Do not hardcode floating-point
2908 (gfc_conv_intrinsic_lib_function): Go through all the extended
2910 (gfc_trans_same_strlen_check): Call builtin_decl_for_float_kind
2911 instead of a switch.
2912 (gfc_conv_intrinsic_abs): Likewise.
2913 (gfc_conv_intrinsic_mod): Likewise.
2914 (gfc_conv_intrinsic_sign): Likewise.
2915 (gfc_conv_intrinsic_fraction): Likewise.
2916 (gfc_conv_intrinsic_nearest): Likewise.
2917 (gfc_conv_intrinsic_spacing): Likewise.
2918 (gfc_conv_intrinsic_rrspacing): Likewise.
2919 (gfc_conv_intrinsic_scale): Likewise.
2920 (gfc_conv_intrinsic_set_exponent): Likewise.
2922 2010-06-11 Paul Thomas <pault@gcc.gnu.org>
2926 * trans-expr.c (gfc_conv_derived_to_class): Handle array-valued
2927 functions with CLASS formal arguments.
2929 2010-06-10 Janus Weil <janus@gcc.gnu.org>
2932 * resolve.c (conformable_arrays): Handle allocatable components.
2934 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2937 * gfortran.texi: Document that Cray pointers cannot be function
2940 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2943 * gfortran.texi: Document lack of support for syntax
2944 "complex FUNCTION name*16()", and existence of alternative
2945 legacy syntax "complex*16 FUNCTION name()".
2947 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2950 * intrinsic.texi (FLUSH): Note the difference between FLUSH and
2951 POSIX's fsync(), and how to call the latter from Fortran code.
2953 2010-06-10 Daniel Franke <franke.daniel@gmail.com>
2956 * interface.c (compare_actual_formal): Reject actual arguments with
2957 array subscript passed to ASYNCHRONOUS dummys.
2959 2010-06-10 Daniel Kraft <d@domob.eu>
2962 * gfortran.h (enum gfc_statement): Add ST_ASSOCIATE, ST_END_ASSOCIATE.
2963 (struct gfc_symbol): New field `assoc'.
2964 (struct gfc_association_list): New struct.
2965 (struct gfc_code): New struct `block' in union, move `ns' there
2966 and add association list.
2967 (gfc_free_association_list): New method.
2968 (gfc_has_vector_subscript): Made public;
2969 * match.h (gfc_match_associate): New method.
2970 * parse.h (enum gfc_compile_state): Add COMP_ASSOCIATE.
2971 * decl.c (gfc_match_end): Handle ST_END_ASSOCIATE.
2972 * interface.c (gfc_has_vector_subscript): Made public.
2973 (compare_actual_formal): Rename `has_vector_subscript' accordingly.
2974 * match.c (gfc_match_associate): New method.
2975 (gfc_match_select_type): Change reference to gfc_code's `ns' field.
2976 * primary.c (match_variable): Don't allow names associated to expr here.
2977 * parse.c (decode_statement): Try matching ASSOCIATE statement.
2978 (case_exec_markers, case_end): Add ASSOCIATE statement.
2979 (gfc_ascii_statement): Hande ST_ASSOCIATE and ST_END_ASSOCIATE.
2980 (parse_associate): New method.
2981 (parse_executable): Handle ST_ASSOCIATE.
2982 (parse_block_construct): Change reference to gfc_code's `ns' field.
2983 * resolve.c (resolve_select_type): Ditto.
2984 (resolve_code): Ditto.
2985 (resolve_block_construct): Ditto and add comment.
2986 (resolve_select_type): Set association list in generated BLOCK to NULL.
2987 (resolve_symbol): Resolve associate names.
2988 * st.c (gfc_free_statement): Change reference to gfc_code's `ns' field
2989 and free association list.
2990 (gfc_free_association_list): New method.
2991 * symbol.c (gfc_new_symbol): NULL new field `assoc'.
2992 * trans-stmt.c (gfc_trans_block_construct): Change reference to
2993 gfc_code's `ns' field.
2995 2010-06-10 Kai Tietz <kai.tietz@onevision.com>
2997 * error.c (error_print): Pre-initialize loc by NULL.
2998 * openmp.c (resolve_omp_clauses): Add explicit
2999 braces to avoid ambigous else.
3000 * array.c (match_subscript): Pre-initialize m to MATCH_ERROR.
3002 2010-06-10 Gerald Pfeifer <gerald@pfeifer.com>
3004 * gfc-internals.texi: Move to GFDL 1.3.
3005 * gfortran.texi: Ditto.
3006 * intrinsic.texi: Ditto.
3007 * invoke.texi: Ditto.
3009 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
3012 * check.c (gfc_check_selected_real_kind): Verify that the
3013 actual arguments are scalar.
3015 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
3018 * intrinsic.c (gfc_convert_type_warn): Further improve -Wconversion.
3020 2010-06-09 Janus Weil <janus@gcc.gnu.org>
3023 * dump-parse-tree.c (show_symbol): Avoid infinite loop.
3025 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
3027 * fortran/symbol.c (check_conflict): Remove an invalid conflict check.
3029 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
3031 * fortran/intrinsic.c (add_functions): Change gfc_check_btest,
3032 gfc_check_ibclr, and gfc_check_ibset to gfc_check_bitfcn.
3033 * fortran/intrinsic.h: Remove prototypes for gfc_check_btest,
3034 gfc_check_ibclr, and gfc_check_ibset. Add prototype for
3036 * fortran/check.c (nonnegative_check, less_than_bitsize1,
3037 less_than_bitsize2): New functions.
3038 (gfc_check_btest): Renamed to gfc_check_bitfcn. Use
3039 nonnegative_check and less_than_bitsize1.
3040 (gfc_check_ibclr, gfc_check_ibset): Removed.
3041 (gfc_check_ibits,gfc_check_mvbits): Use nonnegative_check and
3044 2010-06-09 Janus Weil <janus@gcc.gnu.org>
3047 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
3050 2010-06-09 Kai Tietz <kai.tietz@onevision.com>
3052 * resolve.c (resolve_deallocate_expr): Avoid warning
3053 about possible use of iunitialized sym.
3054 (resolve_allocate_expr): Pre-initialize sym by NULL.
3056 2010-06-09 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3059 * f95-lang.c (gfc_init_builtin_functions): Remove comment.
3061 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
3063 * trans-types.c (gfc_get_nodesc_array_type): Use typed GC
3065 (gfc_get_array_type_bounds): Likewise.
3067 * trans-decl.c (gfc_allocate_lang_decl): Likewise.
3068 (gfc_find_module): Likewise.
3070 * f95-lang.c (pushlevel): Likewise.
3072 * trans.h (struct lang_type): Add variable_size GTY option.
3073 (struct lang_decl): Likewise.
3075 2010-06-08 Tobias Burnus <burnus@net-b.de>
3078 * symbol.c (check_conflict): Move protected--external/procedure check ...
3079 * resolve.c (resolve_select_type): ... to the resolution stage.
3081 2010-06-07 Tobias Burnus <burnus@net-b.de>
3083 * options.c (gfc_handle_option): Fix -fno-recursive.
3085 2010-06-07 Tobias Burnus <burnus@net-b.de>
3087 * gfc-internals.texi (copyrights-gfortran): Fix copyright year format.
3088 * gfortran.texi (copyrights-gfortran): Ditto.
3090 2010-06-07 Joseph Myers <joseph@codesourcery.com>
3092 * lang.opt (fshort-enums): Define using Var and VarExists.
3093 * options.c (gfc_handle_option): Don't set flag_short_enums here.
3095 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
3096 Janus Weil <janus@gcc.gnu.org>
3099 * resolve.c (get_declared_from_expr): Move to before
3100 resolve_typebound_generic_call. Make new_ref and class_ref
3101 ignorable if set to NULL.
3102 (resolve_typebound_generic_call): Once we have resolved the
3103 generic call, check that the specific instance is that which
3104 is bound to the declared type.
3105 (resolve_typebound_function,resolve_typebound_subroutine): Avoid
3106 freeing 'class_ref->next' twice.
3108 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
3111 * trans-array.c (structure_alloc_comps): Dereference scalar
3112 'decl' if it is a REFERENCE_TYPE. Tidy expressions containing
3115 2010-06-04 Joseph Myers <joseph@codesourcery.com>
3117 * gfortranspec.c (append_arg, lang_specific_driver): Use
3118 GCC-specific formats in diagnostics.
3120 2010-06-02 Tobias Burnus <burnus@net-b.de>
3123 * parse.c (gfc_fixup_sibling_symbols): Do not "fix" use-associated
3126 2010-06-01 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3129 * match.c (gfc_match_stopcode): Move gfc_match_eos call inside
3132 2010-05-31 Steven G. Kargl <kargl@gcc.gnu.org>
3134 * fortran/gfortran.texi: Fix typos in description of variable-format-
3137 2010-05-31 Thomas Koenig <tkoenig@gcc.gnu.org>
3140 * dependency.c (gfc_check_section_vs_section): Check
3141 for interleaving array assignments without conflicts.
3143 2010-05-30 Janus Weil <janus@gcc.gnu.org>
3145 * gcc/fortran/gfortran.h (CLASS_DATA): New macro for accessing the
3146 $data component of a class container.
3147 * gcc/fortran/decl.c (attr_decl1): Use macro CLASS_DATA.
3148 * gcc/fortran/expr.c (gfc_check_pointer_assign,gfc_check_assign_symbol,
3149 gfc_has_ultimate_allocatable,gfc_has_ultimate_pointer): Ditto.
3150 * gcc/fortran/interface.c (matching_typebound_op): Ditto.
3151 * gcc/fortran/match.c (gfc_match_allocate, gfc_match_deallocate): Ditto.
3152 * gcc/fortran/parse.c (parse_derived): Ditto.
3153 * gcc/fortran/primary.c (gfc_match_varspec, gfc_variable_attr,
3154 gfc_expr_attr): Ditto.
3155 * gcc/fortran/resolve.c (resolve_structure_cons, find_array_spec,
3156 resolve_deallocate_expr, resolve_allocate_expr, resolve_select_type,
3157 resolve_fl_var_and_proc, resolve_typebound_procedure,
3158 resolve_fl_derived): Ditto.
3159 * gcc/fortran/symbol.c (gfc_type_compatible): Restructured.
3160 * gcc/fortran/trans-array.c (structure_alloc_comps): Use macro
3162 * gcc/fortran/trans-decl.c (gfc_get_symbol_decl,
3163 gfc_trans_deferred_vars): Ditto.
3164 * gcc/fortran/trans-stmt.c (gfc_trans_allocate): Ditto.
3166 2010-05-28 Tobias Burnus <burnus@net-b.de>
3168 * options.c (gfc_handle_option): Fix handling of -fno-whole-file.
3170 2010-05-28 Joseph Myers <joseph@codesourcery.com>
3172 * gfortranspec.c (append_arg, lang_specific_driver): Use
3173 fatal_error instead of fatal. Use warning instead of fprintf for
3176 2010-05-28 Joseph Myers <joseph@codesourcery.com>
3178 * cpp.c (gfc_cpp_init_0): Use xstrerror instead of strerror.
3179 * module.c (write_char, gfc_dump_module, gfc_use_module): Use
3180 xstrerror instead of strerror.
3182 2010-05-26 Joseph Myers <joseph@codesourcery.com>
3184 * cpp.c (cb_cpp_error): Save and restore
3185 global_dc->warn_system_headers, not variable warn_system_headers.
3187 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
3189 * fortran/f95-lang.c: Do not include libfuncs.h, expr.h, and except.h.
3191 2010-05-26 Steven Bosscher <steven@gcc.gnu.org>
3193 * trans-common.c: Do not include rtl.h, include output.h instead.
3194 * trans-decl.c: Likewise.
3196 2010-05-26 Paul Thomas <pault@gcc.gnu.org>
3199 * resolve.c (resolve_global_procedure): Resolve the gsymbol's
3200 namespace before trying to reorder the gsymbols.
3202 2010-05-25 Daniel Franke <franke.daniel@gmail.com>
3207 * resolve.c (resolve_global_procedure): Add check for global
3208 procedures with implicit interfaces and assumed-shape or optional
3209 dummy arguments. Verify that function return type, kind and string
3212 2010-05-21 Tobias Burnus <burnus@net-b.de>
3214 * gfortran.h: Do not include system.h.
3215 * bbt.c: Include system.h.
3217 * dependency.c: Ditto.
3218 * dump-parse-tree.c: Ditto.
3219 * arith.h: Do not include gfortran.h.
3220 * constructor.h: Do not include gfortran.h and splay-tree.h.
3221 * match.h: Do not include gfortran.h.
3223 * target-memory.h: Ditto.
3224 * openmp.c: Do not include toplev.h and target.h.
3225 * trans-stmt.c: Ditto not include toplev.h.
3227 * trans-common.c: Tell why toplev.h is needed. And
3228 do not include target.h.
3229 * trans-expr.c: Tell why toplev.h is needed.
3230 * trans-array.c: Ditto.
3231 * trans-openmp.c: Ditto.
3232 * trans-const.c: Ditto.
3234 * trans-types.c: Ditto.
3235 * trans-io.c: Ditto.
3236 * trans-decl.c: Ditto.
3239 * trans-intrinsic.c: Ditto.
3242 2010-05-22 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3245 * match.c (gfc_match_stopcode): Use gfc_match_init_expr. Go to cleanup
3246 before returning MATCH_ERROR. Add check for scalar. Add check for
3247 default integer kind.
3249 2010-05-22 Janus Weil <janus@gcc.gnu.org>
3252 * match.c (gfc_match_select_type): On error jump back out of the local
3254 * parse.c (parse_derived): Defer creation of vtab symbols to resolution
3255 stage, more precisely to ...
3256 * resolve.c (resolve_fl_derived): ... this place.
3258 2010-05-22 Janus Weil <janus@gcc.gnu.org>
3261 * resolve.c (ensure_not_abstract): Allow abstract types with
3262 non-abstract ancestors.
3264 2010-05-21 Steven Bosscher <steven@gcc.gnu.org>
3266 * trans-const.c: Include realmpfr.h.
3267 * Make-lang.in: Update dependencies.
3269 2010-05-21 Steven Bosscher <steven@gcc.gnu.org>
3271 * trans-const.c, trans-types.c, trans-intrinsic.c:
3272 Clean up redundant includes.
3274 2010-05-20 Daniel Franke <franke.daniel@gmail.com>
3277 * lang.opt (Wunused-dummy-argument): New option.
3278 * gfortran.h (gfc_option_t): Add warn_unused_dummy_argument.
3279 * options.c (gfc_init_options): Disable warn_unused_dummy_argument.
3280 (set_Wall): Enable warn_unused_dummy_argument.
3281 (gfc_handle_option): Set warn_unused_dummy_argument according to
3283 * trans-decl.c (generate_local_decl): Separate warnings about
3284 unused variables and unused dummy arguments.
3285 * invoke.texi: Documented new option.
3287 2010-05-20 Steven Bosscher <steven@gcc.gnu.org>
3289 * trans-expr.c: Do not include convert.h, ggc.h, real.h, and gimple.h.
3290 (gfc_conv_string_tmp): Do not assert type comparibilty.
3291 * trans-array.c: Do not include gimple.h, ggc.h, and real.h.
3292 (gfc_conv_expr_descriptor): Remove assert.
3293 * trans-common.c: Clarify why rtl.h and tm.h are included.
3294 * trans-openmp.c: Do not include ggc.h and real.h.
3295 Explain why gimple.h is included.
3296 * trans-const.c: Do not include ggc.h.
3297 * trans-stmt.c: Do not include gimple.h, ggc.h, and real.h.
3298 * trans.c: Do not include ggc.h and real.h.
3299 Explain why gimple.h is included.
3300 * trans-types.c: Do not include tm.h. Explain why langhooks.h
3301 and dwarf2out.h are included.
3302 * trans-io.c: Do not include gimple.h and real.h.
3303 * trans-decl.c: Explain why gimple.h, tm.h, and rtl.h are included.
3304 * trans-intrinsic.c: Do not include gimple.h. Explain why tm.h
3307 2010-05-20 Tobias Burnus <burnus@net-b.de>
3309 * options.c (gfc_init_options,gfc_post_options): Enable
3310 flag_associative_math by default.
3312 2010-05-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3315 * trans-stmt.c (gfc_trans_stop): Add generation of call to
3316 gfortran_error_stop_numeric. Fix up some whitespace. Use stop_string for
3317 blank STOP, handling a null expression. (gfc_trans_pause): Use
3318 pause_string for blank PAUSE.
3319 * trans.h: Add external function declaration for error_stop_numeric.
3320 * trans-decl.c (gfc_build_builtin_function_decls): Add the building of
3321 the declaration for the library call. Adjust whitespaces.
3322 * match.c (gfc_match_stopcode): Remove use of the actual stop code to
3323 signal no stop code. Match the expression following the stop and pass
3324 that to the translators. Remove the old use of digit matching. Add
3325 checks that the stop_code expression is INTEGER or CHARACTER, constant,
3326 and if CHARACTER, default character KIND.
3328 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
3331 * lang.opt (Wconversion-extra): New option.
3332 * gfortran.h (gfc_option_t): Add warn_conversion_extra.
3333 * options.c (gfc_init_options): Disable -Wconversion-extra by default.
3334 (set_Wall): Enable -Wconversion.
3335 (gfc_handle_option): Set warn_conversion_extra.
3336 * intrinsic.c (gfc_convert_type_warn): Ignore kind conditions
3337 introduced for -Wconversion if -Wconversion-extra is present.
3338 * invoke.texi: Add -Wconversion to -Wall; document new behaviour of
3339 -Wconversion; document -Wconversion-extra.
3341 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
3344 * gfortran.h (gfc_has_default_initializer): New.
3345 * expr.c (gfc_has_default_initializer): New.
3346 * resolve.c (has_default_initializer): Removed, use
3347 gfc_has_default_initializer() instead. Updated all callers.
3348 * trans-array.c (has_default_initializer): Removed, use
3349 gfc_has_default_initializer() instead. Updated all callers.
3350 * trans-decl.c (generate_local_decl): Do not check the
3351 first component only to check for initializers, but use
3352 gfc_has_default_initializer() instead.
3354 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
3357 * primary.c (match_string_constant): Move start_locus just inside
3359 * data.c (create_character_intializer): Clarified truncation warning.
3361 2010-05-19 Daniel Franke <franke.daniel@gmail.com>
<