blob: 162308b4a0df6c5e6c1cfbcc5c113bc16afb9eae (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
######################################################################
# INPUT/OUTPUT maps
# O_OBJECT -> links an opaque C object to a blessed Perl object.
#
TYPEMAP
pmUnits T_INT_EQUIV
pmID T_INT_EQUIV
pmInDom T_INT_EQUIV
######################################################################
INPUT
# struct or typedef that is really the same size as a 32-bit integer
T_INT_EQUIV
{
__int32_t tmp = SvIV($arg);
memcpy((void *)&$var, (void *)&tmp, sizeof(__int32_t));
}
######################################################################
OUTPUT
# struct or typedef that is really the same size as a 32-bit integer
T_INT_EQUIV
sv_setiv($arg, *((int *)&$var));
######################################################################
|