Take the following code as an example:
\documentclass{standalone}
\def\myvar{foobar}
\begin{document}
\makeatletter
\in@{foo}{foobar}\ifin@ Yes\else No\fi,
\in@{foo}{\myvar}\ifin@ Yes\else No\fi
\makeatother
\end{document}
This typesets Yes, No while I would expect Yes, Yes. I'm guessing this is because \myvar is not being expanded before \in@ does its work. How do I make it work?
Note: I'm not very good at expansion, so it may be that the above (or the title) doesn't make much sense.