Perl Monk, Perl Meditation | |
PerlMonks |
Looking for a function that returns status of a scalar's numeric flagsby syphilis (Archbishop) |
on Mar 22, 2020 at 06:06 UTC ( [id://11114538]=perlquestion: print w/replies, xml ) | Need Help?? |
syphilis has asked for the wisdom of the Perl Monks concerning the following question:
Hi, By "numeric flags", I'm referring to the "IOK", "pIOK", "NOK", "pNOK" and the "IsUV" flags (as presented by Devel::Peek::Dump). But rather than have this information displayed, I'm looking for a sub that returns the status of these specific flags. That is, something like: The aim is to be able to determine whether a subroutine call changes the status of any of those flags on the subroutine's argument. That is: Is there already a perl module that ships with the core that will return the status of those 5 flags ? Is there already a module on CPAN that will return the status of those 5 flags ? I know how to find the status of "IOK", "NOK" and "IsUV" in XS. One can merely test the truth of SvIOK(sv), SvNOK(sv) and SvUOK(sv) respectively. But how does one establish, in XS, whether the "pIOK" and "pNOK" flags are set ? Maybe there's another way to approach this. The key thing is that I want to be able to programmatically catch the occurrence of foo() altering its argument's "numeric flags". Cheers, Rob
Back to
Seekers of Perl Wisdom
|
|