Improve inline code documentation regarding function_exists() checks

This is a spin-off of #534. Here, the `endif` tags are all given a comment saying what function they check for, following the style used in `functions.php`. This only affects functions in `template-tags.php`, because it looks like no other functions are missing this documentation.