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
List.Array loses Nil #6114
Comments
From zefram@fysh.org
The coercion from List to Array transforms the Nil element value into -zefram |
From @lizmat
$ 6 'my @a = Nil; dd @a' $ 6 'my @a = (Nil,); dd @a’ # more direct translation $ 6 'dd my @ = (Nil,)' In all of these cases, Nil becomes Any after coercion. The *only* way to keep Nil in here, is to make it the default: $ 6 'dd my @ is default(Nil) = (Nil,)' I’m not sure we want to do that for all Array coercions, or for all Array creation for that matter (seeing RT #130963). |
The RT System itself - Status changed from 'new' to 'open' |
From zefram@fysh.orgElizabeth Mattijsen via RT wrote:
There's also binding:
It's not required for all Array coercions. Only where there's a Nil
That one's even more open. Although it's rather surprising behaviour -zefram |
Migrated from rt.perl.org#130962 (status was 'open')
Searchable as RT130962$
The text was updated successfully, but these errors were encountered: