Age | Commit message (Collapse) | Author | Files | Lines |
|
2007-10-02 Paul Thomas <pault@gcc.gnu.org>
PR fortran/33550
* decl.c (get_proc_name): Return rc if rc is non-zero; ie. if
the name is a reference to an ambiguous symbol.
2007-10-02 Paul Thomas <pault@gcc.gnu.org>
PR fortran/33550
* gfortran.dg/ambiguous_reference_1.f90: New test.
From-SVN: r128949
|
|
kind of procedures)
2007-10-02 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31154
PR fortran/31229
PR fortran/33334
* decl.c : Declare gfc_function_kind_locs and
gfc_function_type_locus.
(gfc_match_kind_spec): Add second argument kind_expr_only.
Store locus before trying to match the expression. If the
current state corresponds to a function declaration and there
is no match to the expression, read to the parenthesis, return
kind = -1, dump the expression and return.
(gfc_match_type_spec): Renamed from match_type_spec and all
references changed. If an interface or an external function,
store the locus, set kind = -1 and return. Otherwise, if kind
is already = -1, use gfc_find_symbol to try to find a use
associated or imported type.
match.h : Prototype for gfc_match_type_spec.
* parse.c (match_deferred_characteristics): New function.
(parse_spec): If in a function, statement is USE or IMPORT
or DERIVED_DECL and the function kind=-1, call
match_deferred_characteristics. If kind=-1 at the end of the
specification expressions, this is an error.
* parse.h : Declare external gfc_function_kind_locs and
gfc_function_type_locus.
2007-10-02 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31154
PR fortran/31229
PR fortran/33334
* gfortran.dg/function_kinds_1.f90: New test.
* gfortran.dg/function_kinds_2.f90: New test.
* gfortran.dg/derived_function_interface_1.f90: Correct illegal
use association into interfaces.
From-SVN: r128948
|
|
PR fortran/33221
* gfortran.h (symbol_attribute): Add zero_comp field.
* symbol.c (gfc_use_derived): Handle case of emtpy derived types.
* decl.c (gfc_match_data_decl): Likewise.
(gfc_match_derived_decl): Likewise.
* module.c (ab_attribute, attr_bits): Add AB_ZERO_COMP member.
(mio_symbol_attribute): Write and read AB_ZERO_COMP.
* resolve.c (resolve_symbol): Handle case of emtpy derived types.
* parse.c (parse_derived): Likewise.
* gfortran.dg/used_types_18.f90: Declare variable of empty
derived type.
From-SVN: r128633
|
|
2007-09-05 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31564
* primary.c (gfc_match_rvalue): Make expressions that refer
to derived type parameters that have array references into
variable expressions. Remove references to use association
from the symbol.
PR fortran/33241
* decl.c (add_init_expr_to_sym): Provide assumed character
length parameters with the length of the initialization
expression, if a constant, or that of the first element of
an array.
2007-09-05 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31564
* gfortran.dg/derived_comp_array_ref_2.f90: New test.
PR fortran/33241
* gfortran.dg/char_length_10.f90: New test.
From-SVN: r128130
|
|
PROCEDURE statements.
2007-09-04 Janus Weil <jaydub66@gmail.com>
Paul Thomas <pault@gcc.gnu.org>
* decl.c (match_procedure_decl,match_procedure_in_interface,
gfc_match_procedure): Handle PROCEDURE statements.
* gfortran.h (struct gfc_symbol): New member "gfc_symbol *interface".
(enum gfc_statement): New element "ST_PROCEDURE".
(strcut symbol_attribute): New member "unsigned procedure".
* interface.c (check_interface0): Extended error checking.
* match.h: Add gfc_match_procedure prototype.
* parse.c (decode_statement,next_statement,gfc_ascii_statement,
parse_derived,parse_interface): Implement PROCEDURE statements.
* resolve.c (resolve_symbol): Ditto.
* symbol.c (check_conflict): Ditto.
(gfc_add_proc): New function for setting the procedure attribute.
(copy_formal_args): New function for copying formal argument lists.
2007-09-04 Janus Weil <jaydub66@gmail.com>
Tobias Burnus <burnus@net-b.de>
* gfortran.dg/proc_decl_1.f90: New.
* gfortran.dg/proc_decl_2.f90: New.
* gfortran.dg/proc_decl_3.f90: New.
* gfortran.dg/proc_decl_4.f90: New.
Co-Authored-By: Paul Thomas <pault@gcc.gnu.org>
Co-Authored-By: Tobias Burnus <burnus@net-b.de>
From-SVN: r128081
|
|
characters.
* decl.c (match_string_p): New helper function to explicitly match
a string of characters.
(match_attr_spec): Remove no longer needed DECL_COLON from decl_types.
Delete decls array and peek_char. Rewrite decl attribute parser to
avoid calling gfc_match_strings.
* match.c (gfc_match_strings): Delete unused function.
* match.h (gfc_match_strings): Delete prototype.
From-SVN: r128028
|
|
and accepts invalid)
2007-08-29 Christopher D. Rickett <crickett@lanl.gov>
PR fortran/33215
* decl.c (build_sym): Pass number of identifiers on line to
set_binding_label.
(set_binding_label): Verify that only one identifier given if
NAME= specified, even if the given binding label has zero length.
(gfc_match_bind_c): Remove declaration for has_name_equals because
it hides the static global one that is needed.
2007-08-29 Christopher D. Rickett <crickett@lanl.gov>
PR fortran/33215
* gfortran.dg/binding_label_tests_15.f03: New test case.
* gfortran.dg/binding_label_tests_16.f03: Ditto.
From-SVN: r127898
|
|
* decl.c (variable_decl): Don't share charlen structs if
length == NULL.
* trans-decl.c (create_function_arglist): Assert
f->sym->ts.cl->backend_decl is NULL instead of unsharing
charlen struct here.
* gfortran.dg/assumed_charlen_sharing.f90: New test.
From-SVN: r127748
|
|
2007-08-22 Janus Weil <jaydub66@gmail.com>
* decl.c (match_attr_spec): Pass on errors from gfc_match_bind_c.
(gfc_match_bind_c): Bugfix in check for NAME= with abstract interfaces.
(gfc_match_mopdproc): Bugfix to reject module procedures in
abstract interfaces.
2007-08-22 Janus Weil <jaydub66@gmail.com>
* interface_abstract_1.f90: Extended test case.
* interface_abstract_3.f90: New test.
From-SVN: r127718
|
|
2007-08-18 Tobias Burnus <burnus@net-b.de>
* gfortran.h (gfc_is_intrinsic_typename): Add declaration.
* symbol.c (gfc_is_intrinsic_typename): New function.
* parse.c (decode_statement): Check for space in ABSTRACT INTERFACE.
(parse_interface): Use gfc_is_intrinsic_typename.
* decl.c (gfc_match_derived_decl): Ditto.
* module.c (gfc_match_use): Use gcc_unreachable() for
INTERFACE_ABSTRACT in switch().
2007-08-19 Tobias Burnus <burnus@net-b.de>
* gfortran.dg/interface_abstract_2.f90: New.
* gfortran.dg/interface_abstract_1.f90: Fix typo.
From-SVN: r127626
|
|
2007-08-18 Paul Thomas <pault@gcc.gnu.org>
Janus Weil <jaydub66@gmail.com>
* interface.c (gfc_match_interface,gfc_match_abstract_interface,
gfc_match_end_interface,gfc_add_interface): Add abstract interface.
* dump-parse-tree.c (gfc_show_attr): Ditto.
* gfortran.h (interface_type,symbol_attribute): Ditto.
* module.c (gfc_match_use,ab_attribute,attr_bits,
mio_symbol_attribute): Ditto.
* resolve.c (resolve_function): Ditto.
* match.h: Ditto.
* parse.c (decode_statement): Ditto.
(parse_interface): Ditto, check for C1203 (name of abstract interface
cannot be the same as an intrinsic type).
* decl.c (gfc_match_bind_c): Check for NAME= with abstract interfaces.
(access_attr_decl): Handle Abstract interfaces.
2007-08-17 Tobias Burnus <burnus@net-b.de>
* gfortran.dg/interface_abstract_1.f90: New.
From-SVN: r127612
|
|
PR fortran/33066
* decl.c (gfc_get_type_attr_spec): Fix whitespace.
(gfc_match_derived_decl): Fix logic.
* gfortran.dg/use_8.f90: New test.
* gfortran.dg/c_loc_tests_2.f03: Fix code.
From-SVN: r127497
|
|
2007-08-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/32827
* decl.c (variable_decl): Check for an imported symbol
by looking for its symtree and testing for the imported
attribute.
(gfc_match_import): Remove change of symbol's namespace
and set the attribute imported instead.
* symbol.c (gfc_get_sym_tree): It is not an error if a
symbol is imported.
* gfortran.h : Add the 'imported' to symbol_attribute.
2007-08-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/32827
* gfortran.dg/import6.f90: New test.
From-SVN: r127397
|
|
2007-08-04 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31214
* symbol.c (get_unique_symtree): Moved from module.c.
* module.c (get_unique_symtree): Moved to symbol.c.
* decl.c (get_proc_name): Transfer the typespec from the local
symbol to the module symbol, in the case that an entry is also
a module procedure. Ensure the local symbol is cleaned up by
pointing to it with a unique symtree.
* dump_parse_tree (gfc_show_code_node): Add EXEC_ASSIGN_CALL.
2007-08-04 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31214
* gfortran.dg/entry_13.f90: New test.
* gfortran.dg/entry_12.f90: Clean up .mod file.
From-SVN: r127213
|
|
Public...
* arith.c: Change copyright header to refer to version 3 of the GNU General
Public License and to point readers at the COPYING3 file and the FSF's
license web page.
* openmp.c, interface.c, intrinsic.c, trans-array.c, trans-expr.c, symbol.c,
iso-fortran-env.def, intrinsic.h, decl.c, trans-array.h, matchexp.c,
dump-parse-tree.c, trans-common.c, array.c, Make-lang.in, trans-openmp.c,
gfortran.h, error.c, iso-c-binding.def, lang.opt, data.c, trans-const.c,
trans-stmt.c, expr.c, trans-const.h, trans-stmt.h, module.c, trans.c,
scanner.c, trans-types.c, trans.h, gfortranspec.c, trans-types.h,
lang-specs.h, io.c, bbt.c, resolve.c, f95-lang.c, st.c, iresolve.c, match.c,
trans-decl.c, trans-io.c, target-memory.c, match.h, target-memory.h, parse.c,
arith.h, check.c, dependency.c, parse.h, types.def, convert.c, dependency.h,
primary.c, trans-intrinsic.c, options.c, misc.c, simplify.c: Likewise.
From-SVN: r127129
|
|
Undefined type)
2007-07-23 Christopher D. Rickett <crickett@lanl.gov>
PR fortran/32797
PR fortran/32800
* decl.c (verify_bind_c_sym): Use the result symbol for functions
with a result clause. Warn if implicitly typed. Verify the type
and rank of the SHAPE argument, if given.
* resolve.c (gfc_iso_c_sub_interface): Use gfc_procedure_use to
check the actual args against the formal, sorting them if
necessary.
* symbol.c (gen_shape_param): Initialize type of SHAPE param to
BT_VOID.
2007-07-23 Christopher D. Rickett <crickett@lanl.gov>
PR fortran/32797
PR fortran/32800
* gfortran.dg/bind_c_usage_8.f03: New test case.
* gfortran.dg/c_f_pointer_tests_2.f03: Ditto.
* gfortran.dg/c_ptr_tests_5.f03: Updated expected error message.
From-SVN: r126856
|
|
fortran/trans-const.c:348 with len)
gcc/fortran:
2007-07-12 Daniel Franke <franke.daniel@gmail.com>
PR fortran/31639
* decl.c (gfc_match_suffix): Removed surplus general error that hides
a more specific message.
* resolve.c (resolve_fl_variable): Reject illegal initializiers only
if not already done.
(resolve_fl_procedure): Added check for initializers of functions.
gcc/testsuite:
2007-07-12 Daniel Franke <franke.daniel@gmail.com>
PR fortran/31639
* gfortran.dg/func_decl_4.f90: New test.
From-SVN: r126605
|
|
2007-07-12 Christopher D. Rickett <crickett@lanl.gov>
PR fortran/32599
* decl.c (verify_c_interop_param): Require character string dummy
args to BIND(C) procedures to have length 1.
* resolve.c (resolve_fl_procedure): Modify parameter checking for
BIND(C) procedures.
PR fortran/32601
* resolve.c (gfc_iso_c_func_interface): Verify that a valid
expression is given as an argument to C_LOC and C_ASSOCIATED.
* trans-io.c (transfer_expr): Add argument for code block. Add
standards check to determine if an error message should be
reported for printing C_PTR or C_FUNPTR.
(transfer_array_component): Update arguments to transfer_expr.
(gfc_trans_transfer): Ditto.
* symbol.c (gen_cptr_param): Fix whitespace.
2007-07-12 Christopher D. Rickett <crickett@lanl.gov>
PR fortran/32599
* gfortran.dg/32599.f03: New test case.
PR fortran/32601
* gfortran.dg/32601.f03: New test case.
* gfortran.dg/32601_1.f03: Ditto.
* gfortran.dg/c_ptr_tests_9.f03: Updated dg-options.
* gfortran.dg/c_ptr_tests_10.f03: Ditto.
From-SVN: r126598
|
|
2007-07-07 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/32644
* decl.c (match_attr_spec): Don't return MATCH_ERROR if comma found and
gfc_match_bind_c does not return MATCH_YES.
From-SVN: r126450
|
|
* decl.c, gfortran.h, interface.c, module.c, resolve.c,
trans-array.c, trans-decl.c: Fix comment typos. Follow
spelling conventions.
* intrinsic.texi: Fix typos. Follow spelling conventions.
From-SVN: r126440
|
|
gcc/fortran:
2007-05-06 Daniel Franke <franke.daniel@gmail.com>
PR fortran/32633
* symbol.c (save_status): New.
* gfortran.h (save_status): Added external declaration.
(check_conflict): Check for conflicting explicite SAVE statements
only.
(gen_special_c_interop_ptr): Use SAVE_EXPLICIT constant.
* module.c (ab_attribute, attr_bits): Removed enumerator value
AB_SAVE for save attribute.
(mio_symbol_attribute): Import/export the full SAVE status,
removed usage of AB_SAVE.
* dump-parse-tree.c (gfc_show_attr): Dump full SAVE status.
* decl.c (add_init_expr_to_sym): Set SAVE_IMPLICIT only if not
already explicit.
gcc/testsuite:
2007-07-06 Daniel Franke <franke.daniel@gmail.com>
* gfortran.dg/save_parameter.f90: New test.
* gfortran.dg/module_md5_1.f90: Updated MD5 sum.
From-SVN: r126413
|
|
save attribute undefined))
gcc/fortran/
2007-07-05 Daniel Franke <franke.daniel@gmail.com>
Tobias Burnus <burnus@net-b.de>
PR fortran/32359
* gfortran.h (symbol_attribute): Change save attribute into an enum.
* decl.c (add_init_expr_to_sym): Set it to SAVE_IMPLICIT.
* symbol.c (gfc_add_save): Check for SAVE_EXPLICIT.
* resolve.c (resolve_fl_variable): Check for SAVE_EXPLICIT.
(resolve_symbol): Allow OMP threadprivate with
initialization SAVEd and save_all variable.
* trans-decl.c (gfc_finish_var_decl): Remove obsolete sym->value check.
libgomp/
2007-07-05 Tobias Burnus <burnus@net-b.de>
PR fortran/32359
* testsuite/libgomp.fortran/pr32359.f90: New.
gcc/testsuite/
2007-07-05 Tobias Burnus <burnus@net-b.de>
PR fortran/32359
* gfortran.dg/module_md5_1.f90: Update MD5 number.
From-SVN: r126366
|
|
edit format statements)
2007-07-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/32545
* io.c (check_format): Always call gfc_error for errors.
(check_format_string): Change type of this function to try and
return the result of check_format.
(check_io_constraints): Return MATCH_ERROR if check_format_string
returns FAILURE.
2007-07-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/32612
* decl.c (get_proc_name): Include attr->mod_proc in check for error.
From-SVN: r126295
|
|
2007-07-01 Christopher D. Rickett <crickett@lanl.gov>
* interface.c (gfc_compare_derived_types): Special case for comparing
derived types across namespaces.
(gfc_compare_types): Deal with BT_VOID.
(compare_parameter): Use BT_VOID to accept ISO C Binding pointers.
* trans-expr.c (gfc_conv_function_call): Remove setting parm_kind
to SCALAR
(gfc_conv_initializer): Deal with ISO C Binding NULL_PTR and
NULL_FUNPTR.
(gfc_conv_expr): Convert expressions for ISO C Binding derived types.
* symbol.c (gfc_set_default_type): BIND(C) variables should not be
implicitly declared.
(check_conflict): Add BIND(C) and check for conflicts.
(gfc_add_explicit_interface): Whitespace.
(gfc_add_is_bind_c): New function.
(gfc_copy_attr): Use it.
(gfc_new_symbol): Initialize ISO C Binding objects.
(get_iso_c_binding_dt): New function.
(verify_bind_c_derived_type): Ditto.
(gen_special_c_interop_ptr): Ditto.
(add_formal_arg): Ditto.
(gen_cptr_param): Ditto.
(gen_fptr_param): Ditto.
(gen_shape_param): Ditto.
(add_proc_interface): Ditto.
(build_formal_args): Ditto.
(generate_isocbinding_symbol): Ditto.
(get_iso_c_sym): Ditto.
* decl.c (num_idents_on_line, has_name_equals): New variables.
(verify_c_interop_param): New function.
(build_sym): Finish binding labels and deal with COMMON blocks.
(add_init_expr_to_sym): Check if the initialized expression is
an iso_c_binding named constants
(variable_decl): Set ISO C Binding type_spec components.
(gfc_match_kind_spec): Check match for C interoperable kind.
(match_char_spec): Fix comment. Chnage gfc_match_small_int
to gfc_match_small_int_expr. Check for C interoperable kind.
(match_type_spec): Clear the current binding label.
(match_attr_spec): Add DECL_IS_BIND_C. If BIND(C) is found, use it
to set attributes.
(set_binding_label): New function.
(set_com_block_bind_c): Ditto.
(verify_c_interop): Ditto.
(verify_com_block_vars_c_interop): Ditto.
(verify_bind_c_sym): Ditto.
(set_verify_bind_c_sym): Ditto.
(set_verify_bind_c_com_block): Ditto.
(get_bind_c_idents): Ditto.
(gfc_match_bind_c_stmt): Ditto.
(gfc_match_data_decl): Use num_idents_on_line.
(match_result): Deal with right paren in BIND(C).
(gfc_match_suffix): New function.
(gfc_match_function_decl): Use it. Code is re-arranged to deal with
ISO C Binding result clauses.
(gfc_match_subroutine): Deal with BIND(C).
(gfc_match_bind_c): New function.
(gfc_get_type_attr_spec): New function. Code is re-arranged in and
taken from gfc_match_derived_decl.
(gfc_match_derived_decl): Add check for BIND(C).
* trans-common.c: Forward declare gfc_get_common.
(gfc_sym_mangled_common_id): Change arg from 'const char *name' to
'gfc_common_head *com'. Check for ISO C Binding of the common block.
(build_common_decl): 'com->name' to 'com in SET_DECL_ASSEMBLER_NAME.
* gfortran.h: Add GFC_MAX_BINDING_LABEL_LEN
(bt): Add BT_VOID
(sym_flavor): Add FL_VOID.
(iso_fortran_env_symbol, iso_c_binding_symbol, intmod_id): New enum
(CInteropKind_t): New struct.
(c_interop_kinds_table): Use it. Declare an array of structs.
(symbol_attribute): Add is_bind_c, is_c_interop, and is_iso_c
bitfields.
(gfc_typespec): Add is_c_interop; is_iso_c, and f90_type members.
(gfc_symbol): Add from_intmod, intmod_sym_id, binding_label, and
common_block members.
(gfc_common_head): Add binding_label and is_bind_c members.
(gfc_gsymbol): Add sym_name, mod_name, and binding_label members.
Add prototypes for get_c_kind, gfc_validate_c_kind,
gfc_check_any_c_kind, gfc_add_is_bind_c, gfc_add_value,
verify_c_interop, verify_c_interop_param, verify_bind_c_sym,
verify_bind_c_derived_type, verify_com_block_vars_c_interop,
generate_isocbinding_symbol, get_iso_c_sym, gfc_iso_c_sub_interface
* iso-c-binding.def: New file. This file contains the definitions
of the types provided by the Fortran 2003 ISO_C_BINDING intrinsic
module.
* trans-const.c (gfc_conv_constant_to_tree): Deal with C_NULL_PTR
or C_NULL_FUNPTR expressions.
* expr.c (gfc_copy_expr): Add BT_VOID case. For BT_CHARACTER, the
ISO C Binding requires a minimum string length of 1 for '\0'.
* module.c (intmod_sym): New struct.
(pointer_info): Add binding_label member.
(write_atom): Set len to 0 for NULL pointers. Check for NULL p and *p.
(ab_attribute): Add AB_IS_BIND_C, AB_IS_C_INTEROP and AB_IS_ISO_C.
(attr_bits): Add "IS_BIND_C", "IS_C_INTEROP", and "IS_ISO_C".
(mio_symbol_attribute): Deal with ISO C Binding attributes.
(bt_types): Add "VOID".
(mio_typespec): Deal with ISO C Binding components.
(mio_namespace_ref): Add intmod variable.
(mio_symbol): Check for symbols from an intrinsic module.
(load_commons): Check for BIND(C) common block.
(read_module): Read binding_label and use it.
(write_common): Add label. Write BIND(C) info.
(write_blank_common): Blank commons are not BIND(C). Explicitly
set is_bind_c=0.
(write_symbol): Deal with binding_label.
(sort_iso_c_rename_list): New function.
(import_iso_c_binding_module): Ditto.
(create_int_parameter): Add to args.
(use_iso_fortran_env_module): Adjust to deal with iso_c_binding
intrinsic module.
* trans-types.c (c_interop_kinds_table): new array of structs.
(gfc_validate_c_kind): New function.
(gfc_check_any_c_kind): Ditto.
(get_real_kind_from_node): Ditto.
(get_int_kind_from_node): Ditto.
(get_int_kind_from_width): Ditto.
(get_int_kind_from_minimal_width): Ditto.
(init_c_interop_kinds): Ditto.
(gfc_init_kinds): call init_c_interop_kinds.
(gfc_typenode_for_spec): Adjust for BT_VOID and ISO C Binding pointers.
Adjust handling of BT_DERIVED.
(gfc_sym_type): Whitespace.
(gfc_get_derived_type): Account for iso_c_binding derived types
* resolve.c (is_scalar_expr_ptr): New function.
(gfc_iso_c_func_interface): Ditto.
(resolve_function): Use gfc_iso_c_func_interface.
(set_name_and_label): New function.
(gfc_iso_c_sub_interface): Ditto.
(resolve_specific_s0): Use gfc_iso_c_sub_interface.
(resolve_bind_c_comms): New function.
(resolve_bind_c_derived_types): Ditto.
(gfc_verify_binding_labels): Ditto.
(resolve_fl_procedure): Check for ISO C interoperability.
(resolve_symbol): Check C interoperability.
(resolve_types): Walk the namespace. Check COMMON blocks.
* trans-decl.c (gfc_sym_mangled_identifier): Prevent the mangling
of identifiers that have an assigned binding label.
(gfc_sym_mangled_function_id): Use the binding label rather than
the mangled name.
(gfc_finish_var_decl): Put variables that are BIND(C) into a common
segment of the object file, because this is what C would do.
(gfc_create_module_variable): Conver to proper types
(set_tree_decl_type_code): New function.
(generate_local_decl): Check dummy variables and derived types for
ISO C Binding attributes.
* match.c (gfc_match_small_int_expr): New function.
(gfc_match_name_C): Ditto.
(match_common_name): Deal with ISO C Binding in COMMON blocks
* trans-io.c (transfer_expr): Deal with C_NULL_PTR or C_NULL_FUNPTR
expressions
* match.h: Add prototypes for gfc_match_small_int_expr,
gfc_match_name_C, match_common_name, set_com_block_bind_c,
set_binding_label, set_verify_bind_c_sym,
set_verify_bind_c_com_block, get_bind_c_idents,
gfc_match_bind_c_stmt, gfc_match_suffix, gfc_match_bind_c,
gfc_get_type_attr_spec
* parse.c (decode_statement): Use gfc_match_bind_c_stmt
(parse_derived): Init *derived_sym = NULL, and gfc_current_block
later for valiadation.
* primary.c (got_delim): Set ISO C Binding components of ts.
(match_logical_constant): Ditto.
(match_complex_constant): Ditto.
(match_complex_constant): Ditto.
(gfc_match_rvalue): Check for existence of at least one arg for
C_LOC, C_FUNLOC, and C_ASSOCIATED.
* misc.c (gfc_clear_ts): Clear ISO C Bindoing components in ts.
(get_c_kind): New function.
2007-07-01 Christopher D. Rickett <crickett@lanl.gov>
* Makefile.in: Add support for iso_c_generated_procs.c and
iso_c_binding.c.
* Makefile.am: Ditto.
* intrinsics/iso_c_generated_procs.c: New file containing helper
functions.
* intrinsics/iso_c_binding.c: Ditto.
* intrinsics/iso_c_binding.h: New file
* gfortran.map: Include the __iso_c_binding_c_* functions.
* libgfortran.h: define GFC_NUM_RANK_BITS.
2007-06-23 Christopher D. Rickett <crickett@lanl.gov>
* bind_c_array_params.f03: New files for Fortran 2003 ISO C Binding.
* bind_c_coms.f90: Ditto.
* bind_c_coms_driver.c: Ditto.
* bind_c_dts.f90: Ditto.
* bind_c_dts_2.f03: Ditto.
* bind_c_dts_2_driver.c: Ditto.
* bind_c_dts_3.f03: Ditto.
* bind_c_dts_4.f03: Ditto.
* bind_c_dts_driver.c: Ditto.
* bind_c_implicit_vars.f03: Ditto.
* bind_c_procs.f03: Ditto.
* bind_c_usage_2.f03: Ditto.
* bind_c_usage_3.f03: Ditto.
* bind_c_usage_5.f03: Ditto.
* bind_c_usage_6.f03: Ditto.
* bind_c_usage_7.f03: Ditto.
* bind_c_vars.f90: Ditto.
* bind_c_vars_driver.c: Ditto.
* binding_c_table_15_1.f03: Ditto.
* binding_label_tests.f03: Ditto.
* binding_label_tests_10.f03: Ditto.
* binding_label_tests_10_main.f03: Ditto.
* binding_label_tests_11.f03: Ditto.
* binding_label_tests_11_main.f03: Ditto.
* binding_label_tests_12.f03: Ditto.
* binding_label_tests_13.f03: Ditto.
* binding_label_tests_13_main.f03: Ditto.
* binding_label_tests_14.f03: Ditto.
* binding_label_tests_2.f03: Ditto.
* binding_label_tests_3.f03: Ditto.
* binding_label_tests_4.f03: Ditto.
* binding_label_tests_5.f03: Ditto.
* binding_label_tests_6.f03: Ditto.
* binding_label_tests_7.f03: Ditto.
* binding_label_tests_8.f03: Ditto.
* binding_label_tests_9.f03: Ditto.
* c_assoc.f90: Ditto.
* c_assoc_2.f03: Ditto.
* c_f_pointer_shape_test.f90: Ditto.
* c_f_pointer_tests.f90: Ditto.
* c_f_tests_driver.c: Ditto.
* c_funloc_tests.f03: Ditto.
* c_funloc_tests_2.f03: Ditto.
* c_funloc_tests_3.f03: Ditto.
* c_funloc_tests_3_funcs.c: Ditto.
* c_kind_params.f90: Ditto.
* c_kind_tests_2.f03: Ditto.
* c_kinds.c: Ditto.
* c_loc_driver.c: Ditto.
* c_loc_test.f90: Ditto.
* c_loc_tests_2.f03: Ditto.
* c_loc_tests_2_funcs.c: Ditto.
* c_loc_tests_3.f03: Ditto.
* c_loc_tests_4.f03: Ditto.
* c_loc_tests_5.f03: Ditto.
* c_loc_tests_6.f03: Ditto.
* c_loc_tests_7.f03: Ditto.
* c_loc_tests_8.f03: Ditto.
* c_ptr_tests.f03: Ditto.
* c_ptr_tests_10.f03: Ditto.
* c_ptr_tests_5.f03: Ditto.
* c_ptr_tests_7.f03: Ditto.
* c_ptr_tests_7_driver.c: Ditto.
* c_ptr_tests_8.f03: Ditto.
* c_ptr_tests_8_funcs.c: Ditto.
* c_ptr_tests_9.f03: Ditto.
* c_ptr_tests_driver.c: Ditto.
* c_size_t_driver.c: Ditto.
* c_size_t_test.f03: Ditto.
* com_block_driver.f90: Ditto.
* global_vars_c_init.f90: Ditto.
* global_vars_c_init_driver.c: Ditto.
* global_vars_f90_init.f90: Ditto.
* global_vars_f90_init_driver.c: Ditto.
* interop_params.f03: Ditto.
* iso_c_binding_only.f03: Ditto.
* iso_c_binding_rename_1.f03: Ditto.
* iso_c_binding_rename_1_driver.c: Ditto.
* iso_c_binding_rename_2.f03: Ditto.
* iso_c_binding_rename_2_driver.c: Ditto.
* kind_tests_2.f03: Ditto.
* kind_tests_3.f03: Ditto.
* module_md5_1.f90: Ditto.
* only_clause_main.c: Ditto.
* print_c_kinds.f90: Ditto.
* test_bind_c_parens.f03: Ditto.
* test_c_assoc.c: Ditto.
* test_com_block.f90: Ditto.
* test_common_binding_labels.f03: Ditto.
* test_common_binding_labels_2.f03: Ditto.
* test_common_binding_labels_2_main.f03: Ditto.
* test_common_binding_labels_3.f03: Ditto.
* test_common_binding_labels_3_main.f03: Ditto.
* test_only_clause.f90: Ditto.
* use_iso_c_binding.f90: Ditto.
* value_5.f90: Ditto.
* value_test.f90: Ditto.
* value_tests_f03.f90: Ditto.
From-SVN: r126185
|
|
2007-06-20 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/25061
* decl.c (get_proc_name) Check symbol for generic interface
and issue an error.
From-SVN: r125906
|
|
* decl.c: Miscellaneous whitespace fixes.
* expr.c: Likewise.
* gfortran.h: Likewise.
* interface.c : Likewise.
* io.c: Likewise.
* match.c: Likewise.
* match.h: Likewise.
* module.c: Likewise.
* parse.c: Likewise.
* resolve.c: Likewise.
* symbol.c: Likewise.
* trans-array.c: Likewise.
* trans-common.c: Likewise.
* trans-decl.c: Likewise.
* trans-intrinsic.c: Likewise.
* trans-io.c: Likewise.
* trans-stmt.c: Likewise.
* trans-types.c: Likewise.
From-SVN: r125533
|
|
found!)
2007-05-11 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31474
* decl.c (get_proc_name): If an entry has already been declared
as a module procedure, pick up the symbol and the symtree and
use them for the entry.
2007-05-11 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31474
* gfortran.dg/entry_10.f90: New test.
From-SVN: r124613
|
|
2007-05-08 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29397
PR fortran/29400
* decl.c (add_init_expr_to_sym): Expand a scalar initializer
for a parameter array into an array expression with the right
shape.
* array.c (spec_dimen_size): Remove static attribute.
* gfortran.h : Prototype for spec_dimen_size.
2007-05-08 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29397
* gfortran.dg/parameter_array_init_1.f90: New test.
PR fortran/29400
* gfortran.dg/parameter_array_init_2.f90: New test.
From-SVN: r124541
|
|
2007-05-05 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/31251
* decl.c (match_char_spec): Add check for invalid character lengths.
2007-05-05 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/31251
* gfortran.dg/char_type_len_2.f90: New test.
From-SVN: r124469
|
|
2007-04-15 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31204
* primary.c (check_for_implicit_index): New function to check
that a host associated variable is not an undeclared implied
do loop index.
(gfc_match_rvalue, match_variable): Use it and reset the
implied_index attribute.
* gfortran.h : Add the implied_index field to symbol_attribute.
* match.c (gfc_match_iterator): Mark the iterator variable
with the new attribute.
* decl.c (build_sym): Reset the new attribute.
2007-04-15 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31204
* gfortran.dg/array_constructor_16.f90: New test.
From-SVN: r123849
|
|
PR fortran/31250
fortran/
* decl.c (match_char_spec): Move check for negative CHARACTER
length ...
* resolve.c (resolve_charlen): ... here.
(resolve_types): Resolve CHARACTER lengths earlier.
teststuite/
* gfortran.dg/char_length_2.f90: New.
From-SVN: r123763
|
|
WERE statements.
fortran/31471
fortran/
* decl.c (gfc_match_end): Also check for construct name in END
FORALL and END WERE statements.
* match.c (match_case_eos): Use uppercase for statement name in
error message.
(match_elsewhere): Construct name may appear iff construct has a
name.
testsuite/
* gfortran.dg/block_name_1.f90: New.
* gfortran.dg/block_name_2.f90: New.
From-SVN: r123758
|
|
specification in a program, subroutine, or function)
2007-04-12 Tobias Burnus <burnus@net-b.de>
PR fortran/31472
* decl.c (match_attr_spec): Allow PRIVATE/PUBLIC
attribute in type definitions.
(gfc_match_private): Allow PRIVATE statement only
in specification part of modules.
(gfc_match_public): Ditto for PUBLIC.
(gfc_match_derived_decl): Allow PRIVATE/PUBLIC attribute only in
specificification part of modules.
2007-04-12 Tobias Burnus <burnus@net-b.de>
PR fortran/31472
* gfortran.dg/access_spec_1.f90: New test.
* gfortran.dg/access_spec_2.f90: New test.
* gfortran.dg/non_module_public.f90: Match new error message.
From-SVN: r123735
|
|
2007-04-05 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31292
* decl.c (gfc_match_modproc): Go up to the top of the namespace
tree to find the module namespace for gfc_get_symbol.
2007-04-05 Paul Thomas <pault@gcc.gnu.org>
PR fortran/31292
* gfortran.dg/contained_module_proc_1.f90: New test.
From-SVN: r123517
|
|
PR fortran/20897
fortran/
* decl.c (gfc_match_derived_decl): Reliably reject
'doubleprecision' and 'doublecomplex' as type names.
testsuite/
* gfortran.dg/derived_name_1.f90: New.
* gfortran.dg/derived_name_2.f: New.
From-SVN: r123129
|
|
2007-03-15 Tobias Burnus <burnus@gcc.gnu.org>
Paul Thomas <pault@gcc.gnu.org>
PR fortran/30922
* decl.c (gfc_match_import): If the parent of the current name-
space is null, try looking for an imported symbol in the parent
of the proc_name interface.
* resolve.c (resolve_fl_variable): Do not check for blocking of
host association by a same symbol, if the symbol is in an
interface body.
2007-03-15 Paul Thomas <pault@gcc.gnu.org>
PR fortran/30879
* decl.c (match_data_constant): Before going on to try to match
a name, try to match a structure component.
PR fortran/30870
* resolve.c (resolve_actual_arglist): Do not reject a generic
actual argument if it has a same name specific interface.
PR fortran/31163
* trans-array.c (parse_interface): Do not nullify allocatable
components if the symbol has the saved attribute.
2007-03-15 Paul Thomas <pault@gcc.gnu.org>
PR fortran/30922
* gfortran.dg/import5.f90.f90: New test.
PR fortran/30879
* gfortran.dg/data_components_1.f90: New test.
PR fortran/30870
* gfortran.dg/generic_13.f90: New test.
PR fortran/31163
* gfortran.dg/alloc_comp_basics_5.f90: New test.
From-SVN: r122944
|
|
old-style kind specifiers for COMPLEX.
* gfortran.texi (Old-style kind specifications): Document
special handling of old-style kind specifiers for COMPLEX.
* decl.c (gfc_match_old_kind_spec): Document kind/bytesize
assumptions for COMPLEX in comment.
From-SVN: r122599
|
|
for recursive functions)
2007-03-02 Paul Thomas <pault@gcc.gnu.org>
Tobias Burnus <burnus@net-b.de>
PR fortran/30873
* decl.c (gfc_match_entry): Remove erroneous entry result check.
2007-03-02 Paul Thomas <pault@gcc.gnu.org>
Tobias Burnus <burnus@net-b.de>
PR fortran/30873
* gfortran.dg/entry_9.f90: New test.
Co-Authored-By: Tobias Burnus <burnus@net-b.de>
From-SVN: r122495
|
|
old-style kind specifiers for COMPLEX.
* gfortran.texi (Old-style kind specifications): Document
special handling of old-style kind specifiers for COMPLEX.
* decl.c (gfc_match_old_kind_spec): Documented kind/bytesize
assumptions in comment.
From-SVN: r122238
|
|
error))
2007-02-11 Tobias Schlueter <tobi@gcc.gnu.org>
PR fortran/30478
fortran/
* decl.c (add_init_expr_to_sym): Remove ENUM specific code.
(variable_decl): Likewise. Rewrap comment.
(match_attr_spec): Remove ENUM specific code.
(gfc_match_enum): Fix typo in error message.
(enumerator_decl): New function.
(gfc_match_enumerator_def): Use enumerator_decl instead of
variable_decl. Adapt code accordingly.
testsuite/
* gfortran.dg/enum_4.f90: Update error message checks.
From-SVN: r121830
|
|
2007-02-11 Paul Thomas <pault@gcc.gnu.org>
PR fortran/30554
* module.c (find_symtree_for_symbol): New function to return
a symtree that is not a "unique symtree" given a symbol.
(read_module): Do not automatically set pointer_info to
referenced because this inhibits the generation of a unique
symtree. Recycle the existing symtree if possible by calling
find_symtree_for_symbol.
PR fortran/30319
* decl.c (add_init_expr_to_sym): Make new charlen for an array
constructor initializer.
2007-02-11 Paul Thomas <pault@gcc.gnu.org>
PR fortran/30554
* gfortran.dg/used_dummy_types_6.f90: Add the "privatized"
versions of the modules.
PR fortran/30617
* gfortran.dg/intrinsic_actual_2.f90: Make this legal fortran
by getting rid of recursive I/O and providing functions with
results.
PR fortran/30319
* gfortran.dg/char_array_constructor_2.f90
From-SVN: r121824
|
|
fortran/
2007-01-31 Tobias Burnus <burnus@net-b.de>
PR fortran/30520
* interface.c (compare_actual_formal): Check conformance between
actual and VOLATILE dummy arguments.
* symbol.c (gfc_add_volatile): Allow setting of VOLATILE
multiple times in different scopes.
* decl.c (gfc_match_volatile): Search symbol in host association.
testsuite/
2007-01-31 Tobias Burnus <burnus@net-b.de>
PR fortran/30520
* gfortran.dg/volatile8.f90: New argument conformance test.
* gfortran.dg/volatile9.f90: New scope test.
From-SVN: r121379
|
|
2007-01-07 Steven G. Kargl <kargl@gcc.gnu.org>
* decl.c, dump-parse-tree.c, error.c, data.c, expr.c, dependency.c,
convert.c: Update Copyright dates. Fix whitespace.
From-SVN: r120552
|
|
2007-01-05 Paul Thomas <pault@gcc.gnu.org>
PR fortran/23232
* decl.c (gfc_in_match_data, gfc_set_in_match_data): New
functions to signal that a DATA statement is being matched.
(gfc_match_data): Call gfc_set_in_match_data on entry and on
exit.
* gfortran.h : Add prototypes for above.
* expr.c (check_init_expr): Avoid check on parameter or
variable if gfc_in_match_data is true.
(gfc_match_init_expr): Do not call error on non-reduction of
expression if gfc_in_match_data is true.
PR fortran/27996
PR fortran/27998
* decl.c (gfc_set_constant_character_len): Add boolean arg to
flag array constructor resolution. Warn if string is being
truncated. Standard dependent error if string is padded. Set
new arg to false for all three calls to
gfc_set_constant_character_len.
* match.h : Add boolean arg to prototype for
gfc_set_constant_character_len.
* gfortran.h : Add warn_character_truncation to gfc_options.
* options.c (set_Wall): Set warn_character_truncation if -Wall
is set.
* resolve.c (resolve_code): Warn if rhs string in character
assignment has to be truncated.
* array.c (gfc_resolve_character_array_constructor): Set new
argument to true for call to gfc_set_constant_character_len.
2007-01-05 Paul Thomas <pault@gcc.gnu.org>
PR fortran/23232
* gfortran.dg/data_implied_do_1.f90: New test.
PR fortran/27996
PR fortran/27998
* gfortran.dg/char_length_1.f90: New test.
From-SVN: r120485
|
|
2006-12-20 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29992
* interface.c (check_sym_interfaces): Module procedures in a
generic must be use associated or contained in the module.
* decl.c (gfc_match_modproc): Set attribute mod_proc.
* gfortran.h (symbol_attribute): Add mod_proc atribute.
PR fortran/30081
* resolve.c (resolve_generic_f, resolve_generic_s): Use
gfc_intrinsic_name to find out if the function is intrinsic
because it does not have to be a generic intrinsic to be
overloaded.
2006-12-20 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29992
* gfortran.dg/generic_9.f90: New test.
PR fortran/30081
* gfortran.dg/generic_10.f90: New test.
From-SVN: r120072
|
|
fortran/
2006-12-10 Tobias Burnus <burnus@net-b.de>
PR fortran/23994
* interface.c (compare_actual_formal): PROTECTED is incompatible
with intent(out).
* symbol.c (check_conflict): Check for PROTECTED conflicts.
(gfc_add_protected): New function.
(gfc_copy_attr): Copy PROTECTED attribute.
* decl.c (match_attr_spec): Add PROTECTED support.
(gfc_match_protected): New function.
* dump-parse-tree.c (gfc_show_attr): Add PROTECTED support.
* gfortran.h (gfc_symbol): Add protected flag.
Add gfc_add_protected prototype.
* expr.c (gfc_check_pointer_assign): Add PROTECTED support.
* module.c (ab_attribute, attr_bits, mio_symbol_attribute,
mio_symbol_attribute):
Add PROTECTED support.
* resolve.c (resolve_equivalence): Add PROTECTED support.
* match.c (gfc_match_assignment,)gfc_match_pointer_assignment:
Check PROTECTED attribute.
* match.h: Add gfc_match_protected prototype.
* parse.c (decode_statement): Match PROTECTED statement.
* primary.c (match_variable): Add PROTECTED support.
testsuite/
2006-12-10 Tobias Burnus <burnus@net-b.de>
PR fortran/23994
* gfortran.dg/protected_1.f90: New test.
* gfortran.dg/protected_2.f90: New test.
* gfortran.dg/protected_3.f90: New test.
* gfortran.dg/protected_4.f90: New test.
* gfortran.dg/protected_5.f90: New test.
* gfortran.dg/protected_6.f90: New test.
From-SVN: r119709
|
|
by reference for actual arguments))
2006-12-03 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29642
* trans-expr.c (gfc_conv_variable): A character expression with
the VALUE attribute needs an address expression; otherwise all
other expressions with this attribute must not be dereferenced.
(gfc_conv_function_call): Pass expressions with the VALUE
attribute by value, using gfc_conv_expr.
* symbol.c (check_conflict): Add strings for INTENT OUT, INOUT
and VALUE. Apply all the constraints associated with the VALUE
attribute.
(gfc_add_value): New function.
(gfc_copy_attr): Call it for VALUE attribute.
* decl.c (match_attr_spec): Include the VALUE attribute.
(gfc_match_value): New function.
* dump-parse-tree.c (gfc_show_attr): Include VALUE.
* gfortran.h : Add value to the symbol_attribute structure and
add a prototype for gfc_add_value
* module.c (mio_internal_string): Include AB_VALUE in enum.
(attr_bits): Provide the VALUE string for it.
(mio_symbol_attribute): Read or apply the VLUE attribute.
* trans-types.c (gfc_sym_type): Variables with the VLAUE
attribute are not passed by reference!
* resolve.c (was_declared): Add value to those that return 1.
(resolve_symbol): Value attribute requires dummy attribute.
* match.h : Add prototype for gfc_match_public.
* parse.c (decode_statement): Try to match a VALUE statement.
2006-12-03 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29642
* gfortran.dg/value_1.f90 : New test.
* gfortran.dg/value_2.f90 : New test.
* gfortran.dg/value_3.f90 : New test.
* gfortran.dg/value_4.f90 : New test.
* gfortran.dg/value_4.c : Called from value_4.f90.
From-SVN: r119461
|
|
* data.c: Remove trailing periods from error messages.
* decl.c: Likewise.
* expr.c: Likewise.
* io.c: Likewise.
* match.c: Likewise.
* module.c: Likewise.
* options.c: Likewise.
* resolve.c: Likewise.
* symbol.c: Likewise.
* trans-io.c: Likewise.
From-SVN: r118880
|
|
fortran/
2006-11-15 Tobias Burnus <burnus@net-b.de>
PR fortran/27546
* decl.c (gfc_match_import,variable_decl):
Add IMPORT support.
(gfc_match_kind_spec): Fix typo in gfc_error.
* gfortran.h (gfc_namespace, gfc_statement):
Add IMPORT support.
* parse.c (decode_statement,gfc_ascii_statement,
verify_st_order): Add IMPORT support.
* match.h: Add gfc_match_import.
* gfortran.texi: Add IMPORT to the supported
Fortran 2003 features.
testsuite/
2006-11-15 Tobias Burnus <burnus@net-b.de>
PR fortran/27546
* gfortran.dg/import.f90: New test.
* gfortran.dg/import2.f90: New test.
* gfortran.dg/import3.f90: New test.
From-SVN: r118857
|
|
2006-11-09 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29699
* trans-array.c (structure_alloc_comps): Detect pointers to
arrays and use indirect reference to declaration.
* resolve.c (resolve_fl_variable): Tidy up condition.
(resolve_symbol): The same and only add initialization code if
the symbol is referenced.
* trans-decl.c (gfc_trans_deferred_vars): Call gfc_trans_
deferred_array before gfc_trans_auto_array_allocation.
PR fortran/21730
* symbol.c (check_done): Remove.
(gfc_add_attribute): Remove reference to check_done and remove
the argument attr_intent.
(gfc_add_allocatable, gfc_add_dimension, gfc_add_external,
gfc_add_intrinsic, gfc_add_optional, gfc_add_pointer,
gfc_add_cray_pointer, gfc_add_cray_pointee, gfc_add_result,
gfc_add_target, gfc_add_in_common, gfc_add_elemental,
gfc_add_pure, gfc_add_recursive, gfc_add_procedure,
gfc_add_type): Remove references to check_done.
* decl.c (attr_decl1): Eliminate third argument in call to
gfc_add_attribute.
* gfortran.h : Change prototype for gfc_add_attribute.
2006-11-09 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29699
* gfortran.dg/alloc_comp_auto_array_1.f90: New test.
PR fortran/21730
* gfortran.dg/change_symbol_attributes_1.f90: New test.
From-SVN: r118624
|