diff options
author | Marcus Holland-Moritz <mhx-perl@gmx.net> | 2007-01-01 21:16:13 +0100 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-01-04 15:33:16 +0000 |
commit | be2597dfdde55c276ac6c4b68dadc448c601d0cc (patch) | |
tree | aef6abfecbcea9a7241e50ad3f55ff3d733ebb35 /universal.c | |
parent | 6c9570dc5de7137a22f5d4e76431529d4f7342b7 (diff) | |
download | perl-be2597dfdde55c276ac6c4b68dadc448c601d0cc.tar.gz |
4th patch from:
Subject: [PATCH] Cleanup SVf arguments (2nd try)
Message-ID: <20070101201613.4120d9ef@r2d2>
Introduce an SVfARG() macro for %SVf (%-p here) arguments to
perl's printf
p4raw-id: //depot/perl@29687
Diffstat (limited to 'universal.c')
-rw-r--r-- | universal.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/universal.c b/universal.c index 251fbacca6..aa1bd66962 100644 --- a/universal.c +++ b/universal.c @@ -114,7 +114,7 @@ S_isa_lookup(pTHX_ HV *stash, const char *name, const HV* const name_stash, if (ckWARN(WARN_MISC)) Perl_warner(aTHX_ packWARN(WARN_SYNTAX), "Can't locate package %"SVf" for @%s::ISA", - (void*)sv, hvname); + SVfARG(sv), hvname); continue; } if (isa_lookup(basestash, name, name_stash, len, level + 1)) { @@ -456,10 +456,10 @@ XS(XS_UNIVERSAL_VERSION) if ( vcmp( req, sv ) > 0 ) Perl_croak(aTHX_ "%s version %"SVf" (%"SVf") required--" "this is only version %"SVf" (%"SVf")", HvNAME_get(pkg), - (void*)vnumify(req), - (void*)vnormal(req), - (void*)vnumify(sv), - (void*)vnormal(sv)); + SVfARG(vnumify(req)), + SVfARG(vnormal(req)), + SVfARG(vnumify(sv)), + SVfARG(vnormal(sv))); } if ( SvOK(sv) && sv_derived_from(sv, "version") ) { @@ -993,11 +993,11 @@ XS(XS_PerlIO_get_layers) else { if (namok && argok) XPUSHs(Perl_newSVpvf(aTHX_ "%"SVf"(%"SVf")", - (void*)*namsvp, - (void*)*argsvp)); + SVfARG(*namsvp), + SVfARG(*argsvp))); else if (namok) XPUSHs(Perl_newSVpvf(aTHX_ "%"SVf, - (void*)*namsvp)); + SVfARG(*namsvp))); else XPUSHs(&PL_sv_undef); nitem++; |