nvptx mkoffload: Fix logic error in skipping of "strange" tokens.
authorThomas Schwinge <thomas@codesourcery.com>
Tue, 17 Feb 2015 18:13:32 +0000 (19:13 +0100)
committerThomas Schwinge <tschwinge@gcc.gnu.org>
Tue, 17 Feb 2015 18:13:32 +0000 (19:13 +0100)
gcc/
* config/nvptx/mkoffload.c (parse_file): Fix logic error in
skipping of "strange" tokens.

From-SVN: r220769

gcc/ChangeLog
gcc/config/nvptx/mkoffload.c

index dcd3d26157f652466296654d0ab846c44b285217..e52e7cf205463fd75bb1fd74c445ff8ec8876880 100644 (file)
@@ -1,3 +1,8 @@
+2015-02-17  Thomas Schwinge  <thomas@codesourcery.com>
+
+       * config/nvptx/mkoffload.c (parse_file): Fix logic error in
+       skipping of "strange" tokens.
+
 2015-02-17  Jeff Law  <law@redhat.com>
 
        * tree-vrp.c (identify_jump_threads): Use last_stmt.  Remove
index 739aee8af85a7a46a5343969e01ba88b4b6310b1..96341b8bc4dcd4438bc2be8a57182d3734179dea 100644 (file)
@@ -755,8 +755,9 @@ parse_file (Token *tok)
       if (comment)
        append_stmt (&fns, comment);
 
-      while (tok->kind && !tok->end)
+      do
        tok++;
+      while (tok->kind && !tok->end);
     }
   return tok;
 }