File: typemap

package info (click to toggle)
libxml-parser-perl 2.47-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,268 kB
  • sloc: xml: 3,937; perl: 2,026; makefile: 38; ansic: 27
file content (24 lines) | stat: -rw-r--r-- 538 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#
##### XML::Parser::Expat typemap
#

XML_Parser				T_PTR
Encinfo *				T_ENCOBJ

################################################################
INPUT
T_ENCOBJ
	if (sv_derived_from($arg, \"XML::Parser::Encinfo\")) {
	    IV tmp = SvIV((SV*)SvRV($arg));
	    $var = ($type) tmp;
	}
	else
	    croak(\"$var is not of type XML::Parser::Encinfo\")
################################################################
OUTPUT
T_ENCOBJ
	if ($var) {
	    sv_setref_pv($arg, \"XML::Parser::Encinfo\", (void*)$var);
	}
	else
	    $arg = &PL_sv_undef;