Why can't I obtain OBJECT_NAME() for a temporary table?
You have to tell object_name that it needs to look in the metadata of tempdb.

select object_name(object_id('tempdb..#t'), db_id('tempdb')) as from_beta1