Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
Even without knowing that .3pm indicates a man page, there's a pretty strong clue in that the full path of the file includes a .../man/... directory.

As for why your code couldn't find the file to (try to) use it, note that the filename is Search::Elasticsearch.3pm, but the error message indicates that Perl was trying to find a module named Search/Elasticsearch.pm - use converts :: to /, while the filename contains a literal ::, in addition to the extension being different.

Of course, if you really wanted to, you could pass the filename as a string (rather than a bareword) to require and get Perl to try to load it as a module that way, despite the literal colons and the extension... but it would still fail, because the file content is written in troff markup rather than Perl code and/or POD markup, so the result would be an ugly mess of syntax errors instead of working code:

~$ perl -E "require '/usr/local/share/man/man3/oo.3pm'" Bareword found where operator expected at /usr/local/share/man/man3/oo +.3pm line 2, near "*(C" (Missing operator before C?) String found where operator expected at /usr/local/share/man/man3/oo.3 +pm line 4, near ". ds C` "" (Missing semicolon on previous line?) String found where operator expected at /usr/local/share/man/man3/oo.3 +pm line 5, near ". ds C' "" (Missing semicolon on previous line?) String found where operator expected at /usr/local/share/man/man3/oo.3 +pm line 6, near ". ds L"" (Missing semicolon on previous line?) <...a few dozen more lines of the same omitted...> String found where operator expected at /usr/local/share/man/man3/oo.3 +pm line 22, at end of line (Missing semicolon on previous line?) Can't find string terminator '"' anywhere before EOF at /usr/local/sha +re/man/man3/oo.3pm line 22. Compilation failed in require at -e line 1.

In reply to Re: cpan installing .3pm files? by dsheroh
in thread cpan installing .3pm files? by merlinsdemon

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



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2024-04-25 11:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found