Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things

Re: Error "Compilation failed in require" with "use" syntax

by sundialsvc4 (Abbot)
on Sep 16, 2013 at 14:28 UTC ( #1054301=note: print w/replies, xml ) Need Help??

in reply to Error "Compilation failed in require" with "use" syntax

In this case, I can tell you definitively, Eclipse is not part of the problem:   you should be able to execute that command on the command-line and get identical results.

When Perl encounters a use (or require) statement, it might subsequently do a lot of compiling, as it processes not only these modules but all of their direct and indirect dependencies.   A syntax-error anywhere can produce this result, with or without Eclipse or any other IDE.

If you do not get identical results, check your local PERL5LIB and other settings to make sure that they really are identical to those that are established in the relevant (Eclipse ...) settings.   You can be quite sure that you will find some discrepancy there.

  • Comment on Re: Error "Compilation failed in require" with "use" syntax

Replies are listed 'Best First'.
Re^2: Error "Compilation failed in require" with "use" syntax
by SuzuBell (Acolyte) on Oct 03, 2013 at 22:35 UTC
    Would the error I got from what I wrote in the command line, ie.
    perl -Mlib=/Desktop/code -e'use pmFile1;'
    be considered a syntax problem? I checked the code, I do not see any other red error logos in Eclipse. Thanks...

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1054301]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (4)
As of 2018-05-26 22:43 GMT
Find Nodes?
    Voting Booth?