in reply to Re^2: Passing undef to XSUB
in thread Passing undef to XSUB
Though, if warnings are enabled, that produces a "Use of uninitialized value in subroutine entry..." for each undef that's passed to it - no such warning with educated_foo's rendition.int foo(ap,bp) int ap int bp PREINIT: int a, b; CODE: a = ap ? ap : -1; b = bp ? bp : -1; RETVAL = a * b; OUTPUT: RETVAL
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Passing undef to XSUB
by ikegami (Patriarch) on May 08, 2008 at 05:00 UTC | |
by syphilis (Archbishop) on May 08, 2008 at 07:32 UTC | |
|
Re^4: Passing undef to XSUB
by kyle (Abbot) on May 08, 2008 at 04:39 UTC | |
by syphilis (Archbishop) on May 08, 2008 at 07:57 UTC |