you can get away with not using
global $user_identity;
get_currentuserinfo();
if your template just has a single index.php file (meaning no header.php, sidebar.php, footer.php etc)
For instance, the simple-green theme I didn’t have to use global, or get_currentuserinfo();
however, with templates that DO have them split up in multiple files (I just found this out reciently after trying to split the simple-green theme up into multiple files) you HAVE to use global.
however, get_currentuserinfo(); isn’t needed either way. not sure why that is… In fact, I used global inside of sidebar.php, just before using $user_identity, and it worked just fine. I didn’t have to put global in header.php or index.php, I’m assuming the reason is because globals are no longer registered inside multiple includes (shrugs) thats just a guess though.