GNATcheck Reference Manual
25.1
1. Getting Started
2. Using GNATcheck
3. Predefined Rules
4. Writing Your Own Rules
5. LKQL Language Reference
Alphabetical List of Rules
GNU Free Documentation License
GNATcheck Reference Manual
Index
Index
Symbols
|
A
|
B
|
C
|
D
|
E
|
F
|
G
|
H
|
I
|
K
|
L
|
M
|
N
|
O
|
P
|
Q
|
R
|
S
|
T
|
U
|
V
|
W
Symbols
+R (gnatcheck)
--brief
--charset
--check-redefinition
--check-semantic
--emit-lkql-rule-file
--help
--ignore
--ignore-project-switches
--include-file=file
--no-subprojects
--no_objects_dir
--RTS
--rule
--rule-file
--rules-dir
--show-instantiation-chain
--show-rule
--subdirs=dir
--target
--version
-eL
-files
-from (gnatcheck)
-h
-j
-l
-log
-m
-nt
-o
-ox
-P file
-q
-r
-R (gnatcheck)
-rules
-s
-t
-U
-v
-W
-xml
-Xname=value
A
Abort_Statements
Abstract_Type_Declarations
Access_To_Local_Objects
Actual_Parameters
Ada05_Formal_Packages
Ada_2022_In_Ghost_Code
add_first() (RewritingContext method)
add_last() (RewritingContext method)
Address_Attribute_For_Non_Volatile_Objects
Address_Specifications_For_Initialized_Objects
Address_Specifications_For_Local_Objects
all()
built-in function
Annotated_Comments
Anonymous_Access
Anonymous_Arrays
Anonymous_Subtypes
any()
built-in function
argument sources legality and project files
At_Representation_Clauses
B
base_name()
built-in function
base_name() (Str method)
Binary_Case_Statements
Bit_Records_Without_Layout_Definition
Blocks
Boolean_Negations
Boolean_Relational_Operators
built-in function
all()
any()
base_name()
children_no_nested()
closest_enclosing_generic()
complete_super_types()
component_types()
concat()
default_bit_order()
depends_on_mutable_discriminant()
doc()
document_builtins()
document_namespace()
enclosing_block()
enclosing_body()
enclosing_package()
find_comment()
first_non_blank()
full_parent_types()
full_root_type()
get_parameter()
get_subp_body()
has_interfaces()
has_local_scope()
has_non_default_sso()
help()
img()
in_generic_instance()
in_generic_template()
is_assert_aspect()
is_assert_pragma()
is_by_copy()
is_classwide_type()
is_composite_type()
is_constant_object()
is_constructor()
is_controlling_param_type()
is_in_library_unit_body()
is_in_package_scope()
is_limited_type()
is_local_object()
is_negated_op()
is_predefined_op()
is_predefined_type()
is_program_unit()
is_standard_boolean()
is_standard_false()
is_standard_numeric()
is_standard_true()
is_unchecked_conversion()
is_unchecked_deallocation()
list_of_units()
map()
max()
negate_op()
next_non_blank_token_line()
node_checker()
number_of_values()
param_pos()
parent_decl_chain()
pattern()
previous_non_blank_token_line()
print()
profile()
propagate_exceptions()
range_values()
reduce()
semantic_parent()
sloc_image()
specified_units()
strip_conversions()
super_types()
ultimate_alias()
ultimate_designated_generic_subp()
ultimate_exception_alias()
ultimate_generic_alias()
ultimate_prefix()
ultimate_subprogram_alias()
unique()
unit_checker()
units()
within_assert()
C
Calls_In_Exception_Handlers
Calls_Outside_Elaboration
children() (Node method)
children_count() (Node method)
children_no_nested()
built-in function
clone() (RewritingNode method)
closest_enclosing_generic()
built-in function
Coding standard file (for gnatcheck)
complete_super_types()
built-in function
Complex_Inlined_Subprograms
component_types()
built-in function
concat()
built-in function
Concurrent_Interfaces
Conditional_Expressions
Constant_Overlays
Constructors
contains() (Str method)
Controlled_Type_Declarations
D
Declarations_In_Blocks
Deep_Inheritance_Hierarchies
Deep_Library_Hierarchy
Deeply_Nested_Generics
Deeply_Nested_Inlining
Deeply_Nested_Instantiations
default_bit_order()
built-in function
Default_Parameters
Default_Values_For_Record_Components
depends_on_mutable_discriminant()
built-in function
Deriving_From_Predefined_Type
Direct_Calls_To_Primitives
Direct_Equalities
Discriminated_Records
doc()
built-in function
doc() (Any method)
document_builtins()
built-in function
document_namespace()
built-in function
Downward_View_Conversions
dump() (Node method)
Duplicate_Branches
E
enclosing_block()
built-in function
enclosing_body()
built-in function
enclosing_package()
built-in function
end_column() (Token method)
end_line() (Token method)
End_Of_Line_Comments
ends_with() (Str method)
enumerate() (LazyList method)
(List method)
(SelectorList method)
Enumeration_Ranges_In_CASE_Statements
Enumeration_Representation_Clauses
Exception_Propagation_From_Callbacks
Exception_Propagation_From_Export
,
[1]
Exceptions_As_Control_Flow
exit code
EXIT_Statements_With_No_Loop_Name
Exits_From_Conditional_Loops
Expanded_Loop_Exit_Names
Explicit_Full_Discrete_Ranges
Explicit_Inlining
Expression_Functions
F
Feature usage related rules
find() (Str method)
find_comment()
built-in function
first_non_blank()
built-in function
Fixed_Equality_Checks
Float_Equality_Checks
Forbidden_Aspects
Forbidden_Attributes
Forbidden_Pragmas
Format of the Report File
full_parent_types()
built-in function
full_root_type()
built-in function
Function_Style_Procedures
G
Generic_IN_OUT_Objects
Generics_In_Subprograms
get_parameter()
built-in function
get_subp_body()
built-in function
Global_Variables
gnatcheck annotations rules
GOTO_Statements
H
has_interfaces()
built-in function
has_local_scope()
built-in function
has_non_default_sso()
built-in function
Headers
help()
built-in function
I
Identifier_Casing
Identifier_Prefixes
Identifier_Suffixes
image() (Node method)
img()
built-in function
img() (Any method)
Implicit_IN_Mode_Parameters
Implicit_SMALL_For_Fixed_Point_Types
Improper_Returns
Improperly_Located_Instantiations
in_generic_instance()
built-in function
in_generic_template()
built-in function
Incomplete_Representation_Specifications
insert_after() (RewritingContext method)
insert_before() (RewritingContext method)
Integer_Types_As_Enum
is_assert_aspect()
built-in function
is_assert_pragma()
built-in function
is_by_copy()
built-in function
is_classwide_type()
built-in function
is_composite_type()
built-in function
is_constant_object()
built-in function
is_constructor()
built-in function
is_controlling_param_type()
built-in function
is_equivalent() (Token method)
is_in_library_unit_body()
built-in function
is_in_package_scope()
built-in function
is_limited_type()
built-in function
is_local_object()
built-in function
is_lower_case() (Str method)
is_mixed_case() (Str method)
is_negated_op()
built-in function
is_predefined_op()
built-in function
is_predefined_type()
built-in function
is_program_unit()
built-in function
is_standard_boolean()
built-in function
is_standard_false()
built-in function
is_standard_numeric()
built-in function
is_standard_true()
built-in function
is_trivia() (Token method)
is_unchecked_conversion()
built-in function
is_unchecked_deallocation()
built-in function
is_upper_case() (Str method)
K
kind() (Node method)
(Token method)
L
length() (LazyList method)
(List method)
(SelectorList method)
(Str method)
Library_Level_Subprograms
list_of_units()
built-in function
Local_Instantiations
Local_Packages
Local_USE_Clauses
M
map()
built-in function
map() (LazyList method)
(List method)
(SelectorList method)
max()
built-in function
Max_Identifier_Length
Maximum_Expression_Complexity
Maximum_Lines
Maximum_OUT_Parameters
Maximum_Parameters
Maximum_Subprogram_Lines
Membership_For_Validity
Membership_Tests
Metrics-related rules
Metrics_Cyclomatic_Complexity
Metrics_Essential_Complexity
Metrics_LSLOC
Min_Identifier_Length
Misnamed_Controlling_Parameters
Misnamed_Identifiers
Misplaced_Representation_Items
Multiple_Entries_In_Protected_Definitions
N
name() (AnalysisUnit method)
Name_Clashes
negate_op()
built-in function
Nested_Paths
Nested_Subprograms
new defaults for recursive subprograms rule
next() (Token method)
next_non_blank_token_line()
built-in function
No_Closing_Names
No_Explicit_Real_Range
No_Inherited_Classwide_Pre
No_Others_In_Exception_Handlers
No_Scalar_Storage_Order_Specified
node_checker()
built-in function
Non_Component_In_Barriers
Non_Constant_Overlays
Non_Qualified_Aggregates
Non_Short_Circuit_Operators
Non_SPARK_Attributes
Non_Tagged_Derived_Types
Non_Visible_Exceptions
Nonoverlay_Address_Specifications
Not_Imported_Overlays
Null_Paths
Number_Declarations
number_of_values()
built-in function
Numeric_Format
Numeric_Indexing
Numeric_Literals
O
Object-Orientation related rules
Object_Declarations_Out_Of_Order
Objects_Of_Anonymous_Types
old unsupported switches
One_Construct_Per_Line
One_Tagged_Type_Per_Package
Operator_Renamings
OTHERS_In_Aggregates
OTHERS_In_CASE_Statements
OTHERS_In_Exception_Handlers
Outbound_Protected_Assignments
Outer_Loop_Exits
Outside_References_From_Subprograms
Overloaded_Operators
Overly_Nested_Control_Structures
Overly_Nested_Scopes
P
param_pos()
built-in function
Parameters_Aliasing
Parameters_Out_Of_Order
parent() (Node method)
parent_decl_chain()
built-in function
pattern()
built-in function
Portability-related rules
POS_On_Enumeration_Types
Positional_Actuals_For_Defaulted_Generic_Parameters
Positional_Actuals_For_Defaulted_Parameters
Positional_Components
Positional_Generic_Parameters
Positional_Parameters
Potential_Parameters_Aliasing
Predefined Rules
Predefined_Numeric_Types
Predicate_Testing
previous() (Token method)
previous_non_blank_token_line()
built-in function
print()
built-in function
print() (Any method)
Printable_ASCII
profile()
built-in function
Profile_Discrepancies
Program Structure related rules
Programming Practice related rules
propagate_exceptions()
built-in function
Q
Quantified_Expressions
R
Raising_External_Exceptions
Raising_Predefined_Exceptions
range_values()
built-in function
Readability-related rules
Recursive_Subprograms
reduce()
built-in function
reduce() (LazyList method)
(List method)
(SelectorList method)
Redundant_Boolean_Expressions
Redundant_Null_Statements
Relative_Delay_Statements
remove() (RewritingContext method)
Renamings
replace() (RewritingContext method)
Representation_Specifications
Restrictions
root() (AnalysisUnit method)
rule aliases no longer supported
Rule exemption
S
Same_Instantiations
Same_Logic
Same_Operands
Same_Tests
same_tokens() (Node method)
semantic_parent()
built-in function
Separate_Numeric_Error_Handlers
Separates
,
[1]
set_child() (RewritingContext method)
Side_Effect_Parameters
Silent_Exception_Handlers
Simple_Loop_Statements
Single_Value_Enumeration_Types
Size_Attribute_For_Types
Slices
sloc_image()
built-in function
SPARK related rules
Specific_Parent_Type_Invariant
Specific_Pre_Post
Specific_Type_Invariants
specified_units()
built-in function
split() (Str method)
start_column() (Token method)
start_line() (Token method)
starts_with() (Str method)
strip_conversions()
built-in function
Style-related rules
Style_Checks
sublist() (List method)
Subprogram_Access
substring() (Str method)
super_types()
built-in function
Suspicious_Equalities
T
Tasking-related rules
text() (AnalysisUnit method)
(Node method)
(Token method)
to_list() (LazyList method)
(List method)
(SelectorList method)
to_lower_case() (Str method)
to_upper_case() (Str method)
tokens() (AnalysisUnit method)
(Node method)
Too_Many_Dependencies
Too_Many_Generic_Dependencies
Too_Many_Parents
Too_Many_Primitives
Trivial_Exception_Handlers
U
ultimate_alias()
built-in function
ultimate_designated_generic_subp()
built-in function
ultimate_exception_alias()
built-in function
ultimate_generic_alias()
built-in function
ultimate_prefix()
built-in function
ultimate_subprogram_alias()
built-in function
Unassigned_OUT_Parameters
Unavailable_Body_Calls
Unchecked_Address_Conversions
Unchecked_Conversions_As_Actuals
Uncommented_BEGIN
Uncommented_BEGIN_In_Package_Bodies
Uncommented_End_Record
Unconditional_Exits
Unconstrained_Array_Returns
Unconstrained_Arrays
Uninitialized_Global_Variables
unique()
built-in function
unique() (List method)
unit() (Node method)
(Token method)
unit_checker()
built-in function
units()
built-in function
Universal_Ranges
Unnamed_Blocks_And_Loops
Unnamed_Exits
Use_Array_Slices
Use_Case_Statements
USE_Clauses
Use_For_Loops
Use_For_Of_Loops
Use_If_Expressions
Use_Memberships
USE_PACKAGE_Clauses
Use_Ranges
Use_Record_Aggregates
Use_Simple_Loops
Use_While_Loops
using comments to control rule and instance exemption
using pragma Annotate to control rule and instance exemption
V
Variable_Scoping
Visible_Components
Volatile_Objects_Without_Address_Clauses
W
Warnings
within_assert()
built-in function