* [Bug fortran/17737] ICE in gfc_assign_data_value, at fortran/data.c:319
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
@ 2004-09-29 20:22 ` schnetter at aei dot mpg dot de
2004-09-30 15:08 ` [Bug fortran/17737] [4.0 regression] ICE when variable appears in two data statements reichelt at gcc dot gnu dot org
` (6 subsequent siblings)
7 siblings, 0 replies; 20+ messages in thread
From: schnetter at aei dot mpg dot de @ 2004-09-29 20:22 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From schnetter at aei dot mpg dot de 2004-09-29 20:22 -------
Created an attachment (id=7241)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=7241&action=view)
failing source code
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] [4.0 regression] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
2004-09-29 20:22 ` [Bug fortran/17737] " schnetter at aei dot mpg dot de
@ 2004-09-30 15:08 ` reichelt at gcc dot gnu dot org
2004-10-02 20:48 ` tobi at gcc dot gnu dot org
` (5 subsequent siblings)
7 siblings, 0 replies; 20+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2004-09-30 15:08 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From reichelt at gcc dot gnu dot org 2004-09-30 15:07 -------
Confirmed.
The problem is that the same variable appears in two data statements.
Just compile the following testcase without command-line parameters:
====================
integer i
data i/0/
data i/0/
end
====================
This works with the lno branch that was merged 20040718.
So I suppose this worked on mainline then, too.
It also worked with g77, so I'm rating this as a regression.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |reichelt at gcc dot gnu dot
| |org
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |ice-on-valid-code, monitored
Known to fail| |4.0.0
Known to work| |3.4.2
Last reconfirmed|0000-00-00 00:00:00 |2004-09-30 15:07:54
date| |
Summary|ICE in |[4.0 regression] ICE when
|gfc_assign_data_value, at |variable appears in two data
|fortran/data.c:319 |statements
Target Milestone|--- |4.0.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] [4.0 regression] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
2004-09-29 20:22 ` [Bug fortran/17737] " schnetter at aei dot mpg dot de
2004-09-30 15:08 ` [Bug fortran/17737] [4.0 regression] ICE when variable appears in two data statements reichelt at gcc dot gnu dot org
@ 2004-10-02 20:48 ` tobi at gcc dot gnu dot org
2004-10-02 20:48 ` tobi at gcc dot gnu dot org
` (4 subsequent siblings)
7 siblings, 0 replies; 20+ messages in thread
From: tobi at gcc dot gnu dot org @ 2004-10-02 20:48 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From tobi at gcc dot gnu dot org 2004-10-02 20:48 -------
This is invalid code. See page 49 of the draft standard. A variable shall not
have more than one explicit initialization. DATA statements count as explicit
initialization.
--
What |Removed |Added
----------------------------------------------------------------------------
Keywords|ice-on-valid-code |ice-on-invalid-code
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] [4.0 regression] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
` (2 preceding siblings ...)
2004-10-02 20:48 ` tobi at gcc dot gnu dot org
@ 2004-10-02 20:48 ` tobi at gcc dot gnu dot org
2004-11-11 15:34 ` [Bug fortran/17737] " pinskia at gcc dot gnu dot org
` (3 subsequent siblings)
7 siblings, 0 replies; 20+ messages in thread
From: tobi at gcc dot gnu dot org @ 2004-10-02 20:48 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From tobi at gcc dot gnu dot org 2004-10-02 20:48 -------
(In reply to comment #3)
> This is invalid code. See page 49 of the draft standard.
The draft fortran 95 standard.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
` (3 preceding siblings ...)
2004-10-02 20:48 ` tobi at gcc dot gnu dot org
@ 2004-11-11 15:34 ` pinskia at gcc dot gnu dot org
2005-01-06 14:41 ` tobi at gcc dot gnu dot org
` (2 subsequent siblings)
7 siblings, 0 replies; 20+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-11-11 15:34 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Summary|[4.0 regression] ICE when |ICE when variable appears in
|variable appears in two data|two data statements
|statements |
Target Milestone|4.0.0 |---
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
` (4 preceding siblings ...)
2004-11-11 15:34 ` [Bug fortran/17737] " pinskia at gcc dot gnu dot org
@ 2005-01-06 14:41 ` tobi at gcc dot gnu dot org
2005-09-14 19:30 ` pinskia at gcc dot gnu dot org
2005-09-28 16:32 ` segalemb at usp dot br
7 siblings, 0 replies; 20+ messages in thread
From: tobi at gcc dot gnu dot org @ 2005-01-06 14:41 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
OtherBugsDependingO| |19292
nThis| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
` (5 preceding siblings ...)
2005-01-06 14:41 ` tobi at gcc dot gnu dot org
@ 2005-09-14 19:30 ` pinskia at gcc dot gnu dot org
2005-09-28 16:32 ` segalemb at usp dot br
7 siblings, 0 replies; 20+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-09-14 19:30 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-09-14 19:29 -------
*** Bug 23884 has been marked as a duplicate of this bug. ***
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |segalemb at usp dot br
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
2004-09-29 20:21 [Bug fortran/17737] New: ICE in gfc_assign_data_value, at fortran/data.c:319 schnetter at aei dot mpg dot de
` (6 preceding siblings ...)
2005-09-14 19:30 ` pinskia at gcc dot gnu dot org
@ 2005-09-28 16:32 ` segalemb at usp dot br
7 siblings, 0 replies; 20+ messages in thread
From: segalemb at usp dot br @ 2005-09-28 16:32 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From segalemb at usp dot br 2005-09-28 16:32 -------
(In reply to comment #5)
> *** Bug 23884 has been marked as a duplicate of this bug. ***
Bug 23884 is not a duplicate of this bug, because there is no repeated
data statements in module.F
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
@ 2005-10-23 21:16 ` steven at gcc dot gnu dot org
2005-10-23 21:35 ` schnetter at aei dot mpg dot de
` (9 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: steven at gcc dot gnu dot org @ 2005-10-23 21:16 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from steven at gcc dot gnu dot org 2005-10-23 21:16 -------
This doesn't ICE for me.
So this should be "accepts-invalid" now, or we could call it a GNU extension
and only disallow it in stricter standard enforcement modes. Or we could just
close it.
Erik, your bug, so your call. ;-)
--
steven at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |steven at gcc dot gnu dot
| |org
Status|NEW |WAITING
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
2005-10-23 21:16 ` steven at gcc dot gnu dot org
@ 2005-10-23 21:35 ` schnetter at aei dot mpg dot de
2005-10-23 21:37 ` steven at gcc dot gnu dot org
` (8 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: schnetter at aei dot mpg dot de @ 2005-10-23 21:35 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from schnetter at aei dot mpg dot de 2005-10-23 21:35 -------
I don't see the point of allowing a variable to be initialised twice. This
should be an error, or at least a warning by default. That would make it an
"accepts-invalid".
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
2005-10-23 21:16 ` steven at gcc dot gnu dot org
2005-10-23 21:35 ` schnetter at aei dot mpg dot de
@ 2005-10-23 21:37 ` steven at gcc dot gnu dot org
2005-10-27 11:18 ` rguenth at gcc dot gnu dot org
` (7 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: steven at gcc dot gnu dot org @ 2005-10-23 21:37 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from steven at gcc dot gnu dot org 2005-10-23 21:37 -------
Alright, accepts-invalid it is for GCC 4.1.
--
steven at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |NEW
Keywords|ice-on-invalid-code |accepts-invalid
Known to fail|4.0.0 |4.0.0 4.1.0
Last reconfirmed|2005-09-04 18:20:26 |2005-10-23 21:37:44
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2005-10-23 21:37 ` steven at gcc dot gnu dot org
@ 2005-10-27 11:18 ` rguenth at gcc dot gnu dot org
2005-11-06 20:05 ` pault at gcc dot gnu dot org
` (6 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2005-10-27 11:18 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from rguenth at gcc dot gnu dot org 2005-10-27 11:18 -------
*** Bug 24554 has been marked as a duplicate of this bug. ***
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mabdallah at unido-ichet dot
| |org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2005-10-27 11:18 ` rguenth at gcc dot gnu dot org
@ 2005-11-06 20:05 ` pault at gcc dot gnu dot org
2005-11-06 22:50 ` pault at gcc dot gnu dot org
` (5 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-11-06 20:05 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from pault at gcc dot gnu dot org 2005-11-06 20:05 -------
Subject: Bug 17737
Author: pault
Date: Sun Nov 6 20:05:12 2005
New Revision: 106567
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=106567
Log:
2005-11-06 Paul Thomas <pault@gcc.gnu.org>
PR fortran/24534
* resolve.c (resolve_symbol): Exclude case of PRIVATE declared
within derived type from error associated with PRIVATE type
components within derived type.
PR fortran/20838
PR fortran/20840
* gfortran.h: Add prototype for gfc_has_vector_index.
* io.c (gfc_resolve_dt): Error if internal unit has a vector index.
* expr.c (gfc_has_vector_index): New function to check if any of
the array references of an expression have vector inidices.
(gfc_check_pointer_assign): Error if internal unit has a vector index.
PR fortran/17737
* data.c (gfc_assign_data_value): Remove gcc_assert that caused the ICE
and replace by a standard dependent warning/error if overwriting an
existing initialization.
* decl.c (gfc_data_variable): Remove old error for already initialized
variable and the unused error check for common block variables. Add
error for hots associated variable and standard dependent error for
common block variables, outside of blockdata.
* symbol.c (check_conflict): Add constraints for DATA statement.
2005-11-06 Paul Thomas <pault@gcc.gnu.org>
PR fortran/24534
gfortran.dg/private_type_2.f90: Modified to check that case with
PRIVATE declaration within derived type is accepted.
PR fortran/20838
gfortran.dg/pointer_assign_1.f90: New test.
PR fortran/20840
* gfortran.dg/arrayio_0.f90: New test.
PR fortran/17737
gfortran.dg/data_initialized.f90: New test.
gfortran.dg/data_constraints_1.f90: New test.
gfortran.dg/data_constraints_2.f90: New test.
Added:
trunk/gcc/testsuite/gfortran.dg/arrayio_0.f90 (with props)
trunk/gcc/testsuite/gfortran.dg/data_constraints_1.f90
trunk/gcc/testsuite/gfortran.dg/data_constraints_2.f90
trunk/gcc/testsuite/gfortran.dg/data_initialized.f90
trunk/gcc/testsuite/gfortran.dg/pointer_assign_1.f90 (with props)
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/data.c
trunk/gcc/fortran/decl.c
trunk/gcc/fortran/expr.c
trunk/gcc/fortran/gfortran.h
trunk/gcc/fortran/io.c
trunk/gcc/fortran/resolve.c
trunk/gcc/fortran/symbol.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gfortran.dg/private_type_2.f90
Added: trunk/gcc/testsuite/gfortran.dg/arrayio_0.f90
URL:
http://gcc.gnu.org/viewcvs/trunk/gcc/testsuite/gfortran.dg/arrayio_0.f90?root=gcc&view=auto&rev=106567
==============================================================================
--- trunk/gcc/testsuite/gfortran.dg/arrayio_0.f90 (added)
+++ trunk/gcc/testsuite/gfortran.dg/arrayio_0.f90 Sun Nov 6 20:05:12 2005
@@ -1,0 +1,19 @@
+! { dg-do compile }
+! Tests fix for PR20840 - would ICE with vector subscript in
+! internal unit.
+!
+! Contributed by Paul Thomas <pault@gcc.gnu.org>
+!
+ character(len=12), dimension(4) :: iu, buff
+ character(len=48), dimension(2) :: iue
+ equivalence (iu, iue)
+ integer, dimension(4) :: v = (/2,1,4,3/)
+ iu = (/"Vector","subscripts","not","allowed!"/)
+ read (iu, '(a12/)') buff
+ read (iue(1), '(4a12)') buff
+ read (iu(4:1:-1), '(a12/)') buff
+ read (iu(v), '(a12/)') buff ! { dg-error "with vector subscript" }
+ read (iu((/2,4,3,1/)), '(a12/)') buff ! { dg-error "with vector subscript" }
+ print *, buff
+ end
+
Propchange: trunk/gcc/testsuite/gfortran.dg/arrayio_0.f90
('svn:executable' added)
Added: trunk/gcc/testsuite/gfortran.dg/pointer_assign_1.f90
URL:
http://gcc.gnu.org/viewcvs/trunk/gcc/testsuite/gfortran.dg/pointer_assign_1.f90?root=gcc&view=auto&rev=106567
==============================================================================
--- trunk/gcc/testsuite/gfortran.dg/pointer_assign_1.f90 (added)
+++ trunk/gcc/testsuite/gfortran.dg/pointer_assign_1.f90 Sun Nov 6 20:05:12
2005
@@ -1,0 +1,17 @@
+! { dg-do compile }
+! Tests fix for PR20838 - would ICE with vector subscript in
+! pointer assignment.
+!
+! Contributed by Paul Thomas <pault@gcc.gnu.org>
+!
+ integer, parameter, dimension(3) :: i = (/2,1,3/)
+ integer, dimension(3), target :: tar
+ integer, dimension(2, 3), target :: tar2
+ integer, dimension(:), pointer :: ptr
+ ptr => tar
+ ptr => tar(3:1:-1)
+ ptr => tar(i) ! { dg-error "with vector subscript" }
+ ptr => tar2(1, :)
+ ptr => tar2(2, i) ! { dg-error "with vector subscript" }
+ end
+
Propchange: trunk/gcc/testsuite/gfortran.dg/pointer_assign_1.f90
('svn:executable' added)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2005-11-06 20:05 ` pault at gcc dot gnu dot org
@ 2005-11-06 22:50 ` pault at gcc dot gnu dot org
2005-11-06 22:55 ` pault at gcc dot gnu dot org
` (4 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-11-06 22:50 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from pault at gcc dot gnu dot org 2005-11-06 22:50 -------
Subject: Bug 17737
Author: pault
Date: Sun Nov 6 22:50:38 2005
New Revision: 106572
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=106572
Log:
2005-11-06 Paul Thomas <pault@gcc.gnu.org>
PR fortran/24534
* resolve.c (resolve_symbol): Exclude case of PRIVATE declared
within derived type from error associated with PRIVATE type
components within derived type.
PR fortran/20838
PR fortran/20840
* gfortran.h: Add prototype for gfc_has_vector_index.
* io.c (gfc_resolve_dt): Error if internal unit has a vector index.
* expr.c (gfc_has_vector_index): New function to check if any of
the array references of an expression have vector inidices.
(gfc_check_pointer_assign): Error if internal unit has a vector index.
PR fortran/17737
* data.c (gfc_assign_data_value): Remove gcc_assert that caused the ICE
and replace by a standard dependent warning/error if overwriting an
existing initialization.
* decl.c (gfc_data_variable): Remove old error for already initialized
variable and the unused error check for common block variables. Add
error for host associated variable and standard dependent error for
common block variables, outside of blockdata.
* symbol.c (check_conflict): Add constraints for DATA statement.
2005-11-06 Paul Thomas <pault@gcc.gnu.org>
PR fortran/24534
gfortran.dg/private_type_2.f90: Modified to check that case with
PRIVATE declaration within derived type is accepted.
PR fortran/20838
gfortran.dg/pointer_assign_1.f90: New test.
PR fortran/20840
* gfortran.dg/arrayio_0.f90: New test.
PR fortran/17737
gfortran.dg/data_initialized.f90: New test.
gfortran.dg/data_constraints_1.f90: New test.
gfortran.dg/data_constraints_2.f90: New test.
Added:
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/arrayio_0.f90 (with
props)
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/data_constraints_1.f90
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/data_constraints_2.f90
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/data_initialized.f90
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/pointer_assign_1.f90
(with props)
Modified:
branches/gcc-4_0-branch/gcc/fortran/ChangeLog
branches/gcc-4_0-branch/gcc/fortran/data.c
branches/gcc-4_0-branch/gcc/fortran/decl.c
branches/gcc-4_0-branch/gcc/fortran/expr.c
branches/gcc-4_0-branch/gcc/fortran/gfortran.h
branches/gcc-4_0-branch/gcc/fortran/io.c
branches/gcc-4_0-branch/gcc/fortran/resolve.c
branches/gcc-4_0-branch/gcc/fortran/symbol.c
branches/gcc-4_0-branch/gcc/testsuite/ChangeLog
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/private_type_2.f90
Added: branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/arrayio_0.f90
URL:
http://gcc.gnu.org/viewcvs/branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/arrayio_0.f90?root=gcc&view=auto&rev=106572
==============================================================================
--- branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/arrayio_0.f90 (added)
+++ branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/arrayio_0.f90 Sun Nov 6
22:50:38 2005
@@ -1,0 +1,19 @@
+! { dg-do compile }
+! Tests fix for PR20840 - would ICE with vector subscript in
+! internal unit.
+!
+! Contributed by Paul Thomas <pault@gcc.gnu.org>
+!
+ character(len=12), dimension(4) :: iu, buff
+ character(len=48), dimension(2) :: iue
+ equivalence (iu, iue)
+ integer, dimension(4) :: v = (/2,1,4,3/)
+ iu = (/"Vector","subscripts","not","allowed!"/)
+ read (iu, '(a12/)') buff
+ read (iue(1), '(4a12)') buff
+ read (iu(4:1:-1), '(a12/)') buff
+ read (iu(v), '(a12/)') buff ! { dg-error "with vector subscript" }
+ read (iu((/2,4,3,1/)), '(a12/)') buff ! { dg-error "with vector subscript" }
+ print *, buff
+ end
+
Propchange: branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/arrayio_0.f90
('svn:executable' added)
Added: branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/pointer_assign_1.f90
URL:
http://gcc.gnu.org/viewcvs/branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/pointer_assign_1.f90?root=gcc&view=auto&rev=106572
==============================================================================
--- branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/pointer_assign_1.f90
(added)
+++ branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/pointer_assign_1.f90 Sun
Nov 6 22:50:38 2005
@@ -1,0 +1,17 @@
+! { dg-do compile }
+! Tests fix for PR20838 - would ICE with vector subscript in
+! pointer assignment.
+!
+! Contributed by Paul Thomas <pault@gcc.gnu.org>
+!
+ integer, parameter, dimension(3) :: i = (/2,1,3/)
+ integer, dimension(3), target :: tar
+ integer, dimension(2, 3), target :: tar2
+ integer, dimension(:), pointer :: ptr
+ ptr => tar
+ ptr => tar(3:1:-1)
+ ptr => tar(i) ! { dg-error "with vector subscript" }
+ ptr => tar2(1, :)
+ ptr => tar2(2, i) ! { dg-error "with vector subscript" }
+ end
+
Propchange:
branches/gcc-4_0-branch/gcc/testsuite/gfortran.dg/pointer_assign_1.f90
('svn:executable' added)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2005-11-06 22:50 ` pault at gcc dot gnu dot org
@ 2005-11-06 22:55 ` pault at gcc dot gnu dot org
2005-11-10 2:46 ` pinskia at gcc dot gnu dot org
` (3 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-11-06 22:55 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from pault at gcc dot gnu dot org 2005-11-06 22:55 -------
Fixed on mainline and 4.0
--
pault at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2005-11-06 22:55 ` pault at gcc dot gnu dot org
@ 2005-11-10 2:46 ` pinskia at gcc dot gnu dot org
2005-12-08 17:49 ` pinskia at gcc dot gnu dot org
` (2 subsequent siblings)
10 siblings, 0 replies; 20+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-11-10 2:46 UTC (permalink / raw)
To: gcc-bugs
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.0.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (7 preceding siblings ...)
2005-11-10 2:46 ` pinskia at gcc dot gnu dot org
@ 2005-12-08 17:49 ` pinskia at gcc dot gnu dot org
2005-12-08 18:10 ` segalemb at usp dot br
2005-12-08 18:14 ` pinskia at gcc dot gnu dot org
10 siblings, 0 replies; 20+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-12-08 17:49 UTC (permalink / raw)
To: gcc-bugs
------- Comment #14 from pinskia at gcc dot gnu dot org 2005-12-08 17:49 -------
*** Bug 25312 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (8 preceding siblings ...)
2005-12-08 17:49 ` pinskia at gcc dot gnu dot org
@ 2005-12-08 18:10 ` segalemb at usp dot br
2005-12-08 18:14 ` pinskia at gcc dot gnu dot org
10 siblings, 0 replies; 20+ messages in thread
From: segalemb at usp dot br @ 2005-12-08 18:10 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from segalemb at usp dot br 2005-12-08 18:10 -------
Subject: Re: ICE when variable appears in two data statements
This is not a duplicated bug, because I recently installed the
last version of gcc and recompiled the operational system.
Why is this problem not solved?
Best regards,
Sergio
Citando pinskia at gcc dot gnu dot org <gcc-bugzilla@gcc.gnu.org>:
>
>
> ------- Comment #14 from pinskia at gcc dot gnu dot org 2005-12-08 17:49
> -------
> *** Bug 25312 has been marked as a duplicate of this bug. ***
>
>
> --
>
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
>
> ------- You are receiving this mail because: -------
> You are on the CC list for the bug, or are watching someone who is.
>
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread
* [Bug fortran/17737] ICE when variable appears in two data statements
[not found] <bug-17737-7427@http.gcc.gnu.org/bugzilla/>
` (9 preceding siblings ...)
2005-12-08 18:10 ` segalemb at usp dot br
@ 2005-12-08 18:14 ` pinskia at gcc dot gnu dot org
10 siblings, 0 replies; 20+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-12-08 18:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #16 from pinskia at gcc dot gnu dot org 2005-12-08 18:14 -------
(In reply to comment #15)
> Subject: Re: ICE when variable appears in two data statements
> This is not a duplicated bug, because I recently installed the
> last version of gcc and recompiled the operational system.
> Why is this problem not solved?
4.0.3 has not been released yet. It has been fixed for 4.0.3 and 4.1.0 both of
which are currently CVS/SVN versions only with a snapshot provided for both of
them.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17737
^ permalink raw reply [flat|nested] 20+ messages in thread