Dynaloader: use PREINIT to avoid compiler errors
authorDavid Mitchell <davem@iabyn.com>
Tue, 26 Nov 2013 13:29:08 +0000 (13:29 +0000)
committerDavid Mitchell <davem@iabyn.com>
Tue, 26 Nov 2013 13:29:08 +0000 (13:29 +0000)
commit3e584864f634c8ccfaa48b2ffec64644d3b2c011
tree35536b7292ab592c2bedf88e3880af68eba8a0f1
parentdf9e1087beb66b5a5eb28ff3c2f0756f25256bc4
Dynaloader: use PREINIT to avoid compiler errors

A recent change to the typmap definitions makes a var declaration
generate code. Move this declaration from CODE: to PREINIT: to avoid a
'Mixed declarations' compiler error.

This was spotted in dl_hpux.xs by bulk88, which I've blindly fixed.
From visual inspection there were also declarations in dl_vms.xs
that needed moving (although in that case it dosen't trigger the typemap
code emission).
ext/DynaLoader/dl_hpux.xs
ext/DynaLoader/dl_vms.xs