https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116481
--- Comment #6 from Richard Biener <rguenth at gcc dot gnu.org> --- For portability you likely want to convert the function pointer to uintptr_t and only that to char */long *. That might also avoid GCCs diagnostic.