1 2010-12-02 Jakub Jelinek <jakub@redhat.com>
4 * trans-openmp.c (gfc_trans_omp_do): Use build2_loc instead of
5 fold_build2_loc for OMP_FOR conditions.
7 2010-11-30 Janne Blomqvist <jb@gcc.gnu.org>
10 * trans-array.c (gfc_unlikely): Helper function to mark boolean
12 (gfc_array_index_size): Check whether the size overflows.
13 (gfc_array_allocate): Check whether size overflows and generate
16 2010-11-30 Joseph Myers <joseph@codesourcery.com>
18 * trans-common.c: Don't include toplev.h.
20 2010-11-29 Joseph Myers <joseph@codesourcery.com>
22 * gfortran.h (alloca): Don't include definitions.
25 2010-11-28 Janus Weil <janus@gcc.gnu.org>
28 * resolve.c (update_ppc_arglist): Add check for abstract passed object.
30 2010-11-28 Paul Thomas <pault@gcc.gnu.org>
33 * trans-array.c (gfc_trans_array_constructor): If the loop->to
34 is a VAR_DECL, assume this is dynamic. In this case, use the
35 counter to obtain the value and set loop->to appropriately.
36 (gfc_conv_ss_descriptor): Always save the offset of a variable
38 (gfc_conv_ss_startstride): Do not attempt bound checking of the
39 lhs of an assignment, if allocatable and f2003 is allowed.
40 (gfc_conv_loop_setup): If possible, do not use an allocatable
41 lhs variable for the loopspec.
42 (gfc_is_reallocatable_lhs): New function.
43 (get_std_lbound): New function.
44 (gfc_alloc_allocatable_for_assignment): New function.
45 * gfortran.h : Add flag_realloc_lhs to the options structure.
46 * lang.opt : Add option f(no-)realloc-lhs.
47 * invoke.texi : Document option f(no-)realloc-lhs.
48 * options.c (gfc_init_options, gfc_post_options,
49 gfc_handle_option): Incorporate f(no-)realloc-lhs with default
50 to frealloc_lhs for -std > f95.
51 * trans-array.h : Add primitive for previous.
52 * trans-expr.c (gfc_conv_string_length): Return if character
53 length is a variable and the expression is NULL.
54 (gfc_conv_procedure_call): If the call is of the kind x = f(...)
55 and the lhs is allocatable and reallocation on assignment OK,
56 call gfc_alloc_allocatable_for_assignment. Do not generate the
57 function call unless direct by reference.
58 (realloc_lhs_loop_for_fcn_call): New function.
59 (realloc_lhs_bounds_for_intrinsic_call): New function.
60 (gfc_trans_arrayfunc_assign): Reallocation assignments need
61 a loopinfo and for the loop bounds to be set. With intrinsic
62 functions, free the lhs data and let the library allocate the
63 data array. Done by the new functions above.
64 (gfc_trans_assignment_1): If the lhs is allocatable and
65 reallocation on assignment is allowed, mark the lhs and use
66 gfc_alloc_allocatable_for_assignment to make the reallocation.
67 * trans.h : Add is_alloc_lhs bitfield to gfc_ss structure.
69 2010-11-27 Tobias Burnus <burnus@net-b.de>
70 Jerry DeLisle <jvdelisle@gcc.gnu.org>
73 trans-decl.c (gfc_trans_auto_character_variable): Use gfc_init_block
74 instead of gfc_start_block.
76 2010-11-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
79 trans-expr.c (gfc_trans_assignment): Add error message for not
80 implemented assignment to deferred-length character variable.
82 2010-11-26 Jakub Jelinek <jakub@redhat.com>
85 * trans.h (build1_stat_loc, build2_stat_loc, build3_stat_loc,
86 build4_stat_loc): Removed.
87 (build1_loc, build2_loc, build3_loc, build4_loc): Removed.
89 2010-11-25 Janus Weil <janus@gcc.gnu.org>
92 * trans.h (gfc_process_block_locals): Removed second argument.
93 * trans-decl.c (trans_associate_var): Moved to trans-stmt.c.
94 (gfc_trans_deferred_vars): Skip ASSOCIATE variables.
95 (gfc_process_block_locals): Don't mark associate names to be
97 * trans-stmt.c (trans_associate_var): Moved here from trans-decl.c.
98 (gfc_trans_block_construct): Call 'trans_associate_var' from here
99 to make sure SELECT TYPE with associate-name is treated correctly.
101 2010-11-24 Tobias Burnus <burnus@net-b.de>
104 * target-memory.c (gfc_interpret_derived): Correctly handle
107 2010-11-23 Tobias Burnus <burnus@net-b.de>
110 * gfortran.texi (KIND Type Parameters): Quadmath and F2008 changes.
112 2010-11-22 Michael Matz <matz@suse.de>
114 * gfortranspec.c (library): New global, moved from ...
115 (lang_specific_driver): ... here.
116 (lang_specific_pre_link): Test it here before including
119 2010-11-21 Michael Matz <matz@suse.de>
120 Tobias Burnus <burnus@net-b.de>
123 * gfortranspec.c (lang_specific_driver,
124 lang_specific_pre_link): Load libgfortran.spec in
125 lang_specific_pre_link unless found in the -L path.
127 2010-11-20 Janne Blomqvist <jb@gcc.gnu.org>
129 * f95-lang.c (gfc_init_decl_processing): Set size_type_node as
130 unsigned int of pointer size and set sizetype based on that.
131 * trans-types.c (gfc_init_types): Don't set size_type_node to an
134 2010-11-17 Joseph Myers <joseph@codesourcery.com>
136 * f95-lang.c (gfc_be_parse_file): Take no arguments.
138 2010-11-16 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
139 Tobias Burnus <burnus@net-b.de>
142 * gfortranspec.c (find_spec_file): New function.
143 (lang_specific_driver): Try to find .spec file and use it.
144 * trans-io.c (iocall): Define IOCALL_X_REAL128/COMPLEX128(,write).
145 (gfc_build_io_library_fndecls): Build decl for __float128 I/O.
146 (transfer_expr): Call __float128 I/O functions.
147 * trans-types.c (gfc_init_kinds): Allow kind-16 belonging
150 2010-11-15 Tobias Burnus <burnus@net.b.de>
153 * check.c (variable_check): Don't treat functions calls as variables;
154 optionally accept function themselves.
155 (gfc_check_all_any, gfc_check_loc, gfc_check_move_alloc,
156 gfc_check_null, gfc_check_present, gfc_check_cpu_time,
157 gfc_check_date_and_time, gfc_check_mvbits, gfc_check_random_number,
158 gfc_check_random_seed, gfc_check_system_clock,
159 gfc_check_dtime_etime, gfc_check_dtime_etime_sub,
160 gfc_check_itime_idate,gfc_check_ltime_gmtime): Update call.
162 2010-11-13 Tobias Burnus <burnus@net-b.de>
165 * trans-common.c (build_field): Add TREE_SIDE_EFFECTS for volatile.
166 * trans-decl.c (gfc_finish_var_decl): Ditto.
167 (create_function_arglist): Handle volatile dummy arguments.
169 2010-11-12 Joseph Myers <joseph@codesourcery.com>
171 * Make-lang.in (gfortranspec.o): Use $(OPTS_H).
172 * gfortran.h (gfc_handle_option): Take location_t parameter.
173 * options.c (gfc_handle_option): Take location_t parameter.
175 2010-11-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
178 trans-expr.c (gfc_conv_procedure_call): Avoid NULL array spec.
180 2010-11-11 Nathan Froyd <froydnj@codesourcery.com>
183 * options.c (gfc_post_options): Initialize gfc_option.max_errors.
184 (gfc_handle_option) [OPT_fmax_errors_]: Remove.
185 * lang.opt (fmax-errors=): Remove.
187 2010-11-11 Steven G. Kargl <kargl@gcc.gnu.org>
189 * symbol.c (verify_bind_c_derived_type): Accept BIND(C) on an empty
192 2010-11-11 Jan Hubicka <jh@suse.cz>
194 * options.c (gfc_post_options): Remove flag_whopr.
196 2010-11-11 Tobias Burnus <burnus@net-b.de>
199 * resolve.c (resolve_transfer): Reject I/O transfer of
203 * resolve.c (resolve_code): Reject nonscalar FORALL masks.
205 2010-11-11 Janus Weil <janus@gcc.gnu.org>
207 * resolve.c (resolve_procedure_interface): Copy 'is_bind_c' attribute.
209 2010-11-10 Joseph Myers <joseph@codesourcery.com>
211 * trans-array.c (gfc_trans_deferred_array): Use "front-end"
212 spelling in diagnostic.
213 * trans.c (gfc_allocate_array_with_status): Add missing space in
216 2010-11-10 Joseph Myers <joseph@codesourcery.com>
218 * cpp.c (asm_file_name): Don't declare here.
220 2010-11-10 Tobias Burnus <burnus@net-b.de>
223 * intrinsic.c (gfc_intrinsic_sub_interface): Check for attr.pure
224 and not for attr.elemental.
225 * intrinsic.texi (move_alloc): Document as being pure.
227 2010-11-10 Tobias Burnus <burnus@net-b.de>
230 * resolve.c (resolve_fl_derived): Don't allow CLASS in
231 sequence/BIND(C) types.
233 2010-11-09 Jerry DeLisle <jvdelisle@gcc.gnu.org>
234 Mikael Morin <mikael@gcc.gnu.org>
237 * intrinsic.c: Correctly set the pure attributes for intrinsic
239 * expr.c (check_specification_function): Remove this function and move
240 its code into gfc_is_constant_expr. (gfc_is_constant_expr): Change the
241 order of checks by checking for non-constant arguments first. Then,
242 check for initialization functions, followed by intrinsics.
244 2010-11-09 Janus Weil <janus@gcc.gnu.org>
247 * gfortran.h (gfc_add_data_component,gfc_add_vptr_component,
248 gfc_add_hash_component,gfc_add_size_component,
249 gfc_add_def_init_component): New macros.
250 * class.c (gfc_add_component_ref): Renamed data component.
251 (get_unique_type_string): New function.
252 (gfc_build_class_symbol): Use 'get_unique_type_string' to construct
253 uniques names for the class containers. Rename components.
254 (gfc_find_derived_vtab): Use 'get_unique_type_string' to construct
255 uniques names for the vtab symbols. Rename components.
256 * decl.c (attr_decl1): Renamed class container components.
257 * iresolve.c (gfc_resolve_extends_type_of): Ditto.
258 * match.c (select_type_set_tmp): Renamed temporaries.
259 * module.c (read_module): Renamed vtab and vtype symbols.
260 * resolve.c (resolve_structure_cons,resolve_typebound_function,
261 resolve_typebound_subroutine,resolve_deallocate_expr,
262 resolve_select_type,resolve_fl_derived): Renamed class container and
264 * trans-array.c (structure_alloc_comps): Ditto.
265 * trans-decl.c (gfc_trans_deferred_vars): Ditto.
266 * trans-expr.c (gfc_conv_derived_to_class,gfc_conv_structure,
267 gfc_trans_class_init_assign,gfc_trans_class_assign): Ditto.
268 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof,
269 gfc_conv_intrinsic_storage_size,gfc_conv_allocated,gfc_conv_associated,
270 gfc_conv_same_type_as): Ditto.
271 * trans-stmt.c (gfc_trans_allocate): Ditto.
273 2010-11-08 Jerry DeLisle <jvdelisle@gcc.gnu.org>
276 * trans-decl.c (generate_local_decl): Do not generate unused warning
277 for variables in namelists.
279 2010-11-08 Janus Weil <janus@gcc.gnu.org>
282 * decl.c (build_struct): Build vtab immediately if derived type
283 has already been declared.
285 2010-11-08 Janus Weil <janus@gcc.gnu.org>
288 * trans-types.c (gfc_copy_dt_decls_ifequal): Handle CLASS components.
290 2010-11-06 Janus Weil <janus@gcc.gnu.org>
293 * trans-expr.c (gfc_trans_class_assign): Find 'vtab' symbol in correct
296 2010-11-05 Janus Weil <janus@gcc.gnu.org>
300 * class.c (gfc_find_derived_vtab): Improved search for existing vtab.
301 Add component '$copy' to vtype symbol for polymorphic deep copying.
302 * expr.c (gfc_check_pointer_assign): Make sure the vtab is generated
303 during resolution stage.
304 * resolve.c (resolve_codes): Don't resolve code if namespace is already
306 * trans-stmt.c (gfc_trans_allocate): Call '$copy' procedure for
307 polymorphic ALLOCATE statements with SOURCE.
309 2010-11-03 Thomas Koenig <tkoenig@gcc.gnu.org>
310 Paul Thomas <pault@gcc.gnu.org>
312 * dump-parse-tree.c (code_indent): Take label into acount
313 when calculating indent.
314 (show_typespec): Also display class.
315 (show_attr): Add module name to argument.
316 Don't show UNKNOWN for flavor, access and save. Don't show
317 SAVE_NONE. Don't show INTENT_UNKNOWN. Show module for use
318 association. Show intent only for dummy arguments.
319 Set length of shown symbol names to minimum of 12.
320 Show attributes header.
321 (show_symbol): Adjust show_level.
322 (show_symtree): Clear up display for ambiguous. Show if symbol
323 was imported from namespace.
324 (show_code_node): Clear up indenting. Traverse symtree and
325 show code directly instead of calling show_namespace.
327 2010-11-02 Nathan Froyd <froydnj@codesourcery.com>
329 * trans-decl.c (add_argument_checking): Use build_zero_cst instead of
331 * trans-expr.c (gfc_conv_missing_dummy, fill_with_spaces): Likewise.
332 * trans-stmt.c (gfc_trans_do): Likewise.
334 2010-11-02 Steven G. Kargl < kargl@gcc.gnu.org>
335 Tobias Burnus <burnus@net-b.de>
338 * array.c (gfc_match_array_constructor): Reject deferred type
339 parameter (DTP) in type-spec.
340 * decl.c (char_len_param_value, match_char_length,
341 gfc_match_char_spec, build_sym, variable_decl,
342 enumerator_decl): Support DTP.
343 * expr.c (check_inquiry): Fix check due to support for DTP.
344 * gfortran.h (gfc_typespec): Add Boolean 'deferred'.
345 * misc.c (gfc_clear_ts): Set it to false.
346 * match.c (gfc_match_allocate): Support DTP.
347 * resolve.c (resolve_allocate_expr): Not-implemented error for DTP.
348 (resolve_fl_variable): Add DTP constraint check.
349 * trans-decl.c (gfc_trans_deferred_vars): Add not-implemented
352 2010-11-01 Steven G. Kargl <kargl@gcc.gnu.org>
355 * fortran/match.c (match_derived_type_spec): Reoplace gfc_match_symbol
356 with a gfc_find_symbol to prevent namespace pollution. Remove dead
358 (match_type_spec): Remove parsing of '::'. Collapse character
359 kind checking to one location.
360 (gfc_match_allocate): Use correct locus in error message.
362 2010-10-30 Thomas Koenig <tkoenig@gcc.gnu.org>
364 * gfortran.h (gfc_option_t): Replace dump_parse_tree by
365 dump_fortran_original and add dump_fortran_optimized.
366 * lang.opt: Add fdump-fortran-original and
367 fdump-fortran-optimized. Document that fdump-parse-tree is
369 * gfortran.texi: Add -fdump-fortran-original and
370 -fdump-fortran-optimized. -fdump-parse-tree is deprecated.
371 * frontend-passes.c (gfc_run_passes): If optimizing and
372 if gfc_option.dump_fortran_optimized is set, dump the parse tree
374 * parse.c: Rename gfc_option.dump_parse_tree to
375 gfc_option.dump_fortran_original.
376 * options.c (gfc_init_options): Rename gfc_option.dump_parse_tree
377 to gfc_option.dump_fortran_original and handle
378 gfc_option.dump_fortran_optimize.
379 (gfc_post_options): Rename gfc_option.dump_parse_tree
380 to gfc_option.dump_fortran_original.
381 (gfc_handle_option): Rename OPT_fdump_parse_tree to
382 OPT_fdump_fortran_original and gfc_option.dump_parse_tree
383 to gfc_option.dump_fortran_original. Handle
384 OPT_fdump_fortran_optimized.
386 2010-10-30 Janus Weil <janus@gcc.gnu.org>
391 * interface.c (count_types_test): Symmetrize type check.
392 (generic_correspondence): Ditto.
394 2010-10-27 Janus Weil <janus@gcc.gnu.org>
397 * interface.c (compare_allocatable): Handle polymorphic allocatables.
398 (compare_parameter): Add two error messages for polymorphic dummies.
400 2010-10-26 Janus Weil <janus@gcc.gnu.org>
403 * trans.h (gfc_deallocate_scalar_with_status): New prototype.
404 * trans.c (gfc_deallocate_scalar_with_status): New function for
405 deallocation of allocatable scalars.
406 * trans-array.c (structure_alloc_comps): Call it here ...
407 * trans-decl.c (gfc_trans_deferred_vars): ... here ...
408 * trans-stmt.c (gfc_trans_deallocate): ... and here.
410 2010-10-26 Tobias Burnus <burnus@net-b.de>
413 * trans-stmt.c (gfc_trans_allocate): Do a deep-copy for SOURCE=.
416 * trans-array.c (duplicate_allocatable): Use size of type and not
417 the size of the pointer to the type.
419 2010-10-25 Steven G. Kargl <kargl@gcc.gnu.org>
422 * fortran/scanner.c (include_line): Check return value of load_file.
424 2010-10-23 Tobias Burnus <burnus@net-b.de>
427 * expr.c (gfc_check_vardef_context): Fix PROTECTED check.
429 2010-10-21 Janus Weil <janus@gcc.gnu.org>
432 * match.h (gfc_matching_ptr_assignment): New global variable to indicate
433 we're currently matching a (non-proc-)pointer assignment.
434 * decl.c (match_pointer_init): Set it.
435 * match.c (gfc_match_pointer_assignment): Ditto.
436 * primary.c (matching_actual_arglist): New global variable to indicate
437 we're currently matching an actual argument list.
438 (gfc_match_actual_arglist): Set it.
439 (gfc_match_varspec): Reject procedure pointer component calls with
440 missing argument list.
442 2010-10-21 Janus Weil <janus@gcc.gnu.org>
445 * interface.c (gfc_compare_interfaces): Switch arguments of type
446 comparison (important for polymorphic variables).
448 2010-10-21 Tobias Burnus <burnus@net-b.de>
451 * expr.c (gfc_check_vardef_context): Treat pointer functions
454 2010-10-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
457 * trans_stmt.c (gfc_trans_stop): Fix whitespace. Build a call to new
458 F08 numeric stop function.
459 * trans.h: Add declaration for gfor_fndecl_stop_numeric_f08.
460 * trans-decl.c (gfc_build_builtin_function_decls): Build declaration
461 for stop_numeric_f08.
463 2010-10-18 Jerry DeLisle <jvdelisle@gcc.gnu.org>
465 * gfortran.h: Remove definition of bt enumerator.
466 * libgfortran.h: Add bt enumerator type alighned with defintion.
467 Remove the dtype enumerator, no longer used.
468 previously given in libgfortran/io.h
469 * trans-types.c: Use new bt enumerator.
470 * trans-io.c: Likewise.
472 2010-10-16 Thomas Koenig <tkoenig@gcc.gnu.org>
474 * trans-io.c (gfc_build_io_library_fndecls):
475 Array descriptor arguments to transfer_array can be
476 dereferenced recursively.
478 2010-10-16 Thomas Koenig <tkoenig@gcc.gnu.org>
483 * trans-io.c (enum iocall): Add IOCALL_X_INTEGER_WRITE,
484 IOCALL_X_LOGICAL_WRITE, IOCALL_X_CHARACTER_WRITE,
485 IOCALL_X_CHARACTER_WIDE_WRIE, IOCALL_X_REAL_WRITE,
486 IOCALL_X_COMPLEX_WRITE and IOCALL_X_ARRAY_WRITE.
487 (gfc_build_io_library_fndecls): Add corresponding function
489 (transfer_expr): If the current transfer is a READ, use
490 the iocall with the original version, otherwise the version
492 (transfer_array_desc): Likewise.
494 2010-10-15 Tobias Burnus <burnus@net-b.de>
497 * trans.h (gfc_add_modify_loc, gfc_evaluate_now_loc): New prototypes.
498 (gfc_trans_runtime_error_vararg): Remove prototype.
499 * trans.c (gfc_add_modify_loc, gfc_evaluate_now_loc): New functions.
500 (gfc_add_modify, gfc_evaluate_now): Use them.
501 (trans_runtime_error_vararg): Renamed from
502 gfc_trans_runtime_error_vararg, made static and use locus.
503 (gfc_trans_runtime_error): Use it.
504 (gfc_trans_runtime_check): Ditto and make use of locus.
505 * trans-stmt.c (gfc_trans_if_1, gfc_trans_simple_do,
506 gfc_trans_do, gfc_trans_do_while): Improve line number
507 associated with generated expressions.
509 2010-10-12 Daniel Kraft <d@domob.eu>
512 * parse.c (parse_associate): Set typespec of associate-name if that of
513 the target is already available.
515 2010-10-10 Janus Weil <janus@gcc.gnu.org>
518 * resolve.c (resolve_typebound_function): Bugfix for type-bound
521 2010-10-09 Thomas Koenig <tkoenig@gcc.gnu.org>
523 * frontend-passes.c: Include opts.h.
524 (optimize_comparison): Renamed from optimize_equality.
525 Change second argument to operation to be compared.
526 Use flag_finite_math_only to avoid comparing REAL and
527 COMPLEX only when NANs are honored. Simplify comparing
528 of string concatenations where left or right operands are
529 equal. Simplify all comparison operations, based on the result
530 of gfc_dep_compare_expr.
531 * dependency.c: Include arith.h.
532 (gfc_are_identical_variables): Volatile variables should not
533 compare equal to themselves.
534 (gfc_dep_compare_expr): Handle string constants and string
537 2010-10-08 Joseph Myers <joseph@codesourcery.com>
539 * f95-lang.c (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
540 * gfortran.h (gfc_init_options_struct): Declare.
541 * options.c (gfc_init_options_struct): New. Split out from
544 2010-10-07 Janus Weil <janus@gcc.gnu.org>
547 * resolve.c (resolve_typebound_function): Use correct declared type
548 for type-bound operators.
550 2010-10-07 Mikael Morin <mikael@gcc.gnu.org>
553 Revert revision 165026:
554 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
556 * decl.c (match_procedure_in_type): Assertify if conditions.
558 2010-10-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
561 * resolve.c (resolve_transfer): Use expression inside parenthesis to
562 find acutal component to be transgferred.
564 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
566 * trans-stmt.c (gfc_trans_allocate): free lhs expr.
568 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
570 * trans-array.c (gfc_free_ss_chain): Made non-static.
571 * trans-array.h (gfc_free_ss_chain): New prototype.
572 * trans-stmt.c (gfc_trans_where_2): Free ss chains.
574 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
576 * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Also free symbol's
579 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
581 * trans-stmt.c (gfc_trans_forall_1): Free forall struct at the end.
583 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
585 * trans-expr.c (get_proc_ptr_comp): Restore initial expression type
586 before calling gfc_free_expr.
588 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
590 * trans-array.c (gfc_conv_tmp_array_ref): Add factorized call to
591 gfc_advance_se_ss_chain.
592 * trans-expr.c (gfc_conv_subref_array_ref, gfc_conv_procedure_call,
593 gfc_conv_array_constructor_expr, gfc_trans_assignment_1): Remove
594 calls to gfc_advance_se_ss_chain after gfc_conv_tmp_array_ref.
595 * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
596 * trans-stmt.c (gfc_trans_where_assign, gfc_trans_where_3): Ditto.
598 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
600 * trans.c (gfc_restore_backend_locus): New function.
601 (gfc_get_backend_locus): Renamed to ...
602 (gfc_save_backend_locus): ... this.
603 * trans.h (gfc_restore_backend_locus, gfc_get_backend_locus,
604 gfc_save_backend_locus): Same.
605 * trans-array.c (gfc_trans_g77_array, gfc_trans_dummy_array_bias,
606 gfc_trans_deferred_array): Rename gfc_get_backend_locus to
607 gfc_save_backend_locus.
608 (gfc_trans_dummy_array_bias): Call gfc_restore_backend_locus at the
610 (gfc_trans_g77_array, gfc_trans_deferred_array): Use
611 gfc_restore_backend_locus instead of gfc_set_backend_locus.
612 (gfc_trans_deferred_array): Call gfc_restore_backend_locus on early
614 * trans-decl.c (gfc_get_extern_function_decl, build_entry_thunks,
615 gfc_trans_deferred_vars):
616 Rename gfc_get_backend_locus to gfc_save_backend_locus.
617 Use gfc_restore_backend_locus insted of gfc_set_backend_locus.
619 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
621 * trans-array.c (gfc_build_constant_array_constructor): Free array
624 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
626 * symbol.c (gfc_copy_formal_args_ppc): Free previous formal arg list
627 before overwriting it.
629 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
631 * array.c (gfc_match_array_spec): Don't re-initialize cleared struct.
632 * symbol.c (gen_shape_param): Ditto.
634 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
636 * symbol.c (free_entry_list): New function.
637 (gfc_free_namespace): Free list of entries.
639 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
641 * symbol.c (free_components): Free list of formal args and formal
644 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
646 * simplify.c (gfc_simplify_size): Clear temporary mpz int before
649 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
651 * resolve.c (add_dt_to_dt_list): Remove unneeded if.
653 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
655 * resolve.c (check_typebound_baseobject): Free local expr before
658 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
660 * primary.c (gfc_match_structure_constructor): Invert the assert logic.
662 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
664 * primary.c (gfc_free_structure_ctor_component): Also free the
665 component structure itself.
667 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
669 * module.c (gfc_use_module): Free atom_string when done with it.
671 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
673 * module.c (read_module): Remove useless string duplication.
675 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
677 * gfortranspec.c (append_arg): Remove commented code.
679 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
681 * decl.c (match_procedure_in_type): Assertify if conditions.
683 2010-10-06 Mikael Morin <mikael@gcc.gnu.org>
685 * cpp.c (gfc_cpp_post_options): Don't create a cpp reader if
686 preprocessing is disabled.
688 2010-10-06 Jakub Jelinek <jakub@redhat.com>
691 * f95-lang.c (ATTR_NOTHROW_LEAF_LIST, ATTR_CONST_NOTHROW_LEAF_LIST,
692 ATTR_NOTHROW_LIST, ATTR_CONST_NOTHROW_LIST): Define.
693 (gfc_define_builtin): Change last argument to int bitmask from bool,
694 control addition of TREE_NOTHROW and leaf attribute as well.
695 (DO_DEFINE_MATH_BUILTIN): Adjust callers.
696 (gfc_init_builtin_functions): Likewise. Remove
697 ATTR_{,CONST_}NOTHROW_LIST enum.
699 2010-10-04 Andi Kleen <ak@linux.intel.com>
701 * Make-lang.in (gfortran, f951): Add + to build rule.
703 2010-10-04 Richard Guenther <rguenther@suse.de>
705 * f95-lang.c (current_translation_unit): New global variable.
706 (gfc_create_decls): Build a translation-unit decl.
707 (pushdecl): In the global binding-level use the
708 translation-unit decl as DECL_CONTEXT.
709 * trans-decl.c (gfc_get_symbol_decl): Use DECL_FILE_SCOPE_P.
710 (build_function_decl): Likewise. Delay setting the assembler
711 name, leave setting of DECL_CONTEXT to pushdecl.
712 (trans_function_start): Use DECL_FILE_SCOPE_P.
713 (gfc_create_module_variable): Likewise. Remove questionable
715 * trans.c (gfc_generate_module_code): Likewise.
717 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
719 * cpp.c (cpp_define_builtins): Call functions from cppbuiltin.c
720 instead of duplicating code.
721 * Make-lang.in: Add dependency on cppbuiltin.h. Don't define
724 2010-10-02 Janus Weil <janus@gcc.gnu.org>
727 * resolve.c (resolve_formal_arglist): Avoid setting default type for
728 formal arguments of intrinsic procedures.
730 2010-09-30 Janus Weil <janus@gcc.gnu.org>
733 * resolve.c (resolve_allocate_expr): Do not use
734 'gfc_has_default_initializer'.
736 2010-09-30 Tobias Burnus <burnus@net-b.de>
738 * gfortran.tex (Fortran 2008 status): Update list of
739 implemented features.
741 2010-09-29 Joseph Myers <joseph@codesourcery.com>
743 * lang.opt: Don't use VarExists.
745 2010-09-29 Joseph Myers <joseph@codesourcery.com>
747 * cpp.c (cpp_define_builtins): Update names of gfc_option_t
749 (gfc_cpp_post_options): Update names of cpp_options members.
750 (cb_cpp_error): Update names of diagnostic_context members.
751 * f95-lang.c (gfc_init_builtin_functions): Update names of
752 gfc_option_t members.
753 * gfortran.h (gfc_option_t): Rename warn_conversion and
755 * intrinsic.c (gfc_convert_type_warn): Update names of
756 gfc_option_t members.
757 * options.c (gfc_init_options, gfc_post_options, set_Wall,
758 gfc_handle_option): Update names of gfc_option_t members.
759 * parse.c (next_free, next_fixed): Update names of gfc_option_t
761 * scanner.c (pedantic): Remove extern declaration.
762 (skip_free_comments, skip_fixed_comments, include_line): Update
763 names of gfc_option_t members.
764 * trans-decl.c (gfc_generate_function_code): Update names of
765 gfc_option_t members.
767 2010-09-28 Tobias Burnus <burnus@net-b.de>
771 * intrinsic.c (add_functions): Make compiler_version and
772 compiler_options CLASS_INQUIRY.
773 * gfortran.h (gfc_get_option_string): New prototype.
774 * intrinsic.texi (COMPILER_VERSION, COMPILER_OPTIONS):
776 (C_SIZEOF): Mark as inquiry function of ISO_C_BINDING.
777 (ISO_FORTRAN_ENV): Refer to COMPILER_VERSION and COMPILER_OPTIONS.
778 (ISO_C_BINDING): Refer to C_SIZEOF.
779 * options.c (gfc_get_option_string): New function.
780 * simplify.c (gfc_simplify_compiler_options): Use it.
781 (gfc_simplify_compiler_version): Include compiler name.
783 2010-09-28 Jan Hubicka <jh@suse.cz>
785 * f95-lang.c (gfc_define_builtin): Make leaf.
786 (gfc_init_builtin_functions): Handle only ATTR_CONST_NOTHROW_LEAF_LIST
787 and ATTR_NOTHROW_LEAF_LIST.
788 (DEF_SYNC_BUILTIN): Check ATTR_CONST_NOTHROW_LEAF_LIST.
789 (DEF_GOMP_BUILTIN): Likewise.
791 2010-09-28 Tobias Burnus <burnus@net-b.de>
794 * trans-decl.c (gfc_get_symbol_decl): Use gsym for decl of
797 2010-09-27 Tobias Burnus <burnus@net-b.de>
801 * intrinsic.h (gfc_simplify_compiler_options,
802 gfc_simplify_compiler_version): New prototypes.
803 * intrinsic.c (gfc_intrinsic_function_by_id,
804 make_from_module): New functions.
805 (gfc_find_function, gfc_find_subroutine, gfc_generic_intrinsic,
806 gfc_specific_intrinsic): Don't return module intrinsics.
807 (add_functions): Add compiler_options, compiler_version.
808 (gfc_intrinsic_func_interface): Also lookup symbol by ISYM ID.
809 * symbol.c (std_for_isocbinding_symbol): Add version check for
811 * iso-fortran-env.def: Add compiler_options, compiler_version.
812 * iso-c-binding.def: Add c_sizeof.
813 * gfortran.h (gfc_intrinsic_sym): Add from_module:1.
814 (iso_c_binding_symbol, iso_fortran_env_symbol): Add NAMED_FUNCTIONS.
815 (gfc_intrinsic_function_by_id): New prototype.
816 * module.c (create_intrinsic_function): New function.
817 (import_iso_c_binding_module, use_iso_fortran_env_module): Use it.
818 * trans-types.c (init_c_interop_kinds): Add NAMED_FUNCTIONS.
819 * resolve.c (resolve_intrinsic): Try also to resolve intrinsics
821 * simplify.c (gfc_simplify_compiler_options,
822 gfc_simplify_compiler_version): New functions.
824 2010-09-26 Daniel Kraft <d@domob.eu>
828 * resolve.c (resolve_select_type): Clarify code.
829 (resolve_assoc_var): Only set typespec if it is currently unknown.
831 2010-09-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
834 * module.c (create_int_parameter_array): Set the array value shape.
836 2010-09-25 Tobias Burnus <burnus@net-b.de>
838 * gfortran.texi: Re-add accidently removed \input line.
840 2010-09-25 Daniel Kraft <d@domob.eu>
843 * gfortran.h (struct gfc_dt): New member `dt_io_kind'.
844 * io.c (resolve_tag): F2008 check for NEWUNIT and variable
845 definition checks for NEWUNIT, IOSTAT, SIZE and IOMSG.
846 (gfc_free_dt): Correctly handle freeing of `dt_io_kind' and
847 `extra_comma' with changed semantics.
848 (gfc_resolve_dt): Check variable definitions.
849 (match_io_element): Remove INTENT and PURE checks here and
850 initialize code->ext.dt member.
851 (match_io): Set dt->dt_io_kind.
852 (gfc_resolve_inquire): Check variable definition for all tags
853 except UNIT, FILE and ID.
854 * resolve.c (resolve_transfer): Variable definition check.
856 2010-09-25 Tobias Burnus <burnus@net-b.de>
858 * interface.c (gfc_match_end_interface): Constify char pointer
861 2010-09-24 Steven G. Kargl < kargl@gcc.gnu.org>
863 * interface.c (gfc_match_end_interface): Deal with user defined
864 operators that overload rational operators and C1202.
866 2010-09-24 Tobias Burnus <burnus@net-b.de>
868 * gfortran.texi: Add second space after end-of-sentence period;
869 change / to /@/ to allow hyphenation of URLs.
870 (Standards): Remove duplicated OpenMP, update wording given that
871 Fortran 2008 now released.
872 (Fortran 2008 status): Update and add list of implemented features.
874 2010-09-24 Tobias Burnus <burnus@net-b.de>
877 * iso-fortran-env.def: Add NAMED_KINDARRAY with
878 character_kinds, integer_kinds, logical_kinds and
880 * gfortran.h: Add them to iso_fortran_env_symbol.
881 * libgfortran.h: Rename GFC_INQUIRE_INTERNAL_UNIT to
882 LIBERROR_INQUIRE_INTERNAL_UNIT and move it from
883 libgfortran_stat_codes to libgfortran_error_codes.
884 * module.c (create_int_parameter_array): New function.
885 (use_iso_fortran_env_module): Use it for
886 NAMED_KINDARRAY of iso-fortran-env.def.
887 * trans-decl.c (gfc_get_symbol_decl): Parameter
888 arrays of intrinsics modules become local static variables.
889 * intrinsic.texi (ISO_FORTRAN_ENV): Add character_kinds,
890 integer_kinds, logical_kinds and real_kinds.
892 2010-09-23 Thomas Koenig <tkoenig@gcc.gnu.org>
895 * frontend-passes.c (optimize_binop_array_assignment):
896 Only re-use lhs as intermediate storage if kind and type
899 2010-09-23 Mikael Morin <mikael@gcc.gnu.org>
903 * trans-array.c (gfc_conv_expr_descriptor): Handle
904 ss->type == GFC_SS_INTRINSIC (for {l,u}bound intrinsics) case.
906 2010-09-23 Tobias Burnus <burnus@net-b.de>
908 * intrinsic.texi (OpenMP modules): Add named constants of
911 2010-09-23 Daniel Kraft <d@domob.eu>
916 * gfortran.h (gfc_check_vardef_context): New method.
917 (struct symbol_attribute): New flag `select_type_temporary'.
918 * primary.c (gfc_variable_attr): Clarify initialization of ref.
919 (match_variable): Remove PROTECTED check and assignment check
920 for PARAMETERs (this is now done later).
921 * match.c (gfc_match_iterator): Remove INTENT(IN) check.
922 (gfc_match_associate): Defer initialization of newAssoc->variable.
923 (gfc_match_nullify): Remove PURE definability check.
924 (select_type_set_tmp): Set new `select_type_temporary' flag.
925 * expr.c (gfc_check_assign): Remove INTENT(IN) check here.
926 (gfc_check_pointer_assign): Ditto (and other checks removed).
927 (gfc_check_vardef_context): New method.
928 * interface.c (compare_parameter_protected): Removed.
929 (compare_actual_formal): Use `gfc_check_vardef_context' for checks
930 related to INTENT([IN]OUT) arguments.
931 * intrinsic.c (check_arglist): Check INTENT for intrinsics.
932 * resolve.c (gfc_resolve_iterator): Use `gfc_check_vardef_context'.
933 (remove_last_array_ref): New method.
934 (resolve_deallocate_expr), (resolve_allocate_expr): Ditto.
935 (resolve_allocate_deallocate): Ditto (for STAT and ERRMSG).
936 (resolve_assoc_var): Remove checks for definability here.
937 (resolve_select_type): Handle resolving of code->block here.
938 (resolve_ordinary_assign): Remove PURE check.
939 (resolve_code): Do not resolve code->blocks for SELECT TYPE here.
940 Use `gfc_check_vardef_context' for assignments and pointer-assignments.
942 2010-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
944 * gfortran.texi (Argument list functions): Allow URL to wrap.
945 * intrinsic.texi (GETGID, GETPID, GETUID, IMAGE_INDEX)
946 (IS_IOSTAT_END, IS_IOSTAT_EOR, NUM_IMAGES, THIS_IMAGE)
947 (ISO_FORTRAN_ENV): Fix markup in index entries, and a couple of
948 code markups in the text.
949 * invoke.texi (Fortran Dialect Options)
950 (Error and Warning Options, Directory Options, Code Gen Options):
951 Likewise. Remove @code inside @smallexample.
953 2010-09-22 Joseph Myers <joseph@codesourcery.com>
955 * gfortranspec.c (lang_specific_driver): Handle OPT__version and
956 OPT__help instead of OPT_fversion and OPT_fhelp.
957 * lang.opt (-all-warnings, -assert, -assert=, -comments,
958 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
959 -dump, -dump=, -include-barrier, -include-directory,
960 -include-directory=, -include-directory-after,
961 -include-directory-after=, -include-prefix, -include-prefix=,
962 -no-line-commands, -no-standard-includes, -output, -output=,
963 -preprocess, -print-missing-file-dependencies, -trace-includes,
964 -undefine-macro, -undefine-macro=, -user-dependencies, -verbose,
965 -write-dependencies, -write-user-dependencies): New.
967 2010-09-21 Jason Blevins <jrblevin@sdf.org>
969 * intrinsics.texi (HYPOT, IMAGE_INDEX, BESSEL_JN, BESSEL_YN,
970 execute_command_line, IEOR, IOR, NORM2, NOT, NULL, PARITY):
973 2010-09-21 Mikael Morin <mikael@gcc.gnu.org>
976 * trans-array.c (gfc_conv_expr_descriptor): Calculate dim out of n and
980 * trans-array.c (gfc_conv_expr_descriptor): Unset full if we are
981 accessing dimensions in reversed order.
984 * trans-array.c (gfc_conv_expr_descriptor): Special case noncopying
985 intrinsic function call.
987 * trans-array.c (gfc_conv_expr_descriptor): Remove ss lookup.
988 Update asserts accordingly.
991 * trans.h (gfc_se): New field force_tmp.
992 * trans-expr.c (gfc_conv_procedure_call): Check for argument alias
993 and set parmse.force_tmp if some alias is found.
994 * trans-array.c (gfc_conv_expr_descriptor): Force a temporary creation
995 if se->force_tmp is set.
997 2010-09-20 Janus Weil <janus@gcc.gnu.org>
1000 * trans-expr.c (gfc_conv_procedure_call): Fix pointer checking for
1001 TBPs, PPCs and pointer/allocatable components.
1003 2010-09-20 Paul Thomas <pault@gcc.gnu.org>
1006 * simplify.c (is_constant_array_expr): Allow structure array
1007 elements as well as constants.
1008 (gfc_simplify_pack, gfc_simplify_reshape, gfc_simplify_spread,
1009 gfc_simplify_transpose, gfc_simplify_unpack): Copy the derived
1010 type of source to the result.
1012 2010-09-19 Thomas Koenig <tkoenig@gcc.gnu.org>
1014 * frontend-passes.c (gfc_expr_walker): Also
1015 handle EXPR_SUBSTRING.
1017 2010-09-19 Thomas Koenig <tkoenig@gcc.gnu.org>
1019 * frontend-passes.c (gfc_expr_walker): Handle
1020 constructors and references.
1022 2010-09-16 Tobias Burnus <burnus@net-b.de>
1025 * trans-types.c (create_fn_spec): New function.
1026 (gfc_get_function_type): Call it.
1028 2010-09-16 Jakub Jelinek <jakub@redhat.com>
1030 * gfortran.h (walk_code_fn_t, walk_expr_fn_t): New types.
1031 (gfc_expr_walker, gfc_code_walker): New prototypes.
1032 * frontend-passes.c (gfc_expr_walker, gfc_code_walker): New functions.
1033 (WALK_SUBEXPR, WALK_SUBEXPR_TAIL, WALK_SUBCODE): Define.
1034 (optimize_namespace): Use gfc_code_walker.
1035 (optimize_code, optimize_expr): Rewritten as gfc_code_walker hooks.
1036 (optimize_expr_0, optimize_code_node,
1037 optimize_actual_arglist): Removed.
1038 (optimize_assignment): Don't call optimize_expr_0.
1040 2010-09-16 Janus Weil <janus@gcc.gnu.org>
1043 * interface.c (compare_parameter): Create vtab for actual argument,
1044 instead of formal (if needed).
1046 2010-09-15 Janus Weil <janus@gcc.gnu.org>
1049 * resolve.c (resolve_allocate_expr): Do default initialization via
1052 2010-09-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1054 * mathbuiltins.def: Do not defined huge_val built-in.
1055 * trans-const.c (gfc_build_inf_or_huge): New function.
1056 * trans-const.h (gfc_build_inf_or_huge): New prototype.
1057 * f95-lang.c (gfc_init_builtin_functions): Don't defined
1059 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): We don't
1060 have functions of type (*) (void) anymore.
1061 (gfc_conv_intrinsic_minmaxloc): Call gfc_build_inf_or_huge.
1062 (gfc_conv_intrinsic_nearest): Call gfc_build_inf_or_huge instead
1063 of generating a call to huge_val().
1065 2010-09-11 Mikael Morin <mikael@gcc.gnu.org>
1067 * gfortran.h (gfc_expr): Remove inline_noncopying_intrinsic attribute.
1068 * dependency.c (gfc_check_dependency): Don't depend on
1069 expr's inline_noncopying_intrinsic_attribute.
1070 * dependency.c (gfc_check_argument_var_dependency,
1071 gfc_check_argument_dependency): Ditto. Recursively check dependency
1072 as NOT_ELEMENTAL in the non-copying (=transpose) case.
1073 * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
1074 * resolve.c (find_noncopying_intrinsics): Remove.
1075 (resolve_function, resolve_call): Remove call to
1076 find_noncopying_intrinsics.
1078 * trans-array.c (gfc_conv_array_transpose): Remove.
1079 (gfc_walk_subexpr): Make non-static. Move prototype...
1080 * trans-array.h (gfc_walk_subexpr): ... here.
1081 * trans-intrinsic.c (gfc_conv_intrinsic_function): Update transpose
1083 (walk_inline_intrinsic_transpose, walk_inline_intrinsic_function,
1084 gfc_inline_intrinsic_function_p): New.
1085 (gfc_is_intrinsic_libcall): Return early in inline intrinsic case.
1086 Remove transpose from the libcall list.
1087 (gfc_walk_intrinsic_function): Special case inline intrinsic.
1088 * trans.h (gfc_inline_intrinsic_function_p): New prototype.
1090 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
1092 * trans-expr.c (expr_is_variable): New function taking non-copying
1093 intrinsic functions into account.
1094 (gfc_trans_assignment_1): Use expr_is_variable.
1096 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
1098 * trans-array.c (gfc_conv_loop_setup): Access the shape along the
1099 real array dimension instead of the scalarizer (loop) dimension.
1101 2010-09-10 Mikael Morin <mikael@gcc.gnu.org>
1103 * trans-array.c (gfc_conv_resolve_dependencies): Handle same-array
1104 transposed references.
1106 2010-09-10 Tobias Burnus <burnus@net-b.de>
1109 * trans.h (build1_stat_loc, build2_stat_loc, build3_stat_loc,
1110 build4_stat_loc): New inline functions.
1111 (build1_loc, build2_loc, build3_loc, build4_loc): New macros.
1112 (build1_v, build2_v, build3_v, build4_v): Use input_location
1114 * trans-array.c (gfc_trans_scalarized_loop_end,
1115 gfc_conv_array_parameter): Replace build[1-4] by build[1-4]_loc.
1116 * trans.c (gfc_build_addr_expr, gfc_build_array_ref,
1117 gfc_finish_wrapped_block): Ditto.
1118 * trans-decl.c (gfc_init_default_dt, init_intent_out_dt): Ditto.
1119 * trans-expr.c (gfc_conv_missing_dummy,
1120 gfc_trans_alloc_subarray_assign, gfc_trans_zero_assign): Ditto.
1121 * trans-openmp.c (gfc_omp_clause_default_ctor,
1122 gfc_trans_omp_critical, gfc_trans_omp_parallel,
1123 gfc_trans_omp_parallel_do, gfc_trans_omp_parallel_sections,
1124 gfc_trans_omp_parallel_workshare, gfc_trans_omp_sections
1125 gfc_trans_omp_single, gfc_trans_omp_task,
1126 gfc_trans_omp_workshare): Ditto.
1128 2010-09-09 Steven G. Kargl <kargl@gcc.gnu.org>
1130 * fortran/expr.c (check_inquiry): OPTIONAL attribute is not allowed
1131 for dummy argument that appears in a specification statement.
1133 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
1135 * trans-array.c (gfc_get_array_ref_dim): New function.
1136 (gfc_trans_create_temp_array): Reconstruct array
1137 bounds from loop bounds. Use array bounds instead of loop bounds.
1139 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
1141 * trans-array.c (gfc_set_loop_bounds_from_array_spec):
1142 Get the array dimension from the dim array.
1144 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
1146 * trans-array.c (gfc_trans_preloop_setup): Unconditionally use the
1147 dim array to get the stride in the innermost loop.
1149 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
1151 * trans-array.c (gfc_trans_create_temp_array): Don't set dim array.
1152 (gfc_conv_loop_setup, gfc_walk_function_expr): Set dim array.
1153 * trans-intrinsic.c (gfc_walk_intrinsic_libfunc): Ditto.
1155 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
1157 * trans-array.c (gfc_trans_create_temp_array): Assert loop dimension
1158 and info dimension are the same. Loop over loop dimension.
1159 * trans-stmt.c (gfc_conv_elemental_dependencies): Set loop dimension
1161 2010-09-09 Mikael Morin <mikael@gcc.gnu.org>
1163 * trans-array.c (gfc_conv_array_transpose): Change generated descriptor
1166 2010-09-09 Tobias Burnus <burnus@net-b.de>
1169 * intrincic.texi (FGET, FGETC, FPUT, FPUTC, FSTAT, GETCWD, KILL,
1170 STAT): Show also syntax for the function version.
1171 * intrinsic.c (add_sym_1s_intent, add_sym_2s_intent,
1172 add_sym_3s_intent): Remove function.
1173 (add_sym_1s, add_sym_2s, add_sym_3s): Take always the intent
1175 (add_sym_2_intent): New function.
1176 (add_functions): Set intent for functions which modify
1177 the argument: fstat, fgetc, fget, hostnm, lstat, stat. Change
1178 argument name of hostnm from "a" to "c"
1179 (add_subroutines): Change add_sym_*s_intent to
1180 add_sym_*s and add intent to the add_sym_*s calls.
1182 2010-09-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1185 * intrinsic.c (add_functions): Add B{G,L}{E,T}, DSHIFT{L,R},
1186 MASK{L,R}, MERGE_BITS and SHIFT{A,L,R}.
1187 * gfortran.h: Define ISYM values for above intrinsics.
1188 * intrinsic.h (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
1189 gfc_check_mask, gfc_check_merge_bits, gfc_check_shift,
1190 gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
1191 gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
1192 gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
1193 gfc_simplify_merge_bits, gfc_simplify_rshift,
1194 gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr,
1195 gfc_resolve_dshift, gfc_resolve_mask, gfc_resolve_merge_bits,
1196 gfc_resolve_shift): New prototypes.
1197 * iresolve.c (gfc_resolve_dshift, gfc_resolve_mask,
1198 gfc_resolve_merge_bits, gfc_resolve_shift): New functions.
1199 * check.c (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
1200 gfc_check_mask, gfc_check_merge_bits, gfc_check_shift): New
1202 * trans-intrinsic.c (gfc_conv_intrinsic_dshift,
1203 gfc_conv_intrinsic_bitcomp, gfc_conv_intrinsic_shift,
1204 gfc_conv_intrinsic_merge_bits, gfc_conv_intrinsic_mask): New
1206 (gfc_conv_intrinsic_function): Call above static functions.
1207 * intrinsic.texi: Document new intrinsics.
1208 * simplify.c (gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
1209 gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
1210 gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
1211 gfc_simplify_merge_bits, gfc_simplify_rshift,
1212 gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr):
1215 2010-09-08 Jakub Jelinek <jakub@redhat.com>
1217 * frontend-passes.c (optimize_code_node): Walk block chain by default.
1220 * trans-openmp.c (gfc_trans_omp_do): Store exit/cycle labels on code
1221 instead of code->block.
1224 * openmp.c (resolve_omp_do): Report not enough do loops for
1225 collapse even if block->next is NULL.
1227 2010-09-07 Thomas Koenig <tkoenig@gcc.gnu.org>
1230 * dependency.c (gfc_deb_compare_expr): Take missing optional
1231 arguments into account.
1233 2010-09-08 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1235 * trans.h (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
1236 * trans-decl.c (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
1237 (gfc_build_intrinsic_function_decls): Don't build the
1238 gfor_fndecl_clz128 and gfor_fndecl_ctz128.
1239 * trans-intrinsic.c (gfc_conv_intrinsic_leadz,
1240 gfc_conv_intrinsic_trailz): Generate inline arithmetic instead
1241 of calling clz128/ctz128 library functions.
1243 2010-09-07 Jan Hubicka <jh@suse.cz>
1245 * trans-expr.c (gfc_conv_initializer): Set STATIC flags for
1248 2010-09-07 Tobias Burnus <burnus@net-b.de>
1251 * intrinsic.texi (COS): Remove superfluous "n".
1253 2010-09-07 Tobias Burnus <burnus@net-b.de>
1256 * trans-array.c (gfc_conv_descriptor_data_get,
1257 gfc_conv_descriptor_data_set, gfc_conv_descriptor_data_addr,
1258 gfc_conv_descriptor_offset, gfc_conv_descriptor_dtype,
1259 gfc_conv_descriptor_dimension, gfc_conv_descriptor_stride,
1260 gfc_conv_descriptor_lbound, gfc_conv_descriptor_ubound,
1261 gfc_conv_shift_descriptor_lbound,
1262 gfc_set_loop_bounds_from_array_spec,
1263 gfc_trans_allocate_array_storage, gfc_trans_create_temp_array,
1264 gfc_conv_array_transpose, gfc_get_iteration_count,
1265 gfc_grow_array, gfc_trans_array_ctor_element,
1266 gfc_trans_array_constructor_subarray,
1267 gfc_trans_array_constructor_value,
1268 constant_array_constructor_loop_size, gfc_trans_array_constructor,
1269 gfc_set_vector_loop_bounds, gfc_trans_array_bound_check,
1270 gfc_conv_array_index_offset, gfc_conv_scalarized_array_ref,
1271 gfc_conv_array_ref, gfc_trans_preloop_setup,
1272 gfc_trans_scalarized_loop_end, gfc_conv_ss_startstride,
1273 gfc_conv_loop_setup, gfc_conv_array_extent_dim,
1274 gfc_conv_descriptor_size, gfc_array_init_size,
1275 gfc_array_allocate, gfc_array_deallocate,
1276 gfc_trans_array_bounds, gfc_trans_auto_array_allocation,
1277 gfc_trans_dummy_array_bias, gfc_get_dataptr_offset,
1278 get_array_charlen, gfc_conv_expr_descriptor,
1279 array_parameter_size, gfc_conv_array_parameter,
1280 gfc_trans_dealloc_allocated, get_full_array_size,
1281 duplicate_allocatable,
1282 structure_alloc_comps): Change fold_build[0-9] to
1283 fold_build[0-9]_loc.
1284 (duplicate_allocatable, structure_alloc_comps,
1285 gfc_duplicate_allocatable): Add space after function name.
1287 2010-09-07 Mikael Morin <mikael@gcc.gnu.org>
1289 * trans-stmt.c (gfc_trans_character_select): Be conversion-safe while
1290 checking string length value.
1291 * trans-intrinsic.c (gfc_conv_intrinsic_char): Build integer using
1292 gfc_charlen_type_node type.
1295 * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Convert string
1296 length to gfc_charlen_type_node.
1298 2010-09-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1301 * frontend-passes.c (optimize_binop_array_assignment): New
1303 (optimize_assignment): Call it.
1305 2010-09-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1308 * trans-expr.c (gfc_conv_substring): If start and end
1309 of the string reference are equal, set the length to one.
1311 2010-09-06 Tobias Burnus <burnus@net-b.de>
1314 * dump-parse-tree.c (gfc_debug_expr): Use stderr instead of stdout.
1316 2010-09-06 Tobias Burnus <burnus@net-b.de>
1319 * dump-parse-tree.c (gfc_debug_expr): New function.
1321 2010-09-06 Tobias Burnus <burnus@net-b.de>
1324 * intrinsic.c (add_functions): Support IALL, IANY, IPARITY.
1325 (check_specific): Special case for those intrinsics.
1326 * gfortran.h (gfc_isym_id): Add new intrinsics
1327 * intrinsic.h (gfc_check_transf_bit_intrins,
1328 gfc_simplify_iall, gfc_simplify_iany, gfc_simplify_iparity,
1329 gfc_resolve_iall, gfc_resolve_iany, gfc_resolve_iparity):
1331 * iresolve.c (gfc_resolve_iall, gfc_resolve_iany,
1332 gfc_resolve_iparity, resolve_transformational): New functions.
1333 (gfc_resolve_product, gfc_resolve_sum,
1334 gfc_resolve_parity): Use resolve_transformational.
1335 * check.c (gfc_check_transf_bit_intrins): New function.
1336 * simplify.c (gfc_simplify_iall, gfc_simplify_iany,
1337 gfc_simplify_iparity, do_bit_any, do_bit_ior,
1338 do_bit_xor, simplify_transformation): New functions.
1339 (gfc_simplify_all, gfc_simplify_any, gfc_simplify_parity,
1340 gfc_simplify_sum, gfc_simplify_product): Use simplify_transformation.
1341 * trans-intrinsic.c (gfc_conv_intrinsic_arith,
1342 gfc_conv_intrinsic_function, gfc_is_intrinsic_libcall):
1343 Handle IALL, IANY and IPARITY intrinsics.
1344 * intrinsic.texi (IMAGE_INDEX): Move up to fix alphabetic
1346 (IALL, IANY, IPARITY): Document new intrinsics.
1348 2010-09-05 Tobias Burnus <burnus@net-b.de>
1351 * f95-lang.c (gfc_truthvalue_conversion): Use
1352 fold_build[0-9]_loc instead of fold_build[0-9].
1353 * convert.c (convert): Ditto.
1354 * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
1355 build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
1356 gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
1357 gfc_conv_intrinsic_conjg, gfc_trans_same_strlen_check,
1358 gfc_conv_intrinsic_bound, gfc_conv_intrinsic_abs,
1359 gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
1360 gfc_conv_intrinsic_dim, gfc_conv_intrinsic_sign,
1361 gfc_conv_intrinsic_dprod, gfc_conv_intrinsic_char,
1362 gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
1363 gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
1364 gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_anyall,
1365 gfc_conv_intrinsic_count, gfc_conv_intrinsic_arith,
1366 gfc_conv_intrinsic_dot_product, gfc_conv_intrinsic_minmaxloc,
1367 gfc_conv_intrinsic_minmaxval, gfc_conv_intrinsic_btest,
1368 gfc_conv_intrinsic_bitop, gfc_conv_intrinsic_not,
1369 gfc_conv_intrinsic_singlebitop, gfc_conv_intrinsic_ibits,
1370 gfc_conv_intrinsic_rlshift, gfc_conv_intrinsic_ishft,
1371 gfc_conv_intrinsic_ishftc, gfc_conv_intrinsic_leadz,
1372 gfc_conv_intrinsic_trailz, gfc_conv_intrinsic_popcnt_poppar,
1373 gfc_conv_intrinsic_ichar, gfc_conv_has_intvalue,
1374 gfc_conv_intrinsic_merge, gfc_conv_intrinsic_spacing,
1375 gfc_conv_intrinsic_rrspacing, gfc_conv_intrinsic_size,
1376 size_of_string_in_bytes, gfc_conv_intrinsic_sizeof,
1377 gfc_conv_intrinsic_storage_size, gfc_conv_intrinsic_strcmp,
1378 gfc_conv_intrinsic_transfer, gfc_conv_allocated,
1379 gfc_conv_associated, gfc_conv_same_type_as,
1380 gfc_conv_intrinsic_trim, gfc_conv_intrinsic_repeat): Ditto.
1382 2010-09-04 Tobias Burnus <burnus@net-b.de>
1385 * resolve.c (resolve_fl_namelist): Change constraint checking
1386 order to prevent endless loop.
1388 2010-09-04 Janus Weil <janus@gcc.gnu.org>
1391 * resolve.c (resolve_allocate_expr): Generate default initializers
1392 already at this point, resolve them and put them into expr3, ...
1393 * trans-stmt.c (gfc_trans_allocate): ... instead of waiting until
1396 2010-09-03 Tobias Burnus <burnus@net-b.de>
1399 * trans-intrinsic.c (gfc_conv_intrinsic_sign,
1400 gfc_conv_intrinsic_leadz): Use build_call_expr_loc instead
1402 * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
1403 gfc_conv_string_length, gfc_conv_substring,
1404 gfc_conv_component_ref, gfc_conv_unary_op, gfc_conv_powi,
1405 gfc_conv_cst_int_power, gfc_conv_string_tmp, gfc_conv_concat_op,
1406 gfc_conv_expr_op, gfc_build_compare_string,
1407 gfc_set_interface_mapping_bounds, gfc_conv_subref_array_arg,
1408 gfc_conv_derived_to_class, conv_isocbinding_procedure,
1409 gfc_conv_procedure_call, fill_with_spaces,
1410 gfc_trans_string_copy, gfc_trans_alloc_subarray_assign,
1411 gfc_trans_structure_assign, gfc_trans_pointer_assignment,
1412 gfc_trans_scalar_assign, gfc_trans_zero_assign,
1413 gfc_trans_array_copy, gfc_trans_array_constructor_copy): Change
1414 fold_build[0-9] to fold_build[0-9]_loc.
1415 * trans-io.c (set_parameter_const, set_parameter_value,
1416 set_parameter_ref, gfc_convert_array_to_string, set_string,
1417 set_internal_unit, io_result, set_error_locus,
1418 nml_get_addr_expr, build_dt): Ditto.
1419 * trans-openmp.c (gfc_omp_clause_default_ctor,
1420 gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
1421 gfc_trans_omp_array_reduction, gfc_trans_omp_atomic,
1422 gfc_trans_omp_do): Ditto.
1423 * trans.c (gfc_add_modify, gfc_build_addr_expr,
1424 gfc_build_array_ref, gfc_trans_runtime_error_vararg,
1425 gfc_trans_runtime_check, gfc_call_malloc,
1426 gfc_allocate_with_status, gfc_allocate_array_with_status,
1427 gfc_call_free, gfc_deallocate_with_status,
1428 gfc_call_realloc): Ditto.
1430 2010-09-03 Thomas Koenig <tkoenig@gcc.gnu.org>
1433 * dependency.c (gfc_deb_compare_expr): Compare equal for equal
1434 arglists for pure user functions, or for those intrinsic
1435 functions which are also pure.
1436 * intrinsics.c (add_conv): Mark conversion functions as pure.
1437 (add_char_conversions): Likewise.
1439 2010-09-03 Daniel Kraft <d@domob.eu>
1442 * resolve.c (resolve_actual_arglist): Allow internal procedure
1443 as actual argument with Fortran 2008.
1445 2010-09-03 Daniel Kraft <d@domob.eu>
1448 * gfortran.h (struct gfc_code): Renamed `whichloop' to
1449 `which_construct' as this is no longer restricted to loops.
1450 * parse.h (struct gfc_state_data): New field `construct'.
1451 * match.c (match_exit_cycle): Handle EXIT from non-loops.
1452 * parse.c (push_state): Set `construct' field.
1453 * resolve.c (resolve_select_type): Extend comment.
1454 * trans-stmt.c (gfc_trans_if): Add exit label.
1455 (gfc_trans_block_construct), (gfc_trans_select): Ditto.
1456 (gfc_trans_simple_do): Store exit/cycle labels on the gfc_code itself.
1457 (gfc_trans_do), (gfc_trans_do_while): Ditto.
1458 (gfc_trans_exit): Use new name `which_construct' instead of `whichloop'.
1459 (gfc_trans_cycle): Ditto.
1460 (gfc_trans_if_1): Use fold_build3_loc instead of fold_build3.
1462 2010-09-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1464 * trans-intrinsic.c (gfc_conv_intrinsic_aint): Fix whitespace.
1465 (gfc_conv_intrinsic_ishft): Only evaluate arguments once.
1466 (gfc_conv_intrinsic_ishftc): Only evaluate arguments once.
1467 * intrinsic.texi (RSHIFT): Fix documentation.
1469 2010-09-02 Tobias Burnus <burnus@net-b.de>
1472 * trans-common.c (create_common): Change build[0-9] to
1474 * trans-const.c (gfc_conv_constant_to_tree,
1475 gfc_conv_constant_to_tree): Ditto.
1476 * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
1477 gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
1478 add_argument_checking, create_main_function,
1479 gfc_generate_return): Ditto.
1480 * trans-types.c (gfc_get_dtype, gfc_get_array_type_bounds): Ditto.
1481 * trans-stmt.c (allocate_temp_for_forall_nest_1,
1482 compute_inner_temp_size, compute_overall_iter_number,
1483 generate_loop_for_rhs_to_temp, generate_loop_for_temp_to_lhs,
1484 gfc_conv_elemental_dependencies, gfc_do_allocate,
1485 gfc_evaluate_where_mask, gfc_trans_allocate,
1486 gfc_trans_arithmetic_if, gfc_trans_call,
1487 gfc_trans_character_select, gfc_trans_deallocate,
1488 gfc_trans_do, gfc_trans_do_while, gfc_trans_forall_1,
1489 gfc_trans_forall_loop, gfc_trans_goto, gfc_trans_if_1,
1490 gfc_trans_integer_select, gfc_trans_logical_select,
1491 gfc_trans_pointer_assign_need_temp, gfc_trans_return,
1492 gfc_trans_simple_do, gfc_trans_sync, gfc_trans_where_2,
1493 gfc_trans_where_assign) Ditto.
1495 2010-09-02 Janus Weil <janus@gcc.gnu.org>
1498 * resolve.c (resolve_symbol): Correct check for attributes of CLASS
1501 2010-09-02 Tobias Burnus <burnus@net-b.de>
1504 * resolve.c (apply_default_init): Mark symbol as referenced,
1505 if it is initialized.
1506 (resolve_symbol): Change intialized check for BT_DERIVED such
1507 that also function results get initialized; remove now obsolete
1508 gfc_set_sym_referenced for BT_CLASS.
1510 2010-09-01 Janus Weil <janus@gcc.gnu.org>
1513 * class.c (gfc_find_derived_vtab): Add component '$def_init'.
1514 * resolve.c (resolve_allocate_expr): Defer handling of default
1515 initialization to 'gfc_trans_allocate'.
1516 (apply_default_init,resolve_symbol): Handle polymorphic dummies.
1517 (resolve_fl_derived): Suppress error messages for vtypes.
1518 * trans-stmt.c (gfc_trans_allocate): Handle initialization via
1519 polymorphic MOLD expression.
1520 * trans-expr.c (gfc_trans_class_init_assign): Now only used for
1521 dummy initialization.
1523 2010-09-01 Tobias Burnus <burnus@net-b.de>
1525 * gfortran.texi (preprocessing): Update URL to COCO.
1527 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1529 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Resize
1530 array quad_decls. Remove unnecessary assignment.
1532 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1534 * trans-expr.c (gfc_conv_power_op): Handle floating-point types
1535 other than long double.
1536 * mathbuiltins.def: Add builtins from the POW and CPOW family.
1537 * trans.h (gfc_builtin_decl_for_float_kind): New prototype.
1538 * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Add gfc_
1539 prefix to function name.
1540 (gfc_build_intrinsic_lib_fndecls): Add cpow prototype.
1541 (gfc_conv_intrinsic_aint): Use gfc_builtin_decl_for_float_kind
1543 (gfc_conv_intrinsic_exponent): Likewise.
1544 (gfc_conv_intrinsic_abs): Likewise.
1545 (gfc_conv_intrinsic_mod): Likewise.
1546 (gfc_conv_intrinsic_sign): Likewise.
1547 (gfc_conv_intrinsic_arith): Likewise.
1548 (gfc_conv_intrinsic_fraction): Likewise.
1549 (gfc_conv_intrinsic_nearest): Likewise.
1550 (gfc_conv_intrinsic_spacing): Likewise.
1551 (gfc_conv_intrinsic_rrspacing): Likewise.
1552 (gfc_conv_intrinsic_scale): Likewise.
1553 (gfc_conv_intrinsic_set_exponent): Likewise.
1555 2010-09-01 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1557 * intrinsic.c: Add EXECUTE_COMMAND_LINE intrinsic.
1558 * intrinsic.h (gfc_resolve_execute_command_line): New function.
1559 * iresolve.c (gfc_resolve_execute_command_line): New function.
1560 * gfortran.h (GFC_ISYM_EXECUTE_COMMAND_LINE): New value.
1561 * intrinsic.texi: Document EXECUTE_COMMAND_LINE.
1563 2010-08-31 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1566 * f95-lang.c (gfc_init_builtin_functions): Define popcount{,l,ll}
1567 and parity{,l,ll} builtins.
1568 * trans-intrinsic.c (gfc_conv_intrinsic_popcnt_poppar): New function.
1569 (gfc_conv_intrinsic_function): Call above new functions.
1570 * simplify.c (gfc_simplify_popcnt, gfc_simplify_poppar): New
1572 * intrinsic.texi: Document POPCNT and POPPAR.
1574 2010-08-30 Janus Weil <janus@gcc.gnu.org>
1577 * resolve.c (resolve_structure_cons): Handle pointer-valued PPCs.
1579 2010-08-30 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1581 * Make-lang.in: Add frontend-passes.o dependencies.
1583 2010-08-29 Janus Weil <janus@gcc.gnu.org>
1586 * resolve.c (resolve_structure_cons): For derived types, make sure the
1587 type has been resolved.
1588 (resolve_typebound_procedures): Make sure the vtab has been generated.
1590 2010-08-29 Janus Weil <janus@gcc.gnu.org>
1593 * match.c (gfc_match_select_type): Give the associate-name the
1594 FL_VARIABLE attribute.
1596 2010-08-28 Steven G. Kargl <kargl@gcc.gnu.org>
1598 * simplify.c (gfc_simplify_bessel_n2): Fix indention
1601 2010-08-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1604 * trans-types.c (gfc_init_kinds): Disable TFmode.
1606 2010-08-27 Janus Weil <janus@gcc.gnu.org>
1609 * match.c (gfc_match_allocate): Avoid double free on error.
1611 2010-08-27 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1614 * gfortran.h (gfc_real_info): Add c_float128 field.
1615 * mathbuiltins.def: Indicate which builtins are const.
1616 * trans-types.h (float128_type_node, complex_float128_type_node,
1617 gfc_real16_is_float128): New variables.
1618 * trans-types.c (float128_type_node, complex_float128_type_node,
1619 gfc_real16_is_float128): New variables.
1620 (gfc_init_kinds): Allow TFmode.
1621 (gfc_build_real_type): Mark __float128 types as such.
1622 (gfc_init_types): Initialize float128_type_node and
1623 complex_float128_type_node
1624 * f95-lang.c (gfc_init_builtin_functions): Adjust for new
1625 argument of OTHER_BUILTIN macro.
1626 * trans-intrinsic.c (gfc_intrinsic_map_t): Likewise.
1627 (builtin_decl_for_precision): Special case for __float128.
1628 (builtin_decl_for_float_kind): Likewise.
1629 (define_quad_builtin): New function.
1630 (gfc_build_intrinsic_lib_fndecls): Create all __float128
1631 library decls if necessary. Store them in the real16_decl and
1632 complex16_decl builtin map fields.
1633 (gfc_get_intrinsic_lib_fndecl): Handle q-suffixed __float128
1634 library function names.
1636 2010-08-27 Tobias Burnus <burnus@net-b.de>
1639 * gcc/fortran/intrinsic.c (add_functions): Add norm2 and parity.
1640 * gcc/fortran/intrinsic.h (gfc_check_norm2, gfc_check_parity):
1641 gfc_simplify_norm2, gfc_simplify_parity, gfc_resolve_norm2,
1642 gfc_resolve_parity): New prototypes.
1643 * gcc/fortran/gfortran.h (gfc_isym_id): New enum items
1644 GFC_ISYM_NORM2 and GFC_ISYM_PARITY.
1645 * gcc/fortran/iresolve.c (gfc_resolve_norm2,
1646 gfc_resolve_parity): New functions.
1647 * gcc/fortran/check.c (gfc_check_norm2, gfc_check_parity):
1649 * gcc/fortran/trans-intrinsic.c (gfc_conv_intrinsic_arith,
1650 gfc_conv_intrinsic_function): Handle NORM2 and PARITY.
1651 * gcc/fortran/intrinsic.texi (NORM2, PARITY): Add.
1652 * gcc/fortran/simplify.c (simplify_transformation_to_array):
1653 Add post-processing opterator.
1654 (gfc_simplify_all, gfc_simplify_any, gfc_simplify_count,
1655 gfc_simplify_product, gfc_simplify_sum): Update call.
1656 (add_squared, do_sqrt, gfc_simplify_norm2, do_xor,
1657 gfc_simplify_parity): New functions.
1659 2010-08-27 Janus Weil <janus@gcc.gnu.org>
1662 * match.c (select_type_set_tmp): Add the possibility to reset the
1664 (gfc_match_class_is): Reset the temporary in CLASS DEFAULT clauses.
1666 2010-08-27 Thomas Koenig <tkoenig@gcc.gnu.org>
1669 * dependency.c (check_section_vs_section): Single test for
1670 identical strides which takes into account that only one
1671 of the strides may be NULL.
1673 2010-08-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1676 * primary.c (match_hollerith_constant): Calculate padding needed to
1677 fill default integer and allocate string for that size. Set pad bytes
1679 * gfortran.h: Add hollerith pad value to type spec union.
1680 * data.c (create_character_initializer): Fix spelling of function name.
1681 Use hollerith pad value to calculate length.
1682 * arith.c (hollerith2representation); Use hollerith pad value to
1685 2010-08-26 Daniel Kraft <d@domob.eu>
1690 * gfortran.h (struct gfc_association_list): New flag `dangling'.
1691 (gfc_build_block_ns): Declared here...
1692 * parse.h (gfc_build_block_ns): ...instead of here.
1693 * trans.h (gfc_process_block_locals): Expect additionally the
1694 gfc_association_list of BLOCK (if present).
1695 * match.c (select_type_set_tmp): Create sym->assoc for temporary.
1696 * resolve.c (resolve_variable): Only check for invalid *array*
1697 references on associate-names.
1698 (resolve_assoc_var): New method with code previously in resolve_symbol.
1699 (resolve_select_type): Use association to give the selector and
1700 temporaries their values instead of ordinary assignment.
1701 (resolve_fl_var_and_proc): Allow CLASS associate-names.
1702 (resolve_symbol): Use new `resolve_assoc_var' instead of inlining here.
1703 * trans-stmt.c (gfc_trans_block_construct): Pass association-list
1704 to `gfc_process_block_locals' to match new interface.
1705 * trans-decl.c (gfc_get_symbol_decl): Don't defer associate-names
1707 (gfc_process_block_locals): Defer them rather here when linked to
1708 from the BLOCK's association list.
1710 2010-08-25 Jakub Jelinek <jakub@redhat.com>
1712 * trans-decl.c (gfc_build_intrinsic_function_decls): Set
1713 TREE_NOTHROW on fndecls that can't throw. Set
1714 TREE_READONLY on gfor_fndecl_math_ishftc{4,8,16}.
1715 (gfc_build_builtin_function_decls): Set TREE_NOTHROW on
1716 gfor_fndecl_associated.
1718 2010-08-23 Mikael Morin <mikael@gcc.gnu.org>
1721 * frontend-passes.c (optimize_equality): Don't optimize array equality
1723 2010-08-23 Janus Weil <janus@gcc.gnu.org>
1726 * resolve.c (resolve_procedure_interface): New function split off from
1728 (resolve_formal_arglist): Call it here ...
1729 (resolve_symbol): ... and here.
1731 2010-08-22 Joseph Myers <joseph@codesourcery.com>
1733 * Make-lang.in (gfortranspec.o): Update dependencies.
1734 * gfortranspec.c: Include coretypes.h before gcc.h. Include
1736 (MATH_LIBRARY, FORTRAN_LIBRARY): Remove initial "-l".
1737 (ADD_ARG_LIBGFORTRAN, Option, lookup_option): Remove.
1738 (g77_xargc): Make unsigned.
1739 (g77_xargv): Change to g77_x_decoded_options.
1740 (g77_newargc): Make unsigned.
1741 (g77_newargv): Change to g77_new_decoded_options.
1742 (strings_same, options_same): New.
1743 (append_arg): Use cl_decoded_option structures.
1744 (append_option): New.
1745 (add_arg_libgfortran): New.
1746 (lang_specific_driver): Use cl_decoded_option structures.
1748 2010-08-21 Janus Weil <janus@gcc.gnu.org>
1752 * class.c (add_proc_comp): Add static initializer for PPCs.
1753 (add_procs_to_declared_vtab): Modified comment.
1754 * module.c (mio_component): Add argument 'vtype'. Don't read/write the
1755 initializer if the component is part of a vtype.
1756 (mio_component_list): Add argument 'vtype', pass it on to
1758 (mio_symbol): Modified call to 'mio_component_list'.
1759 * trans.h (gfc_conv_initializer): Modified prototype.
1760 (gfc_trans_assign_vtab_procs): Removed.
1761 * trans-common.c (create_common): Modified call to
1762 'gfc_conv_initializer'.
1763 * trans-decl.c (gfc_get_symbol_decl,get_proc_pointer_decl,
1764 gfc_emit_parameter_debug_info): Modified call to
1765 'gfc_conv_initializer'.
1766 (build_function_decl): Remove assertion.
1767 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
1768 Removed call to 'gfc_trans_assign_vtab_procs'.
1769 (gfc_conv_initializer): Add argument 'procptr'.
1770 (gfc_conv_structure): Modified call to 'gfc_conv_initializer'.
1771 (gfc_trans_assign_vtab_procs): Removed.
1772 * trans-stmt.c (gfc_trans_allocate): Removed call to
1773 'gfc_trans_assign_vtab_procs'.
1775 2010-08-21 Tobias Burnus <burnus@net-b.de>
1779 * intrinsic.c (add_sym): Init value attribute.
1780 (set_attr_value): New function.
1781 (add_functions) Use it and add JN/YN resolvers.
1782 * symbol.c (gfc_copy_formal_args_intr): Copy value attr.
1783 * intrinsic.h (gfc_resolve_bessel_n2): New prototype.
1784 * gfortran.h (gfc_intrinsic_arg): Add value attribute.
1785 * iresolve.c (gfc_resolve_bessel_n2): New function.
1786 * trans-intrinsic.c (gfc_get_symbol_for_expr): Create
1788 (gfc_conv_intrinsic_function,gfc_is_intrinsic_libcall):
1789 Add GFC_ISYM_JN2/GFC_ISYM_YN2 as case value.
1790 * simplify.c (): For YN set to -INF if previous values
1792 * trans-expr.c (gfc_conv_procedure_call): Don't crash
1794 * iresolve.c (gfc_resolve_extends_type_of): Set the
1795 type of the dummy argument to the one of the actual.
1797 2010-08-20 Joseph Myers <joseph@codesourcery.com>
1799 * lang.opt (MD, MMD): Use NoDriverArg instead of NoArgDriver.
1801 2010-08-20 Joseph Myers <joseph@codesourcery.com>
1803 * gfortranspec.c (lang_specific_driver): Refer to -lgfortran in
1806 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
1808 * trans-openmp.c: Use FOR_EACH_VEC_ELT.
1810 2010-08-19 Daniel Kraft <d@domob.eu>
1814 * trans.h (struct gfc_se): New flag `byref_noassign'.
1815 * trans-array.h (gfc_conv_shift_descriptor_lbound): New method.
1816 (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
1817 * expr.c (gfc_check_pointer_assign): Allow bounds and rank remapping
1818 and check for compile-time errors with those.
1819 * trans-decl.c (trans_associate_var): Use new routine
1820 `gfc_conv_shift_descriptor_lbound' instead of doing it manually.
1821 * trans-array.c (gfc_conv_shift_descriptor_lbound): New method.
1822 (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
1823 (gfc_array_init_size): Use new `gfc_conv_array_extent_dim'.
1824 (gfc_conv_expr_descriptor): Handle new flag `byref_noassign'.
1825 * trans-expr.c (gfc_trans_pointer_assignment): Handle bounds and
1826 rank remapping for assignment.
1828 2010-08-19 Tobias Burnus <burnus@net-b.de>
1830 * intrinsic.texi (Bessel_jn, Bessel_yn): Fix typo.
1831 * * simplify.c (gfc_simplify_bessel_yn): Change recursive
1834 2010-08-19 Tobias Burnus <burnus@net-b.de>
1838 * check.c (gfc_check_bessel_n2): New function.
1839 * gfortran.h (gfc_isym_id): Add GFC_ISYM_JN2 and GFC_ISYM_YN2.
1840 * intrinsic.c (add_functions): Add transformational version
1841 of the Bessel_jn/yn intrinsics.
1842 * intrinsic.h (gfc_check_bessel_n2,gfc_simplify_bessel_jn2,
1843 gfc_simplify_bessel_yn2): New prototypes.
1844 * intrinsic.texi (Bessel_jn, Bessel_yn): Document
1845 transformational variant.
1846 * simplify.c (gfc_simplify_bessel_jn, gfc_simplify_bessel_yn):
1847 Check for negative order.
1848 (gfc_simplify_bessel_n2,gfc_simplify_bessel_jn2,
1849 gfc_simplify_bessel_yn2): New functions.
1851 2010-08-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1854 * resolve.c (resolve_transfer): Traverse operands and set expression
1855 to be checked to a non EXPR_OP type.
1857 2010-08-19 Janus Weil <janus@gcc.gnu.org>
1860 * gfortran.h (gfc_add_save): Modified prototype.
1861 * decl.c (add_init_expr_to_sym): Defer checking of proc pointer init.
1862 (match_pointer_init): New function to match F08 pointer initialization.
1863 (variable_decl,match_procedure_decl,match_ppc_decl): Use
1864 'match_pointer_init'.
1865 (match_attr_spec): Module variables are implicitly SAVE.
1866 (gfc_match_save): Modified call to 'gfc_add_save'.
1867 * expr.c (gfc_check_assign_symbol): Extra checks for pointer
1869 * primary.c (gfc_variable_attr): Handle SAVE attribute.
1870 * resolve.c (resolve_structure_cons): Add new argument and do pointer
1871 initialization checks.
1872 (gfc_resolve_expr): Modified call to 'resolve_structure_cons'.
1873 (resolve_values): Call 'resolve_structure_cons' directly with init arg.
1874 (resolve_fl_variable): Handle SAVE_IMPLICIT.
1875 * symbol.c (gfc_add_save,gfc_copy_attr,save_symbol): Handle
1877 * trans-decl.c (gfc_create_module_variable): Module variables with
1878 TARGET can already exist.
1879 * trans-expr.c (gfc_conv_variable): Check for 'current_function_decl'.
1880 (gfc_conv_initializer): Implement non-NULL pointer
1883 2010-08-18 Tobias Burnus <burnus@net-b.de>
1886 * intrinsic.texi (selected_char_kind): Document ISO_10646
1889 2010-08-17 Jakub Jelinek <jakub@redhat.com>
1892 * trans-decl.c (build_library_function_decl_1): Chain on
1893 void_list_node instead of creating a new TREE_LIST.
1894 * trans-intrinsic.c (gfc_get_intrinsic_lib_fndecl): Likewise.
1895 * trans-types.c (gfc_get_function_type): Likewise. Set
1896 typelist to void_list_node for the main program.
1898 2010-08-17 Daniel Kraft <d@domob.eu>
1901 * gfortran.h (struct gfc_association_list): New member `where'.
1902 (gfc_is_associate_pointer) New method.
1903 * match.c (gfc_match_associate): Remember locus for each associate
1904 name matched and do not try to set variable flag.
1905 * parse.c (parse_associate): Use remembered locus for symbols.
1906 * primary.c (match_variable): Instead of variable-flag check for
1907 associate names set it for all such names used.
1908 * symbol.c (gfc_is_associate_pointer): New method.
1909 * resolve.c (resolve_block_construct): Don't generate assignments
1910 to give associate-names their values.
1911 (resolve_fl_var_and_proc): Allow associate-names to be deferred-shape.
1912 (resolve_symbol): Set some more attributes for associate variables,
1913 set variable flag here and check it and don't try to build an
1914 explicitely shaped array-spec for array associate variables.
1915 * trans-expr.c (gfc_conv_variable): Dereference in case of association
1917 * trans-types.c (gfc_is_nodesc_array): Handle array association symbols.
1918 (gfc_sym_type): Return pointer type for association to scalar vars.
1919 * trans-decl.c (gfc_get_symbol_decl): Defer association symbols.
1920 (trans_associate_var): New method.
1921 (gfc_trans_deferred_vars): Handle association symbols.
1923 2010-08-16 Joseph Myers <joseph@codesourcery.com>
1925 * lang.opt (MDX): Change back to MD. Mark NoDriverArg instead of
1927 (MMDX): Change back to MMD. Mark NoDriverArg instead of
1929 * cpp.c (gfc_cpp_handle_option): Use OPT_MD and OPT_MMD instead of
1930 OPT_MDX and OPT_MMDX.
1932 2010-08-16 Joseph Myers <joseph@codesourcery.com>
1934 * lang.opt (MDX, MMDX): Mark RejectDriver.
1936 2010-08-15 Janus Weil <janus@gcc.gnu.org>
1938 * trans-expr.c (gfc_trans_assign_vtab_procs): Clean up (we don't have
1939 vtabs for generics any more).
1941 2010-08-15 Daniel Kraft <d@domob.eu>
1944 * gfortran.h (gfc_find_proc_namespace): New method.
1945 * expr.c (gfc_build_intrinsic_call): No need to build symtree messing
1946 around with namespace.
1947 * symbol.c (gfc_find_proc_namespace): New method.
1948 * trans-decl.c (gfc_build_qualified_array): Use it for correct
1950 * primary.c (gfc_match_varspec): Handle associate-names as arrays.
1951 * parse.c (parse_associate): Removed assignment-generation here...
1952 * resolve.c (resolve_block_construct): ...and added it here.
1953 (resolve_variable): Handle names that are arrays but were not parsed
1954 as such because of association.
1955 (resolve_code): Fix BLOCK resolution.
1956 (resolve_symbol): Generate array-spec for associate-names.
1958 2010-08-15 Tobias Burnus <burnus@net-b.de>
1961 * decl.c (verify_c_interop_param): Remove superfluous space (" ").
1962 (verify_c_interop): Handle unresolved DT with bind(C).
1964 2010-08-15 Tobias Burnus <burnus@net-b.de>
1966 * trans-expr.c (gfc_conv_expr_present): Regard nullified
1967 pointer arrays as absent.
1968 (gfc_conv_procedure_call): Handle EXPR_NULL for non-pointer
1969 dummys as absent argument.
1970 * interface.c (compare_actual_formal,compare_parameter):
1973 2010-08-15 Tobias Burnus <burnus@net-b.de>
1975 * interface.c (compare_pointer, ): Allow passing TARGETs to pointers
1976 dummies with intent(in).
1978 2010-08-15 Daniel Kraft <d@domob.eu>
1981 * decl.c (gfc_match_prefix): Match IMPURE prefix and mark ELEMENTAL
1982 routines not IMPURE also as PURE.
1983 * intrinsic.c (enum klass): New class `CLASS_PURE' and renamed
1984 `NO_CLASS' in `CLASS_IMPURE'.
1985 (add_sym): Set symbol-attributes `pure' and `elemental' correctly.
1986 (add_sym_0s): Renamed `NO_CLASS' in `CLASS_IMPURE'.
1987 (add_functions): Ditto.
1988 (add_subroutines): Ditto and mark `MOVE_ALLOC' as CLASS_PURE.
1989 * resolve.c (gfc_pure): Do not treat ELEMENTAL as automatically PURE.
1990 (resolve_formal_arglist): Check that arguments to ELEMENTAL procedures
1991 are not ALLOCATABLE and have their INTENT specified.
1993 2010-08-13 Daniel Kraft <d@domob.eu>
1995 * gfortran.h (array_type): New type `AS_IMPLIED_SHAPE'.
1996 * array.c (gfc_match_array_spec): Match implied-shape specification and
1997 handle AS_IMPLIED_SHAPE correctly otherwise.
1998 * decl.c (add_init_expr_to_sym): Set upper bounds for implied-shape.
1999 (variable_decl): Some checks for implied-shape declaration.
2000 * resolve.c (resolve_symbol): Assert that array-spec is no longer
2001 AS_IMPLIED_SHAPE in any case.
2003 2010-08-12 Joseph Myers <joseph@codesourcery.com>
2005 * lang.opt (MD, MMD): Change to MDX and MMDX.
2006 * cpp.c (gfc_cpp_handle_option): Use OPT_MMD and OPT_MMDX.
2008 2010-08-11 Janus Weil <janus@gcc.gnu.org>
2011 * intrinsic.c (gfc_current_intrinsic_arg): Change type from 'char' to
2012 'gfc_intrinsic_arg'.
2013 (check_arglist,check_specific): Add reference to 'name' field.
2014 (init_arglist): Remove reference to 'name' field.
2015 * intrinsic.h (gfc_current_intrinsic_arg): Modify prototype.
2016 * check.c (variable_check): Reverse order of checks. Respect intent of
2018 (int_or_proc_check): New function.
2019 (coarray_check): New function.
2020 (allocatable_check): New function.
2021 (gfc_check_allocated,gfc_check_move_alloc): Use 'allocatable_check'.
2022 (gfc_check_complex): Use 'int_or_real_check'.
2023 (gfc_check_lcobound,gfc_check_image_index,gfc_check_this_image,
2024 gfc_check_ucobound): Use 'coarray_check'.
2025 (gfc_check_pack): Use 'real_or_complex_check'.
2026 (gfc_check_alarm_sub,gfc_check_signal,gfc_check_signal_sub): Use
2027 'int_or_proc_check'.
2028 (scalar_check,type_check,numeric_check,int_or_real_check,
2029 real_or_complex_check,kind_check,double_check,logical_array_check,
2030 array_check,same_type_check,rank_check,nonoptional_check,
2031 kind_value_check,gfc_check_a_p,gfc_check_associated,gfc_check_cmplx,
2032 gfc_check_cshift,gfc_check_dcmplx,gfc_check_dot_product,gfc_check_dprod,
2033 gfc_check_eoshift,gfc_check_fn_rc2008,gfc_check_index,gfc_check_kind,
2034 gfc_check_matmul,gfc_check_minloc_maxloc,check_reduction,gfc_check_null,
2035 gfc_check_present,gfc_check_reshape,gfc_check_same_type_as,
2036 gfc_check_spread,gfc_check_unpack,gfc_check_random_seed,
2037 gfc_check_getarg,gfc_check_and,gfc_check_storage_size): Add reference
2040 2010-08-10 Daniel Kraft <d@domob.eu>
2042 * gfortran.texi (Interoperability with C): Fix ordering in menu
2043 and add new subsection about pointers.
2044 (Interoperable Subroutines and Functions): Split off the pointer part.
2045 (working with Pointers): New subsection with extended discussion
2046 of pointers (especially procedure pointers).
2048 2010-08-09 Thomas Koenig <tkoenig@gcc.gnu.org>
2051 * array.c (gfc_ref_dimen_size): Add end argument.
2052 If end is non-NULL, calculate it.
2053 (ref_size): Adjust call to gfc_ref_dimen_size.
2054 (gfc_array_dimen_size): Likewise.
2055 (gfc_array_res_shape): Likewise.
2056 * gfortran.h: Adjust prototype for gfc_ref_dimen_size.
2057 * resolve.c (resolve_array_ref): For stride not equal to -1,
2058 fill in the lowest possible end.
2060 2010-08-09 Janus Weil <janus@gcc.gnu.org>
2062 * intrinsic.texi: Correct documentation of ASINH, ACOSH and ATANH.
2064 2010-08-07 Nathan Froyd <froydnj@codesourcery.com>
2066 * interface.c (compare_actual_formal): Use XALLOCAVEC instead of
2068 (check_some_aliasing): Likewise.
2069 * trans-intrinsic.c (gfc_conv_intrinsic_conversion): Likewise.
2070 (gfc_conv_intrinsic_int): Likewise.
2071 (gfc_conv_intrinsic_lib_function): Likewise.
2072 (gfc_conv_intrinsic_cmplx): Likewise.
2073 (gfc_conv_intrinsic_ctime): Likewise.
2074 (gfc_conv_intrinsic_fdate): Likewise.
2075 (gfc_conv_intrinsic_ttynam): Likewise.
2076 (gfc_conv_intrinsic_minmax): Likewise.
2077 (gfc_conv_intrinsic_minmax_char): Likewise.
2078 (gfc_conv_intrinsic_ishftc): Likewise.
2079 (gfc_conv_intrinsic_index_scan_verify): Likewise.
2080 (gfc_conv_intrinsic_merge): Likewise.
2081 (gfc_conv_intrinsic_trim): Likewise.
2082 * trans.c (gfc_trans_runtime_error_vararg): Likewise.
2084 2010-08-06 Thomas Koenig <tkoenig@gcc.gnu.org>
2087 * dependency.c (check_section_vs_section): Handle cases where
2088 the start expression coincides with the lower or upper
2091 2010-08-04 Janus Weil <janus@gcc.gnu.org>
2096 * class.c (gfc_find_derived_vtab): Do not generate vtabs for class
2097 container types. Do not artificially increase refs. Commit symbols one
2099 * interface.c (compare_parameter): Make sure vtabs are present before
2100 generating module variables.
2101 * resolve.c (resolve_allocate_expr): Ditto.
2103 2010-08-04 Tobias Burnus <burnus@net-b.de>
2107 * resolve.c (resolve_structure_cons): Fix
2110 2010-08-04 Mikael Morin <mikael@gcc.gnu.org>
2114 * symbol.c (changed_syms): Made static again.
2115 (gfc_symbol_state): Don't conditionalize on GFC_DEBUG.
2116 Changed conditional internal error into assert.
2117 Rename function to ...
2118 (gfc_enforce_clean_symbol_state): ... this.
2119 * gfortran.h (gfc_symbol_state, gfc_enforce_clean_symbol_state):
2120 Rename the former to the latter.
2121 * parse.c (decode_statement, decode_omp_directive,
2122 decode_gcc_attribute): Update callers accordingly. Don't conditionalize
2124 (changed_syms): Remove declaration.
2125 (next_statement): Use gfc_enforce_clean_symbol_state.
2127 2010-08-04 Tobias Burnus <burnus@net-b.de>
2130 * resolve.c (resolve_structure_cons): Fix handling of
2131 initialization structure constructors with character
2132 elements of the wrong length.
2133 * array.c (gfc_check_iter_variable): Add NULL check.
2134 (gfc_resolve_character_array_constructor): Also truncate
2137 2010-08-04 Tobias Burnus <burnus@net-b.de>
2139 * trans-io.c (gfc_build_io_library_fndecls): Fix return
2140 value of some libgfortran functions.
2142 2010-08-03 Thomas Koenig <tkoenig@gcc.gnu.org>
2145 * dependency.c (gfc_deb_compare_expr): Remove any integer
2146 conversion functions to larger types from both arguments.
2147 Remove handling these functions futher down.
2149 2010-08-03 Janus Weil <janus@gcc.gnu.org>
2153 * class.c (add_procs_to_declared_vtab1): Don't add erroneous procedures.
2154 * resolve.c (resolve_tb_generic_targets): Check for errors.
2156 2010-08-02 Thomas Koenig <tkoenig@gcc.gnu.org>
2159 * depencency.c (gfc_dep_resolver): Fix logic for when a loop
2162 2010-08-02 Thomas Koenig <tkoenig@gcc.gnu.org>
2165 * dependency.h: Add prototype for gfc_are_identical_variables.
2166 * frontend-passes.c: Include depencency.h.
2167 (optimimize_equality): Use gfc_are_identical_variables.
2168 * dependency.c (identical_array_ref): New function.
2169 (gfc_are_identical_variables): New function.
2170 (gfc_deb_compare_expr): Use gfc_are_identical_variables.
2171 * dependency.c (gfc_check_section_vs_section). Rename gfc_
2172 prefix from statc function.
2173 (check_section_vs_section): Change arguments to gfc_array_ref,
2174 adjust function body accordingly.
2176 2010-08-02 Mikael Morin <mikael@gcc.gnu.org>
2177 Janus Weil <janus@gcc.gnu.org>
2182 * intrinsic.c (gfc_get_intrinsic_sub_symbol): Commit changed symbol.
2183 * symbol.c (gen_cptr_param, gen_fptr_param, gen_shape_param,
2184 gfc_copy_formal_args, gfc_copy_formal_args_intr,
2185 gfc_copy_formal_args_ppc, generate_isocbinding_symbol): Ditto.
2186 * parse.c (parse_derived_contains, parse_spec, parse_progunit):
2187 Call reject_statement in case of error.
2188 (match_deferred_characteritics): Call gfc_undo_symbols in case match
2191 2010-08-01 Janus Weil <janus@gcc.gnu.org>
2194 * class.c (gfc_build_class_symbol): Make '$vptr' component private.
2195 (gfc_find_derived_vtab): Make vtabs and vtypes public.
2196 * module.c (read_module): When reading module files, always import
2197 vtab and vtype symbols.
2199 2010-07-31 Mikael Morin <mikael@gcc.gnu.org>
2203 * symbol.c (changed_syms): Made non-static.
2204 * parse.c (changed_syms): Declare new external.
2205 (next_statement): Assert changed_syms is NULL at the beginning.
2207 2010-07-30 Janus Weil <janus@gcc.gnu.org>
2208 Steven G. Kargl <kargl@gcc.gnu.org>
2211 * match.c (match_type_spec): Try to parse derived types before
2214 2010-07-30 Mikael Morin <mikael@gcc.gnu.org>
2216 * gfortran.h (gfc_release_symbol): New prototype.
2217 * symbol.c (gfc_release_symbol): New. Code taken from free_sym_tree.
2218 (gfc_undo_symbols, free_sym_tree, gfc_free_finalizer):
2219 Use gfc_release_symbol.
2220 * parse.c (gfc_fixup_sibling_symbols): Ditto.
2221 * resolve.c (resolve_symbol): Ditto.
2223 2010-07-29 Tobias Burnus <burnus@net-b.de>
2227 * trans-decl.c (gfc_get_extern_function_decl): Correctly handle
2228 external procedure declarations in modules.
2229 (gfc_get_symbol_decl): Modify assert.
2231 2010-07-29 Janus Weil <janus@gcc.gnu.org>
2234 * resolve.c (resolve_fl_derived): Call gfc_resolve_array_spec.
2236 2010-07-29 Janus Weil <janus@gcc.gnu.org>
2239 * trans-stmt.h (gfc_trans_class_init_assign): New prototype.
2240 (gfc_trans_class_assign): Modified prototype.
2241 * trans.h (gfc_conv_intrinsic_move_alloc): New prototype.
2242 * trans-expr.c (gfc_trans_class_init_assign): Split off from ...
2243 (gfc_trans_class_assign): ... here. Modified actual arguments.
2244 * trans-intrinsic.c (gfc_conv_intrinsic_move_alloc): New function to
2245 handle the MOVE_ALLOC intrinsic with scalar and class arguments.
2246 * trans.c (trans_code): Call 'gfc_conv_intrinsic_move_alloc'.
2248 2010-07-29 Mikael Morin <mikael@gcc.gnu.org>
2252 * class.c (gfc_find_derived_vtab): Accept or discard newly created
2253 symbols before returning.
2255 2010-07-29 Joseph Myers <joseph@codesourcery.com>
2257 * lang.opt (cpp): Remove Joined and Separate markers.
2258 (cpp=): New internal option.
2259 * lang-specs.h (F951_CPP_OPTIONS): Generate -cpp= option.
2260 * cpp.c (gfc_cpp_handle_option): Handle OPT_cpp_ instead of
2263 2010-07-29 Daniel Kraft <d@domob.eu>
2266 * array.c (resolve_array_bound): Fix error message to properly handle
2267 non-variable expressions.
2269 2010-07-28 Mikael Morin <mikael@gcc.gnu.org>
2271 * decl.c (free_value): Also free repeat field.
2272 * data.c (gfc_assign_data_value): Always free offset before returning.
2274 2010-07-28 Daniel Kraft <d@domob.eu>
2276 * gfortran.h (gfc_build_intrinsic_call): New method.
2277 * expr.c (gfc_build_intrinsic_call): New method.
2278 * simplify.c (range_check): Ignore non-constant value.
2279 (simplify_bound_dim): Handle non-variable expressions and
2280 fix memory leak with non-free'ed expression.
2281 (simplify_bound): Handle non-variable expressions.
2282 (gfc_simplify_shape): Ditto.
2283 (gfc_simplify_size): Ditto, but only in certain cases possible.
2285 2010-07-28 Joseph Myers <joseph@codesourcery.com>
2287 * gfortranspec.c (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
2290 2010-07-28 Tobias Burnus <burnus@net-b.de>
2293 * trans-types.c (gfc_get_derived_type): Fix DT declaration
2294 from modules for whole-file mode.
2296 2010-07-27 Joseph Myers <joseph@codesourcery.com>
2298 * gfortran.h (gfc_handle_option): Update prototype and return
2300 * options.c (gfc_handle_option): Update prototype and return value
2303 2010-07-27 Joseph Myers <joseph@codesourcery.com>
2305 * cpp.c (gfc_cpp_init_options): Update prototype. Use number of
2306 decoded options in allocating deferred_opt.
2307 * cpp.h (gfc_cpp_init_options): Update prototype.
2308 * f95-lang.c (LANG_HOOKS_OPTION_LANG_MASK): Define.
2309 * gfortran.h (gfc_option_lang_mask): New.
2310 (gfc_init_options): Update prototype.
2311 * options.c (gfc_option_lang_mask): New.
2312 (gfc_init_options): Update prototype. Pass new arguments to
2313 gfc_cpp_init_options.
2315 2010-07-26 Tobias Burnus <burnus@net-b.de>
2318 * trans-decl.c (gfc_get_extern_function_decl): Fix generation
2319 for functions which are later in the same file.
2320 (gfc_create_function_decl, build_function_decl,
2321 build_entry_thunks): Add global argument.
2322 * trans.c (gfc_generate_module_code): Update
2323 gfc_create_function_decl call.
2324 * trans.h (gfc_create_function_decl): Update prototype.
2325 * resolve.c (resolve_global_procedure): Also resolve for
2328 2010-07-26 Richard Henderson <rth@redhat.com>
2331 * f95-lang.c (LANG_HOOKS_WRITE_GLOBALS): New.
2332 (gfc_write_global_declarations): New.
2334 2010-07-26 Tobias Burnus <burnus@net-b.de>
2337 * trans-io.c (build_dt): Use NULL_TREE rather than NULL
2338 for call to transfer_namelist_element.
2339 * trans-decl.c (gfc_get_symbol_decl): Also set sym->backend_decl
2342 2010-07-25 Thomas Koenig <tkoenig@gcc.gnu.org>
2345 * Make-lang.in: Add fortran/frontend-passes.o.
2346 * gfortran.h: Add prototype for gfc_run_passes.
2347 * resolve.c (gfc_resolve): Call gfc_run_passes.
2348 * frontend-passes.c: New file.
2350 2010-07-25 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2353 * scanner.c (gfc_next_char_literal): Enable truncation warning for
2356 2010-07-25 Mikael Morin <mikael@gcc.gnu.org>
2359 * gfortran.h (gfc_namespace): New field old_equiv.
2360 (gfc_free_equiv_until): New prototype.
2361 * match.c (gfc_free_equiv_until): New, renamed from gfc_free_equiv with
2362 a parameterized stop condition.
2363 (gfc_free_equiv): Use gfc_free_equiv_until.
2364 * parse.c (next_statement): Save equivalence list.
2365 (reject_statement): Restore equivalence list.
2367 2010-07-25 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2370 * scanner.c (gfc_next_char_literal): Move check for truncation earlier
2371 in the function so that it does not get missed by early exits.
2372 (load_line): Add checks for quoted strings and free form comments to
2373 disable warnings on comments. Add check for ampersand as first
2374 character after truncation and don't warn for this case, but warn if
2375 there are subsequent non-whitespace characters.
2377 2010-07-24 Tobias Burnus <burnus@net-b.de>
2380 * parse.c (gfc_parse_file): Do not override
2381 gfc_global_ns_list items.
2383 2010-07-24 Tobias Burnus <burnus@net-b.de>
2385 * options.c (gfc_init_options): Enable -fwhole-file by default.
2386 * interface.c (compare_parameter): Assume a Hollerith constant is
2387 compatible with all other argument types.
2389 2010-07-23 Tobias Burnus <burnus@net-b.de>
2392 * trans-decl.c (gfc_get_symbol_decl): Use module decl with
2393 -fwhole-file also for derived types.
2394 * trans-types.c (copy_dt_decls_ifequal): Remove static and
2395 rename to gfc_copy_dt_decls_ifequal.
2396 (gfc_get_derived_type): Update call.
2397 * trans-types.h (gfc_copy_dt_decls_ifequal): Add prototype.
2399 2010-07-23 Tobias Burnus <burnus@net-b.de>
2402 * resolve.c (resolve_global_procedure): Properly handle ENTRY.
2404 2010-07-23 Jakub Jelinek <jakub@redhat.com>
2406 * trans-types.c (gfc_get_array_descriptor_base,
2407 gfc_get_array_type_bounds): Set TYPE_NAMELESS.
2408 * trans-decl.c (gfc_build_qualified_array): Set DECL_NAMELESS
2409 instead of clearing DECL_NAME.
2410 (gfc_build_dummy_array_decl): Set DECL_NAMELESS.
2412 2009-07-23 Paul Thomas <pault@gcc.gnu.org>
2415 * trans-array.c (gfc_init_loopinfo): Initialize the reverse
2417 gfc_trans_scalarized_loop_end: If reverse set in dimension n,
2418 reverse the scalarization loop.
2419 gfc_conv_resolve_dependencies: Pass the reverse field of the
2420 loopinfo to gfc_dep_resolver.
2421 trans-expr.c (gfc_trans_assignment_1): Enable loop reversal for
2422 assignment by resetting loop.reverse.
2423 gfortran.h : Add the gfc_reverse enum.
2424 trans.h : Add the reverse field to gfc_loopinfo.
2425 dependency.c (gfc_check_dependency): Pass null to the new arg
2426 of gfc_dep_resolver.
2427 (gfc_check_section_vs_section): Check for reverse dependencies.
2428 (gfc_dep_resolver): Add reverse argument and deal with the loop
2430 dependency.h : Modify prototype for gfc_dep_resolver to include
2433 2010-07-23 Daniel Kraft <d@domob.eu>
2436 * gfortran.h (gfc_find_symtree_in_proc): New method.
2437 * symbol.c (gfc_find_symtree_in_proc): New method.
2438 * match.c (match_exit_cycle): Look for loop name also in parent
2439 namespaces within current procedure.
2441 2010-07-22 Tobias Burnus <burnus@net-b.de>
2444 * dependency.c (gfc_check_dependency): Add argument alising check.
2445 * symbol.c (gfc_symbols_could_alias): Add argument alising check.
2447 2010-07-22 Daniel Kraft <d@domob.eu>
2449 * trans-stmt.c (gfc_trans_return): Put back in the handling of se.post,
2450 now in the correct place.
2452 2010-07-21 Steven G. Kargl <kargl@gcc.gnu.org>
2455 * Revert my commit r162325.
2457 2010-07-21 Daniel Kraft <d@domob.eu>
2459 * trans.h (gfc_get_return_label): Removed.
2460 (gfc_generate_return): New method.
2461 (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
2462 returning a tree directly.
2463 * trans-stmt.c (gfc_trans_return): Use `gfc_generate_return'.
2464 (gfc_trans_block_construct): Update for new interface to
2465 `gfc_trans_deferred_vars'.
2466 * trans-decl.c (current_function_return_label): Removed.
2467 (current_procedure_symbol): New variable.
2468 (gfc_get_return_label): Removed.
2469 (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
2470 returning a tree directly.
2471 (get_proc_result), (gfc_generate_return): New methods.
2472 (gfc_generate_function_code): Clean up and do init/cleanup here
2473 also with gfc_wrapped_block. Remove return-label but rather
2476 2010-07-19 Steven G. Kargl <kargl@gcc.gnu.org>
2479 * fortran/match.c (match_type_spec): Check for derived type before
2482 2010-07-19 Paul Thomas <pault@gcc.gnu.org>
2485 * interface.c (matching_typebound_op): Add argument for the
2486 return of the generic name for the procedure.
2487 (build_compcall_for_operator): Add an argument for the generic
2488 name of an operator procedure and supply it to the expression.
2489 (gfc_extend_expr, gfc_extend_assign): Use the generic name in
2490 calls to the above procedures.
2491 * resolve.c (resolve_typebound_function): Catch procedure
2492 component calls for CLASS objects, check that the vtable is
2493 complete and insert the $vptr and procedure components, to make
2495 (resolve_typebound_function): The same.
2496 * trans-decl.c (gfc_trans_deferred_vars): Do not deallocate
2497 an allocatable scalar if it is a result.
2499 2010-07-19 Paul Thomas <pault@gcc.gnu.org>
2502 * match.c (gfc_match_iterator): Reverted.
2504 2010-07-18 Paul Thomas <pault@gcc.gnu.org>
2507 * match.c (gfc_match_iterator): Remove error that iterator
2508 cannot be INTENT(IN).
2510 2010-07-17 Mikael Morin <mikael@gcc.gnu.org>
2512 * trans-array.c (gfc_free_ss): Don't free beyond ss rank.
2513 Access subscript through the "dim" field index.
2514 (gfc_trans_create_temp_array): Access ss info through the "dim" field
2516 (gfc_conv_array_index_offset): Ditto.
2517 (gfc_conv_loop_setup): Ditto.
2518 (gfc_conv_expr_descriptor): Ditto.
2519 (gfc_conv_ss_startstride): Ditto. Update call to
2520 gfc_conv_section_startstride.
2521 (gfc_conv_section_startstride): Set values along the array dimension.
2522 Get array dimension directly from the argument.
2524 2010-07-15 Jakub Jelinek <jakub@redhat.com>
2526 * trans.h (gfc_string_to_single_character): New prototype.
2527 * trans-expr.c (string_to_single_character): Renamed to ...
2528 (gfc_string_to_single_character): ... this. No longer static.
2529 (gfc_conv_scalar_char_value, gfc_build_compare_string,
2530 gfc_trans_string_copy): Adjust callers.
2531 * config-lang.in (gtfiles): Add fortran/trans-stmt.c.
2532 * trans-stmt.c: Include ggc.h and gt-fortran-trans-stmt.h.
2533 (select_struct): Move to toplevel, add GTY(()).
2534 (gfc_trans_character_select): Optimize SELECT CASE
2535 with character length 1.
2537 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
2539 * f95-lang.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
2540 * trans-common.c: Likewise.
2541 * trans-decl.c: Likewise.
2542 * trans-types.c: Likewise.
2543 * trans.c: Likewise.
2545 2010-07-15 Janus Weil <janus@gcc.gnu.org>
2548 * resolve.c (resolve_typebound_generic_call): Resolve generic
2549 non-polymorphic type-bound procedure calls to the correct specific
2551 (resolve_typebound_subroutine): Remove superfluous code.
2553 2010-07-15 Daniel Kraft <d@domob.eu>
2556 * trans.h (struct gfc_wrapped_block): New struct.
2557 (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
2558 (gfc_finish_wrapped_block): New method.
2559 (gfc_init_default_dt): Add new init code to block rather than
2561 * trans-array.h (gfc_trans_auto_array_allocation): Use gfc_wrapped_block
2562 (gfc_trans_dummy_array_bias): Ditto.
2563 (gfc_trans_g77_array): Ditto.
2564 (gfc_trans_deferred_array): Ditto.
2565 * trans.c (gfc_add_expr_to_block): Call add_expr_to_chain.
2566 (add_expr_to_chain): New method based on old gfc_add_expr_to_block.
2567 (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
2568 (gfc_finish_wrapped_block): New method.
2569 * trans-array.c (gfc_trans_auto_array_allocation): use gfc_wrapped_block
2570 (gfc_trans_g77_array), (gfc_trans_dummy_array_bias): Ditto.
2571 (gfc_trans_deferred_array): Ditto.
2572 * trans-decl.c (gfc_trans_dummy_character): Ditto.
2573 (gfc_trans_auto_character_variable), (gfc_trans_assign_aux_var): Ditto.
2574 (init_intent_out_dt): Ditto.
2575 (gfc_init_default_dt): Add new init code to block rather than
2577 (gfc_trans_deferred_vars): Use gfc_wrapped_block to collect all init
2578 and cleanup code and put it all together.
2580 2010-07-15 Jakub Jelinek <jakub@redhat.com>
2582 * trans.h (gfc_build_compare_string): Add CODE argument.
2583 * trans-intrinsic.c (gfc_conv_intrinsic_strcmp): Pass OP to
2584 gfc_build_compare_string.
2585 * trans-expr.c (gfc_conv_expr_op): Pass CODE to
2586 gfc_build_compare_string.
2587 (string_to_single_character): Rename len variable to length.
2588 (gfc_optimize_len_trim): New function.
2589 (gfc_build_compare_string): Add CODE argument. If it is EQ_EXPR
2590 or NE_EXPR and one of the strings is string literal with LEN_TRIM
2591 bigger than the length of the other string, they compare unequal.
2594 * trans-stmt.c (gfc_trans_character_select): Always use NULL for high
2595 in CASE_LABEL_EXPR and use NULL for low for the default case.
2597 2010-07-14 Mikael Morin <mikael@gcc.gnu.org>
2599 * trans-array.c (gfc_conv_section_upper_bound): Remove
2600 (gfc_conv_section_startstride): Don't set the upper bound in the
2601 vector subscript case.
2602 (gfc_conv_loop_setup): Don't use gfc_conv_section_upper_bound
2604 2010-07-14 Janus Weil <janus@gcc.gnu.org>
2607 * gfortran.h (gfc_is_data_pointer): Remove prototype.
2608 * dependency.c (gfc_is_data_pointer): Make it static.
2609 * intrinsic.texi: Update documentation on C_LOC.
2610 * resolve.c (gfc_iso_c_func_interface): Fix pointer and target checks
2611 and add a check for polymorphic variables.
2613 2010-07-14 Jakub Jelinek <jakub@redhat.com>
2615 * trans-expr.c (string_to_single_character): Also optimize
2616 string literals containing a single char followed only by spaces.
2617 (gfc_trans_string_copy): Remove redundant string_to_single_character
2620 * trans-decl.c (gfc_build_intrinsic_function_decls,
2621 gfc_build_builtin_function_decls): Mark functions as
2622 DECL_PURE_P or TREE_READONLY.
2624 2010-07-13 Nathan Froyd <froydnj@codesourcery.com>
2626 * trans-decl.c (build_entry_thunks): Call build_call_expr_loc_vec
2627 instead of build_function_call_expr.
2628 * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Likewise.
2630 2010-07-13 Tobias Burnus <burnus@net-b.de>
2631 Daniel Franke <franke.daniel@gmail.com>
2634 * trans.h (gfc_build_library_function_decl_with_spec): New prototype.
2635 * trans-decl.c (gfc_build_library_function_decl_with_spec): Removed
2637 * trans-io (gfc_build_io_library_fndecls): Add "fn spec" annotations.
2639 2010-07-13 Daniel Franke <franke.daniel@gmail.com>
2640 Tobias Burnus <burnus@net-b.de>
2643 * trans-decl.c (gfc_build_intrinsic_function_decls): Add
2644 noclobber/noescape annotations to function calls.
2645 (gfc_build_builtin_function_decls): Likewise.
2647 2010-07-13 Janus Weil <janus@gcc.gnu.org>
2653 * gfortran.h (gfc_find_derived_vtab): Modified prototype.
2654 * class.c (gfc_build_class_symbol): Modified call to
2655 'gfc_find_derived_vtab'.
2656 (add_proc_component): Removed, moved code into 'add_proc_comp'.
2657 (add_proc_comps): Renamed to 'add_proc_comp', removed treatment of
2659 (add_procs_to_declared_vtab1): Removed unnecessary argument 'resolved'.
2660 Removed treatment of generics.
2661 (copy_vtab_proc_comps): Removed unnecessary argument 'resolved'.
2662 Call 'add_proc_comp' instead of duplicating code.
2663 (add_procs_to_declared_vtab): Removed unnecessary arguments 'resolved'
2665 (add_generic_specifics,add_generics_to_declared_vtab): Removed.
2666 (gfc_find_derived_vtab): Removed unnecessary argument 'resolved'.
2667 Removed treatment of generics.
2668 * iresolve.c (gfc_resolve_extends_type_of): Modified call to
2669 'gfc_find_derived_vtab'.
2670 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
2671 Removed treatment of generics.
2672 (resolve_select_type,resolve_fl_derived): Modified call to
2673 'gfc_find_derived_vtab'.
2674 * trans-decl.c (gfc_get_symbol_decl): Ditto.
2675 * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
2677 * trans-stmt.c (gfc_trans_allocate): Ditto.
2679 2010-07-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2682 * trans-io.c (build_dt): Set common.unit to flag chracter(kind=4)
2685 2010-07-12 Mikael Morin <mikael@gcc.gnu.org>
2687 * expr.c (gfc_get_int_expr): Don't initialize mpfr data twice.
2688 * resolve.c (build_default_init_expr): Ditto.
2690 2010-07-11 Tobias Burnus <burnus@net-b.de>
2693 * module.c (sort_iso_c_rename_list): Remove.
2694 (import_iso_c_binding_module,use_iso_fortran_env_module):
2695 Allow multiple imports of the same symbol.
2697 2010-07-11 Mikael Morin <mikael@gcc.gnu.org>
2699 * arith.c (gfc_arith_done_1): Release mpfr internal caches.
2701 2010-07-11 Janus Weil <janus@gcc.gnu.org>
2704 * decl.c (build_sym,attr_decl1): Only build the class container if the
2705 symbol has sufficient attributes.
2706 * expr.c (gfc_check_pointer_assign): Use class_pointer instead of
2707 pointer attribute for classes.
2708 * match.c (gfc_match_allocate,gfc_match_deallocate): Ditto.
2709 * module.c (MOD_VERSION): Bump.
2710 (enum ab_attribute,attr_bits): Add AB_CLASS_POINTER.
2711 (mio_symbol_attribute): Handle class_pointer attribute.
2712 * parse.c (parse_derived): Use class_pointer instead of pointer
2713 attribute for classes.
2714 * primary.c (gfc_variable_attr,gfc_expr_attr): Ditto.
2715 * resolve.c (resolve_structure_cons,resolve_deallocate_expr,
2716 resolve_allocate_expr,resolve_fl_derived): Ditto.
2717 (resolve_fl_var_and_proc): Check for class_ok attribute.
2719 2010-07-10 Mikael Morin <mikael@gcc.gnu.org>
2721 * trans-io.c (gfc_build_st_parameter): Update calls to
2722 gfc_add_field_to_struct.
2723 * trans-stmt.c (ADD_FIELD): Ditto.
2725 (gfc_get_derived_type): Ditto. Don't create backend_decl for C_PTR's
2727 (gfc_add_field_to_struct_1): Set TYPE_FIELDS(context) instead of
2728 fieldlist, remove fieldlist from argument list.
2729 (gfc_add_field_to_struct): Update call to gfc_add_field_to_struct_1
2730 and remove fieldlist from argument list.
2731 (gfc_get_desc_dim_type, gfc_get_array_descriptor_base,
2732 gfc_get_mixed_entry_union): Move setting
2733 TYPE_FIELDS to gfc_add_field_to_struct_1 and update calls to it.
2734 * trans-types.h (gfc_add_field_to_struct): Update prototype.
2736 2010-07-10 Paul Thomas <pault@gcc.gnu.org>
2739 * trans-expr.c (arrayfunc_assign_needs_temporary): No temporary
2740 if the lhs has never been host associated, as well as not being
2741 use associated, a pointer or a target.
2742 * resolve.c (resolve_variable): Mark variables that are host
2744 * gfortran.h: Add the host_assoc bit to the symbol_attribute
2747 2010-07-09 Janus Weil <janus@gcc.gnu.org>
2749 * intrinsic.texi: Add documentation for SAME_TYPE_AS, EXTENDS_TYPE_OF,
2750 STORAGE_SIZE, C_NULL_PTR and C_NULL_FUNPTR. Modify documentation of
2751 SIZEOF and C_SIZEOF.
2753 2010-07-08 Janus Weil <janus@gcc.gnu.org>
2756 * gfortran.h (gfc_isym_id): Add GFC_ISYM_C_SIZEOF,GFC_ISYM_STORAGE_SIZE.
2757 * intrinsic.h (gfc_check_c_sizeof,gfc_check_storage_size,
2758 gfc_resolve_storage_size): New prototypes.
2759 * check.c (gfc_check_c_sizeof,gfc_check_storage_size): New functions.
2760 * intrinsic.c (add_functions): Add STORAGE_SIZE.
2761 * iresolve.c (gfc_resolve_storage_size): New function.
2762 * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Handle polymorphic
2764 (gfc_conv_intrinsic_storage_size): New function.
2765 (gfc_conv_intrinsic_function): Handle STORAGE_SIZE.
2767 2010-07-08 Jakub Jelinek <jakub@redhat.com>
2770 * match.c (match_exit_cycle): Error on EXIT also from collapsed
2771 !$omp do loops. Error on CYCLE to non-innermost collapsed
2774 2010-07-08 Tobias Burnus <burnus@net-b.de>
2777 * array.c (gfc_match_array_ref): Better error message for
2778 coarrays with too few ranks.
2779 (match_subscript): Move one diagnostic to caller.
2780 * gfortran.h (gfc_get_corank): Add prottype.
2781 * expr.c (gfc_get_corank): New function.
2782 * iresolve.c (resolve_bound): Fix rank for cobounds.
2783 (gfc_resolve_lbound,gfc_resolve_lcobound, gfc_resolve_ubound,
2784 gfc_resolve_ucobound, gfc_resolve_this_image): Update
2787 2010-07-06 Tobias Burnus <burnus@net-b.de>
2790 * array.c (gfc_expand_constructor): Add optional diagnostic.
2791 * gfortran.h (gfc_expand_constructor): Update prototype.
2792 * expr.c (gfc_simplify_expr, check_init_expr,
2793 gfc_reduce_init_expr): Update gfc_expand_constructor call.
2794 * resolve.c (gfc_resolve_expr): Ditto.
2796 2010-07-06 Tobias Burnus <burnus@net-b.de>
2798 * trans-decl.c: Include diagnostic-core.h besides toplev.h.
2799 * trans-intrinsic.c: Ditto.
2800 * trans-types.c: Ditto.
2801 * convert.c: Include diagnostic-core.h instead of toplev.h.
2803 * trans-array.c: Ditto.
2804 * trans-const.c: Ditto.
2805 * trans-expr.c: Ditto.
2806 * trans-io.c: Ditto.
2807 * trans-openmp.c: Ditto.
2810 2010-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
2813 * check.c (dim_rank_check): Also check intrinsic functions.
2814 Adjust permissible rank for functions which reduce the rank of
2815 their argument. Spread is an exception, where DIM can
2816 be one larger than the rank of array.
2818 2010-07-05 Steven G. Kargl <kargl@gcc.gnu.org>
2821 * fortran/io.c (resolve_tag): Check EXIST tag is a default logical.
2823 2010-07-05 Paul Thomas <pault@gcc.gnu.org>
2826 * trans-types.c (gfc_get_derived_type): Derived type fields
2827 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set
2828 but build_pointer_type_for_mode must be used for this.
2830 2010-07-05 Nathan Froyd <froydnj@codesourcery.com>
2832 * trans.h (gfc_conv_procedure_call): Take a VEC instead of a tree.
2833 * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Adjust for new
2834 type of gfc_conv_procedure_call.
2835 (conv_generic_with_optional_char_arg): Likewise.
2836 * trans-stmt.c (gfc_trans_call): Likewise.
2837 * trans-expr.c (gfc_conv_function_expr): Likewise.
2838 (gfc_conv_procedure_call): Use build_call_vec instead of
2841 2010-07-04 Daniel Kraft <d@domob.eu>
2843 * gfc-internals.texi (gfc_code): Document BLOCK and ASSOCIATE.
2845 2010-07-04 Paul Thomas <pault@gcc.gnu.org>
2849 * trans-types.c (gfc_get_derived_type): Derived type fields
2850 with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set.
2852 2010-07-02 Mikael Morin <mikael@gcc.gnu.org>
2855 * decl.c (match_procedure_in_type): Clear structure before using.
2856 (gfc_match_generic): Ditto.
2858 2010-07-02 Nathan Froyd <froydnj@codesourcery.com>
2860 * trans-types.h (gfc_add_field_to_struct): Add tree ** parameter.
2861 * trans-types.c (gfc_add_field_to_struct_1): New function, most
2862 of which comes from...
2863 (gfc_add_field_to_struct): ...here. Call it. Add new parameter.
2864 (gfc_get_desc_dim_type): Call gfc_add_field_to_struct_1 for
2866 (gfc_get_array_descriptor_base): Likewise.
2867 (gfc_get_mixed_entry_union): Likewise.
2868 (gfc_get_derived_type): Add extra chain parameter for
2869 gfc_add_field_to_struct.
2870 * trans-stmt.c (gfc_trans_character_select): Likewise.
2871 * trans-io.c (gfc_build_st_parameter): Likewise.
2873 2010-06-29 Janus Weil <janus@gcc.gnu.org>
2876 * resolve.c (is_external_proc): Prevent procedure pointers from being
2877 regarded as external procedures.
2879 2010-06-29 Janus Weil <janus@gcc.gnu.org>
2882 * trans-intrinsic.c (gfc_conv_associated): Handle polymorphic variables
2883 passed as second argument of ASSOCIATED.
2885 2010-06-29 Paul Thomas <pault@gcc.gnu.org>
2888 * trans-expr.c (arrayfunc_assign_needs_temporary): New function
2889 to determine if a function assignment can be made without a
2891 (gfc_trans_arrayfunc_assign): Move all the conditions that
2892 suppress the direct function call to the above new functon and
2895 2010-06-28 Paul Thomas <pault@gcc.gnu.org>
2898 * interface.c (argument_rank_mismatch): New function.
2899 (compare_parameter): Call new function instead of generating
2902 2010-06-28 Nathan Froyd <froydnj@codesourcery.com>
2904 * trans-openmp.c (dovar_init): Define. Define VECs containing it.
2905 (gfc_trans_omp_do): Use a VEC to accumulate variables and their
2908 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
2910 * Make-lang.in: Update dependencies.
2912 2010-06-27 Nathan Froyd <froydnj@codesourcery.com>
2914 * gfortran.h (gfc_code): Split backend_decl field into cycle_label
2915 and exit_label fields.
2916 * trans-openmp.c (gfc_trans_omp_do): Assign to new fields
2918 * trans-stmt.c (gfc_trans_simple_do): Likewise.
2919 (gfc_trans_do): Likewise.
2920 (gfc_trans_do_while): Likewise.
2921 (gfc_trans_cycle): Use cycle_label directly.
2922 (gfc_trans_exit): Use exit_label directly.
2924 2010-06-27 Daniel Kraft <d@domob.eu>
2926 * dump-parse-tree.c (show_symbol): Dump target-expression for
2928 (show_code_node): Make distinction between BLOCK and ASSOCIATE.
2929 (show_namespace): Use show_level for correct indentation of
2930 "inner namespaces" (contained procedures or BLOCK).
2932 2010-06-27 Thomas Koenig <tkoenig@gcc.gnu.org>
2935 * dump-parse-tree.c (show_code_node): Show namespace for
2938 2010-06-26 Tobias Burnus <burnus@net-b.de>
2940 * decl.c (gfc_match_decl_type_spec): Support
2941 TYPE(intrinsic-type-spec).
2943 2010-06-25 Tobias Burnus <burnus@net-b.de>
2945 * intrinsic.h (gfc_check_selected_real_kind,
2946 gfc_simplify_selected_real_kind): Update prototypes.
2947 * intrinsic.c (add_functions): Add radix support to
2949 * check.c (gfc_check_selected_real_kind): Ditto.
2950 * simplify.c (gfc_simplify_selected_real_kind): Ditto.
2951 * trans-decl.c (gfc_build_intrinsic_function_decls):
2952 Change call from selected_real_kind to selected_real_kind2008.
2953 * intrinsic.texi (SELECTED_REAL_KIND): Update for radix.
2954 (PRECISION, RANGE, RADIX): Add cross @refs.
2956 2010-06-25 Tobias Burnus <burnus@net-b.de>
2958 * decl.c (gfc_match_entry): Mark ENTRY as GFC_STD_F2008_OBS.
2959 * gfortran.texi (_gfortran_set_options): Update for
2960 GFC_STD_F2008_OBS addition.
2961 * libgfortran.h: Add GFC_STD_F2008_OBS.
2962 * options.c (set_default_std_flags, gfc_handle_option): Handle
2964 io.c (check_format): Fix allow_std check.
2966 2010-06-25 Tobias Burnus <burnus@net-b.de>
2968 * decl.c (gfc_match_entry): Allow END besides
2969 END SUBROUTINE/END FUNCTION for contained procedures.
2971 2010-06-25 Tobias Burnus <burnus@net-b.de>
2973 * parse.c (next_free, next_fixed): Allow ";" as first character.
2975 2010-06-24 Tobias Burnus <burnus@net-b.de>
2978 * decl.c (variable_decl): Fix IMPORT diagnostic for CLASS.
2980 2010-06-22 Janus Weil <janus@gcc.gnu.org>
2983 * resolve.c (resolve_fl_derived): Avoid checking for abstract on class
2986 2010-06-21 Tobias Burnus <burnus@net-b.de>
2989 * interface.c (compare_parameter): Add gfc_is_simply_contiguous
2991 * symbol.c (gfc_add_contiguous): New function.
2992 (gfc_copy_attr, check_conflict): Handle contiguous attribute.
2993 * decl.c (match_attr_spec): Ditto.
2994 (gfc_match_contiguous): New function.
2995 * resolve.c (resolve_fl_derived, resolve_symbol): Handle
2997 * gfortran.h (symbol_attribute): Add contiguous.
2998 (gfc_is_simply_contiguous): Add prototype.
2999 (gfc_add_contiguous): Add prototype.
3000 * match.h (gfc_match_contiguous): Add prototype.
3001 * parse.c (decode_specification_statement,
3002 decode_statement): Handle contiguous attribute.
3003 * expr.c (gfc_is_simply_contiguous): New function.
3004 * dump-parse-tree.c (show_attr): Handle contiguous.
3005 * module.c (ab_attribute, attr_bits, mio_symbol_attribute):
3007 * trans-expr.c (gfc_add_interface_mapping): Copy
3009 * trans-array.c (gfc_conv_descriptor_stride_get,
3010 gfc_conv_array_parameter): Handle contiguous arrays.
3011 * trans-types.c (gfc_build_array_type, gfc_build_array_type,
3012 gfc_sym_type, gfc_get_derived_type, gfc_get_array_descr_info):
3014 * trans.h (gfc_array_kind): Ditto.
3015 * trans-decl.c (gfc_get_symbol_decl): Ditto.
3017 2010-06-20 Joseph Myers <joseph@codesourcery.com>
3019 * options.c (gfc_handle_option): Don't handle N_OPTS.
3021 2010-06-19 Janus Weil <janus@gcc.gnu.org>
3024 * resolve.c (resolve_fl_derived): Reverse ordering of conditions
3027 2010-06-18 Tobias Burnus <burnus@net-b.de>
3030 * resolve.c (resolve_allocate_deallocate): Properly check
3031 part-refs in stat=/errmsg= for invalid use.
3033 2010-06-17 Janus Weil <janus@gcc.gnu.org>
3036 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
3037 Return directly in case of an error.
3039 2010-06-16 Janus Weil <janus@gcc.gnu.org>
3042 * gfortran.h (gfc_get_typebound_proc): Modified Prototype.
3043 * decl.c (match_procedure_in_type): Give a unique gfc_typebound_proc
3044 structure to each procedure in a procedure list.
3045 * module.c (mio_typebound_proc): Add NULL argument to
3046 'gfc_get_typebound_proc'.
3047 * symbol.c (gfc_get_typebound_proc): Add a new argument, which is used
3048 to initialize the new structure.
3050 2010-06-15 Janus Weil <janus@gcc.gnu.org>
3053 * gfortran.h (gfc_expr): Add new member 'mold'.
3054 * match.c (gfc_match_allocate): Implement the MOLD tag.
3055 * resolve.c (resolve_allocate_expr): Ditto.
3056 * trans-stmt.c (gfc_trans_allocate): Ditto.
3058 2010-06-15 Jakub Jelinek <jakub@redhat.com>
3061 * trans-openmp.c (gfc_omp_predetermined_sharing): Don't return
3062 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with
3063 GFC_DECL_SAVED_DESCRIPTOR set.
3064 (gfc_omp_report_decl): New function.
3065 * trans.h (gfc_omp_report_decl): New prototype.
3066 * f95-lang.c (LANG_HOOKS_OMP_REPORT_DECL): Redefine.
3068 2010-06-13 Daniel Franke <franke.daniel@gmail.com>
3072 * gfortranspec.c (lang_specific_driver): Removed deprecation
3074 * lang.opt: Add options -M, -MM, -MD, -MMD, -MF, -MG, -MP, -MT, -MQ.
3075 * lang-specs.h (CPP_FORWARD_OPTIONS): Add -M* options.
3076 * cpp.h (gfc_cpp_makedep): New.
3077 (gfc_cpp_add_dep): New.
3078 (gfc_cpp_add_target): New.
3079 * cpp.c (gfc_cpp_option): Add deps* members.
3080 (gfc_cpp_makedep): New.
3081 (gfc_cpp_add_dep): New.
3082 (gfc_cpp_add_target): New.
3083 (gfc_cpp_init_options): Initialize new options.
3084 (gfc_cpp_handle_option): Handle new options.
3085 (gfc_cpp_post_options): Map new options to libcpp-options.
3086 (gfc_cpp_init): Handle deferred -MQ and -MT options.
3087 (gfc_cpp_done): If requested, write dependencies to file.
3088 * module.c (gfc_dump_module): Add a module filename as target.
3089 * scanner.c (open_included_file): New parameter system; add the
3090 included file as dependency.
3091 (gfc_open_included_file): Add the included file as dependency.
3092 (gfc_open_intrinsic_module): Likewise.
3093 * invoke.texi: Removed deprecation warning for -M.
3094 * gfortran.texi: Removed Makefile-dependencies project.
3096 2010-06-12 Daniel Franke <franke.daniel@gmail.com>
3098 * resolve.c (resolve_global_procedure): Improved checking if an
3099 explicit interface is required.
3101 2010-06-12 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3103 * trans-decl.c (gfc_build_intrinsic_function_decls): Fix
3105 * trans-intrinsic.c (gfc_conv_intrinsic_fdate): Fix argument type.
3106 (gfc_conv_intrinsic_ttynam): Likewise.
3107 (gfc_conv_intrinsic_trim): Likewise.
3109 2010-06-12 Janus Weil <janus@gcc.gnu.org>
3112 * decl.c (match_procedure_in_type): Allow procedure lists (F08).
3114 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3116 * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Fix comment.
3118 2010-06-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3120 * mathbuiltins.def: Add builtins that do not directly correspond
3121 to a Fortran intrinsic, with new macro OTHER_BUILTIN.
3122 * f95-lang.c (gfc_init_builtin_functions): Define OTHER_BUILTIN.
3123 * trans-intrinsic.c (gfc_intrinsic_map_t): Remove
3124 code_{r,c}{4,8,10,16} fields. Add
3125 {,complex}{float,double,long_double}_built_in fields.
3126 (gfc_intrinsic_map): Adjust definitions of DEFINE_MATH_BUILTIN,
3127 DEFINE_MATH_BUILTIN_C and LIB_FUNCTION accordingly. Add
3128 definition of OTHER_BUILTIN.
3129 (real_compnt_info): Remove unused struct.
3130 (builtin_decl_for_precision, builtin_decl_for_float_kind): New
3132 (build_round_expr): Call builtin_decl_for_precision instead of
3134 (gfc_conv_intrinsic_aint): Call builtin_decl_for_float_kind
3135 instead of a switch.
3136 (gfc_build_intrinsic_lib_fndecls): Match
3137 {real,complex}{4,8,10,16}decl into the C-style built_in_decls.
3138 (gfc_get_intrinsic_lib_fndecl): Do not hardcode floating-point
3140 (gfc_conv_intrinsic_lib_function): Go through all the extended
3142 (gfc_trans_same_strlen_check): Call builtin_decl_for_float_kind
3143 instead of a switch.
3144 (gfc_conv_intrinsic_abs): Likewise.
3145 (gfc_conv_intrinsic_mod): Likewise.
3146 (gfc_conv_intrinsic_sign): Likewise.
3147 (gfc_conv_intrinsic_fraction): Likewise.
3148 (gfc_conv_intrinsic_nearest): Likewise.
3149 (gfc_conv_intrinsic_spacing): Likewise.
3150 (gfc_conv_intrinsic_rrspacing): Likewise.
3151 (gfc_conv_intrinsic_scale): Likewise.
3152 (gfc_conv_intrinsic_set_exponent): Likewise.
3154 2010-06-11 Paul Thomas <pault@gcc.gnu.org>
3158 * trans-expr.c (gfc_conv_derived_to_class): Handle array-valued
3159 functions with CLASS formal arguments.
3161 2010-06-10 Janus Weil <janus@gcc.gnu.org>
3164 * resolve.c (conformable_arrays): Handle allocatable components.
3166 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3169 * gfortran.texi: Document that Cray pointers cannot be function
3172 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3175 * gfortran.texi: Document lack of support for syntax
3176 "complex FUNCTION name*16()", and existence of alternative
3177 legacy syntax "complex*16 FUNCTION name()".
3179 2010-06-10 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3182 * intrinsic.texi (FLUSH): Note the difference between FLUSH and
3183 POSIX's fsync(), and how to call the latter from Fortran code.
3185 2010-06-10 Daniel Franke <franke.daniel@gmail.com>
3188 * interface.c (compare_actual_formal): Reject actual arguments with
3189 array subscript passed to ASYNCHRONOUS dummys.
3191 2010-06-10 Daniel Kraft <d@domob.eu>
3194 * gfortran.h (enum gfc_statement): Add ST_ASSOCIATE, ST_END_ASSOCIATE.
3195 (struct gfc_symbol): New field `assoc'.
3196 (struct gfc_association_list): New struct.
3197 (struct gfc_code): New struct `block' in union, move `ns' there
3198 and add association list.
3199 (gfc_free_association_list): New method.
3200 (gfc_has_vector_subscript): Made public;
3201 * match.h (gfc_match_associate): New method.
3202 * parse.h (enum gfc_compile_state): Add COMP_ASSOCIATE.
3203 * decl.c (gfc_match_end): Handle ST_END_ASSOCIATE.
3204 * interface.c (gfc_has_vector_subscript): Made public.
3205 (compare_actual_formal): Rename `has_vector_subscript' accordingly.
3206 * match.c (gfc_match_associate): New method.
3207 (gfc_match_select_type): Change reference to gfc_code's `ns' field.
3208 * primary.c (match_variable): Don't allow names associated to expr here.
3209 * parse.c (decode_statement): Try matching ASSOCIATE statement.
3210 (case_exec_markers, case_end): Add ASSOCIATE statement.
3211 (gfc_ascii_statement): Hande ST_ASSOCIATE and ST_END_ASSOCIATE.
3212 (parse_associate): New method.
3213 (parse_executable): Handle ST_ASSOCIATE.
3214 (parse_block_construct): Change reference to gfc_code's `ns' field.
3215 * resolve.c (resolve_select_type): Ditto.
3216 (resolve_code): Ditto.
3217 (resolve_block_construct): Ditto and add comment.
3218 (resolve_select_type): Set association list in generated BLOCK to NULL.
3219 (resolve_symbol): Resolve associate names.
3220 * st.c (gfc_free_statement): Change reference to gfc_code's `ns' field
3221 and free association list.
3222 (gfc_free_association_list): New method.
3223 * symbol.c (gfc_new_symbol): NULL new field `assoc'.
3224 * trans-stmt.c (gfc_trans_block_construct): Change reference to
3225 gfc_code's `ns' field.
3227 2010-06-10 Kai Tietz <kai.tietz@onevision.com>
3229 * error.c (error_print): Pre-initialize loc by NULL.
3230 * openmp.c (resolve_omp_clauses): Add explicit
3231 braces to avoid ambigous else.
3232 * array.c (match_subscript): Pre-initialize m to MATCH_ERROR.
3234 2010-06-10 Gerald Pfeifer <gerald@pfeifer.com>
3236 * gfc-internals.texi: Move to GFDL 1.3.
3237 * gfortran.texi: Ditto.
3238 * intrinsic.texi: Ditto.
3239 * invoke.texi: Ditto.
3241 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
3244 * check.c (gfc_check_selected_real_kind): Verify that the
3245 actual arguments are scalar.
3247 2010-06-09 Daniel Franke <franke.daniel@gmail.com>
3250 * intrinsic.c (gfc_convert_type_warn): Further improve -Wconversion.
3252 2010-06-09 Janus Weil <janus@gcc.gnu.org>
3255 * dump-parse-tree.c (show_symbol): Avoid infinite loop.
3257 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
3259 * fortran/symbol.c (check_conflict): Remove an invalid conflict check.
3261 2010-06-09 Steven G. Kargl <kargl@gcc.gnu.org>
3263 * fortran/intrinsic.c (add_functions): Change gfc_check_btest,
3264 gfc_check_ibclr, and gfc_check_ibset to gfc_check_bitfcn.
3265 * fortran/intrinsic.h: Remove prototypes for gfc_check_btest,
3266 gfc_check_ibclr, and gfc_check_ibset. Add prototype for
3268 * fortran/check.c (nonnegative_check, less_than_bitsize1,
3269 less_than_bitsize2): New functions.
3270 (gfc_check_btest): Renamed to gfc_check_bitfcn. Use
3271 nonnegative_check and less_than_bitsize1.
3272 (gfc_check_ibclr, gfc_check_ibset): Removed.
3273 (gfc_check_ibits,gfc_check_mvbits): Use nonnegative_check and
3276 2010-06-09 Janus Weil <janus@gcc.gnu.org>
3279 * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
3282 2010-06-09 Kai Tietz <kai.tietz@onevision.com>
3284 * resolve.c (resolve_deallocate_expr): Avoid warning
3285 about possible use of iunitialized sym.
3286 (resolve_allocate_expr): Pre-initialize sym by NULL.
3288 2010-06-09 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3291 * f95-lang.c (gfc_init_builtin_functions): Remove comment.
3293 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
3295 * trans-types.c (gfc_get_nodesc_array_type): Use typed GC
3297 (gfc_get_array_type_bounds): Likewise.
3299 * trans-decl.c (gfc_allocate_lang_decl): Likewise.
3300 (gfc_find_module): Likewise.
3302 * f95-lang.c (pushlevel): Likewise.
3304 * trans.h (struct lang_type): Add variable_size GTY option.
3305 (struct lang_decl): Likewise.
3307 2010-06-08 Tobias Burnus <burnus@net-b.de>
3310 * symbol.c (check_conflict): Move protected--external/procedure check ...
3311 * resolve.c (resolve_select_type): ... to the resolution stage.
3313 2010-06-07 Tobias Burnus <burnus@net-b.de>
3315 * options.c (gfc_handle_option): Fix -fno-recursive.
3317 2010-06-07 Tobias Burnus <burnus@net-b.de>
3319 * gfc-internals.texi (copyrights-gfortran): Fix copyright year format.
3320 * gfortran.texi (copyrights-gfortran): Ditto.
3322 2010-06-07 Joseph Myers <joseph@codesourcery.com>
3324 * lang.opt (fshort-enums): Define using Var and VarExists.
3325 * options.c (gfc_handle_option): Don't set flag_short_enums here.
3327 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
3328 Janus Weil <janus@gcc.gnu.org>
3331 * resolve.c (get_declared_from_expr): Move to before
3332 resolve_typebound_generic_call. Make new_ref and class_ref
3333 ignorable if set to NULL.
3334 (resolve_typebound_generic_call): Once we have resolved the
3335 generic call, check that the specific instance is that which
3336 is bound to the declared type.
3337 (resolve_typebound_function,resolve_typebound_subroutine): Avoid
3338 freeing 'class_ref->next' twice.
3340 2010-06-05 Paul Thomas <pault@gcc.gnu.org>
3343 * trans-array.c (structure_alloc_comps): Dereference scalar
3344 'decl' if it is a REFERENCE_TYPE. Tidy expressions containing
3347 2010-06-04 Joseph Myers <joseph@codesourcery.com>
3349 * gfortranspec.c (append_arg, lang_specific_driver): Use
3350 GCC-specific formats in diagnostics.
3352 2010-06-02 Tobias Burnus <burnus@net-b.de>
3355 * parse.c (gfc_fixup_sibling_symbols): Do not "fix" use-associated
3358 2010-06-01 Jerry DeLisle <jvdelisle@gcc.gnu.org>
3361 * match.c (gfc_match_stopcode): Move gfc_match_eos call inside
3364 2010-05-31 Steven G. Kargl <kargl@gcc.gnu.org>