Skip to content

Detect pointers to candidates in global variables

Previously, the plugin only detected function usage within function bodies via GIMPLE IR processing, missing global function pointer assignments that occur at file scope.

This change adds process_global_variables() to iterate through all global variables using GCC's varpool API and processes their initializers to detect function assignments like:

int (*func_ptr)() = some_func;

Resolves: #12 (closed)

Edited by Mark Kemel

Merge request reports

Loading