Miscellaneous-NoFunctionPointersΒΆ
Avoid defining function pointers
Required inputs: IR
Example
typedef void (*callback) (int); // bad
int h(int (g)(int)); // bad
int f(int i); // plain function
auto g() {return &f;}; // bad
Possible Messages
Key |
Text |
Severity |
Disabled |
|---|---|---|---|
function_pointer_definition |
Avoid defining function pointers. |
None |
False |
Options
This rule shares the following common options: exclude_in_macros, exclude_messages_in_system_headers, excludes, extend_exclude_to_macro_invocations, includes, justification_checker, languages, post_processing, provider, report_at, severity
The following places define options that affect this rule: Stylechecks, Analysis-GlobalOptions
This rule has no individual options.