If fetches already have the output type after the colon, then the converter should not have the input type after the colon, i.e.

     iif(str,str): bool => str

is confusing, because it looks like it returns a bool, ... I guess?

While this is mainly a feelings thing, I'd say that it is more widespread (if not nowadays near-mainstream? not that this is necessarily a good argument of course) to write it that way


     iif(str,str): str <= bool


Though I guess this one is clear enough, if unusual (to me anyway)

Another option might be listing the "implicit" parameter as a real parameter:

     iif(bool,str,str): str

This one feels quite unnatural to me; unless you're familiar with the underlying implementation of many OOP systems and see this as some kind of extension method definition, the fact that the first parameter is implicitly passed seems (to me) like it's coming out of nowhere

Tristan

Reply via email to