1. 18 Aug, 2010 1 commit
    • janus's avatar
      2010-08-19 Janus Weil <janus@gcc.gnu.org> · 23d075f4
      janus authored
      	PR fortran/45290
      	* gfortran.h (gfc_add_save): Modified prototype.
      	* decl.c (add_init_expr_to_sym): Defer checking of proc pointer init.
      	(match_pointer_init): New function to match F08 pointer initialization.
      	(variable_decl,match_procedure_decl,match_ppc_decl): Use
      	'match_pointer_init'.
      	(match_attr_spec): Module variables are implicitly SAVE.
      	(gfc_match_save): Modified call to 'gfc_add_save'.
      	* expr.c (gfc_check_assign_symbol): Extra checks for pointer
      	initialization.
      	* primary.c (gfc_variable_attr): Handle SAVE attribute.
      	* resolve.c (resolve_structure_cons): Add new argument and do pointer
      	initialization checks.
      	(gfc_resolve_expr): Modified call to 'resolve_structure_cons'.
      	(resolve_values): Call 'resolve_structure_cons' directly with init arg.
      	(resolve_fl_variable): Handle SAVE_IMPLICIT.
      	* symbol.c (gfc_add_save,gfc_copy_attr,save_symbol): Handle
      	SAVE_IMPLICIT.
      	* trans-decl.c (gfc_create_module_variable): Module variables with
      	TARGET can already exist.
      	* trans-expr.c (gfc_conv_variable): Check for 'current_function_decl'.
      	(gfc_conv_initializer): Implement non-NULL pointer
      	initialization.
      
      
      2010-08-19  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/45290
      	* gfortran.dg/proc_ptr_comp_3.f90: Modified.
      	* gfortran.dg/pointer_init_2.f90: New.
      	* gfortran.dg/pointer_init_3.f90: New.
      	* gfortran.dg/pointer_init_4.f90: New.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@163356 138bc75d-0d04-0410-961f-82ee72b054a4
      23d075f4
  2. 17 Aug, 2010 1 commit
    • domob's avatar
      2010-08-17 Daniel Kraft <d@domob.eu> · 8f3f9eab
      domob authored
      	PR fortran/38936
      	* gfortran.h (struct gfc_association_list): New member `where'.
      	(gfc_is_associate_pointer) New method.
      	* match.c (gfc_match_associate): Remember locus for each associate
      	name matched and do not try to set variable flag.
      	* parse.c (parse_associate): Use remembered locus for symbols.
      	* primary.c (match_variable): Instead of variable-flag check for
      	associate names set it for all such names used.
      	* symbol.c (gfc_is_associate_pointer): New method.
      	* resolve.c (resolve_block_construct): Don't generate assignments
      	to give associate-names their values.
      	(resolve_fl_var_and_proc): Allow associate-names to be deferred-shape.
      	(resolve_symbol): Set some more attributes for associate variables,
      	set variable flag here and check it and don't try to build an
      	explicitely shaped array-spec for array associate variables.
      	* trans-expr.c (gfc_conv_variable): Dereference in case of association
      	to scalar variable.
      	* trans-types.c (gfc_is_nodesc_array): Handle array association symbols.
      	(gfc_sym_type): Return pointer type for association to scalar vars.
      	* trans-decl.c (gfc_get_symbol_decl): Defer association symbols.
      	(trans_associate_var): New method.
      	(gfc_trans_deferred_vars): Handle association symbols.
      
      2010-08-17  Daniel Kraft  <d@domob.eu>
      
      	PR fortran/38936
      	* gfortran.dg/associate_1.f03: Extended to test newly supported
      	features like association to variables.
      	* gfortran.dg/associate_3.f03: Removed check for illegal change
      	of associate-name here...
      	* gfortran.dg/associate_5.f03: ...and added it here.
      	* gfortran.dg/associate_6.f03: No longer XFAIL'ed.
      	* gfortran.dg/associate_7.f03: New test.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@163295 138bc75d-0d04-0410-961f-82ee72b054a4
      8f3f9eab
  3. 15 Aug, 2010 2 commits
  4. 29 Jul, 2010 1 commit
    • janus's avatar
      2010-07-29 Janus Weil <janus@gcc.gnu.org> · 0fc13348
      janus authored
      	PR fortran/45004
      	* trans-stmt.h (gfc_trans_class_init_assign): New prototype.
      	(gfc_trans_class_assign): Modified prototype.
      	* trans.h (gfc_conv_intrinsic_move_alloc): New prototype.
      	* trans-expr.c (gfc_trans_class_init_assign): Split off from ...
      	(gfc_trans_class_assign): ... here. Modified actual arguments.
      	* trans-intrinsic.c (gfc_conv_intrinsic_move_alloc): New function to
      	handle the MOVE_ALLOC intrinsic with scalar and class arguments.
      	* trans.c (trans_code): Call 'gfc_conv_intrinsic_move_alloc'.
      
      
      2010-07-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/45004
      	* gfortran.dg/move_alloc_2.f90: New.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162688 138bc75d-0d04-0410-961f-82ee72b054a4
      0fc13348
  5. 23 Jul, 2010 1 commit
    • pault's avatar
      2009-07-23 Paul Thomas <pault@gcc.gnu.org> · 25f9f93d
      pault authored
      	PR fortran/24524
      	* trans-array.c (gfc_init_loopinfo): Initialize the reverse
      	field.
      	gfc_trans_scalarized_loop_end: If reverse set in dimension n,
      	reverse the scalarization loop.
      	gfc_conv_resolve_dependencies: Pass the reverse field of the
      	loopinfo to gfc_dep_resolver.
      	trans-expr.c (gfc_trans_assignment_1): Enable loop reversal for
      	assignment by resetting loop.reverse.
      	gfortran.h : Add the gfc_reverse enum.
      	trans.h : Add the reverse field to gfc_loopinfo.
      	dependency.c (gfc_check_dependency): Pass null to the new arg
      	of gfc_dep_resolver.
      	(gfc_check_section_vs_section): Check for reverse dependencies.
      	(gfc_dep_resolver): Add reverse argument and deal with the loop
      	reversal logic.
      	dependency.h : Modify prototype for gfc_dep_resolver to include
      	gfc_reverse *.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162462 138bc75d-0d04-0410-961f-82ee72b054a4
      25f9f93d
  6. 15 Jul, 2010 2 commits
    • jakub's avatar
      * trans.h (gfc_string_to_single_character): New prototype. · d04cac57
      jakub authored
      	* trans-expr.c (string_to_single_character): Renamed to ...
      	(gfc_string_to_single_character): ... this.  No longer static.
      	(gfc_conv_scalar_char_value, gfc_build_compare_string,
      	gfc_trans_string_copy): Adjust callers.
      	* config-lang.in (gtfiles): Add fortran/trans-stmt.c.
      	* trans-stmt.c: Include ggc.h and gt-fortran-trans-stmt.h.
      	(select_struct): Move to toplevel, add GTY(()).
      	(gfc_trans_character_select): Optimize SELECT CASE
      	with character length 1.
      
      	* gfortran.dg/select_char_2.f90: New test.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162226 138bc75d-0d04-0410-961f-82ee72b054a4
      d04cac57
    • jakub's avatar
      * trans.h (gfc_build_compare_string): Add CODE argument. · a313dc3a
      jakub authored
      	* trans-intrinsic.c (gfc_conv_intrinsic_strcmp): Pass OP to
      	gfc_build_compare_string.
      	* trans-expr.c (gfc_conv_expr_op): Pass CODE to
      	gfc_build_compare_string.
      	(string_to_single_character): Rename len variable to length.
      	(gfc_optimize_len_trim): New function.
      	(gfc_build_compare_string): Add CODE argument.  If it is EQ_EXPR
      	or NE_EXPR and one of the strings is string literal with LEN_TRIM
      	bigger than the length of the other string, they compare unequal.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162208 138bc75d-0d04-0410-961f-82ee72b054a4
      a313dc3a
  7. 13 Jul, 2010 2 commits
    • jakub's avatar
      * trans-expr.c (string_to_single_character): Also optimize · 7f7b3f75
      jakub authored
      	string literals containing a single char followed only by spaces.
      	(gfc_trans_string_copy): Remove redundant string_to_single_character
      	calls.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162161 138bc75d-0d04-0410-961f-82ee72b054a4
      7f7b3f75
    • janus's avatar
      2010-07-13 Janus Weil <janus@gcc.gnu.org> · 09276310
      janus authored
      	PR fortran/44434
      	PR fortran/44565
      	PR fortran/43945
      	PR fortran/44869
      	* gfortran.h (gfc_find_derived_vtab): Modified prototype.
      	* class.c (gfc_build_class_symbol): Modified call to
      	'gfc_find_derived_vtab'.
      	(add_proc_component): Removed, moved code into 'add_proc_comp'.
      	(add_proc_comps): Renamed to 'add_proc_comp', removed treatment of
      	generics.
      	(add_procs_to_declared_vtab1): Removed unnecessary argument 'resolved'.
      	Removed treatment of generics.
      	(copy_vtab_proc_comps): Removed unnecessary argument 'resolved'.
      	Call 'add_proc_comp' instead of duplicating code.
      	(add_procs_to_declared_vtab): Removed unnecessary arguments 'resolved'
      	and 'declared'.
      	(add_generic_specifics,add_generics_to_declared_vtab): Removed.
      	(gfc_find_derived_vtab): Removed unnecessary argument 'resolved'.
      	Removed treatment of generics.
      	* iresolve.c (gfc_resolve_extends_type_of): Modified call to
      	'gfc_find_derived_vtab'.
      	* resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
      	Removed treatment of generics.
      	(resolve_select_type,resolve_fl_derived): Modified call to
      	'gfc_find_derived_vtab'.
      	* trans-decl.c (gfc_get_symbol_decl): Ditto.
      	* trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
      	Ditto.
      	* trans-stmt.c (gfc_trans_allocate): Ditto.
      
      2010-07-13  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/44434
      	PR fortran/44565
      	PR fortran/43945
      	PR fortran/44869
      	* gfortran.dg/dynamic_dispatch_1.f03: Fixed invalid test case.
      	* gfortran.dg/dynamic_dispatch_2.f03: Ditto.
      	* gfortran.dg/dynamic_dispatch_3.f03: Ditto.
      	* gfortran.dh/typebound_call_16.f03: New.
      	* gfortran.dg/typebound_generic_6.f03: New.
      	* gfortran.dg/typebound_generic_7.f03: New.
      	* gfortran.dg/typebound_generic_8.f03: New.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162125 138bc75d-0d04-0410-961f-82ee72b054a4
      09276310
  8. 10 Jul, 2010 1 commit
    • pault's avatar
      2010-07-10 Paul Thomas <pault@gcc.gnu.org> · e20c5d83
      pault authored
      	PR fortran/44773
      	* trans-expr.c (arrayfunc_assign_needs_temporary): No temporary
      	if the lhs has never been host associated, as well as not being
      	use associated, a pointer or a target.
      	* resolve.c (resolve_variable): Mark variables that are host
      	associated.
      	* gfortran.h: Add the host_assoc bit to the symbol_attribute
      	structure.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162038 138bc75d-0d04-0410-961f-82ee72b054a4
      e20c5d83
  9. 06 Jul, 2010 1 commit
    • burnus's avatar
      2010-07-06 Tobias Burnus <burnus@net-b.de> · 7cbc820e
      burnus authored
              * trans-decl.c: Include diagnostic-core.h besides toplev.h.
              * trans-intrinsic.c: Ditto.
              * trans-types.c: Ditto.
              * convert.c: Include diagnostic-core.h instead of toplev.h.
              * options.c: Ditto.
              * trans-array.c: Ditto.
              * trans-const.c: Ditto.
              * trans-expr.c: Ditto.
              * trans-io.c: Ditto.
              * trans-openmp.c: Ditto.
              * trans.c: Ditto.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161885 138bc75d-0d04-0410-961f-82ee72b054a4
      7cbc820e
  10. 05 Jul, 2010 1 commit
    • froydnj's avatar
      gcc/ · 008f96d8
      froydnj authored
      	* vec.h (VEC_splice, VEC_safe_splice): New macros.  Add function
      	implementations.
      
      gcc/fortran/
      	* trans.h (gfc_conv_procedure_call): Take a VEC instead of a tree.
      	* trans-intrinsic.c (gfc_conv_intrinsic_funcall): Adjust for new
      	type of gfc_conv_procedure_call.
      	(conv_generic_with_optional_char_arg): Likewise.
      	* trans-stmt.c (gfc_trans_call): Likewise.
      	* trans-expr.c (gfc_conv_function_expr): Likewise.
      	(gfc_conv_procedure_call): Use build_call_vec instead of
      	build_call_list.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161834 138bc75d-0d04-0410-961f-82ee72b054a4
      008f96d8
  11. 29 Jun, 2010 1 commit
    • pault's avatar
      2010-06-29 Paul Thomas <pault@gcc.gnu.org> · 5d7ab965
      pault authored
      	PR fortran/44582
      	* trans-expr.c (arrayfunc_assign_needs_temporary): New function
      	to determine if a function assignment can be made without a
      	temporary.
      	(gfc_trans_arrayfunc_assign): Move all the conditions that
      	suppress the direct function call to the above new functon and
      	call it.
      
      2010-06-29  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/44582
      	* gfortran.dg/aliasing_array_result_1.f90 : New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161550 138bc75d-0d04-0410-961f-82ee72b054a4
      5d7ab965
  12. 21 Jun, 2010 1 commit
    • burnus's avatar
      2010-06-20 Tobias Burnus <burnus@net-b.de> · b3c3927c
      burnus authored
              PR fortran/40632
              * interface.c (compare_parameter): Add gfc_is_simply_contiguous
              checks.
              * symbol.c (gfc_add_contiguous): New function.
              (gfc_copy_attr, check_conflict): Handle contiguous attribute.
              * decl.c (match_attr_spec): Ditto.
              (gfc_match_contiguous): New function.
              * resolve.c (resolve_fl_derived, resolve_symbol): Handle
              contiguous.
              * gfortran.h (symbol_attribute): Add contiguous.
              (gfc_is_simply_contiguous): Add prototype.
              (gfc_add_contiguous): Add prototype.
              * match.h (gfc_match_contiguous): Add prototype.
              * parse.c (decode_specification_statement,
              decode_statement): Handle contiguous attribute.
              * expr.c (gfc_is_simply_contiguous): New function.
              * dump-parse-tree.c (show_attr): Handle contiguous.
              * module.c (ab_attribute, attr_bits, mio_symbol_attribute):
              Ditto.
              * trans-expr.c (gfc_add_interface_mapping): Copy
              attr.contiguous.
              * trans-array.c (gfc_conv_descriptor_stride_get,
              gfc_conv_array_parameter): Handle contiguous arrays.
              * trans-types.c (gfc_build_array_type, gfc_build_array_type,
              gfc_sym_type, gfc_get_derived_type, gfc_get_array_descr_info):
              Ditto.
              * trans.h (gfc_array_kind): Ditto.
              * trans-decl.c (gfc_get_symbol_decl): Ditto.
      
      2010-06-20  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/40632
              * gfortran.dg/contiguous_1.f90: New.
              * gfortran.dg/contiguous_2.f90: New.
              * gfortran.dg/contiguous_3.f90: New.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161079 138bc75d-0d04-0410-961f-82ee72b054a4
      b3c3927c
  13. 11 Jun, 2010 1 commit
  14. 23 May, 2010 1 commit
    • burnus's avatar
      2010-05-21 Tobias Burnus <burnus@net-b.de> · dca58d21
      burnus authored
              * gfortran.h: Do not include system.h.
              * bbt.c: Include system.h.
              * data.c: Ditto.
              * dependency.c: Ditto.
              * dump-parse-tree.c: Ditto.
              * arith.h: Do not include gfortran.h.
              * constructor.h: Do not include gfortran.h and splay-tree.h.
              * match.h: Do not include gfortran.h.
              * parse.h: Ditto.
              * target-memory.h: Ditto.
              * openmp.c: Do not include toplev.h and target.h.
              * trans-stmt.c: Ditto not include toplev.h.
              * primary.c: Ditto.
              * trans-common.c: Tell why toplev.h is needed. And
              do not include target.h.
              * trans-expr.c: Tell why toplev.h is needed.
              * trans-array.c: Ditto.
              * trans-openmp.c: Ditto.
              * trans-const.c: Ditto.
              * trans.c: Ditto.
              * trans-types.c: Ditto.
              * trans-io.c: Ditto.
              * trans-decl.c: Ditto.
              * scanner.c: Ditto.
              * convert.c: Ditto.
              * trans-intrinsic.c: Ditto.
              * options.c: Ditto.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159763 138bc75d-0d04-0410-961f-82ee72b054a4
      dca58d21
  15. 20 May, 2010 1 commit
    • steven's avatar
      * trans-expr.c: Do not include convert.h, ggc.h, real.h, and gimple.h. · 989adef3
      steven authored
      	(gfc_conv_string_tmp): Do not assert type comparibilty.
      	*  trans-array.c: Do not include gimple.h, ggc.h, and real.h.
      	(gfc_conv_expr_descriptor): Remove assert.
      	* trans-common.c: Clarify why rtl.h and tm.h are included.
      	* trans-openmp.c: Do not include ggc.h and real.h.
      	Explain why gimple.h is included.
      	* trans-const.c: Do not include ggc.h.
      	* trans-stmt.c: Do not include gimple.h, ggc.h, and real.h.
      	* trans.c: Do not include ggc.h and real.h.
      	Explain why gimple.h is included.
      	* trans-types.c: Do not include tm.h.  Explain why langhooks.h
      	and dwarf2out.h are included.
      	* trans-io.c: Do not include gimple.h and real.h.
      	* trans-decl.c: Explain why gimple.h, tm.h, and rtl.h are included.
      	* trans-intrinsic.c: Do not include gimple.h.  Explain why tm.h
      	is included.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159640 138bc75d-0d04-0410-961f-82ee72b054a4
      989adef3
  16. 17 May, 2010 1 commit
  17. 15 May, 2010 1 commit
    • janus's avatar
      2010-05-15 Janus Weil <janus@gcc.gnu.org> · bcc41e51
      janus authored
      	PR fortran/43207
      	PR fortran/43969
      	* gfortran.h (gfc_class_null_initializer): New prototype.
      	* expr.c (gfc_class_null_initializer): New function to build a NULL
      	initializer for CLASS pointers.
      	* symbol.c (gfc_build_class_symbol): Modify internal naming of class
      	containers. Remove default NULL initialization of $data component.
      	* trans.c (gfc_allocate_array_with_status): Fix wording of an error 
      	message.
      	* trans-expr.c (gfc_conv_initializer,gfc_trans_subcomponent_assign):
      	Use new function 'gfc_class_null_initializer'.
      	* trans-intrinsic.c (gfc_conv_allocated): Handle allocatable scalar
      	class variables.
      
      
      2010-05-15  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/43207
      	PR fortran/43969
      	* gfortran.dg/class_18.f03: New.
      	* gfortran.dg/class_19.f03: New.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159431 138bc75d-0d04-0410-961f-82ee72b054a4
      bcc41e51
  18. 06 May, 2010 1 commit
    • jason's avatar
      Add support for C++0x nullptr. · 6fe11077
      jason authored
      gcc:
      	* c-common.c (c_common_reswords): Add nullptr.
      	* c-common.h: Add RID_NULLPTR.  Reorganize C++0x rids.
      	* dwarf2out.c (is_base_type): Handle NULLPTR_TYPE.
      	(gen_type_die_with_usage): Likewise.
      	* dbxout.c (dbxout_type): Likewise.
      	* sdbout.c (plain_type_1): Likewise.
      gcc/cp:
      	* cp-tree.def: Add NULLPTR_TYPE.
      	* cp-tree.h: Add nullptr_node.
      	(cp_tree_index): Add CPTI_NULLPTR.
      	(SCALAR_TYPE_P): Add NULLPTR_TYPE.
      	* call.c (null_ptr_cst_p): Handle nullptr.
      	(standard_conversion): Likewise.
      	(convert_arg_to_ellipsis): Likewise.
      	* mangle.c (write_type): Likewise.
      	* name-lookup.c (arg_assoc_type): Likewise.
      	* parser.c (cp_parser_primary_expression): Likewise.
      	* typeck.c (cp_build_binary_op): Likewise.
      	(build_reinterpret_cast_1): Likewise.
      	* error.c (dump_type): Likewise.
      	(dump_type_prefix, dump_type_suffix): Likewise.
      	* decl.c (cxx_init_decl_processing): Likewise.
      	* cxx-pretty-print.c (pp_cxx_constant): Likewise.
      	* cvt.c (ocp_convert): Likewise.
      	* rtti.c (typeinfo_in_lib_p, emit_support_tinfos): Put
      	nullptr_t tinfo in libsupc++.
      libstdc++-v3:
      	* config/abi/pre/gnu.ver: Add typeinfo for decltype(nullptr).
      libiberty:
      	* cp-demangle.c (cplus_demangle_builtin_types): Add nullptr.
      	(cplus_demangle_type): Handle nullptr.
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159131 138bc75d-0d04-0410-961f-82ee72b054a4
      6fe11077
  19. 29 Apr, 2010 1 commit
    • pault's avatar
      2010-04-29 Janus Weil <janus@gcc.gnu.org> · 09c509ed
      pault authored
      	PR fortran/43896
      	* symbol.c (add_proc_component,copy_vtab_proc_comps): Remove
      	initializers for PPC members of the vtabs.
      
      2010-04-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42274
      	* symbol.c (add_proc_component,add_proc_comps): Correctly set the 'ppc'
      	attribute for all PPC members of the vtypes.
      	(copy_vtab_proc_comps): Copy the correct interface.
      	* trans.h (gfc_trans_assign_vtab_procs): Modified prototype.
      	* trans-expr.c (gfc_trans_assign_vtab_procs): Pass the derived type as
      	a dummy argument and make sure all PPC members of the vtab are
      	initialized correctly.
      	(gfc_conv_derived_to_class,gfc_trans_class_assign): Additional argument
      	in call to gfc_trans_assign_vtab_procs.
      	* trans-stmt.c (gfc_trans_allocate): Ditto.
      
      2010-04-29  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/43326
      	* resolve.c (resolve_typebound_function): Renamed
      	resolve_class_compcall.Do all the detection of class references
      	here.
      	(resolve_typebound_subroutine): resolve_class_typebound_call
      	renamed. Otherwise same as resolve_typebound_function.
      	(gfc_resolve_expr): Call resolve_typebound_function.
      	(resolve_code): Call resolve_typebound_subroutine.
      
      2010-04-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/43492
      	* resolve.c (resolve_typebound_generic_call): For CLASS methods
      	pass back the specific symtree name, rather than the target
      	name.
      
      2010-04-29  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/42353
      	* resolve.c (resolve_structure_cons): Make the initializer of
      	the vtab component 'extends' the same type as the component.
      
      2010-04-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
      
      	PR fortran/42680
      	* interface.c (check_interface1): Pass symbol name rather than NULL to
      	gfc_compare_interfaces.(gfc_compare_interfaces): Add assert to
      	trap MULL. (gfc_compare_derived_types): Revert previous change
      	incorporated incorrectly during merge from trunk, r155778.
      	* resolve.c (check_generic_tbp_ambiguity): Pass symbol name rather
      	than NULL to gfc_compare_interfaces.
      	* symbol.c (add_generic_specifics): Likewise.
      
      2010-02-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42353
      	* interface.c (gfc_compare_derived_types): Add condition for vtype.
      	* symbol.c (gfc_find_derived_vtab): Sey access to private.
      	(gfc_find_derived_vtab): Likewise.
      	* module.c (ab_attribute): Add enumerator AB_VTAB.
      	(mio_symbol_attribute): Use new attribute, AB_VTAB.
      	(check_for_ambiguous): Likewise.
      
      2010-04-29  Paul Thomas  <pault@gcc.gnu.org>
      	    Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/41829
      	* trans-expr.c (select_class_proc): Remove function.
      	(conv_function_val): Delete reference to previous.
      	(gfc_conv_derived_to_class): Add second argument to the call to
      	gfc_find_derived_vtab.
      	(gfc_conv_structure): Exclude proc_pointer components when
      	accessing $data field of class objects.
      	(gfc_trans_assign_vtab_procs): New function.
      	(gfc_trans_class_assign): Add second argument to the call to
      	gfc_find_derived_vtab.
      	* symbol.c (gfc_build_class_symbol): Add delayed_vtab arg and
      	implement holding off searching for the vptr derived type.
      	(add_proc_component): New function.
      	(add_proc_comps): New function.
      	(add_procs_to_declared_vtab1): New function.
      	(copy_vtab_proc_comps): New function.
      	(add_procs_to_declared_vtab): New function.
      	(void add_generic_specifics): New function.
      	(add_generics_to_declared_vtab): New function.
      	(gfc_find_derived_vtab): Add second argument to the call to
      	gfc_find_derived_vtab. Add the calls to
      	add_procs_to_declared_vtab and add_generics_to_declared_vtab.
      	* decl.c (build_sym, build_struct): Use new arg in calls to
      	gfc_build_class_symbol.
      	* gfortran.h : Add vtype bitfield to symbol_attr. Remove the
      	definition of struct gfc_class_esym_list. Modify prototypes
      	of gfc_build_class_symbol and gfc_find_derived_vtab.
      	* trans-stmt.c (gfc_trans_allocate): Add second argument to the
      	call to gfc_find_derived_vtab.
      	* module.c : Add the vtype attribute.
      	* trans.h : Add prototype for gfc_trans_assign_vtab_procs.
      	* resolve.c (resolve_typebound_generic_call): Add second arg
      	to pass along the generic name for class methods.
      	(resolve_typebound_call): The same.
      	(resolve_compcall): Use the second arg to carry the generic
      	name from the above. Remove the reference to class_esym.
      	(check_members, check_class_members, resolve_class_esym,
      	hash_value_expr): Remove functions.
      	(resolve_class_compcall, resolve_class_typebound_call): Modify
      	to use vtable rather than member by member calls.
      	(gfc_resolve_expr): Modify second arg in call to
      	resolve_compcall.
      	(resolve_select_type): Add second arg in call to
      	gfc_find_derived_vtab.
      	(resolve_code): Add second arg in call resolve_typebound_call.
      	(resolve_fl_derived): Exclude vtypes from check for late
      	procedure definitions. Likewise for checking of explicit
      	interface and checking of pass arg.
      	* iresolve.c (gfc_resolve_extends_type_of): Add second arg in
      	calls to gfc_find_derived_vtab.
      	* match.c (select_type_set_tmp): Use new arg in call to
      	gfc_build_class_symbol.
      	* trans-decl.c (gfc_get_symbol_decl): Complete vtable if
      	necessary.
      	* parse.c (endType): Finish incomplete classes.
      
      
      2010-04-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42274
      	* gfortran.dg/class_16.f03: New test.
      
      2010-04-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42274
      	* gfortran.dg/class_15.f03: New.
      
      2010-04-29  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/43326
      	* gfortran.dg/dynamic_dispatch_9.f03: New test.
      
      2010-04-29  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/43492
      	* gfortran.dg/generic_22.f03 : New test.
      
      2010-04-29  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/42353
      	* gfortran.dg/class_14.f03: New test.
      
      2010-04-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
      
      	PR fortran/42680
      	* gfortran.dg/interface_32.f90: New test.
      
      2009-04-29  Paul Thomas  <pault@gcc.gnu.org>
      	    Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/41829
      	* gfortran.dg/dynamic_dispatch_5.f03 : Change to "run".
      	* gfortran.dg/dynamic_dispatch_7.f03 : New test.
      	* gfortran.dg/dynamic_dispatch_8.f03 : New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158910 138bc75d-0d04-0410-961f-82ee72b054a4
      09c509ed
  20. 24 Apr, 2010 1 commit
    • pault's avatar
      2010-04-24 Paul Thomas <pault@gcc.gnu.org> · 4abd9760
      pault authored
      	PR fortran/43841
      	PR fortran/43843
      	* trans-expr.c (gfc_conv_expr): Supply an address expression for
      	GFC_SS_REFERENCE.
      	(gfc_conv_expr_reference): Call gfc_conv_expr and return for
      	GFC_SS_REFERENCE.
      	* trans-array.c (gfc_add_loop_ss_code): Store the value rather
      	than the address of a GFC_SS_REFERENCE.
      	* trans.h : Change comment on GFC_SS_REFERENCE. 
      
      2010-04-24  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/43841
      	PR fortran/43843
      	* gfortran.dg/elemental_scalar_args_1.f90 : New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158683 138bc75d-0d04-0410-961f-82ee72b054a4
      4abd9760
  21. 13 Apr, 2010 1 commit
    • jvdelisle's avatar
      2010-04-12 Jerry DeLisle <jvdelisle@gcc.gnu.org> · 126387b5
      jvdelisle authored
      	* array.c (extract_element): Restore function from trunk.
      	(gfc_get_array_element): Restore function from trunk.
      	(gfc_expand_constructor): Restore check against
      	flag_max_array_constructor.
      	* constructor.c (node_copy_and_append): Delete unused.
      	* gfortran.h: Delete comment and extra include.
      	* constructor.h: Bump copyright and clean up TODO comments.
      	* resolve.c: Whitespace.
      
      2010-04-12  Daniel Franke  <franke.daniel@gmail.com>
      
      	* simplify.c (compute_dot_product): Replaced usage of ADVANCE macro
      	with direct access access to elements. Adjusted prototype, fixed all
      	callers.
      	(gfc_simplify_dot_product): Removed duplicate check for zero-sized
      	array.
      	(gfc_simplify_matmul): Removed usage of ADVANCE macro.
      	(gfc_simplify_spread): Removed workaround, directly insert elements
      	at a given array position.
      	(gfc_simplify_transpose): Likewise.
      	(gfc_simplify_pack): Replaced usage of ADVANCE macro with corresponding
      	function calls.
      	(gfc_simplify_unpack): Likewise.
      
      2010-04-12  Daniel Franke  <franke.daniel@gmail.com>
      
      	* simplify.c (only_convert_cmplx_boz): Renamed to ...
      	(convert_boz): ... this and moved to start of file.
      	(gfc_simplify_abs): Whitespace fix.
      	(gfc_simplify_acos): Whitespace fix.
      	(gfc_simplify_acosh): Whitespace fix.
      	(gfc_simplify_aint): Whitespace fix.
      	(gfc_simplify_dint): Whitespace fix.
      	(gfc_simplify_anint): Whitespace fix.
      	(gfc_simplify_and): Replaced if-gate by more common switch-over-type.
      	(gfc_simplify_dnint): Whitespace fix.
      	(gfc_simplify_asin): Whitespace fix.
      	(gfc_simplify_asinh): Moved creation of result-expr out of switch.
      	(gfc_simplify_atan): Likewise.
      	(gfc_simplify_atanh): Whitespace fix.
      	(gfc_simplify_atan2): Whitespace fix.
      	(gfc_simplify_bessel_j0): Removed ATTRIBUTE_UNUSED.
      	(gfc_simplify_bessel_j1): Likewise.
      	(gfc_simplify_bessel_jn): Likewise.
      	(gfc_simplify_bessel_y0): Likewise.
      	(gfc_simplify_bessel_y1): Likewise.
      	(gfc_simplify_bessel_yn): Likewise.
      	(gfc_simplify_ceiling): Reorderd statements.
      	(simplify_cmplx): Use convert_boz(), check for constant arguments.
      	Whitespace fix.
      	(gfc_simplify_cmplx): Use correct default kind. Removed check for
      	constant arguments.
      	(gfc_simplify_complex): Replaced if-gate. Removed check for
      	constant arguments.
      	(gfc_simplify_conjg): Whitespace fix.
      	(gfc_simplify_cos): Whitespace fix.
      	(gfc_simplify_cosh): Replaced if-gate by more common switch-over-type.
      	(gfc_simplify_dcmplx): Removed check for constant arguments.
      	(gfc_simplify_dble): Use convert_boz() and gfc_convert_constant().
      	(gfc_simplify_digits): Whitespace fix.
      	(gfc_simplify_dim): Whitespace fix.
      	(gfc_simplify_dprod): Reordered statements.
      	(gfc_simplify_erf): Whitespace fix.
      	(gfc_simplify_erfc): Whitespace fix.
      	(gfc_simplify_epsilon): Whitespace fix.
      	(gfc_simplify_exp): Whitespace fix.
      	(gfc_simplify_exponent): Use convert_boz().
      	(gfc_simplify_floor): Reorderd statements.
      	(gfc_simplify_gamma): Whitespace fix.
      	(gfc_simplify_huge): Whitespace fix.
      	(gfc_simplify_iand): Whitespace fix.
      	(gfc_simplify_ieor): Whitespace fix.
      	(simplify_intconv): Use gfc_convert_constant().
      	(gfc_simplify_int): Use simplify_intconv().
      	(gfc_simplify_int2): Reorderd statements.
      	(gfc_simplify_idint): Reorderd statements.
      	(gfc_simplify_ior): Whitespace fix.
      	(gfc_simplify_ishftc): Removed duplicate type check.
      	(gfc_simplify_len): Use range_check() instead of manual range check.
      	(gfc_simplify_lgamma): Removed ATTRIBUTE_UNUSED. Whitespace fix.
      	(gfc_simplify_log): Whitespace fix.
      	(gfc_simplify_log10): Whitespace fix.
      	(gfc_simplify_minval): Whitespace fix.
      	(gfc_simplify_maxval): Whitespace fix.
      	(gfc_simplify_mod): Whitespace fix.
      	(gfc_simplify_modulo): Whitespace fix.
      	(simplify_nint): Reorderd statements.
      	(gfc_simplify_not): Whitespace fix.
      	(gfc_simplify_or): Replaced if-gate by more common switch-over-type.
      	(gfc_simplify_radix): Removed unused result-variable. Whitespace fix.
      	(gfc_simplify_range): Removed unused result-variable. Whitespace fix.
      	(gfc_simplify_real): Use convert_boz() and gfc_convert_constant().
      	(gfc_simplify_realpart): Whitespace fix.
      	(gfc_simplify_selected_char_kind): Removed unused result-variable.
      	(gfc_simplify_selected_int_kind): Removed unused result-variable.
      	(gfc_simplify_selected_real_kind): Removed unused result-variable.
      	(gfc_simplify_sign): Whitespace fix.
      	(gfc_simplify_sin): Whitespace fix.
      	(gfc_simplify_sinh): Replaced if-gate by more common switch-over-type.
      	(gfc_simplify_sqrt): Avoided goto by inlining check. Whitespace fix.
      	(gfc_simplify_tan): Replaced if-gate by more common switch-over-type.
      	(gfc_simplify_tanh): Replaced if-gate by more common switch-over-type.
      	(gfc_simplify_xor): Replaced if-gate by more common switch-over-type.
      
      2010-04-12  Daniel Franke  <franke.daniel@gmail.com>
      
      	* gfortran.h (gfc_start_constructor): Removed.
      	(gfc_get_array_element): Removed.
      	* array.c (gfc_start_constructor): Removed, use gfc_get_array_expr 
      	instead. Fixed all callers.
      	(extract_element): Removed.
      	(gfc_expand_constructor): Temporarily removed check for
      	max-array-constructor. Will be re-introduced later if still required.
      	(gfc_get_array_element): Removed, use gfc_constructor_lookup_expr
      	instead. Fixed all callers.
      	* expr.c (find_array_section): Replaced manual lookup of elements
      	by gfc_constructor_lookup.
      
      2010-04-12  Daniel Franke  <franke.daniel@gmail.com>
      
              * gfortran.h (gfc_get_null_expr): New prototype.
              (gfc_get_operator_expr): New prototype.
              (gfc_get_character_expr): New prototype.
              (gfc_get_iokind_expr): New prototype.
              * expr.c (gfc_get_null_expr): New.
              (gfc_get_character_expr): New.
              (gfc_get_iokind_expr): New.
              (gfc_get_operator_expr): Moved here from matchexp.c (build_node).
              * matchexp.c (build_node): Renamed and moved to
              expr.c (gfc_get_operator_expr). Reordered arguments to match 
              other functions. Fixed all callers.
              (gfc_get_parentheses): Use specific function to build expr.
              * array.c (gfc_match_array_constructor): Likewise.
              * arith.c (eval_intrinsic): Likewise.
              (gfc_hollerith2int): Likewise.
              (gfc_hollerith2real): Likewise.
              (gfc_hollerith2complex): Likewise.
              (gfc_hollerith2logical): Likewise.
              * data.c (create_character_intializer): Likewise.
              * decl.c (gfc_match_null): Likewise.
              (enum_initializer): Likewise.
              * io.c (gfc_match_format): Likewise.
              (match_io): Likewise.
              * match.c (gfc_match_nullify): Likewise.
              * primary.c (match_string_constant): Likewise.
              (match_logical_constant): Likewise.
              (build_actual_constructor): Likewise.
              * resolve.c (build_default_init_expr): Likewise.
              * symbol.c (generate_isocbinding_symbol): Likewise.
              (gfc_build_class_symbol): Likewise.
              (gfc_find_derived_vtab): Likewise.
              * simplify.c (simplify_achar_char): Likewise.
              (gfc_simplify_adjustl): Likewise.
              (gfc_simplify_adjustr): Likewise.
              (gfc_simplify_and): Likewise.
              (gfc_simplify_bit_size): Likewise.
              (gfc_simplify_is_iostat_end): Likewise.
              (gfc_simplify_is_iostat_eor): Likewise.
              (gfc_simplify_isnan): Likewise.
              (simplify_bound): Likewise.
              (gfc_simplify_leadz): Likewise.
              (gfc_simplify_len_trim): Likewise.
              (gfc_simplify_logical): Likewise.
              (gfc_simplify_maxexponent): Likewise.
              (gfc_simplify_minexponent): Likewise.
              (gfc_simplify_new_line): Likewise.
              (gfc_simplify_null): Likewise.
              (gfc_simplify_or): Likewise.
              (gfc_simplify_precision): Likewise.
              (gfc_simplify_repeat): Likewise.
              (gfc_simplify_scan): Likewise.
              (gfc_simplify_size): Likewise.
              (gfc_simplify_trailz): Likewise.
              (gfc_simplify_trim): Likewise.
              (gfc_simplify_verify): Likewise.
              (gfc_simplify_xor): Likewise.
              * trans-io.c (build_dt): Likewise.
              (gfc_new_nml_name_expr): Removed.
      
      2010-04-12  Daniel Franke  <franke.daniel@gmail.com>
      
      	* arith.h (gfc_constant_result): Removed prototype.
      	* constructor.h (gfc_build_array_expr): Removed prototype.
      	(gfc_build_structure_constructor_expr): Removed prototype.
      	* gfortran.h (gfc_int_expr): Removed prototype.
      	(gfc_logical_expr): Removed prototype.
      	(gfc_get_array_expr): New prototype.
      	(gfc_get_structure_constructor_expr): New prototype.
      	(gfc_get_constant_expr): New prototype.
      	(gfc_get_int_expr): New prototype.
      	(gfc_get_logical_expr): New prototype.
      	* arith.c (gfc_constant_result): Moved and renamed to
      	expr.c (gfc_get_constant_expr). Fixed all callers.
      	* constructor.c (gfc_build_array_expr): Moved and renamed to
      	expr.c (gfc_get_array_expr). Split gfc_typespec argument to type
      	and kind. Fixed all callers.
      	(gfc_build_structure_constructor_expr): Moved and renamed to
      	expr.c (gfc_get_structure_constructor_expr). Split gfc_typespec argument
      	to type and kind. Fixed all callers.
      	* expr.c (gfc_logical_expr): Renamed to ...
      	(gfc_get_logical_expr): ... this. Added kind argument. Fixed all callers.
      	(gfc_int_expr): Renamed to ...
      	(gfc_get_int_expr): ... this. Added kind and where arguments. Fixed all
      	callers.
      	(gfc_get_constant_expr): New.
      	(gfc_get_array_expr): New.
      	(gfc_get_structure_constructor_expr): New.
      	* simplify.c (int_expr_with_kind): Removed, callers use gfc_get_int_expr
      	instead.
      
      2010-04-12  Daniel Franke  <franke.daniel@gmail.com>
      
      	* constructor.h: New.
      	* constructor.c: New.
      	* Make-lang.in: Add new files to F95_PARSER_OBJS.
      	* arith.c (reducy_unary): Use constructor API.
      	(reduce_binary_ac): Likewise.
      	(reduce_binary_ca): Likewise.
      	(reduce_binary_aa): Likewise.
      	* check.c (gfc_check_pack): Likewise.
      	(gfc_check_reshape): Likewise.
      	(gfc_check_unpack): Likewise.
      	* decl.c (add_init_expr_to_sym): Likewise.
      	(build_struct): Likewise.
      	* dependency.c (gfc_check_dependency): Likewise.
      	(contains_forall_index_p): Likewise.
      	* dump-parse-tree.c (show_constructor): Likewise.
      	* expr.c (free_expr0): Likewise.
      	(gfc_copy_expr): Likewise.
      	(gfc_is_constant_expr): Likewise.
      	(simplify_constructor): Likewise.
      	(find_array_element): Likewise.
      	(find_component_ref): Likewise.
      	(find_array_section): Likewise.
      	(find_substring_ref): Likewise.
      	(simplify_const_ref): Likewise.
      	(scalarize_intrinsic_call): Likewise.
      	(check_alloc_comp_init): Likewise.
      	(gfc_default_initializer): Likewise.
      	(gfc_traverse_expr): Likewise.
      	* iresolve.c (check_charlen_present): Likewise.
      	(gfc_resolve_reshape): Likewise.
      	(gfc_resolve_transfer): Likewise.
      	* module.c (mio_constructor): Likewise.
      	* primary.c (build_actual_constructor): Likewise.
      	(gfc_match_structure_constructor): Likewise.
      	* resolve.c (resolve_structure_cons): Likewise.
      	* simplify.c (is_constant_array_expr): Likewise.
      	(init_result_expr): Likewise.
      	(transformational_result): Likewise.
      	(simplify_transformation_to_scalar): Likewise.
      	(simplify_transformation_to_array): Likewise.
      	(gfc_simplify_dot_product): Likewise.
      	(simplify_bound): Likewise.
      	(simplify_matmul): Likewise.
      	(simplify_minval_maxval): Likewise.
      	(gfc_simplify_pack): Likewise.
      	(gfc_simplify_reshape): Likewise.
      	(gfc_simplify_shape): Likewise.
      	(gfc_simplify_spread): Likewise.
      	(gfc_simplify_transpose): Likewise.
      	(gfc_simplify_unpack): Likewise.q
      	(gfc_convert_constant): Likewise.
      	(gfc_convert_char_constant): Likewise.
      	* target-memory.c (size_array): Likewise.
      	(encode_array): Likewise.
      	(encode_derived): Likewise.
      	(interpret_array): Likewise.
      	(gfc_interpret_derived): Likewise.
      	(expr_to_char): Likewise.
      	(gfc_merge_initializers): Likewise.
      	* trans-array.c (gfc_get_array_constructor_size): Likewise.
      	(gfc_trans_array_constructor_value): Likewise.
      	(get_array_ctor_strlen): Likewise.
      	(gfc_constant_array_constructor_p): Likewise.
      	(gfc_build_constant_array_constructor): Likewise.
      	(gfc_trans_array_constructor): Likewise.
      	(gfc_conv_array_initializer): Likewise.
      	* trans-decl.c (check_constant_initializer): Likewise.
      	* trans-expr.c (flatten_array_ctors_without_strlen): Likewise.
      	(gfc_apply_interface_mapping_to_cons): Likewise.
      	(gfc_trans_structure_assign): Likewise.
      	(gfc_conv_structure): Likewise.
      	* array.c (check_duplicate_iterator): Likewise.
      	(match_array_list): Likewise.
      	(match_array_cons_element): Likewise.
      	(gfc_match_array_constructor): Likewise.
      	(check_constructor_type): Likewise.
      	(check_constructor): Likewise.
      	(expand): Likewise.
      	(expand_constructor): Likewise.
      	(extract_element): Likewise.
      	(gfc_expanded_ac): Likewise.
      	(resolve_array_list): Likewise.
      	(gfc_resolve_character_array_constructor): Likewise.
      	(copy_iterator): Renamed to ...
      	(gfc_copy_iterator): ... this.
      	(gfc_append_constructor): Removed.
      	(gfc_insert_constructor): Removed unused function.
      	(gfc_get_constructor): Removed.
      	(gfc_free_constructor): Removed.
      	(qgfc_copy_constructor): Removed.
      	* gfortran.h (struct gfc_expr): Removed member 'con_by_offset'.
      	Removed all references. Replaced constructor list by splay-tree.
      	(struct gfc_constructor): Removed member 'next', moved 'offset' from
      	the inner struct, added member 'base'.
      	(gfc_append_constructor): Removed prototype.
      	(gfc_insert_constructor): Removed prototype.
      	(gfc_get_constructor): Removed prototype.
      	(gfc_free_constructor): Removed prototype.
      	(qgfc_copy_constructor): Removed prototype.
      	(gfc_copy_iterator): New prototype.
      	* trans-array.h (gfc_constant_array_constructor_p): Adjusted prototype.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158253 138bc75d-0d04-0410-961f-82ee72b054a4
      126387b5
  22. 09 Apr, 2010 1 commit
    • burnus's avatar
      2010-04-09 Tobias Burnus <burnus@net-b.de> · e97ac7c0
      burnus authored
              PR fortran/18918
              * decl.c (variable_decl, match_attr_spec): Fix setting the array
              spec.
              * array.c (match_subscript,gfc_match_array_ref): Add coarray
              * support.
              * data.c (gfc_assign_data_value): Ditto.
              * expr.c (gfc_check_pointer_assign): Add check for coarray
              * constraint.
              (gfc_traverse_expr): Traverse also through codimension expressions.
              (gfc_is_coindexed, gfc_has_ultimate_allocatable,
              gfc_has_ultimate_pointer): New functions.
              * gfortran.h (gfc_array_ref_dimen_type): Add DIMEN_STAR for
              * coarrays.
              (gfc_array_ref): Add codimen.
              (gfc_array_ref): Add in_allocate.
              (gfc_is_coindexed, gfc_has_ultimate_allocatable,
              gfc_has_ultimate_pointer): Add prototypes.
              * interface.c (compare_parameter, compare_actual_formal,
              check_intents): Add coarray constraints.
              * match.c (gfc_match_iterator): Add coarray constraint.
              * match.h (gfc_match_array_ref): Update interface.
              * primary.c (gfc_match_varspec): Handle codimensions.
              * resolve.c (coarray_alloc, inquiry_argument): New static
              * variables.
              (check_class_members): Return gfc_try instead for error recovery.
              (resolve_typebound_function,resolve_typebound_subroutine,
              check_members): Handle return value of check_class_members.
              (resolve_structure_cons, resolve_actual_arglist, resolve_function,
              check_dimension, compare_spec_to_ref, resolve_array_ref,
              resolve_ref, resolve_variable, gfc_resolve_expr, conformable_arrays,
              resolve_allocate_expr, resolve_ordinary_assign): Add coarray
              support.
              * trans-array.c (gfc_conv_array_ref, gfc_walk_variable_expr):
              Skip over coarray refs.
              (gfc_array_allocate) Add support for references containing coindexes.
              * trans-expr.c (gfc_add_interface_mapping): Copy coarray
              * attribute.
              (gfc_map_intrinsic_function): Ignore codimensions.
      
      2010-04-09  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/18918
              * gfortran.dg/coarray_7.f90: New test.
              * gfortran.dg/coarray_8.f90: New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158149 138bc75d-0d04-0410-961f-82ee72b054a4
      e97ac7c0
  23. 06 Apr, 2010 1 commit
    • burnus's avatar
      2010-04-06 Tobias Burnus <burnus@net-b.de> · a545a8f8
      burnus authored
              PR fortran/43178
              * trans-array.c (gfc_conv_expr_descriptor): Update
              gfc_trans_scalar_assign call.
              (has_default_initializer): New function.
              (gfc_trans_deferred_array): Nullify less often.
              * trans-expr.c (gfc_conv_subref_array_arg,
              gfc_trans_subcomponent_assign): Update call to
              gfc_trans_scalar_assign.
              (gfc_trans_scalar_assign): Add parameter and pass it on.
              (gfc_trans_assignment_1): Optionally, do not dealloc before
              assignment.
              * trans-openmp.c (gfc_trans_omp_array_reduction): Update
              call to gfc_trans_scalar_assign.
              * trans-decl.c (gfc_get_symbol_decl): Do not always apply
              initializer to static variables.
              (gfc_init_default_dt): Add dealloc parameter and pass it on.
              * trans-stmt.c (forall_make_variable_temp,
              generate_loop_for_temp_to_lhs, generate_loop_for_rhs_to_temp,
              gfc_trans_forall_1, gfc_trans_where_assign, gfc_trans_where_3
              gfc_trans_allocate): Update gfc_trans_assignment call.
              * trans.h (gfc_trans_scalar_assign, gfc_init_default_dt,
              gfc_init_default_dt, gfc_trans_assignment): Add bool dealloc
              parameter to prototype.
      
      2010-04-06  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/43178
              * gfortran.dg/alloc_comp_basics_1.f90: Update
              * scan-tree-dump-times.
              * gfortran.dg/alloc_comp_constructor_1.f90: Ditto.
              * gfortran.dg/auto_dealloc_1.f90: Ditto.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@157993 138bc75d-0d04-0410-961f-82ee72b054a4
      a545a8f8
  24. 18 Mar, 2010 1 commit
    • pault's avatar
      2010-03-18 Paul Thomas <pault@gcc.gnu.org> · 8fcd6158
      pault authored
              PR fortran/43039
              * trans-expr.c (conv_parent_component_references): Ensure that
      	'dt' has a backend_decl.
      
              PR fortran/43043
              * trans-expr.c (gfc_conv_structure): Ensure that the derived
      	type has a backend_decl.
      
              PR fortran/43044
              * resolve.c (resolve_global_procedure): Check that the 'cl'
      	structure is not NULL.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@157552 138bc75d-0d04-0410-961f-82ee72b054a4
      8fcd6158
  25. 28 Feb, 2010 1 commit
  26. 24 Feb, 2010 1 commit
  27. 21 Feb, 2010 1 commit
    • burnus's avatar
      2010-02-21 Tobias Burnus <burnus@net-b.de> · 54564d01
      burnus authored
              PR fortran/35259
              * doc/invoke.texi (-fassociative-math): Document that this
              option is automatically enabled for Fortran.
      
      2010-02-21  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/35259
              * gfortran.h (gfc_option_t): New flag -fprotect-parens.
              * lang.opt: Ditto.
              * option.c (gfc_init_options,gfc_handle_option): Ditto.
              * trans-expr.c (gfc_conv_expr_op): Use the flag.
              * invoke.texi: Document new -fno-protect-parens flag.
      
      2010-02-21  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/35259
              * gfortran.dg/reassoc_5.f90: New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@156937 138bc75d-0d04-0410-961f-82ee72b054a4
      54564d01
  28. 20 Feb, 2010 1 commit
    • pault's avatar
      2010-02-20 Paul Thomas <pault@gcc.gnu.org> · 08803898
      pault authored
      	PR fortran/36932
      	PR fortran/36933
      	PR fortran/43072
      	PR fortran/43111
      	* dependency.c (gfc_check_argument_var_dependency): Use enum
      	value instead of arithmetic vaue for 'elemental'.
      	(check_data_pointer_types): New function.
      	(gfc_check_dependency): Call check_data_pointer_types.
      	* trans-array.h : Change fourth argument of
      	gfc_conv_array_parameter to boolean.
      	* trans-array.c (gfc_conv_array_parameter): A contiguous array
      	can be a dummy but it must not be assumed shape or deferred.
      	Change fourth argument to boolean. Array constructor exprs will
      	always be contiguous and do not need packing and unpacking.
      	* trans-expr.c (gfc_conv_procedure_call): Clean up some white
      	space and change fourth argument of gfc_conv_array_parameter
      	to boolean.
      	(gfc_trans_arrayfunc_assign): Change fourth argument of
      	gfc_conv_array_parameter to boolean.
      	* trans-io.c (gfc_convert_array_to_string): The same.
      	* trans-intrinsic.c (gfc_conv_intrinsic_loc): The same.
      
      2010-02-20  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/36932
      	PR fortran/36933
      	* gfortran.dg/dependency_26.f90: New test.
      
      	PR fortran/43072
      	* gfortran.dg/internal_pack_7.f90: New test.
      
      	PR fortran/43111
      	* gfortran.dg/internal_pack_8.f90: New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@156926 138bc75d-0d04-0410-961f-82ee72b054a4
      08803898
  29. 10 Feb, 2010 1 commit
  30. 05 Feb, 2010 1 commit
    • pault's avatar
      2010-02-05 Paul Thomas <pault@gcc.gnu.org> · 3446c28b
      pault authored
      	PR fortran/42309
      	* trans-expr.c (gfc_conv_subref_array_arg): Add new argument
      	'formal_ptr'. If this is true, give returned descriptor unity
      	lbounds, in all dimensions, and the appropriate offset.
      	(gfc_conv_procedure_call); If formal is a pointer, set the last
      	argument of gfc_conv_subref_array_arg to true.
      	* trans.h : Add last argument for gfc_conv_subref_array_arg.
      	* trans-io.c (set_internal_unit, gfc_trans_transfer): Set the
      	new arg of gfc_conv_subref_array_arg to false.
      	* trans-stmt.c (forall_make_variable_temp): The same.
      
      2010-02-05  Paul Thomas  <pault@gcc.gnu.org>
      
      	PR fortran/42309
      	* gfortran.dg/subref_array_pointer_4.f90 : New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@156512 138bc75d-0d04-0410-961f-82ee72b054a4
      3446c28b
  31. 31 Jan, 2010 2 commits
    • janus's avatar
      gcc/fortran/ · dba1636b
      janus authored
      2010-01-31  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42888
      	* resolve.c (resolve_allocate_expr): Move default initialization code
      	here from gfc_trans_allocate.
      	* trans.c (gfc_trans_code): Call gfc_trans_class_assign also for
      	EXEC_INIT_ASSIGN.
      	* trans-expr.c (gfc_trans_class_assign): Handle default initialization
      	of CLASS variables via memcpy.
      	* trans-stmt.c (gfc_trans_allocate): Move default initialization code
      	to resolve_allocate_expr.
      
      gcc/testsuite/
      2010-01-31  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42888
      	* gfortran.dg/allocate_derived_2.f90: New test.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@156418 138bc75d-0d04-0410-961f-82ee72b054a4
      dba1636b
    • pault's avatar
      2010-01-31 Paul Thomas <pault@gcc.gnu.org> · ffc91ac1
      pault authored
              PR fortran/38324
      	* expr.c (gfc_get_full_arrayspec_from_expr): New function.
      	* gfortran.h : Add prototype for above.
              * trans-expr.c (gfc_trans_alloc_subarray_assign): New function.
      	(gfc_trans_subcomponent_assign): Call new function to replace
      	the code to deal with allocatable components.
      	* trans-intrinsic.c (gfc_conv_intrinsic_bound): Call
      	gfc_get_full_arrayspec_from_expr to replace existing code.
      
      2010-01-31  Paul Thomas  <pault@gcc.gnu.org>
      
              PR fortran/38324
              * gfortran.dg/alloc_comp_basics_1.f90: Remove option -O2.
              * gfortran.dg/alloc_comp_bounds_1.f90: New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@156399 138bc75d-0d04-0410-961f-82ee72b054a4
      ffc91ac1
  32. 14 Jan, 2010 1 commit
    • pault's avatar
      2010-01-14 Paul Thomas <pault@gcc.gnu.org> · 64a8f98f
      pault authored
              PR fortran/41478
              * trans-array.c (duplicate_allocatable):  Static version of
      	gfc_duplicate_allocatable with provision to handle scalar
      	components. New boolean argument to switch off call to malloc
      	if true.
      	(gfc_duplicate_allocatable): New function to call above with
      	new argument false.
      	(gfc_copy_allocatable_data): New function to call above with
      	new argument true.
      	(structure_alloc_comps): Do not apply indirect reference to
      	scalar pointers. Add new section to copy allocatable components
      	of arrays. Extend copying of allocatable components to include
      	scalars.
      	(gfc_copy_only_alloc_comp): New function to copy allocatable
      	component derived types, without allocating the base structure.
      	* trans-array.h : Add primitive for gfc_copy_allocatable_data.
      	Add primitive for gfc_copy_only_alloc_comp.
      	* trans-expr.c (gfc_conv_procedure_call): After calls to
      	transformational functions with results that are derived types
      	with allocatable components, copy the components in the result.
      	(gfc_trans_arrayfunc_assign): Deallocate allocatable components
      	of lhs derived types before allocation.
      	
      
      2010-01-14  Paul Thomas  <pault@gcc.gnu.org>
      
              PR fortran/41478
              * gfortran.dg/alloc_comp_scalar_1.f90: New test.
              * gfortran.dg/alloc_comp_transformational_1.f90: New test.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@155877 138bc75d-0d04-0410-961f-82ee72b054a4
      64a8f98f
  33. 09 Jan, 2010 1 commit
    • burnus's avatar
      2010-01-09 Tobias Burnus <burnus@net-b.de> · 650ee6fb
      burnus authored
              PR fortran/41298
              * trans-expr.c (gfc_trans_structure_assign): Handle
              c_null_(fun)ptr.
              * symbol.c (gen_special_c_interop_ptr): Add NULL_EXPR
              to the constructor for c_null_(fun)ptr.
              * resolve.c (resolve_structure_cons): Add special case
              for c_null_(fun)ptr.
      
      2010-01-09  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/41298
              * gfortran.dg/c_ptr_tests_14.f90: New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@155755 138bc75d-0d04-0410-961f-82ee72b054a4
      650ee6fb
  34. 05 Jan, 2010 1 commit
  35. 04 Jan, 2010 1 commit
    • burnus's avatar
      2009-01-04 Tobias Burnus <burnus@net-b.de> · 53169279
      burnus authored
              PR fortran/41872
              * trans-expr.c (gfc_conv_procedure_call): Add indirect ref
              for functions returning allocatable scalars.
              * trans-stmt.c (gfc_trans_allocate): Emmit error when
              reallocating an allocatable scalar.
              * trans.c (gfc_allocate_with_status): Fix pseudocode syntax
              in comment.
              * trans-decl.c (gfc_trans_deferred_vars): Nullify local
              allocatable scalars.
              (gfc_generate_function_code): Nullify result variable for
              allocatable scalars.
              
              PR fortran/40849
              * module.c (gfc_use_module): Fix warning string to allow
              for translation.
      
              PR fortran/42517
              * invoke.texi (-fcheck=recursion): Mention that the checking
              is also disabled for -frecursive.
              * trans-decl.c (gfc_generate_function_code): Disable
              -fcheck=recursion when -frecursive is used.
      
              * intrinsic.texi (iso_c_binding): Improve wording.
      
      2009-01-04  Tobias Burnus  <burnus@net-b.de>
      
              PR fortran/41872
              * gfortran.dg/allocatable_scalar_5.f90: New test.
              * gfortran.dg/allocatable_scalar_6.f90: New test.
      
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@155606 138bc75d-0d04-0410-961f-82ee72b054a4
      53169279
  36. 17 Dec, 2009 1 commit
    • janus's avatar
      gcc/fortran/ · 70f88196
      janus authored
      2009-12-17 Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42144
      	* trans-expr.c (select_class_proc): Skip abstract base types.
      
      gcc/testsuite/
      2009-12-17  Janus Weil  <janus@gcc.gnu.org>
      
      	PR fortran/42144
      	* gfortran.dg/dynamic_dispatch_6.f03: New test.
      
      
      git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@155305 138bc75d-0d04-0410-961f-82ee72b054a4
      70f88196