This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[perl #113932] UNIVERSAL::can with globs and globrefs
authorFather Chrysostomos <sprout@cpan.org>
Sun, 7 Jul 2013 19:31:00 +0000 (12:31 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Tue, 9 Jul 2013 01:05:43 +0000 (18:05 -0700)
commit4178f891f552ec7af2342df2bd612ce144646330
tree6c687a6f83ade7708ec57613d96b2a9ff509aad8
parent3a0b4597b2f8395314ac26ae64724f8965fa7bed
[perl #113932] UNIVERSAL::can with globs and globrefs

(Also perl #118105.)

This allows *ARGV->can("print") to work as long as IO::Handle is
loaded.  This translates into UNIVERSAL::can(\*ARGV,"print").  This
commit also changes UNIVERSAL::can to accept a plain *ARGV as well.

UNIVERSAL::can("ARGV",...) is left as it is (ARGV is treated as a pack-
age name), because changing that requires a bigger patch, and I don’t
know when I will get to it.
t/op/universal.t
universal.c