When I try to install Crypt::TEA module to perl 5.18 on Windows 7, displayed error:
TEA.xs: In function 'XS_Crypt__TEA_crypt': TEA.xs:58:9: error: invalid use of void expression
The problem is this line:
if (SvREADONLY(output) || !SvUPGRADE(output, SVt_PV))
croak("cannot use output as lvalue");
SvUPGRADE() is a macro with two void operations, it does not return a value. It will croak if it fails. Change it to this:
if (!SvREADONLY(output))
SvUPGRADE(output, SVt_PV);