Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LTA error message when structures are not congruent on deeper levels than 0 in Rakudo #2224

Closed
p6rt opened this issue Oct 14, 2010 · 4 comments
Labels

Comments

@p6rt
Copy link

p6rt commented Oct 14, 2010

Migrated from rt.perl.org#78368 (status was 'resolved')

Searchable as RT78368$

@p6rt
Copy link
Author

p6rt commented Oct 14, 2010

From @masak

<masak> rakudo​: say ([[1, 2], 3] >>+<< [4, [5, 6]]).perl
<p6eval> rakudo 5d23e3​: OUTPUT«Sorry, sides are of uneven length and
not dwimmy. [...]
<masak> I'm thinking whether this error message is LTA.
<masak> the sides are in fact not of 'uneven length'.
<masak> (well, they are both of length 3, which is not an even number,
but...) :)
<moritz_> what could we say instead?
<masak> good question.
<masak> printing out the contents of the sub-arrays might be a Bad
Idea for big arrays.
<moritz_> "the structures on both sides of non-dwimmy hyperop are not congruent"
<masak> I like that better.
* masak submits rakudobug
<masak> moritz_++
<moritz_> left​: 1 element
<moritz_> right​: 2 elements
<moritz_> at nesting level 2
<masak> excellent.
<masak> yes!
* moritz_ has no idea how hard the nesting level will be to obtain
<flussence> wouldn't the code that prints the error know where it went wrong?
<moritz_> flussence​: the code for hyper is spread out over half a
dozen multis, and there are three die()s in there concerning non-equal
length
<flussence> oh, hm.
<moritz_> but that would be nice project to work on
<moritz_> (one could even track the indexes that lead to the mismatch,
and then say (left)[1]<foo>[3] has length 3, (right)[1]<foo>[3] has
length 2)

@p6rt
Copy link
Author

p6rt commented Feb 20, 2011

From @moritz

On Thu Oct 14 04​:25​:27 2010, masak wrote​:

<moritz_> "the structures on both sides of non-dwimmy hyperop are not
congruent"
<masak> I like that better.
* masak submits rakudobug
<masak> moritz_++
<moritz_> left​: 1 element
<moritz_> right​: 2 elements
<moritz_> at nesting level 2
<masak> excellent.
<masak> yes!
...
<moritz_> (one could even track the indexes that lead to the mismatch,
and then say (left)[1]<foo>[3] has length 3, (right)[1]<foo>[3] has
length 2)

That's what happens now​:

say ([[1, 2], 3] >>+<< [4, [5, 6]]).perl
Sorry, lists on both sides of non-dwimmy hyperop are not of same length​:
  left​: 2 elements
  right​: 1 elements
At .[0]

@p6rt
Copy link
Author

p6rt commented Feb 20, 2011

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Feb 20, 2011

@moritz - Status changed from 'open' to 'resolved'

@p6rt p6rt closed this as completed Feb 20, 2011
@p6rt p6rt added the Bug label Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant