in reply to Re^3: Defining classes and inheritance using packages within a single .pl file, without creating modules
in thread Defining classes and inheritance using packages within a single .pl file, without creating modules

I'm not sure how base has evolved over the years, but I've had problems where it died complaining it couldn't locate a module where the package was inline in the script further down, and it may indeed load an unwanted module of the same name (B is a favourite example) under similar circumstances. Fun for the whole family.

Checking $VERSION in a package, to check if the package exists, is not the best way to tackle the problems, IMO.

  • Comment on Re^4: Defining classes and inheritance using packages within a single .pl file, without creating modules
  • Download Code

Replies are listed 'Best First'.
Re^5: Defining classes and inheritance using packages within a single .pl file, without creating modules
by Anonymous Monk on Nov 29, 2006 at 13:01 UTC
    Don't blame base. If you're going to inline modules that use base, do it properly.