in a C API, returning NULL is more appropriate, and the XS sub will just turn it into PL_sv_undef for me anyway