Browse Source

* don't eat char directly after a comment

git-svn-id: trunk@13811 -
florian 16 years ago
parent
commit
cbfcb00ded
2 changed files with 4 additions and 8 deletions
  1. 2 4
      utils/h2pas/scan.l
  2. 2 4
      utils/h2pas/scan.pas

+ 2 - 4
utils/h2pas/scan.l

@@ -503,11 +503,9 @@ D [0-9]
                                       if not stripcomment then
                                       if not stripcomment then
                                        write(outfile,' }');
                                        write(outfile,' }');
                                       c:=get_char;
                                       c:=get_char;
-                                      if (c=newline) then
-                                      begin
+                                      if c=newline then
                                         writeln(outfile);
                                         writeln(outfile);
-                                        unget_char(c);
-                                      end;
+                                      unget_char(c);
                                       flush(outfile);
                                       flush(outfile);
                                       exit;
                                       exit;
                                     end
                                     end

+ 2 - 4
utils/h2pas/scan.pas

@@ -512,11 +512,9 @@ begin
                                       if not stripcomment then
                                       if not stripcomment then
                                        write(outfile,' }');
                                        write(outfile,' }');
                                       c:=get_char;
                                       c:=get_char;
-                                      if (c=newline) then
-                                      begin
+                                      if c=newline then
                                         writeln(outfile);
                                         writeln(outfile);
-                                        unget_char(c);
-                                      end;
+                                      unget_char(c);
                                       flush(outfile);
                                       flush(outfile);
                                       exit;
                                       exit;
                                     end
                                     end