* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
@ 2012-09-16 15:53 ` mikael at gcc dot gnu.org
2012-09-17 12:08 ` burnus at gcc dot gnu.org
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: mikael at gcc dot gnu.org @ 2012-09-16 15:53 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
Mikael Morin <mikael at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mikael at gcc dot gnu.org
--- Comment #1 from Mikael Morin <mikael at gcc dot gnu.org> 2012-09-16 15:52:47 UTC ---
dependency.c:
1060 else
1061 {
1062 gfc_symbol *sym1 = expr1->symtree->n.sym;
1063 gfc_symbol *sym2 = expr2->symtree->n.sym;
//At (1): "!sym2->attr.dimension || sym2->as->type == 2" looks like the
original copy.
//CID 721803: Copy-paste error (COPY_PASTE_ERROR)At (2): "sym2" in
//"!sym1->attr.dimension || sym2->as->type == 2" looks like a copy-paste error.
//Should it say "sym1" instead?
1064 if (sym1->attr.target && sym2->attr.target
1065 && ((sym1->attr.dummy && !sym1->attr.contiguous
1066 && (!sym1->attr.dimension
1067 || sym2->as->type == AS_ASSUMED_SHAPE))
1068 || (sym2->attr.dummy && !sym2->attr.contiguous
1069 && (!sym2->attr.dimension
1070 || sym2->as->type == AS_ASSUMED_SHAPE))))
1071 return 1;
1072 }
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
2012-09-16 15:53 ` [Bug fortran/54599] " mikael at gcc dot gnu.org
@ 2012-09-17 12:08 ` burnus at gcc dot gnu.org
2012-09-18 9:29 ` burnus at gcc dot gnu.org
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: burnus at gcc dot gnu.org @ 2012-09-17 12:08 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
Tobias Burnus <burnus at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |burnus at gcc dot gnu.org
--- Comment #2 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-09-17 12:08:06 UTC ---
I forgot to put the PR in the ChangeLog, when I fixed some of the issues; see:
http://gcc.gnu.org/viewcvs?view=revision&revision=191381
Still to do
- dependency.c (both issues of comment 1 and the one of comment 2)
- interface.c: gfc_compare_derived_types
- openmp.c
- cpp.c
and possibly the two RFC for resolve.c and intrinsic.c
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
2012-09-16 15:53 ` [Bug fortran/54599] " mikael at gcc dot gnu.org
2012-09-17 12:08 ` burnus at gcc dot gnu.org
@ 2012-09-18 9:29 ` burnus at gcc dot gnu.org
2012-09-18 10:10 ` burnus at gcc dot gnu.org
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: burnus at gcc dot gnu.org @ 2012-09-18 9:29 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
--- Comment #3 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-09-18 09:28:46 UTC ---
Dump two patches here. First is about a pointless check ("nl->sym->..." is used
all over the place) and the second: If the assert fails, we would use
TREE_TYPE(NULL_TREE) ...
--- a/gcc/fortran/resolve.c
+++ b/gcc/fortran/resolve.c
@@ -12481 +12481 @@ resolve_fl_namelist (gfc_symbol *sym)
- if (nl->sym && nl->sym->name)
+ if (nl->sym->name)
--- a/gcc/fortran/trans-array.c
+++ b/gcc/fortran/trans-array.c
@@ -1024,4 +1024,4 @@ gfc_trans_create_temp_array (stmtblock_t * pre,
stmtblock_t * post, gfc_ss * ss,
{
- if (POINTER_TYPE_P (TREE_TYPE (initial)))
- class_expr = build_fold_indirect_ref_loc (input_location, initial);
+ gcc_assert (POINTER_TYPE_P (TREE_TYPE (initial)));
+ class_expr = build_fold_indirect_ref_loc (input_location, initial);
eltype = TREE_TYPE (class_expr);
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (2 preceding siblings ...)
2012-09-18 9:29 ` burnus at gcc dot gnu.org
@ 2012-09-18 10:10 ` burnus at gcc dot gnu.org
2012-09-20 20:50 ` burnus at gcc dot gnu.org
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: burnus at gcc dot gnu.org @ 2012-09-18 10:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
--- Comment #4 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-09-18 10:10:28 UTC ---
And another one: Unreachable code; due to "if(extremum == NULL) {...;
continue}", last == NULL is always false:
--- a/gcc/fortran/simplify.c
+++ b/gcc/fortran/simplify.c
@@ -4109,4 +4109 @@ simplify_min_max (gfc_expr *expr, int sign)
- if (last == NULL)
- expr->value.function.actual = arg->next;
- else
- last->next = arg->next;
+ last->next = arg->next;
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (3 preceding siblings ...)
2012-09-18 10:10 ` burnus at gcc dot gnu.org
@ 2012-09-20 20:50 ` burnus at gcc dot gnu.org
2012-09-22 10:34 ` tkoenig at gcc dot gnu.org
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: burnus at gcc dot gnu.org @ 2012-09-20 20:50 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
--- Comment #5 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-09-20 20:49:27 UTC ---
Author: burnus
Date: Thu Sep 20 20:49:20 2012
New Revision: 191590
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=191590
Log:
2012-09-20 Tobias Burnus <burnus@net-b.de>
PR fortran/54599
* cpp.c (print_line): Properly handle extern C.
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/cpp.c
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (4 preceding siblings ...)
2012-09-20 20:50 ` burnus at gcc dot gnu.org
@ 2012-09-22 10:34 ` tkoenig at gcc dot gnu.org
2012-09-22 10:35 ` tkoenig at gcc dot gnu.org
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: tkoenig at gcc dot gnu.org @ 2012-09-22 10:34 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
--- Comment #6 from Thomas Koenig <tkoenig at gcc dot gnu.org> 2012-09-22 10:32:58 UTC ---
Author: tkoenig
Date: Sat Sep 22 10:32:51 2012
New Revision: 191640
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=191640
Log:
2012-09-22 Thomas König <tkoenig@gcc.gnu.org>
PR fortran/54599
* dependency.c (gfc_dep_compare_expr): Clarify logic,
remove dead code.
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/dependency.c
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (5 preceding siblings ...)
2012-09-22 10:34 ` tkoenig at gcc dot gnu.org
@ 2012-09-22 10:35 ` tkoenig at gcc dot gnu.org
2012-09-22 21:48 ` dominiq at lps dot ens.fr
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: tkoenig at gcc dot gnu.org @ 2012-09-22 10:35 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
Thomas Koenig <tkoenig at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-09-22
Ever Confirmed|0 |1
--- Comment #7 from Thomas Koenig <tkoenig at gcc dot gnu.org> 2012-09-22 10:34:22 UTC ---
The dependency.c issue is fixed.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (6 preceding siblings ...)
2012-09-22 10:35 ` tkoenig at gcc dot gnu.org
@ 2012-09-22 21:48 ` dominiq at lps dot ens.fr
2012-09-23 6:49 ` burnus at gcc dot gnu.org
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: dominiq at lps dot ens.fr @ 2012-09-22 21:48 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
--- Comment #8 from Dominique d'Humieres <dominiq at lps dot ens.fr> 2012-09-22 21:48:01 UTC ---
> --------------------------------------------------------
> interface.c: gfc_compare_derived_types BUG
> --------------------------------------------------------
> Same line twice:
> 450 if ( !(dt1->ts.type == BT_DERIVED && derived1 == dt1->ts.u.derived)
> 451 && !(dt1->ts.type == BT_DERIVED && derived1 ==dt1->ts.u.derived)
This is pr46244.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (7 preceding siblings ...)
2012-09-22 21:48 ` dominiq at lps dot ens.fr
@ 2012-09-23 6:49 ` burnus at gcc dot gnu.org
2014-12-07 10:16 ` dominiq at lps dot ens.fr
2015-08-29 13:48 ` dominiq at lps dot ens.fr
10 siblings, 0 replies; 12+ messages in thread
From: burnus at gcc dot gnu.org @ 2012-09-23 6:49 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
--- Comment #9 from Tobias Burnus <burnus at gcc dot gnu.org> 2012-09-23 06:48:56 UTC ---
Author: burnus
Date: Sun Sep 23 06:48:48 2012
New Revision: 191649
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=191649
Log:
2012-09-23 Tobias Burnus <burnus@net-b.de>
* parse.c (parse_derived): Don't set attr.alloc_comp
for pointer components with allocatable subcomps.
PR fortran/54599
* resolve.c (resolve_fl_namelist): Remove superfluous
NULL check.
* simplify.c (simplify_min_max): Remove unreachable code.
* trans-array.c (gfc_trans_create_temp_array): Change
a condition into an assert.
PR fortran/54618
* trans-expr.c (gfc_trans_class_init_assign): Guard
re-setting of the _data by gfc_conv_expr_present.
(gfc_conv_procedure_call): Fix INTENT(OUT) handling
for allocatable BT_CLASS.
2012-09-23 Tobias Burnus <burnus@net-b.de>
PR fortran/54618
* gfortran.dg/class_array_14.f90: New.
Added:
trunk/gcc/testsuite/gfortran.dg/class_array_14.f90
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/parse.c
trunk/gcc/fortran/resolve.c
trunk/gcc/fortran/simplify.c
trunk/gcc/fortran/trans-array.c
trunk/gcc/fortran/trans-expr.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (8 preceding siblings ...)
2012-09-23 6:49 ` burnus at gcc dot gnu.org
@ 2014-12-07 10:16 ` dominiq at lps dot ens.fr
2015-08-29 13:48 ` dominiq at lps dot ens.fr
10 siblings, 0 replies; 12+ messages in thread
From: dominiq at lps dot ens.fr @ 2014-12-07 10:16 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
Dominique d'Humieres <dominiq at lps dot ens.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |WAITING
--- Comment #10 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
What is left of this PR besides pr46244? I think new PRs should be opened for
the remaining issues and this should be closed.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/54599] Issues found in gfortran by the Coverity Scan
2012-09-16 11:02 [Bug fortran/54599] New: Issues found in gfortran by the Coverity Scan burnus at gcc dot gnu.org
` (9 preceding siblings ...)
2014-12-07 10:16 ` dominiq at lps dot ens.fr
@ 2015-08-29 13:48 ` dominiq at lps dot ens.fr
10 siblings, 0 replies; 12+ messages in thread
From: dominiq at lps dot ens.fr @ 2015-08-29 13:48 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54599
Dominique d'Humieres <dominiq at lps dot ens.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |RESOLVED
Resolution|--- |FIXED
--- Comment #11 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
> What is left of this PR besides pr46244? I think new PRs should be opened
> for the remaining issues and this should be closed.
No answer for almost nine months. Closing as FIXED.
^ permalink raw reply [flat|nested] 12+ messages in thread