Just installed Inline this week.
Bravo. That's the tool I was waiting for. =o)
One suggestion for the cookbook -- what's the best way to do Boolean
returns?
For example, I'm writing an object module usine Inline C to read
complex datafiles, and want to add a small herd of boolean test methods
to check the values of certain indicators. The fields usually contain a
character indicating one of several possible states, and I want to
write methods to test for a given state and return yes or no. I'm
pretty sure I can get that working with a little testing, but my
initial attempt to return &sv_undef didn't work, and I was just
wondering what would be the simplest way to return a false value. Would
an int 0 work, or will Perl think of that as a null byte, which
evaluates to true? =o) Is it better to send back an empty string?
Actually, I'm about to try newSVpvf ("") for false, which seems pretty
safe, but is there a better way? After all, the reason I'm doing this
with Inline is because the pure Perl object, while wonderfully
flexible, is *REALLY* slow when having to read a file which is around
350MB after compression.....
__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - Buy the things you want at great prices! http://auctions.yahoo.com/