Please use modules, its just easier (see Simple Module Tutorial)
$ echo sub crap { ' crap '; } 1; >crap.pl $ perl -MDevel::Peek -e" require 'crap.pl' ; Dump(\&crap )" SV = RV(0x3e8cb8) at 0x3e8cac REFCNT = 1 FLAGS = (TEMP,ROK) RV = 0x3e8cbc SV = PVCV(0x9b50b4) at 0x3e8cbc REFCNT = 2 FLAGS = () COMP_STASH = 0x3e8acc "main" START = 0x9b25f4 ===> 0 ROOT = 0x9b25b8 GVGV::GV = 0x98a484 "main" :: "crap" FILE = "crap.pl" DEPTH = 0 FLAGS = 0x0 OUTSIDE_SEQ = 96 PADLIST = 0x98a4b4 PADNAME = 0x3e8c8c(0x9961c4) PAD = 0x98a4f4(0x9abc2c) OUTSIDE = 0x3e8abc (UNIQUE) $

In reply to Re: Getting perl file path from Function by Anonymous Monk
in thread Getting perl file path from Function by clintonm9

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.