On Tue, 15 Nov 2005, Sisyphus wrote: > The following code works fine on my Windows2000 box: > > use warnings; > print Win32::IsWinNT(); > > How come it is unnecessary to explicitly load the Win32 module ? > > Is it possible to write and install a non-core module in such a way that it > doesn't need to be explicitly loaded - or is this something that can only be > achieved when perl itself is being built ?
These functions are built into Perl itself. Please read `perldoc Win32`. The functions marked with [CORE] are built into Perl while the ones marked with [EXT] are part of the Win32 module and are only available if you load the module. This is strictly due to historical reasons and I really wish this namespace wasn't split up this way. This can't really be fixed anymore for backwards compatibility reasons now. > Are there other modules that, similarly, don't need to be loaded ? There are a couple of others, e.g. UNIVERSAL::isa, UNIVERSAL::can, UNIVERSAL::VERSION, attributes::bootstrap, DynaLoader::boot_DynaLoader, RegExp::DESTROY. There are more (at least in the Internals::, PerlIO::, and utf8:: namespaces), but I'm too lazy to investigate... :) I don't understand why this would be important. Cheers, -Jan _______________________________________________ Perl-Win32-Users mailing list [email protected] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
