diff options
author | Janus Weil <janus@gcc.gnu.org> | 2010-12-17 13:31:54 +0100 |
---|---|---|
committer | Janus Weil <janus@gcc.gnu.org> | 2010-12-17 13:31:54 +0100 |
commit | 7ca17033382c71cbfe6cd24da017c2c333b114af (patch) | |
tree | 30a6e0f0a3a917b592de55c9931bebb93e7e552f /gcc/fortran/resolve.c | |
parent | eab89c86a2e7366d3437107f6568ff41d98b0453 (diff) | |
download | gcc-7ca17033382c71cbfe6cd24da017c2c333b114af.zip gcc-7ca17033382c71cbfe6cd24da017c2c333b114af.tar.gz gcc-7ca17033382c71cbfe6cd24da017c2c333b114af.tar.bz2 |
re PR fortran/46849 ([OOP] MODULE PROCEDURE resolution does not work in BLOCK or SELECT TYPE)
2010-12-17 Janus Weil <janus@gcc.gnu.org>
Tobias Burnus <burnus@gcc.gnu.org>
PR fortran/46849
* resolve.c (resolve_symbol): Remove symbols that wrongly ended up
in a local BLOCK namespace.
2010-12-17 Janus Weil <janus@gcc.gnu.org>
PR fortran/46849
* gfortran.dg/block_9.f08: New.
Co-Authored-By: Tobias Burnus <burnus@gcc.gnu.org>
From-SVN: r167978
Diffstat (limited to 'gcc/fortran/resolve.c')
-rw-r--r-- | gcc/fortran/resolve.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/fortran/resolve.c b/gcc/fortran/resolve.c index a27fe2d..7081146 100644 --- a/gcc/fortran/resolve.c +++ b/gcc/fortran/resolve.c @@ -11784,7 +11784,9 @@ resolve_symbol (gfc_symbol *sym) for (ns = gfc_current_ns->parent; ns; ns = ns->parent) { symtree = gfc_find_symtree (ns->sym_root, sym->name); - if (symtree && symtree->n.sym->generic) + if (symtree && (symtree->n.sym->generic || + (symtree->n.sym->attr.flavor == FL_PROCEDURE + && sym->ns->construct_entities))) { this_symtree = gfc_find_symtree (gfc_current_ns->sym_root, sym->name); |