public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/103779] New: ICE in gfc_convert_chartype, at fortran/intrinsic.c:5400
@ 2021-12-20 17:55 gscfq@t-online.de
  2021-12-22 23:24 ` [Bug fortran/103779] " kargl at gcc dot gnu.org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: gscfq@t-online.de @ 2021-12-20 17:55 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103779

            Bug ID: 103779
           Summary: ICE in gfc_convert_chartype, at
                    fortran/intrinsic.c:5400
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gscfq@t-online.de
  Target Milestone: ---

Affects versions down to at least r5 :
(gcc configured with --enable-checking=yes)


$ cat z1.f90
character(1,) function f()
   f = 'a'
end


$ cat z2.f90
character(1, kind=) function f()
   f = 'a'
end


$ cat z3.f90
character(1,n) function f()
   f = 'a'
end


$ gfortran-12-20211219 -c z1.f90
z1.f90:1:13:

    1 | character(1,) function f()
      |             1
Error: Expected initialization expression at (1)
z1.f90:1:0:

    1 | character(1,) function f()
      |
Error: Bad kind expression for function 'f' at (1)
f951: internal compiler error: in gfc_convert_chartype, at
fortran/intrinsic.c:5400
0x7fde0a gfc_convert_chartype(gfc_expr*, gfc_typespec*)
        ../../gcc/fortran/intrinsic.c:5400
0x84e195 resolve_ordinary_assign
        ../../gcc/fortran/resolve.c:11183
0x85648c gfc_resolve_code(gfc_code*, gfc_namespace*)
        ../../gcc/fortran/resolve.c:12042
0x8589e7 resolve_codes
        ../../gcc/fortran/resolve.c:17532
0x858aae gfc_resolve(gfc_namespace*)
        ../../gcc/fortran/resolve.c:17567
0x840dd4 resolve_all_program_units
        ../../gcc/fortran/parse.c:6586
0x840dd4 gfc_parse_file()
        ../../gcc/fortran/parse.c:6842
0x88efcf gfc_be_parse_file
        ../../gcc/fortran/f95-lang.c:216

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-02-09 20:30 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-20 17:55 [Bug fortran/103779] New: ICE in gfc_convert_chartype, at fortran/intrinsic.c:5400 gscfq@t-online.de
2021-12-22 23:24 ` [Bug fortran/103779] " kargl at gcc dot gnu.org
2021-12-22 23:25 ` kargl at gcc dot gnu.org
2023-02-09 19:59 ` anlauf at gcc dot gnu.org
2023-02-09 20:22 ` cvs-commit at gcc dot gnu.org
2023-02-09 20:30 ` anlauf at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).