in reply to Re^3: checking a set of numbers for consistency mod p
in thread checking a set of numbers for consistency mod p

> And @LanX: there's no XS code here.

This doesn't look like vanilla C

> > SV* item = *av_fetch( array, i, 0 );

Probably differing definitions of "XS" ?

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery

Replies are listed 'Best First'.
Re^5: checking a set of numbers for consistency mod p
by hv (Prior) on Apr 17, 2022 at 03:03 UTC

    SV* item = *av_fetch( array, i, 0 );

    I worry I'm simply being trolled, but: that looks absolutely like vanilla C to me. We're calling a function, passing it some arguments, getting back some sort of pointer-to-a-pointer, which we dereference and store in a new pointer variable. Clearly the function av_fetch() and the type SV will have been declared somewhere.

    The only magic here is an implicit #include <perl.h>, which brings in perl's standard typedefs, function declarations, etc. XS is a whole 'nother language that is parsed by its own compiler (xsubpp) rather than by a C compiler.