-
Notifications
You must be signed in to change notification settings - Fork 550
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
[EXPERIMENT] autoderef, the implicit deref in push REF and others #13181
Comments
From @rjbsPerl 5.14.0 introduced this behavior, described in perl5140delta as: Array and hash container functions accept references Warning: This feature is considered experimental, as the exact All builtin functions that operate directly on array or hash containers [table] This allows these builtin functions to act on long dereferencing chains The behavior of autoderef changed between David Golden's original work and the Specific questions: * do we revert the behavior changes, at least in some cases? On the third point, my current thought is that it seems like removing it just Anyway, the general question is the same as any other [EXPERIMENT] ticket: What are the criteria for accepting or rejecting this experiment? -- |
From @cpansproutOn Thu Aug 22 18:47:31 2013, rjbs wrote:
For acceptance: -- Father Chrysostomos |
The RT System itself - Status changed from 'new' to 'open' |
From @nwc10On Thu, Aug 22, 2013 at 06:47:31PM -0700, Ricardo SIGNES wrote:
Assuming that postfix deref works, and works out, I certainly think that we I don't think that there will be anywhere near as much grousing 1) if a replacement is available My assumption is that if a more general, more powerful [2] replacement is Nicholas Clark 1: Yes, I know the answer. But I have to *think* about it. |
From @rjbs* Nicholas Clark <nick@ccl4.org> [2013-08-23T03:26:26]
^^^^^^^- I think you mean auto- -- |
From @nwc10On Fri, Aug 23, 2013 at 06:57:10AM -0400, Ricardo Signes wrote:
I think I did too. Thanks for spotting this. use more 'coffee'; # or something like that* Nicholas Clark * says the hypocrite who is usually drinking decaf. |
From @ikegamiOn Thu, Aug 22, 2013 at 9:47 PM, Ricardo SIGNES
I'm still opposed to it on the grounds that it only works for some - Eric |
From @cpansproutOn Fri Aug 23 09:59:45 2013, ikegami@adaelis.com wrote:
As I’ve been saying from the outset: If push $scalar always implies -- Father Chrysostomos |
From @ap* Father Chrysostomos via RT <perlbug-followup@perl.org> [2013-08-23 20:15]:
That is the only form in which I find this feature viable. The current -- |
From @xdgOn Thu, Aug 22, 2013 at 9:47 PM, Ricardo SIGNES
There are mixed solutions as well: * make pure array functions (push/pop/shift/unshift/splice) auto-deref Because of the ambiguity of keys/values/each, we're always going to In hindsight, I wish we had said keys($ref) is always keys(%$ref). I (I assume at this point that deprecating keys/values/each on arrays Ultimately, I'd hate to see the baby thrown out with the bathwater I think this decision is somewhat orthogonal to postfix dereference, David -- |
From @b2gillsOn Fri, Aug 23, 2013 at 7:39 PM, David Golden <xdg@xdg.me> wrote:
I kind of like that I can have a subroutine like this that will sub say_kv{ That being said, I have yet to come up with an example |
From @HugmeirOn Sat, Aug 24, 2013 at 1:03 AM, Brad Gilbert <b2gills@gmail.com> wrote:
Or even better: sub say_kv{ each $arrayref is the only thing I would miss if this were yanked out. |
@arc - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#119437 (status was 'resolved')
Searchable as RT119437$
The text was updated successfully, but these errors were encountered: