[self-interest] Keyword message associativity.
David Ungar
ungar at mac.com
Sun Jul 22 22:01:26 UTC 2018
Can you write a parser to give you the result you want?
- David
> On Jul 22, 2018, at 10:17 AM, rvclayton at acm.org [self-interest] <self-interest at yahoogroups.com> wrote:
>
> The self 2017.1 handbook interprets the expression
>
> 5 min: 6 min: 7 Max: 8 Max: 9 min: 10 Max: 11
>
> as
>
> 5 min: (6 min: 7 Max: 8 Max: (9 min: 10 Max: 11))
>
> (pgs 17-18) for the message min:Max. This strikes me as wrong - where's the
> Max: part for the message sent to 5? It seems to me that the interpretation
> should be
>
> 5 min: (6 min: 7 Max: 8) Max: (9 min: 10 Max: 11)
>
> or, to use indentation
>
> 5 min:
> 6 min:
> 7
> Max:
> 8
> Max:
> 9 min:
> 10
> Max:
> 11
>
> I understand that one likes to see a pleasing pile-up of parentheses at the end
> of right-associative expressions, so maybe the example could be
>
> 5 min: 6 Max: 7 min: 8 Max: 9 min: 10 Max: 11 min: 12 Max: 13
>
> which equivalent to (if I'm understanding things correctly)
>
> 5 min: 6 Max: (7 min: 8 Max: (9 min: 10 Max: (11 min: 12 Max: 13)))
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.selflanguage.org/pipermail/self-interest/attachments/20180722/0af26e6a/attachment.html>
More information about the Self-interest
mailing list