ajaffres has asked for the wisdom of the Perl Monks concerning the following question:
Now I need to do the opposite, it should look like this:%typemap(in) (unsigned char *string1) { $1 = (unsigned char *)SvPV_nolen($input); }
but I don't need the length and even with the length I tried this example without success.%typemap(out) (unsigned char *output, const size_t output_length) { $result = newSVpv((char *)$1, $2); sv_2mortal($result); argvi++; delete $1; }
Edited by Chady -- added code tags.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: typemap problem
by Anonymous Monk on May 20, 2005 at 11:22 UTC | |
by ajaffres (Novice) on May 20, 2005 at 11:30 UTC | |
by Anonymous Monk on May 20, 2005 at 11:56 UTC | |
by demerphq (Chancellor) on May 20, 2005 at 12:05 UTC | |
by ajaffres (Novice) on May 20, 2005 at 12:01 UTC | |
by demerphq (Chancellor) on May 20, 2005 at 12:30 UTC | |
by Anonymous Monk on May 20, 2005 at 12:07 UTC | |
by ajaffres (Novice) on May 20, 2005 at 12:32 UTC | |
|
Re: typemap problem
by Anonymous Monk on May 20, 2005 at 11:38 UTC | |
by ajaffres (Novice) on May 20, 2005 at 11:45 UTC |