4 ms·
> infix notation is considered more "natural" Infix notation only works "naturally" for two operands.
by Koshkin 9y ago
> infix notation is considered more "natural"
Infix notation only works "naturally" for two operands.
- TuringTest 9y ago> Infix notation only works "naturally" for two operands. Or n operands where the operator is the same (think a + b + c + ... ). The Readable Lisp project for Lisp without parentheses allows using infix notation in Lisp for these two use cases.
- mpweiher 9y agoNope, Smalltalk keyword syntax works for as many operands as you need.
- Koshkin 9y agoCalling keywords "infix operators" is a bit disingenuous, they are just labels used to mark off different arguments in an otherwise normally looking method call.
- mpweiher 9y agoThey are infix notation, not infix operators. a raisedTo: 2 vs. a ** 2
- munificent 9y agoThose would probably be considered "mixfix" more than "infix". I think most people who use "infix" use it to refer to binary expressions with two operands.