Re: Stringwise comparisons (Inline::C)

[email protected] ("Sisyphus")
Newsgroups perl.inline
Message-ID <90B9B4233FD84D8782C7FDB043198B12@desktop2>
----- Original Message ----- 
From: "David Oswald"

> But for this:
>
> bsearch_str $needle, @haystack
>
> I wouldn't be calling out to a subroutine implemented in Perl, but
> rather, to a Perl internal built-in that does comparisons.
>
> The [email protected] mailing list has been completely silent on my
> request for suggestions.  Max Maischein (Corion) has been helpful,
> with this suggestion over at PerlMonks:
>
>        Corion says: I think you'll need to call the appropriate OP,
>        which seems (wildly guessing) to be pp_scmp in pp.c.
>        Or appropriate the code from there.

Yep, if you can't re-structure the code to call a perl sub then, afaik, 
you'll have to do as Corion has suggested.

> Once I figure it out it actually may make a good addition to the
> Inline::C cookbook.

Yes, I think so.

Cheers,
Rob
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.