[perl #128811] non-associatives are somehow getting treated as list associatives

2016-08-02 Thread Larry Wall via RT
We've split the non-associative exceptions into the base class, 
X::Syntax::NonAssociative, with a subclass off X::Syntax::NonListAssociative.  
nqp's EXPR now calls a different method to fail list associativity, and rakudo 
provides the alternate method to get the appropriate message.

nqp fix in 9073af7ab6049485a245fce383a034a41603cfd8

rakudo fix in f568db26f85909a2431325491405fea6a1efed87

tests in 5939e74f80322a1288fbd891b24311186b015eb8


[perl #128811] non-associatives are somehow getting treated as list associatives

2016-08-01 Thread via RT
# New Ticket Created by  Aaron Sherman 
# Please include the string:  [perl #128811]
# in the subject line of all future correspondence about this issue. 
# https://rt.perl.org/Ticket/Display.html?id=128811 >


>From tonight's IRC:

[01:01]  I'm not sure how to read this error: Only identical
operators may be list associative; since '..' and '..' differ, they are
non-associative and you need to clarify with parentheses
...
[01:05]  m: say 1 .. 2 .. 3
[01:05] <+camelia> rakudo-moar f1313d: OUTPUT«===SORRY!=== Error while
compiling ␤Only identical operators may be list associative; since
'..' and '..' differ, they are non-associative and you need to clarify with
parentheses␤at :1␤--> say 1 .. 2⏏ .. 3␤expectin…»
[01:05]  it's LTA for sure
[01:06]  .. should really be considered non-associative, probably
[01:06]  TimToady: Great example. I'll rakudobug that before I turn
in.
[01:06]  m: 1 but 2 but 3
[01:06] <+camelia> rakudo-moar f1313d: OUTPUT«===SORRY!=== Error while
compiling ␤Only identical operators may be list associative; since
'but' and 'but' differ, they are non-associative and you need to clarify
with parentheses␤at :1␤--> 1 but 2⏏ but 3␤expecti…»
[01:07]  yeah, non-associatives are somehow getting treated as
list associatives
[01:07]  m: say 1 <=> 2 <=> 3
[01:07] <+camelia> rakudo-moar f1313d: OUTPUT«===SORRY!=== Error while
compiling ␤Only identical operators may be list associative; since
'<=>' and '<=>' differ, they are non-associative and you need to clarify
with parentheses␤at :1␤--> say 1 <=> 2⏏ <=> 3␤expe…»
[01:07]  it's just the wrong error

--
Aaron Sherman, M.:
P: 617-440-4332 Google Talk, Email and Google Plus: a...@ajs.com
Toolsmith, developer, gamer and life-long student.