in reply to RE: Re: How do I get the name of the file from which the class was loaded?
in thread How do I get the name of the file from which the class was loaded?

Yes, it's amazing how many things can be wrong in a single post when you type it late at night. Or whenver I was typing it. {grin}

Something more like this is gonna work a whole lot better.

use vars qw(_Filename); _Filename = __FILE__;
Sorry for the wild goose chase.

-- Randal L. Schwartz, Perl hacker


Update: OK, I give up on this thread. See the right way to do it, below. {grin}
  • Comment on RE: RE: Re: How do I get the name of the file from which the class was loaded?
  • Download Code

Replies are listed 'Best First'.
RE: RE: RE: Re: How do I get the name of the file from which the class was loaded?
by Rudif (Hermit) on Oct 24, 2000 at 00:41 UTC
    >Something more like this is gonna work a whole lot better.
    > use vars qw(_Filename); > _Filename = __FILE__;<br>
    ... yes, after a tweak or two ;-)
    use strict; use vars qw( $_Filename ); $_Filename = __FILE__; print $_Filename;
    Rudif