develooper Front page | perl.perl5.porters | Postings from October 2005

[perl #36875] Certain string handling functions don't warn on undef

Steve Peters via RT
October 5, 2005 20:54
[perl #36875] Certain string handling functions don't warn on undef
Message ID:
> [ - Thu Aug 11 23:04:35 2005]:
> This is a bug report for perl from tassilo.von.parseval@rwth-
> generated with the help of perlbug 1.35 running under perl v5.8.4.
> -----------------------------------------------------------------
> [Please enter your report here]
> It appears that perl (any perl between 5.5.4 and 5.9.3) wont always
>    warn when
> an undefined value is used as an argument:
>     perl -we 'print lc(undef)'
> There will be no uninitialized-value-warning with (at least)
>    (lc|uc)(_first)?
> and reverse in scalar context.
> If this is intentional behaviour then I see no mentioning of it in the
> documentation. From a cursory glance at the source it looks as if the
>    wrong
> version of one of the many SvPV_* macros is used.
> I'll investigate further if it's agreed on that this is in fact a bug.

I also agree that this is a bug.  I do have a preliminary patch to fix
this, but I received several warnings from EU::MM when building at least
one module.  I need to investigate this further before applying my patch. Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About