extend is_function() with support for public local functions
Brought to you by:
bgamez23
Originally created by: Helianthella
This is a follow-up to [#2142]
FUNCTION_IS_PUBLIC to check if a local function is public