2010-05-03 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/43592 * fortran/parse.c (parse_interface): Do not dereference a NULL pointer. 2010-05-03 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/43592 * gfortran.dg/unexpected_interface.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158998 138bc75d-0d04-0410-961f-82ee72b054a4
2010-05-02 Tobias Burnus <burnus@net-b.de> PR fortran/18918 * intrinsic.c (add_functions): Fix GFC_STD and add gfc_resolve_* calls for lcobound, ucobound, image_index and this_image. * intrinsic.h (gfc_resolve_lcobound, gfc_resolve_this_image, gfc_resolve_image_index, gfc_resolve_ucobound): New prototypes. * iresolve.c (gfc_resolve_lcobound, gfc_resolve_this_image, gfc_resolve_image_index, gfc_resolve_ucobound, resolve_bound): New functions. (gfc_resolve_lbound, gfc_resolve_ubound): Use resolve_bound. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158974 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-30 Tobias Burnus Mburnus@net-b.de> PR fortran/18918 PR fortran/43931 * trans-types.c (gfc_get_array_descriptor_base): Fix index calculation for array descriptor types. 2010-04-30 Tobias Burnus Mburnus@net-b.de> PR fortran/18918 PR fortran/43931 * gfortran.dg/coarray_13.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158941 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-29 Janus Weil <janus@gcc.gnu.org> 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
2010-04-28 Tobias Burnus <burnus@net-b.de> PR fortran/18918 PR fortran/43919 * simplify.c (simplify_cobound): Handle scalar coarrays. 2010-04-28 Tobias Burnus <burnus@net-b.de> PR fortran/18918 PR fortran/43919 * gfortran.dg/coarray_11.f90: Add scalar-coarrays test case. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158843 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-27 Tobias Burnus <burnus@net-b.de> * gfc-internals.texi: Update copyright year. * gfortran.texi: Ditto. * invoke.texi: Ditto. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158779 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-27 Tobias Burnus <burnus@net-b.de> PR fortran/18918 * resolve.c (resolve_allocate_expr): Allow array coarrays. * trans-types.h (gfc_get_array_type_bounds): Update prototype. * trans-types.c (gfc_get_array_type_bounds, gfc_get_array_descriptor_base): Add corank argument. * trans-array.c (gfc_array_init_size): Handle corank. (gfc_trans_create_temp_array, gfc_array_allocate, gfc_conv_expr_descriptor): Add corank argument to call. * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Ditto. 2010-04-27 Tobias Burnus <burnus@net-b.de> PR fortran/18918 * gfortran.dg/coarray_7.f90: Modified and removed obsolete tests. * gfortran.dg/coarray_12.f90: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158768 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-24 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/30073 PR fortran/43793 * trans-array.c (gfc_trans_array_bound_check): Use TREE_CODE instead of mucking with a tree directly. 2010-04-24 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/30073 PR fortran/43793 gfortran.dg/pr43793.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158692 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-24 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR fortran/43832 * io.c (gfc_match_open): Remove branch to syntax error. Add call to gfc_error with new error message. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158684 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-24 Paul Thomas <pault@gcc.gnu.org> 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
2010-04-22 Richard Guenther <rguenther@suse.de> PR fortran/43829 * resolve.c (gfc_resolve_index): Wrap around ... (gfc_resolve_index_1): ... this. Add parameter to allow any integer kind index type. (resolve_array_ref): Allow any integer kind for the start index of an array ref. * gfortran.dg/vector_subscript_6.f90: New testcase. * gfortran.dg/assign_10.f90: Adjust. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158632 138bc75d-0d04-0410-961f-82ee72b054a4
PR fortran/43836 * f95-lang.c (gfc_define_builtin): Set TREE_NOTHROW on the decl. * gfortran.dg/gomp/pr43836.f90: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158619 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-20 Harald Anlauf <anlauf@gmx.de> * intrinsic.c (sort_actual): Remove 'is' in error message. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158577 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-20 Paul Thomas <pault@gcc.gnu.org> PR fortran/43227 * resolve.c (resolve_fl_derived): If a component character length has not been resolved, do so now. (resolve_symbol): The same as above for a symbol character length. * trans-decl.c (gfc_create_module_variable): A 'length' decl is not needed for a character valued, procedure pointer. PR fortran/43266 * resolve.c (ensure_not_abstract_walker): If 'overriding' is not found, return FAILURE rather than ICEing. 2010-04-20 Paul Thomas <pault@gcc.gnu.org> PR fortran/43227 * gfortran.dg/proc_decl_23.f90: New test. PR fortran/43266 * gfortran.dg/abstract_type_6.f03: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158570 138bc75d-0d04-0410-961f-82ee72b054a4
PR fortran/43339 * openmp.c (gfc_resolve_do_iterator): Only make iteration vars for sequential loops private in the innermost containing task region. * gfortran.dg/gomp/sharing-2.f90: Adjust for iteration vars of sequential loops being private only in the innermost containing task region. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158528 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-18 Eric Botcazou <ebotcazou@adacore.com> * fold-const.c (fold_comparison): Use ssizetype. * gimple-fold.c (maybe_fold_offset_to_array_ref): Likewise. * ipa-prop.c (ipa_modify_call_arguments): Use sizetype. * tree-loop-distribution.c (build_size_arg_loc): Likewise. * tree-object-size.c (compute_object_sizes): Use size_type_node. * tree.h (initialize_sizetypes): Remove parameter. (build_common_tree_nodes): Remove second parameter. * stor-layout.c (initialize_sizetypes): Remove parameter. Always create an unsigned type. (set_sizetype): Assert that the passed type is unsigned and simplify. * tree.c (build_common_tree_nodes): Remove second parameter. Adjust call to initialize_sizetypes. * c-decl.c (c_init_decl_processing): Remove second argument in call to build_common_tree_nodes. cp/ * decl.c (cxx_init_decl_processing): Remove second argument in call to build_common_tree_nodes. java/ * decl.c (java_init_decl_processing): Remove argument in call to initialize_sizetypes fortran/ * f95-lang.c (gfc_init_decl_processing): Remove second argument in call to build_common_tree_nodes. ada/ * gcc-interface/misc.c (gnat_init): Remove second argument in call to build_common_tree_nodes. lto/ * lto-lang.c (lto_init): Remove second argument in call to build_common_tree_nodes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158496 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-17 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/31538 * gfortran.dg/bounds_check_fail_4.f90: Adjust error message. * gfortran.dg/bounds_check_fail_3.f90: Ditto. 2010-04-17 Steven G. Kargl <kargl@gcc.gnu.org> PR fortran/31538 * fortran/trans-array.c (gfc_conv_ss_startstride): Remove the use of gfc_msg_bounds by using 'Array bound mismatch' directly. (gfc_trans_dummy_array_bias): Remove the use of gfc_msg_bounds. Reword error message to include the mismatch in the extent of array bound. * fortran/trans.c: Remove gfc_msg_bounds. It is only used in one place. * fortran/trans.h: Remove extern definition of gfc_msg_bounds. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158474 138bc75d-0d04-0410-961f-82ee72b054a4
2010-04-17 Jerry DeLisle <jvdelisle@gcc.gnu.org> * gfortran.texi: Update information on temporary file locations. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158473 138bc75d-0d04-0410-961f-82ee72b054a4
* trans-decl.c (gfc_build_qualified_array): Ensure ubound.N and lbound.N artificial variable names don't appear in debug info. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158451 138bc75d-0d04-0410-961f-82ee72b054a4
PR fortran/30073 * trans-array.c (gfc_trans_array_bound_check): Eliminate a redundant block of code. Set name to the variable associated with the descriptor. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158392 138bc75d-0d04-0410-961f-82ee72b054a4