[Python-ideas] Python 4: Concatenation

Clint Hepner clint.hepner at gmail.com
Fri Jun 30 10:14:47 EDT 2017


> On Jun 30, 2017, at 8:43 AM, Steven D'Aprano <steve at pearwood.info> wrote:
> 
>> On Fri, Jun 30, 2017 at 12:51:26PM +0100, Jamie Willis wrote:
>> 
>> Alternatively
>> "<>" is an alternative, being the monoidal append operator in Haskell,
>> which retains a certain similarly.
> 
> "<>" is familiar to many people as "not equal" in various programming 
> languages, including older versions of Python. I'm not entirely sure 
> what connection "<>" has to append, it seems pretty arbitrary to me, 
> although in fairness nearly all operators are arbitrary symbols if you 
> go back far enough.
> 

Even in Haskell, <> relies on the context of other operators like <*>, <$>, <+>, <|>, etc. to suggest a sort of generic, minimal binary operator. That meaning wouldn't translate well to other languages.

Clint


More information about the Python-ideas mailing list