diff options
author | Salvador FandiXXo <unknown> | 2005-06-15 13:54:53 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2005-06-15 14:40:40 +0000 |
commit | 61dbb99a522b2949bb5b65d33183104796a3c272 (patch) | |
tree | 4fee217db29a16bca2a6ab823ac84ed2a701d84e /t/op | |
parent | 97972285a7cc3296dc99230fa10f7a030afa733f (diff) | |
download | perl-61dbb99a522b2949bb5b65d33183104796a3c272.tar.gz |
[perl #36297] builtin attrs on subrutine declarations
From: Salvador "FandiXXo" (via RT) <perlbug-followup@perl.org>
Message-ID: <rt-3.0.11-36297-115797.8.75971493113916@perl.org>
p4raw-id: //depot/perl@24851
Diffstat (limited to 't/op')
-rw-r--r-- | t/op/attrs.t | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/t/op/attrs.t b/t/op/attrs.t index 2169e3cd7c..10e2c2493c 100644 --- a/t/op/attrs.t +++ b/t/op/attrs.t @@ -106,6 +106,11 @@ is ref($thunk), "Z"; @attrs = eval 'attributes::get $thunk'; is "@attrs", "locked method Z"; +# Test attributes on predeclared subroutines: +eval 'package A; sub PS : lvalue'; +@attrs = eval 'attributes::get \&A::PS'; +is "@attrs", "lvalue"; + # Test ability to modify existing sub's (or XSUB's) attributes. eval 'package A; sub X { $_[0] } sub X : lvalue'; @attrs = eval 'attributes::get \&A::X'; |