Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

RE: -c

by Maqs (Deacon)
on May 09, 2000 at 13:40 UTC ( #10733=note: print w/ replies, xml ) Need Help??


in reply to -c

In my humble opinion you can check the existance of a subroutine
or anything else verifying the symbol table of the given routine
in a way it is described in Programming Perl book (5.1.1. Symbol
tables)
.
i.e.:
#!/usr/bin/perl
&greet;

sub greet () {#some stuff here
};
foreach $symname (sort keys %main::) {
local *sym = $main::{$symname};
print "\&$symname is defined\n" if defined &sym;
}
----
This code will print out: "&greet is defined". You see, you can modufy that code to meet your taste. But the main
problem is that I didn't tested it with the incapsulated packages.

--
With best regards
Maqs.


Comment on RE: -c

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (3)
As of 2014-07-26 11:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (175 votes), past polls