Hello,
I posted this earlier to irssi-users, but after investigating it a bit
more I think it might be related to the src/perl/ui/Window.c file.
Basically, the problem is that, on most computers, the following
command:
/script exec $^W=1; Irssi::windows;
(turns on warnings and calls Irssi::windows(),
just do '/script exec $^W=0;' to turn it off again)
will cause the following warnings:
Cant locate package Irssi::Nick for @Irssi::Irc::Nick::ISA at (eval
xx) line yy.
At first, I thought it was a faulty perl installation or a wrong irssi
compile, but I've seen it on over a dozen different installations of
freebsd/gentoo/debian, all running different perl/irssi(some
compiled, some packaged).
The following section of src/perl/ui/Window.c is the one causing the
warnings:
for (tmp = windows; tmp != NULL; tmp = tmp->next) {
XPUSHs(sv_2mortal(plain_bless(tmp->data, "Irssi::UI::Window")));
}
For comparison, with a different type of 'similar' cycling, Irssi::queries
is the same except(of course since it's not the same objects) in the
for loop which looks like that:
for (tmp = queries; tmp != NULL; tmp = tmp->next) {
QUERY_REC *rec = tmp->data;
XPUSHs(sv_2mortal(iobject_bless(rec)));
}
My uneducated guess would be that there is a different returning behavior
between plain_bless and iobject_bless that's causing sv_2mortal to
spit the errors somehow(since removing the sv_2mortal does not yield
the error anymore).
On another side in src/perl/ui/UI.c there's the following:
for (tmp = processes; tmp != NULL; tmp = tmp->next) {
XPUSHs(sv_2mortal(plain_bless(tmp->data,
"Irssi::UI::Process")));
}
But this one does not cause any warnings, so I'm (maybe wrongly)
assuming that it's related to "Irssi::UI::Window" with plain_bless.
Any clarification/solution/help would be really appreciated, as this error
makes pedantic/strict perl scripts very annoying to debug.
--
Best regards,
Paul-Kenji Cahier