J
Julian Lafontaine
Hi Group,
There are two syntax for the "use constant" pragma: to declare a scalar
or to declare a list.
use constant CONST => scalarvalue;
use constant LIST => qw( listitem1, listitem2, listitem3);
I've found this in a perl module :Win32::Exe.
Could someone explain the syntax?
use constant DISPATCH_TABLE => (
"PE\0\0" => "PE",
'*' => sub { die "Incorrect PE header -- not a valid .exe file" },
);
What is DISPATCH_TABLE: a scalar or a list?
Thanks in advance.
There are two syntax for the "use constant" pragma: to declare a scalar
or to declare a list.
use constant CONST => scalarvalue;
use constant LIST => qw( listitem1, listitem2, listitem3);
I've found this in a perl module :Win32::Exe.
Could someone explain the syntax?
use constant DISPATCH_TABLE => (
"PE\0\0" => "PE",
'*' => sub { die "Incorrect PE header -- not a valid .exe file" },
);
What is DISPATCH_TABLE: a scalar or a list?
Thanks in advance.