* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
@ 2022-09-21 17:32 ` gscfq@t-online.de
2022-09-22 6:48 ` rguenth at gcc dot gnu.org
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: gscfq@t-online.de @ 2022-09-21 17:32 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
--- Comment #1 from G. Steinmetz <gscfq@t-online.de> ---
FYI, a directly matching variant compiles :
$ cat z2.f90
program p
type t
procedure(g), pointer :: f
end type
class(t), allocatable :: z
call s(z%f)
contains
subroutine g(x)
class(t) :: x
end
subroutine s(x)
procedure(g) :: x
end
end
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
2022-09-21 17:32 ` [Bug fortran/106999] " gscfq@t-online.de
@ 2022-09-22 6:48 ` rguenth at gcc dot gnu.org
2022-09-22 19:22 ` marxin at gcc dot gnu.org
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-09-22 6:48 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P4
Target Milestone|--- |11.4
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
2022-09-21 17:32 ` [Bug fortran/106999] " gscfq@t-online.de
2022-09-22 6:48 ` rguenth at gcc dot gnu.org
@ 2022-09-22 19:22 ` marxin at gcc dot gnu.org
2023-04-17 19:42 ` [Bug fortran/106999] [11/12/13/14 " anlauf at gcc dot gnu.org
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: marxin at gcc dot gnu.org @ 2022-09-22 19:22 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
Martin Liška <marxin at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |marxin at gcc dot gnu.org
--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> ---
Also GCC 4.8 ICEs.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13/14 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (2 preceding siblings ...)
2022-09-22 19:22 ` marxin at gcc dot gnu.org
@ 2023-04-17 19:42 ` anlauf at gcc dot gnu.org
2023-05-29 10:07 ` jakub at gcc dot gnu.org
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: anlauf at gcc dot gnu.org @ 2023-04-17 19:42 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
anlauf at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever confirmed|0 |1
Last reconfirmed| |2023-04-17
--- Comment #3 from anlauf at gcc dot gnu.org ---
FWIW, it is -fcheck=pointer triggering the ICE.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13/14 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (3 preceding siblings ...)
2023-04-17 19:42 ` [Bug fortran/106999] [11/12/13/14 " anlauf at gcc dot gnu.org
@ 2023-05-29 10:07 ` jakub at gcc dot gnu.org
2024-03-31 12:16 ` pault at gcc dot gnu.org
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: jakub at gcc dot gnu.org @ 2023-05-29 10:07 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|11.4 |11.5
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
GCC 11.4 is being released, retargeting bugs to GCC 11.5.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13/14 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (4 preceding siblings ...)
2023-05-29 10:07 ` jakub at gcc dot gnu.org
@ 2024-03-31 12:16 ` pault at gcc dot gnu.org
2024-04-02 14:53 ` cvs-commit at gcc dot gnu.org
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu.org @ 2024-03-31 12:16 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
Paul Thomas <pault at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |pault at gcc dot gnu.org
Assignee|unassigned at gcc dot gnu.org |pault at gcc dot gnu.org
--- Comment #5 from Paul Thomas <pault at gcc dot gnu.org> ---
Created attachment 57838
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=57838&action=edit
Fix for this PR
Thanks for the report. The attached does what is required, I believe. It is
regtesting as I write.
Paul
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13/14 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (5 preceding siblings ...)
2024-03-31 12:16 ` pault at gcc dot gnu.org
@ 2024-04-02 14:53 ` cvs-commit at gcc dot gnu.org
2024-04-23 9:49 ` [Bug fortran/106999] [11/12/13 " pault at gcc dot gnu.org
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-04-02 14:53 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Paul Thomas <pault@gcc.gnu.org>:
https://gcc.gnu.org/g:a7aa9455a8b9cb080649a7357b7360f2d99bcbf1
commit r14-9753-ga7aa9455a8b9cb080649a7357b7360f2d99bcbf1
Author: Paul Thomas <pault@gcc.gnu.org>
Date: Tue Apr 2 15:53:29 2024 +0100
Fortran: Add error for subroutine passed to a variable dummy [PR106999]
2024-04-02 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran
PR fortran/106999
* interface.cc (gfc_compare_interfaces): Add error for a
subroutine proc pointer passed to a variable formal.
(compare_parameter): If a procedure pointer is being passed to
a non-procedure formal arg, and there is an an interface, use
gfc_compare_interfaces to check and provide a more useful error
message.
gcc/testsuite/
PR fortran/106999
* gfortran.dg/pr106999.f90: New test.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (6 preceding siblings ...)
2024-04-02 14:53 ` cvs-commit at gcc dot gnu.org
@ 2024-04-23 9:49 ` pault at gcc dot gnu.org
2024-05-06 9:57 ` cvs-commit at gcc dot gnu.org
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu.org @ 2024-04-23 9:49 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
Paul Thomas <pault at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|[11/12/13/14 Regression] |[11/12/13 Regression] ICE
|ICE tree check: expected |tree check: expected
|record_type or union_type |record_type or union_type
|or qual_union_type, have |or qual_union_type, have
|function_type in |function_type in
|gfc_class_data_get, at |gfc_class_data_get, at
|fortran/trans-expr.cc:233 |fortran/trans-expr.cc:233
--- Comment #7 from Paul Thomas <pault at gcc dot gnu.org> ---
Needs backporting. Changed summary.
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (7 preceding siblings ...)
2024-04-23 9:49 ` [Bug fortran/106999] [11/12/13 " pault at gcc dot gnu.org
@ 2024-05-06 9:57 ` cvs-commit at gcc dot gnu.org
2024-05-06 10:01 ` cvs-commit at gcc dot gnu.org
2024-05-06 10:03 ` pault at gcc dot gnu.org
10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-05-06 9:57 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
--- Comment #8 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-13 branch has been updated by Paul Thomas <pault@gcc.gnu.org>:
https://gcc.gnu.org/g:429935510202c4efee933bf907fd9dff816193f2
commit r13-8692-g429935510202c4efee933bf907fd9dff816193f2
Author: Paul Thomas <pault@gcc.gnu.org>
Date: Tue Apr 2 15:53:29 2024 +0100
Fortran: Add error for subroutine passed to a variable dummy [PR106999]
2024-04-02 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran
PR fortran/106999
* interface.cc (gfc_compare_interfaces): Add error for a
subroutine proc pointer passed to a variable formal.
(compare_parameter): If a procedure pointer is being passed to
a non-procedure formal arg, and there is an an interface, use
gfc_compare_interfaces to check and provide a more useful error
message.
gcc/testsuite/
PR fortran/106999
* gfortran.dg/pr106999.f90: New test.
(cherry picked from commit a7aa9455a8b9cb080649a7357b7360f2d99bcbf1)
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (8 preceding siblings ...)
2024-05-06 9:57 ` cvs-commit at gcc dot gnu.org
@ 2024-05-06 10:01 ` cvs-commit at gcc dot gnu.org
2024-05-06 10:03 ` pault at gcc dot gnu.org
10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2024-05-06 10:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
--- Comment #9 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Paul Thomas <pault@gcc.gnu.org>:
https://gcc.gnu.org/g:d72e9f90e370538b057690b16c1e65350dbbb75c
commit r12-10416-gd72e9f90e370538b057690b16c1e65350dbbb75c
Author: Paul Thomas <pault@gcc.gnu.org>
Date: Tue Apr 2 15:53:29 2024 +0100
Fortran: Add error for subroutine passed to a variable dummy [PR106999]
2024-04-02 Paul Thomas <pault@gcc.gnu.org>
gcc/fortran
PR fortran/106999
* interface.cc (gfc_compare_interfaces): Add error for a
subroutine proc pointer passed to a variable formal.
(compare_parameter): If a procedure pointer is being passed to
a non-procedure formal arg, and there is an an interface, use
gfc_compare_interfaces to check and provide a more useful error
message.
gcc/testsuite/
PR fortran/106999
* gfortran.dg/pr106999.f90: New test.
(cherry picked from commit a7aa9455a8b9cb080649a7357b7360f2d99bcbf1)
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug fortran/106999] [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233
2022-09-21 17:32 [Bug fortran/106999] New: [11/12/13 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233 gscfq@t-online.de
` (9 preceding siblings ...)
2024-05-06 10:01 ` cvs-commit at gcc dot gnu.org
@ 2024-05-06 10:03 ` pault at gcc dot gnu.org
10 siblings, 0 replies; 12+ messages in thread
From: pault at gcc dot gnu.org @ 2024-05-06 10:03 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106999
Paul Thomas <pault at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|NEW |RESOLVED
--- Comment #10 from Paul Thomas <pault at gcc dot gnu.org> ---
Fixed on 12-branch through to mainline. Thanks for the report.
Paul
^ permalink raw reply [flat|nested] 12+ messages in thread