ext/Devel-PPPort/parts/inc/exception Devel::PPPort include
ext/Devel-PPPort/parts/inc/format Devel::PPPort include
ext/Devel-PPPort/parts/inc/grok Devel::PPPort include
+ext/Devel-PPPort/parts/inc/gv Devel::PPPort include
+ext/Devel-PPPort/parts/inc/HvNAME Devel::PPPort include
ext/Devel-PPPort/parts/inc/limits Devel::PPPort include
ext/Devel-PPPort/parts/inc/magic Devel::PPPort include
ext/Devel-PPPort/parts/inc/memory Devel::PPPort include
ext/Devel-PPPort/parts/inc/MY_CXT Devel::PPPort include
ext/Devel-PPPort/parts/inc/newCONSTSUB Devel::PPPort include
ext/Devel-PPPort/parts/inc/newRV Devel::PPPort include
+ext/Devel-PPPort/parts/inc/newSV_type Devel::PPPort include
ext/Devel-PPPort/parts/inc/newSVpv Devel::PPPort include
ext/Devel-PPPort/parts/inc/podtest Devel::PPPort include
ext/Devel-PPPort/parts/inc/ppphbin Devel::PPPort include
ext/Devel-PPPort/t/exception.t Devel::PPPort test file
ext/Devel-PPPort/t/format.t Devel::PPPort test file
ext/Devel-PPPort/t/grok.t Devel::PPPort test file
+ext/Devel-PPPort/t/gv.t Devel::PPPort test file
+ext/Devel-PPPort/t/HvNAME.t Devel::PPPort test file
ext/Devel-PPPort/t/limits.t Devel::PPPort test file
ext/Devel-PPPort/t/magic.t Devel::PPPort test file
ext/Devel-PPPort/t/memory.t Devel::PPPort test file
ext/Devel-PPPort/t/MY_CXT.t Devel::PPPort test file
ext/Devel-PPPort/t/newCONSTSUB.t Devel::PPPort test file
ext/Devel-PPPort/t/newRV.t Devel::PPPort test file
+ext/Devel-PPPort/t/newSV_type.t Devel::PPPort test file
ext/Devel-PPPort/t/newSVpv.t Devel::PPPort test file
ext/Devel-PPPort/TODO Devel::PPPort Todo
ext/Devel-PPPort/t/podtest.t Devel::PPPort test file
+3.18_01 - 2009-06-12
+
+ * fix CPAN #44614: Please support XSBODY
+ * fix CPAN #44655: Please support SVfARG
+ * added support for the following API
+ gv_fetchpvn_flags
+ gv_fetchpvs
+ gv_stashpvs
+ GvSVn
+ HvNAME_get
+ HvNAMELEN_get
+ isGV_with_GP
+ newSV_type
+ PL_error_count
+ PL_in_my
+ PL_in_my_stash
+ SVfARG
+ XSPROTO
+ (thanks to Goro Fuji for providing a patch to
+ implement almost all of these, fixes CPAN #44087)
+
3.18 - 2009-06-12
* remove MAN3PODS option from Makefile.PL, which is
#
################################################################################
#
-# $Revision: 31 $
+# $Revision: 30 $
# $Author: mhx $
-# $Date: 2009/06/12 12:45:44 +0200 $
+# $Date: 2009/06/12 04:07:05 +0200 $
#
################################################################################
#
#
################################################################################
#
-# $Revision: 64 $
+# $Revision: 65 $
# $Author: mhx $
-# $Date: 2009/01/18 14:10:49 +0100 $
+# $Date: 2009/06/12 04:10:36 +0200 $
#
################################################################################
#
#
################################################################################
#
-# $Revision: 64 $
+# $Revision: 65 $
# $Author: mhx $
-# $Date: 2009/01/18 14:10:49 +0100 $
+# $Date: 2009/06/12 04:10:36 +0200 $
#
################################################################################
#
use strict;
use vars qw($VERSION $data);
-$VERSION = do { my @r = '$Snapshot: /Devel-PPPort/3.18 $' =~ /(\d+\.\d+(?:_\d+)?)/; @r ? $r[0] : '9.99' };
+$VERSION = do { my @r = '$Snapshot: /Devel-PPPort/3.18_01 $' =~ /(\d+\.\d+(?:_\d+)?)/; @r ? $r[0] : '9.99' };
sub _init_data
{
%include SvREFCNT
+%include newSV_type
+
%include newSVpv
%include SvPV
%include shared_pv
+%include HvNAME
+
+%include gv
+
%include warn
%include pvs
#
################################################################################
#
-# $Revision: 32 $
+# $Revision: 31 $
# $Author: mhx $
-# $Date: 2009/06/12 12:46:07 +0200 $
+# $Date: 2009/06/11 20:53:42 +0200 $
#
################################################################################
#
#
################################################################################
#
-# $Revision: 34 $
+# $Revision: 35 $
# $Author: mhx $
-# $Date: 2009/01/18 14:10:51 +0100 $
+# $Date: 2009/06/12 12:29:35 +0200 $
#
################################################################################
#
#define NEED_my_strlcpy
#define NEED_newCONSTSUB
#define NEED_newRV_noinc
+#define NEED_newSV_type
#define NEED_newSVpvn_share
#define NEED_pv_display
#define NEED_pv_escape
--- /dev/null
+################################################################################
+##
+## $Revision: 1 $
+## $Author: mhx $
+## $Date: 2009/06/12 12:29:57 +0200 $
+##
+################################################################################
+##
+## Version 3.x, Copyright (C) 2004-2009, Marcus Holland-Moritz.
+## Version 2.x, Copyright (C) 2001, Paul Marquess.
+## Version 1.x, Copyright (C) 1999, Kenneth Albanowski.
+##
+## This program is free software; you can redistribute it and/or
+## modify it under the same terms as Perl itself.
+##
+################################################################################
+
+=provides
+
+__UNDEFINED__
+
+=implementation
+
+__UNDEFINED__ HvNAME_get(hv) HvNAME(hv)
+
+__UNDEFINED__ HvNAMELEN_get(hv) (HvNAME_get(hv) ? (I32)strlen(HvNAME_get(hv)) : 0)
+
+=xsubs
+
+char*
+HvNAME_get(hv)
+ HV *hv
+
+int
+HvNAMELEN_get(hv)
+ HV *hv
+
+=tests plan => 4
+
+ok(Devel::PPPort::HvNAME_get(\%Devel::PPPort::), 'Devel::PPPort');
+ok(Devel::PPPort::HvNAME_get({}), undef);
+
+ok(Devel::PPPort::HvNAMELEN_get(\%Devel::PPPort::), length('Devel::PPPort'));
+ok(Devel::PPPort::HvNAMELEN_get({}), 0);
+
--- /dev/null
+################################################################################
+##
+## $Revision: 1 $
+## $Author: mhx $
+## $Date: 2009/06/12 12:29:56 +0200 $
+##
+################################################################################
+##
+## Version 3.x, Copyright (C) 2004-2009, Marcus Holland-Moritz.
+## Version 2.x, Copyright (C) 2001, Paul Marquess.
+## Version 1.x, Copyright (C) 1999, Kenneth Albanowski.
+##
+## This program is free software; you can redistribute it and/or
+## modify it under the same terms as Perl itself.
+##
+################################################################################
+
+=provides
+
+__UNDEFINED__
+
+=implementation
+
+__UNDEFINED__ GvSVn(gv) GvSV(gv)
+__UNDEFINED__ isGV_with_GP(gv) isGV(gv)
+
+=xsubs
+
+int
+GvSVn()
+ PREINIT:
+ GV* gv;
+ CODE:
+ RETVAL = 0;
+ gv = gv_fetchpvs("Devel::PPPort::GvTest", GV_ADDMULTI, SVt_PVGV);
+ if (GvSVn(gv) != NULL)
+ {
+ RETVAL++;
+ }
+ OUTPUT:
+ RETVAL
+
+int
+isGV_with_GP()
+ PREINIT:
+ GV* gv;
+ CODE:
+ RETVAL = 0;
+ gv = gv_fetchpvs("Devel::PPPort::GvTest", GV_ADDMULTI, SVt_PVGV);
+ if (isGV_with_GP(gv))
+ {
+ RETVAL++;
+ }
+ if (!isGV(&PL_sv_undef))
+ {
+ RETVAL++;
+ }
+ OUTPUT:
+ RETVAL
+
+
+=tests plan => 2
+
+ok(Devel::PPPort::GvSVn(), 1);
+
+ok(Devel::PPPort::isGV_with_GP(), 2)
################################################################################
##
-## $Revision: 52 $
+## $Revision: 53 $
## $Author: mhx $
-## $Date: 2009/03/15 06:51:00 +0100 $
+## $Date: 2009/03/31 23:05:55 +0200 $
##
################################################################################
##
} STMT_END
#endif
+__UNDEFINED__ XSPROTO(name) void name(pTHX_ CV* cv)
+__UNDEFINED__ SVfARG(p) ((void*)(p))
+
__UNDEFINED__ PERL_ABS(x) ((x) < 0 ? -(x) : (x))
__UNDEFINED__ dVAR dNOOP
=xsmisc
+typedef XSPROTO(XSPROTO_test_t);
+typedef XSPROTO_test_t *XSPROTO_test_t_ptr;
+
XS(XS_Devel__PPPort_dXSTARG); /* prototype */
XS(XS_Devel__PPPort_dXSTARG)
{
=xsboot
-newXS("Devel::PPPort::dXSTARG", XS_Devel__PPPort_dXSTARG, file);
+{
+ XSPROTO_test_t_ptr p = &XS_Devel__PPPort_dXSTARG;
+ newXS("Devel::PPPort::dXSTARG", *p, file);
+}
newXS("Devel::PPPort::dAXMARK", XS_Devel__PPPort_dAXMARK, file);
=xsubs
SV *x
PPCODE:
#if { VERSION >= 5.004 }
- x = sv_2mortal(newSVpvf("[%"SVf"]", x));
+ x = sv_2mortal(newSVpvf("[%"SVf"]", SVfARG(x)));
#endif
XPUSHs(x);
XSRETURN(1);
--- /dev/null
+################################################################################
+##
+## $Revision: 1 $
+## $Author: mhx $
+## $Date: 2009/06/12 12:29:57 +0200 $
+##
+################################################################################
+##
+## Version 3.x, Copyright (C) 2004-2009, Marcus Holland-Moritz.
+## Version 2.x, Copyright (C) 2001, Paul Marquess.
+## Version 1.x, Copyright (C) 1999, Kenneth Albanowski.
+##
+## This program is free software; you can redistribute it and/or
+## modify it under the same terms as Perl itself.
+##
+################################################################################
+
+=provides
+
+newSV_type
+
+=implementation
+
+#ifndef newSV_type
+
+#if { NEED newSV_type }
+
+SV*
+newSV_type(pTHX_ svtype const t)
+{
+ SV* const sv = newSV(0);
+ sv_upgrade(sv, t);
+ return sv;
+}
+
+#endif
+
+#endif
+
+=xsinit
+
+#define NEED_newSV_type
+
+=xsubs
+
+int
+newSV_type()
+ PREINIT:
+ SV* sv;
+ CODE:
+ RETVAL = 0;
+ sv = newSV_type(SVt_NULL);
+ if (SvTYPE(sv) == SVt_NULL)
+ {
+ RETVAL++;
+ }
+ SvREFCNT_dec(sv);
+
+ sv = newSV_type(SVt_PVIV);
+ if (SvTYPE(sv) == SVt_PVIV)
+ {
+ RETVAL++;
+ }
+ SvREFCNT_dec(sv);
+
+ sv = newSV_type(SVt_PVHV);
+ if (SvTYPE(sv) == SVt_PVHV)
+ {
+ RETVAL++;
+ }
+ SvREFCNT_dec(sv);
+
+ sv = newSV_type(SVt_PVAV);
+ if (SvTYPE(sv) == SVt_PVAV)
+ {
+ RETVAL++;
+ }
+ SvREFCNT_dec(sv);
+ OUTPUT:
+ RETVAL
+
+
+=tests plan => 1
+
+ok(Devel::PPPort::newSV_type(), 4);
+
################################################################################
##
-## $Revision: 9 $
+## $Revision: 11 $
## $Author: mhx $
-## $Date: 2009/01/18 14:10:52 +0100 $
+## $Date: 2009/06/12 12:19:15 +0200 $
##
################################################################################
##
__UNDEFINED__ hv_fetchs(hv, key, lval) hv_fetch(hv, key "", sizeof(key) - 1, lval)
__UNDEFINED__ hv_stores(hv, key, val) hv_store(hv, key "", sizeof(key) - 1, val, 0)
+__UNDEFINED__ gv_fetchpvn_flags(name, len, flags, svt) gv_fetchpv(name, flags, svt)
+__UNDEFINED__ gv_fetchpvs(name, flags, svt) gv_fetchpvn_flags(name "", sizeof(name) - 1, flags, svt)
+__UNDEFINED__ gv_stashpvs(name, flags) gv_stashpvn(name "", sizeof(name) - 1, flags)
+
=xsubs
void
PPCODE:
(void) hv_stores((HV *) SvRV(hv), "hv_stores", SvREFCNT_inc_simple(sv));
-=tests plan => 8
+SV*
+gv_fetchpvn_flags()
+ CODE:
+ RETVAL = newRV_inc((SV*)gv_fetchpvn_flags("Devel::PPPort::VERSION", sizeof("Devel::PPPort::VERSION")-1, 0, SVt_PV));
+ OUTPUT:
+ RETVAL
+
+SV*
+gv_fetchpvs()
+ CODE:
+ RETVAL = newRV_inc((SV*)gv_fetchpvs("Devel::PPPort::VERSION", 0, SVt_PV));
+ OUTPUT:
+ RETVAL
+
+SV*
+gv_stashpvs()
+ CODE:
+ RETVAL = newRV_inc((SV*)gv_stashpvs("Devel::PPPort", 0));
+ OUTPUT:
+ RETVAL
+
+
+=tests plan => 11
my $x = 'foo';
ok(exists $h{'hv_stores'});
ok($h{'hv_stores'}, 4711);
ok(Devel::PPPort::hv_fetchs(\%h), 42);
+ok(Devel::PPPort::gv_fetchpvn_flags(), \*Devel::PPPort::VERSION);
+ok(Devel::PPPort::gv_fetchpvs(), \*Devel::PPPort::VERSION);
+ok(Devel::PPPort::gv_stashpvs(), \%Devel::PPPort::);
################################################################################
##
-## $Revision: 19 $
+## $Revision: 20 $
## $Author: mhx $
-## $Date: 2009/01/18 14:10:53 +0100 $
+## $Date: 2009/06/12 04:10:50 +0200 $
##
################################################################################
##
PL_dirty
PL_dowarn
PL_errgv
+PL_error_count
PL_expect
PL_hexdigit
PL_hints
+PL_in_my
+PL_in_my_stash
PL_laststatval
PL_lex_state
PL_lex_stuff
# define PL_dirty dirty
# define PL_dowarn dowarn
# define PL_errgv errgv
+# define PL_error_count error_count
# define PL_expect expect
# define PL_hexdigit hexdigit
# define PL_hints hints
+# define PL_in_my in_my
# define PL_laststatval laststatval
# define PL_lex_state lex_state
# define PL_lex_stuff lex_stuff
# define PL_lex_state D_PPP_my_PL_parser_var(lex_state)
# define PL_lex_stuff D_PPP_my_PL_parser_var(lex_stuff)
# define PL_tokenbuf D_PPP_my_PL_parser_var(tokenbuf)
+# define PL_in_my D_PPP_my_PL_parser_var(in_my)
+# define PL_in_my_stash D_PPP_my_PL_parser_var(in_my_stash)
+# define PL_error_count D_PPP_my_PL_parser_var(error_count)
+
#else
count++; \
} STMT_END
+#define ppp_PARSERVAR_dummy STMT_START { \
+ mXPUSHi(1); \
+ count++; \
+ } STMT_END
+
#if { VERSION < 5.004 }
# define ppp_rsfp_t FILE *
#else
# define ppp_lex_state_t U8
#endif
+#if { VERSION < 5.6.0 }
+# define ppp_in_my_t bool
+#elif { VERSION < 5.9.5 }
+# define ppp_in_my_t I32
+#else
+# define ppp_in_my_t U16
+#endif
+
+#if { VERSION < 5.9.5 }
+# define ppp_error_count_t I32
+#else
+# define ppp_error_count_t U8
+#endif
+
=xsubs
int
ppp_PARSERVAR(char *, PL_bufend);
ppp_PARSERVAR(ppp_lex_state_t, PL_lex_state);
ppp_PARSERVAR(SV *, PL_lex_stuff);
-
+ ppp_PARSERVAR(ppp_error_count_t, PL_error_count);
+ ppp_PARSERVAR(ppp_in_my_t, PL_in_my);
+#if { VERSION >= 5.5.0 }
+ ppp_PARSERVAR(HV*, PL_in_my_stash);
+#else
+ ppp_PARSERVAR_dummy;
+#endif
XSRETURN(count);
int
int
dummy_parser_warning()
-=tests plan => 49
+=tests plan => 52
ok(Devel::PPPort::compare_PL_signals());
use List::Util qw(max);
use Config;
-my $VERSION = do { my @r = '$Snapshot: /Devel-PPPort/3.18 $' =~ /(\d+\.\d+(?:_\d+)?)/; @r ? $r[0] : '9.99' };
+my $VERSION = do { my @r = '$Snapshot: /Devel-PPPort/3.18_01 $' =~ /(\d+\.\d+(?:_\d+)?)/; @r ? $r[0] : '9.99' };
$| = 1;
my %OPT = (
--- /dev/null
+################################################################################
+#
+# !!!!! Do NOT edit this file directly! !!!!!
+#
+# Edit mktests.PL and/or parts/inc/HvNAME instead.
+#
+# This file was automatically generated from the definition files in the
+# parts/inc/ subdirectory by mktests.PL. To learn more about how all this
+# works, please read the F<HACKERS> file that came with this distribution.
+#
+################################################################################
+
+BEGIN {
+ if ($ENV{'PERL_CORE'}) {
+ chdir 't' if -d 't';
+ @INC = ('../lib', '../ext/Devel-PPPort/t') if -d '../lib' && -d '../ext';
+ require Config; import Config;
+ use vars '%Config';
+ if (" $Config{'extensions'} " !~ m[ Devel/PPPort ]) {
+ print "1..0 # Skip -- Perl configured without Devel::PPPort module\n";
+ exit 0;
+ }
+ }
+ else {
+ unshift @INC, 't';
+ }
+
+ sub load {
+ eval "use Test";
+ require 'testutil.pl' if $@;
+ }
+
+ if (4) {
+ load();
+ plan(tests => 4);
+ }
+}
+
+use Devel::PPPort;
+use strict;
+$^W = 1;
+
+package Devel::PPPort;
+use vars '@ISA';
+require DynaLoader;
+@ISA = qw(DynaLoader);
+bootstrap Devel::PPPort;
+
+package main;
+
+ok(Devel::PPPort::HvNAME_get(\%Devel::PPPort::), 'Devel::PPPort');
+ok(Devel::PPPort::HvNAME_get({}), undef);
+
+ok(Devel::PPPort::HvNAMELEN_get(\%Devel::PPPort::), length('Devel::PPPort'));
+ok(Devel::PPPort::HvNAMELEN_get({}), 0);
+
--- /dev/null
+################################################################################
+#
+# !!!!! Do NOT edit this file directly! !!!!!
+#
+# Edit mktests.PL and/or parts/inc/gv instead.
+#
+# This file was automatically generated from the definition files in the
+# parts/inc/ subdirectory by mktests.PL. To learn more about how all this
+# works, please read the F<HACKERS> file that came with this distribution.
+#
+################################################################################
+
+BEGIN {
+ if ($ENV{'PERL_CORE'}) {
+ chdir 't' if -d 't';
+ @INC = ('../lib', '../ext/Devel-PPPort/t') if -d '../lib' && -d '../ext';
+ require Config; import Config;
+ use vars '%Config';
+ if (" $Config{'extensions'} " !~ m[ Devel/PPPort ]) {
+ print "1..0 # Skip -- Perl configured without Devel::PPPort module\n";
+ exit 0;
+ }
+ }
+ else {
+ unshift @INC, 't';
+ }
+
+ sub load {
+ eval "use Test";
+ require 'testutil.pl' if $@;
+ }
+
+ if (2) {
+ load();
+ plan(tests => 2);
+ }
+}
+
+use Devel::PPPort;
+use strict;
+$^W = 1;
+
+package Devel::PPPort;
+use vars '@ISA';
+require DynaLoader;
+@ISA = qw(DynaLoader);
+bootstrap Devel::PPPort;
+
+package main;
+
+ok(Devel::PPPort::GvSVn(), 1);
+
+ok(Devel::PPPort::isGV_with_GP(), 2)
+
--- /dev/null
+################################################################################
+#
+# !!!!! Do NOT edit this file directly! !!!!!
+#
+# Edit mktests.PL and/or parts/inc/newSV_type instead.
+#
+# This file was automatically generated from the definition files in the
+# parts/inc/ subdirectory by mktests.PL. To learn more about how all this
+# works, please read the F<HACKERS> file that came with this distribution.
+#
+################################################################################
+
+BEGIN {
+ if ($ENV{'PERL_CORE'}) {
+ chdir 't' if -d 't';
+ @INC = ('../lib', '../ext/Devel-PPPort/t') if -d '../lib' && -d '../ext';
+ require Config; import Config;
+ use vars '%Config';
+ if (" $Config{'extensions'} " !~ m[ Devel/PPPort ]) {
+ print "1..0 # Skip -- Perl configured without Devel::PPPort module\n";
+ exit 0;
+ }
+ }
+ else {
+ unshift @INC, 't';
+ }
+
+ sub load {
+ eval "use Test";
+ require 'testutil.pl' if $@;
+ }
+
+ if (1) {
+ load();
+ plan(tests => 1);
+ }
+}
+
+use Devel::PPPort;
+use strict;
+$^W = 1;
+
+package Devel::PPPort;
+use vars '@ISA';
+require DynaLoader;
+@ISA = qw(DynaLoader);
+bootstrap Devel::PPPort;
+
+package main;
+
+ok(Devel::PPPort::newSV_type(), 4);
+
require 'testutil.pl' if $@;
}
- if (8) {
+ if (11) {
load();
- plan(tests => 8);
+ plan(tests => 11);
}
}
ok(exists $h{'hv_stores'});
ok($h{'hv_stores'}, 4711);
ok(Devel::PPPort::hv_fetchs(\%h), 42);
+ok(Devel::PPPort::gv_fetchpvn_flags(), \*Devel::PPPort::VERSION);
+ok(Devel::PPPort::gv_fetchpvs(), \*Devel::PPPort::VERSION);
+ok(Devel::PPPort::gv_stashpvs(), \%Devel::PPPort::);
require 'testutil.pl' if $@;
}
- if (49) {
+ if (52) {
load();
- plan(tests => 49);
+ plan(tests => 52);
}
}
#
################################################################################
#
-# $Revision: 8 $
+# $Revision: 9 $
# $Author: mhx $
-# $Date: 2009/01/18 14:10:48 +0100 $
+# $Date: 2009/06/12 04:07:19 +0200 $
#
################################################################################
#
UV T_UV
NV T_NV
+HV * T_HVREF
INPUT
T_UV
$var = ($type)SvUV($arg)
T_NV
$var = ($type)SvNV($arg)
+T_HVREF
+ if (SvROK($arg) && SvTYPE(SvRV($arg))==SVt_PVHV)
+ $var = (HV*)SvRV($arg);
+ else
+ Perl_croak(aTHX_ \"$var is not a hash reference\")
OUTPUT
T_UV