in reply to Re: Class::Interface -- isa() Considered Harmful
in thread Class::Interface -- isa() Considered Harmful
You can write INIT { } as sub INIT { } - that would be the easiest fix. Such INIT blocks will then work as INIT blocks in newer Perls and fulfill the syntax constraints of earlier ones. Alternatively, if you have several INIT blocks, you could define a sub INIT (&) { ... } or similar - however, that should be done depending on version since it will change the semantics of INIT { } for newer Perls as well.
The question is inhowfar these can be considered to compile "as expected", since the compilation stage specific behaviour is lost. It's in the nature of modules such as this one to require finer control of execution time than what the "blunt" BEGIN block offers, and in that case you're out of luck since old Perls just don't offer that no matter what.
Makeshifts last the longest.
|
|---|