-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add '-W/--warnings-as-errors' flag to GNATcheck
- Loading branch information
1 parent
688bc47
commit 19c129a
Showing
9 changed files
with
93 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
procedure Main is | ||
begin | ||
goto lbl; -- FLAG (2) | ||
<<lbl>> | ||
end Main; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
val rules = @{ | ||
goto_statements, | ||
restrictions: {arg: ["No_Recursion"]} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
Without "warnings as errors" | ||
============================ | ||
|
||
gnatcheck: restriction No_Recursion ignored (cannot be checked statically), use rule Recursive_Subprograms instead | ||
main.adb:3:04: goto statement | ||
|
||
With "warnings as errors" | ||
========================= | ||
|
||
gnatcheck: restriction No_Recursion ignored (cannot be checked statically), use rule Recursive_Subprograms instead | ||
main.adb:3:04: goto statement | ||
>>>program returned status code 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
driver: gnatcheck | ||
format: brief | ||
input_sources: | ||
- main.adb | ||
lkql_rule_file: rules.lkql | ||
tests: | ||
- label: Without "warnings as errors" | ||
- label: With "warnings as errors" | ||
extra_args: | ||
- -W |