How can I see $post object in frontend from functions.php?

I would like to see the dump data of $post object in any page. So which code snippet to add in functions.php?

This is not working. Please suggest.