in reply to dynamiclly assigning values to global variables in modules
I think that is a very bad idea. A module should be (as much as possible) self-contained and know its own version number. If somehow other scripts need to know the version number of a module, there should be a variable or method available in that module to provide the version number. Look at many modules on CPAN: they have their version number stored in a $VERSION variable.
But perhaps I misunderstood you or perhaps you have a very good reason to externally save the version number, but then you will have to explain it more clearly.
CountZero
A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
My blog: Imperial Deltronics
|
|---|