[fpc-pascal] Disable Warning: (6060) Case statement does not handle all possible cases
Jonas Maebe
jonas at freepascal.org
Fri Mar 27 22:45:11 CET 2020
On 27/03/2020 22:26, fredvs via fpc-pascal wrote:
>> It works for me:
>
> It seems that you did try to use {$warn 6060 off} in a program-file.
>
> But did you try with a unit-file?
$ cat tt.pp
unit tt;
{$warn 6060 off}
interface
uses
sysutils;
implementation
procedure test;
var
b: 1..10;
begin
case b of
1: writeln('hello');
end
end;
end.
$ ../compiler/ppcx64 -l -vw tt
Free Pascal Compiler version 3.3.1 [2020/03/27] for x86_64
Copyright (c) 1993-2020 by Florian Klaempfl and others
Target OS: Darwin for x86_64
Compiling tt.pp
tt.pp(16,8) Warning: Local variable "b" does not seem to be initialized
Assembling tt
21 lines compiled, 0.1 sec
1 warning(s) issued
Jonas
More information about the fpc-pascal
mailing list