-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
\tl_case:nn, \str_case:Nn, and \str_if_empty:n #1071
Comments
There is There is also an inherent difference between Indeed, I find strange that |
I guess As @eg9 says, I'm not keen on |
I think consistency is important. otherwise it will confuse users. In my opinion, it would be better to use \str_set:Nn \l_tmpa_str {\abc}
\str_set:Nn \l_tmpb_str {\abc}
\str_case:VnF \l_tmpa_str
{
\uvw { UVW }
\l_tmpb_str { TMP }
\abc { ABC }
}
{ No Match } The above code gives |
I think |
I think @blefloch is right here: the approach of comparing token lists is actually not that useful in the main in my experience. We can't remove the name, but we can deprecate. |
I'm not sure what you mean here: the defined behaviour is that |
Because \str_case:Nn <test str variable> {
<str variable case 1> {<code case 1>}
<str variable case 2> {<code case 2>}
<str variable case 3> {<code case 3>}
} |
We concluded \tl_case:Nn should be deprecated and renamed \cs_case_meaning:Nn, but there is already \token_case_meaning:Nn, which seems to fit the bill. Relatedly, |
Multiple names are fine as long as they help with understanding: I think |
We still need some action here? |
This closes #1071: all tasks done.
Still planning to add |
They were done the same day they were discussed here :) |
Recently I compared
tl
andstr
packages:\tl_case:Nn
but not\str_case:Nn
\str_case:nn
but not\tl_case:nn
\tl_if_empty:n
but not\str_if_empty:n
Could these missing functions be added to
expl3
?The text was updated successfully, but these errors were encountered: