Dominique Pelle wrote:
> >> 2008/11/29 Bram Moolenaar wrote:
> >>
> >> > Tony Mechelynck wrote:
> >> ...[snip...]
> >> >> if_perl.xs:463: null argument where non-null required
> >> >> a line specific to Perl ver. 5.10 (included) to 6.0 (excluded).
> >> >
> >> > I actually think NULL is OK here. At least, it has always worked. I
> >> > don't know how to pass something else, one can't simply pass an empty
> >> > environment.
> >>
> >>
> >> I see this compilation warning as well. In my Perl the header file
> >> /usr/lib/perl/5.10.0/CORE/proto.h on Ubuntu-8.10, I see:
> >>
> >>
> >> PERL_CALLCONV void Perl_sys_init(int* argc, char*** argv)
> >> __attribute__nonnull__(1)
> >> __attribute__nonnull__(2);
> >>
> >> PERL_CALLCONV void Perl_sys_init3(int* argc, char*** argv, char***
> >> env)
> >> __attribute__nonnull__(1)
> >> __attribute__nonnull__(2)
> >> __attribute__nonnull__(3);
> >>
> >>
> >> The "__attribute__nonnull(3)" explains why we get the warning.
> >>
> >> We can probably call the other function Perl_sys_init(...) instead
> >> of Perl_sys_init3(...). The patch below gets rid of the compilation
> >> warning but I prefer to let the author of the Perl interface (in CC)
> >> verify whether it's correct.
> >
> > You also need to adjust the other places where "init3" appears.
> > Otherwise it looks like a good change to avoid the warning. Question is
> > if it also works with all versions of Perl.
>
>
> Perl_sys_init3(...) in Vim code appears only in between...
>
> #if (PERL_REVISION == 5) && (PERL_VERSION >= 10)
> ...
> #endif
>
> And since Perl-5.10.0 is the latest version of Perl,
> changing Perl_sys_init3 into Perl_sys_init should not
> break anything for older versions of Perl.
I suppose it's unlikely that this will fail somewhere. I'll just send
out a patch and keep fingers crossed :-).
There are a few other warnings in if_perl.xs and the generated
if_perl.c. I don't know how to avoid those.
--
ARTHUR: Be quiet!
DENNIS: --but by a two-thirds majority in the case of more--
ARTHUR: Be quiet! I order you to be quiet!
WOMAN: Order, eh -- who does he think he is?
ARTHUR: I am your king!
The Quest for the Holy Grail (Monty Python)
/// Bram Moolenaar -- [EMAIL PROTECTED] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ download, build and distribute -- http://www.A-A-P.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---