From ef3af890207c78e8352e850ed9fd510c10f7db56 Mon Sep 17 00:00:00 2001 From: mdw Date: Fri, 8 Oct 2004 08:39:16 +0000 Subject: [PATCH] Fix typemap for older Perls. --- typemap | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/typemap b/typemap index e28ed73..f18025c 100644 --- a/typemap +++ b/typemap @@ -1,4 +1,6 @@ TYPEMAP +const char * T_PV + mp * T_MP gf * T_MP GE * T_CATSTRUCT @@ -45,24 +47,24 @@ INPUT T_MP $var = mp_fromsv($arg, \"$var\", \"${my $ntt = $ntype; $ntt =~ s/^(.*)Ptr$/Catacomb::\U$1/; $ntt =~ s/_/::/g; \$ntt}\", 0, 0) T_CATSTRUCT - $var = ptrfromsv($arg, \"${my $ntt = $ntype; $ntt =~ s/^(.*)Ptr$/Catacomb::$1/; $ntt =~ s/_/::/g; \$ntt}\", \"$var\"); + $var = ptrfromsv($arg, \"${my $ntt = $ntype; $ntt =~ s/^(.*)Ptr$/Catacomb::$1/; $ntt =~ s/_/::/g; \$ntt}\", \"$var\") T_GALG - $var = ptrfromsv($arg, \"${my $ntt = $ntype; $ntt =~ s/^g(.*)Ptr$/Catacomb::\u$1/; \$ntt}\", \"$var\"); + $var = ptrfromsv($arg, \"${my $ntt = $ntype; $ntt =~ s/^g(.*)Ptr$/Catacomb::\u$1/; \$ntt}\", \"$var\") T_GCALG - $var = ptrfromsv($arg, \"${my $ntt = $ntype; $ntt =~ s/^gc(.*)Ptr$/Catacomb::\u$1Class/; \$ntt}\", \"$var\"); + $var = ptrfromsv($arg, \"${my $ntt = $ntype; $ntt =~ s/^gc(.*)Ptr$/Catacomb::\u$1Class/; \$ntt}\", \"$var\") T_KEYSZ - $var = ptrfromsv($arg, \"Catacomb::KeySize\", \"$var\"); + $var = ptrfromsv($arg, \"Catacomb::KeySize\", \"$var\") T_PGENPROC if (sv_derived_from($arg, \"Catacomb::MP::Prime::Gen::Proc\")) $var = $arg; else - croak(\"$var is not of type Catacomb::MP::Prime::Gen::Proc\") + croak(\"$var is not of type Catacomb::MP::Prime::Gen::Proc\"); T_NULLPGENPROC if (!SvOK($arg) || sv_derived_from($arg, \"Catacomb::MP::Prime::Gen::Proc\")) $var = $arg; else - croak(\"$var is not of type Catacomb::MP::Prime::Gen::Proc\") + croak(\"$var is not of type Catacomb::MP::Prime::Gen::Proc\"); OUTPUT T_MP -- 2.11.0