On 08/05/2015 07:12 PM, Max Samukha wrote:
On Wednesday, 5 August 2015 at 15:58:28 UTC, Timon Gehr wrote:

The point is that '+' for string concatenation is no more of an 'idiot
thing' than '~'.

My point is that it is. String concatenation is not commutative.

Ok, good point. Except that '+' in a programming language is not the
mathematical '+'.

It's obvious where the notation has been borrowed from.

Why define '+' as strictly commutative operation and
not more generally as an abstract binary operation,

Descriptive names do have some value.

considering the middle dot is unavailable?

(It isn't.)

Or, if we want to stick to the math notation,
then '*' would be more appropriate than the idiot thing '~'.

That's a different discussion. '*' is certainly more appropriate than '+'. Anyway, I think it is sensible to use distinct names for distinct operations when they are used in the same system.

Reply via email to