in reply to Perl_call_pv(, , G_ARRAY) returns references as integer type SVt_IV
SvTYPE() merely tells you the type of the storage container; it doesn't in general say what the logical type of the SV is.
Since 5.12.0, the SVt_RV sv type has been abolished, on the grounds that the SVt_IV container type is perfectly capable of holding a reference.
In general you shouldn't be basing code on tests like SvTYPE(sv) == SVt_RV; instead you should be testing the relevant flags, e.g.:
if (SvROK(sv)) ref = SvRV(sv);
Dave.
In Section
Seekers of Perl Wisdom