Consider the following example:
\documentclass{article}
\usepackage{booktabs,xparse}
\ExplSyntaxOn%
\NewDocumentCommand\GetListMember{s m m}{% https://tex.stackexchange.com/a/468450
\IfBooleanTF{ #1 }{% * means control sequence
\clist_item:Nn #2 { #3 } }{%
\clist_item:nn { #2 } { #3 } }}%
\NewDocumentCommand\ConcatArguments{>{\SplitList{,}} m } { #1 }
\ExplSyntaxOff%
\begin{document}
\newcommand\testA{{a,b},{c,d},{e,f}}
\begin{tabular}{lll}
\toprule
no.& reality & expectation\\
\midrule
1 & \ConcatArguments{{a,b},{c,d},{e,f}} & a,bc,de,f\\
2 & \ConcatArguments{\testA} & a,bc,de,f\\
% https://tex.stackexchange.com/a/323873 :
2a & \expandafter\ConcatArguments\expandafter{\testA} & a,bc,de,f\\
3 & \GetListMember*{\testA}{2} & c,d\\
4 & \ConcatArguments{\GetListMember*{\testA}{2}} & cd\\
4a & \expandafter\ConcatArguments\expandafter{\GetListMember*{\testA}{2}} & cd\\
\bottomrule
\end{tabular}
\end{document}
How can I achieve my expectation in no. 4? (I tried to reduce the problem but am unsure how to correctly apply what worked in 2a.)



Expandable. Is it possible to avoid introducingcameron_concat? (Apologies for the contrived MWE. I tried to keep it simple.) – Cameron Hudson May 25 '21 at 12:16\SplitListmakes the command not expandable. – egreg May 25 '21 at 12:36