* lex.c (java_read_char): Check for EOF from getc first.
authorRichard Earnshaw <rearnsha@arm.com>
Thu, 25 Jan 2001 10:35:09 +0000 (10:35 +0000)
committerRichard Earnshaw <rearnsha@gcc.gnu.org>
Thu, 25 Jan 2001 10:35:09 +0000 (10:35 +0000)
From-SVN: r39261

gcc/java/ChangeLog
gcc/java/lex.c

index c610918465c2a36d713902aa41244da52ba1ffee..cbe63223b3599ac5858836636222c801474a8734 100644 (file)
@@ -1,3 +1,7 @@
+2001-01-25  Richard Earnshaw  <rearnsha@arm.com>
+
+       * lex.c (java_read_char): Check for EOF from getc first.
+
 2001-01-23  Alexandre Petit-Bianco  <apbianco@cygnus.com>
 
        * class.c (layout_class): Don't lay the superclass out if it's
index 32c104e770cb38c5378b4533768980f2db06c91c..fdfb0a7705d5b28aeedb1e09783e1a9d709efe5b 100644 (file)
@@ -447,10 +447,10 @@ java_read_char (lex)
       int c, c1, c2;
       c = getc (lex->finput);
 
-      if (c < 128)
-       return (unicode_t)c;
       if (c == EOF)
        return UEOF;
+      if (c < 128)
+       return (unicode_t)c;
       else
        {
          if ((c & 0xe0) == 0xc0)