Sub::Identify allows you to retrieve the real name of code references. For this, it uses Perl's introspection mechanism, provided by the B module.