What is the equivalent of \ifthenelse{<statement>}{<iftrue>}{<iffalse>} when using expl3 syntax?
Asked
Active
Viewed 193 times
1
What is the equivalent of \ifthenelse{<statement>}{<iftrue>}{<iffalse>} when using expl3 syntax?
expl3has different conditional macros, such as\bool_if:NTF \some_bool {true branch}{false branch}or\seq_if_in:NnTFetc, depending on the 'variable' type and the precise application usage – Feb 16 '19 at 19:39\bool_if:{ \equal{#1}{#2} }{ <iftrue> }{ <iffalse> }work? – noibe Feb 16 '19 at 19:42\int_compare:nNnTF {#1} = {#2} {true}{false}-- the\equaletc. syntax is not available inexpl3and I found\ifthenelsenever convincing -- see theinterface3manual please – Feb 16 '19 at 19:44\bool_if:nTF { \int_compare_p:nNn {#1} = {#2} } { true } { false }, but as @ChristianHupfer says normally one would use just the basicintcomparison. – Joseph Wright Feb 16 '19 at 19:46\int_compare_p:nNnhowever yet -- most likely I had no need for it (yet) – Feb 16 '19 at 19:50