Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Re: undefining one slot of a typeglob

by AidanLee (Chaplain)
on Feb 24, 2004 at 06:15 UTC ( [id://331329]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    if    ($type eq 'SCALAR') { undef ${*{$glob}} ;}
      elsif ($type eq 'ARRAY')  { undef @{*{$glob}} ;}
      elsif ($type eq 'HASH')   { undef %{*{$glob}} ;}
      elsif ($type eq 'CODE')   { undef &{*{$glob}} ;}
      elsif ($type eq 'IO')     { close *{$glob} ;}
    
  2. or download this
    ($type eq 'IO') ? close *{$glob} : undef *{$glob}{$type};
    
  3. or download this
    undef *{$glob}{$type};
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2024-04-23 07:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found