Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^4: How do I determine if a variable contains a type glob? (bless)

by tye (Sage)
on Dec 05, 2016 at 07:08 UTC ( #1177198=note: print w/replies, xml ) Need Help??


in reply to Re^3: How do I determine if a variable contains a type glob?
in thread How do I determine if a variable contains a type glob?

Just FYI, when you bless a reference, the blessing is actually stored in the referenced variable. So, due to this current implementation detail, your code can actually be tripped up by such a weird scenario:

my $glob = *X; my $ref = bless \$glob; print ref(\$glob); __END__ main

- tye        

  • Comment on Re^4: How do I determine if a variable contains a type glob? (bless)
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1177198]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2020-09-20 06:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If at first I donít succeed, I Ö










    Results (119 votes). Check out past polls.

    Notices?