in reply to Re^3: testing for undef in perl XS code (in DBD::ODBC)
in thread testing for undef in perl XS code (in DBD::ODBC)
There can be other perl scalars with the undef value. Actually, you can create then using SV *a = newSV(0).
With a == &PL_sv_undef you are not testing if they contain the same value but if they are both pointers to the same scalar!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: testing for undef in perl XS code (in DBD::ODBC)
by syphilis (Archbishop) on Nov 07, 2007 at 06:39 UTC |