From: Nicholas Clark Date: Sun, 2 Nov 2003 22:32:21 +0000 (+0000) Subject: Provide Internals::new_hash_seed to return PL_new_hash_seed, and X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=8e90d776335dcf68d19230bed1f95b7f5237577b;p=p5sagit%2Fp5-mst-13.2.git Provide Internals::new_hash_seed to return PL_new_hash_seed, and make Hash::Util::hash_seed use this. p4raw-id: //depot/perl@21634 --- diff --git a/lib/Hash/Util.pm b/lib/Hash/Util.pm index c5d3059..03308c8 100644 --- a/lib/Hash/Util.pm +++ b/lib/Hash/Util.pm @@ -196,7 +196,7 @@ See also L. =cut sub hash_seed () { - Internals::hash_seed(); + Internals::new_hash_seed(); } =back diff --git a/universal.c b/universal.c index 9a8ec1b..e877b31 100644 --- a/universal.c +++ b/universal.c @@ -188,6 +188,7 @@ XS(XS_Internals_hv_clear_placehold); XS(XS_PerlIO_get_layers); XS(XS_Regexp_DESTROY); XS(XS_Internals_hash_seed); +XS(XS_Internals_new_hash_seed); XS(XS_Internals_HvREHASH); void @@ -233,6 +234,8 @@ Perl_boot_core_UNIVERSAL(pTHX) XS_PerlIO_get_layers, file, "*;@"); newXS("Regexp::DESTROY", XS_Regexp_DESTROY, file); newXSproto("Internals::hash_seed",XS_Internals_hash_seed, file, ""); + newXSproto("Internals::new_hash_seed",XS_Internals_new_hash_seed, file, + ""); newXSproto("Internals::HvREHASH", XS_Internals_HvREHASH, file, "\\%"); } @@ -918,6 +921,14 @@ XS(XS_Internals_hash_seed) XSRETURN_UV(PERL_HASH_SEED); } +XS(XS_Internals_new_hash_seed) +{ + /* Using dXSARGS would also have dITEM and dSP, + * which define 2 unused local variables. */ + dMARK; dAX; + XSRETURN_UV(PL_new_hash_seed); +} + XS(XS_Internals_HvREHASH) /* Subject to change */ { dXSARGS;