浏览代码

Fix ignoring directives.

Rika Ichinose 4 年之前
父节点
当前提交
597afd9f23
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      compiler/scanner.pas

+ 2 - 1
compiler/scanner.pas

@@ -371,6 +371,7 @@ implementation
 *****************************************************************************}
 
     const
+      DirectiveIgnored=pointer(1);
       { use any special name that is an invalid file name to avoid problems }
       preprocstring : array [preproctyp] of string[7]
         = ('$IFDEF','$IFNDEF','$IF','$IFOPT','$ELSE','$ELSEIF');
@@ -4567,7 +4568,7 @@ type
              end
             else
              begin
-               current_scanner.ignoredirectives.Add(hs,nil);
+               current_scanner.ignoredirectives.Add(hs,DirectiveIgnored);
                Message1(scan_w_illegal_directive,'$'+hs);
              end;
             { conditionals already read the comment }