To find where a function is defined in a Laravel application I'm trying to do this:
Inside App\Http\Controllers
Namespace:
$reflFunc = new ReflectionFunction('function_name');
But get an error:
PHP Error: Class 'App\Http\Controllers\ReflectionFunction' not found in /var/www/html/s/source/app/Http/Controllers/HomeController.php on line 169
I even tried to use the global namespace:
ReflectionFunction Class is not supposed to be located where laravel is trying to find it, But please suggest what is that I could be missing?