This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
In Perl_scalarvoid(), avoid creating a temporary SV for simple messages.
authorNicholas Clark <nick@ccl4.org>
Wed, 11 Jul 2012 18:24:14 +0000 (20:24 +0200)
committerNicholas Clark <nick@ccl4.org>
Tue, 31 Jul 2012 11:04:42 +0000 (13:04 +0200)
commit095b19d150eee57ee8501177d6950002977ef74c
treef799b90548e4dbcaa0b0f3483b48517370c7006e
parent7e2a0d4586762cf28c9cdfb3c49d57d805879ac9
In Perl_scalarvoid(), avoid creating a temporary SV for simple messages.

If using an SV to generate a potentially UTF-8 error message, pass that SV
onward to the code that generates warnings, and use a SV-specific format.
Otherwise use a %s format and pass the char * pointer directly to
Perl_ck_warner(). This avoids creating a temporary SV just to hold a fixed
ASCII string, but retains the ability to generate clean UTF-8 error messages.
op.c