Hi guys, First, I really like the feature, that's a great idea.
On Fri, Sep 11, 2020 at 04:28:31PM +0200, Miroslav Zagorac wrote: > On 09/11/2020 03:56 PM, Tim Düsterhus, WoltLab GmbH wrote: > > We've had a bit of discussion regarding the naming of the converter. I > > wanted to avoid calling it `if`, because then we could have stuff like this: > > > > http-request set-var(txn.foo) bool(1),if(bar,baz) > > > > which can easily be confused with: > > > > http-request set-var(txn.foo) bool(1) if bar > > > > Some other naming suggestions that came up: > > > > - choice (my initial choice) > > - ifor / if_or > > - ifelse / if_else > > - iftrue (with the<false> argument being optional) > > Maybe something like this would be appropriate (IIF)? I was thinking about "select" which I've seldom seen, I never heard about "iif" previously but it has the benefit of being quite short (convenient for long expressions) and already in use elsewhere. And it also has the benefit that someone searching for "if" would easily stumble on it. I'm fine with the patch BTW, so if everyone agrees on "iif", let's suggest we go with it ? thanks, Willy

