Sometimes, in LaTeX one wants to do the simple test if a macro is empty, e.g.
\def\foo{%
This is...
\ifx\baz\@empty
Sparta!
\else
a pony farm.
\fi
}
I am interested in how the definition of \baz has to be made in order to obtain the desired results. A few thoughts make evident that all of the three definitions
\def\baz{}
\edef\baz{\@empty}
\let\baz=\@empty
will lead to the true case. Now, I would like to know, what is the best practice, or if there aren't any differences (as far as \def\@empty{}), or if there are cases in which one is to favor, (obviously) depending on what one is doing? (Examples would be really nice!)