This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/17941] gfortran: parser chokes on complex literal constant
- From: "tobi at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 11 Oct 2004 22:48:44 -0000
- Subject: [Bug fortran/17941] gfortran: parser chokes on complex literal constant
- References: <20041011203308.17941.anlauf@hep.tu-darmstadt.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From tobi at gcc dot gnu dot org 2004-10-11 22:48 -------
I'm not sure if this suffices, will try tomorrow:
Index: primary.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/fortran/primary.c,v
retrieving revision 1.13
diff -u -p -r1.13 primary.c
--- primary.c 7 Oct 2004 15:12:01 -0000 1.13
+++ primary.c 11 Oct 2004 22:46:36 -0000
@@ -1028,6 +1028,13 @@ match_const_complex_part (gfc_expr ** re
for (;; c = gfc_next_char (), count++)
{
+ if (c == ' ')
+ {
+ if (seen_dp || seen_digits)
+ break;
+ continue;
+ }
+
if (c == '.')
{
if (seen_dp)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17941