Skip to content

Commit e2b082b

Browse files
committed
Remove 'Warning_Mode' global because it is never wrote
1 parent 19c129a commit e2b082b

File tree

3 files changed

+2
-14
lines changed

3 files changed

+2
-14
lines changed

lkql_checker/src/gnatcheck-options.ads

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -94,16 +94,6 @@ package Gnatcheck.Options is
9494
KP_Version : GNAT.OS_Lib.String_Access;
9595
-- If set, the relevant GNAT version to check when running gnatkp.
9696

97-
type Warning_Modes is
98-
(Quiet, -- all warnings are suppressed
99-
Short,
100-
Normal,
101-
Full);
102-
103-
Warning_Mode : Warning_Modes := Normal;
104-
-- Specifies the warning message level
105-
-- '-w(q|s|n|f)
106-
10797
Log_Mode : Boolean := False;
10898
-- Create the log file and duplicate in this file all the messages
10999
-- generated by a tool.

lkql_checker/src/gnatcheck-output.adb

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -543,9 +543,7 @@ package body Gnatcheck.Output is
543543

544544
procedure Warning (Message : String) is
545545
begin
546-
if Arg.Warnings_As_Errors.Get or else Warning_Mode /= Quiet then
547-
Error (Message);
548-
end if;
546+
Error (Message);
549547

550548
-- Force a non-zero return code when "warnings as errors" is enabled
551549
if Arg.Warnings_As_Errors.Get then

lkql_checker/src/gnatcheck-output.ads

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ package Gnatcheck.Output is
4848
-- Sends into Stderr the error message with no tool name prefix
4949

5050
procedure Warning (Message : String);
51-
-- Same as Error, but do nothing if Warning_Mode = Quiet.
51+
-- Same as ``Error``
5252

5353
procedure Info (Message : String);
5454
-- Sends Message into Stderr (with no tool name prefix).

0 commit comments

Comments
 (0)