3 * Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
4 * 2003, 2004, 2005, 2006, 2007, 2008 by Larry Wall and others
6 * You may distribute under the terms of either the GNU General Public
7 * License or the Artistic License, as specified in the README file.
11 #ifndef _INC_PERL_XSUB_H
12 #define _INC_PERL_XSUB_H 1
14 /* first, some documentation for xsubpp-generated items */
17 =head1 Variables created by C<xsubpp> and C<xsubpp> internal functions
19 =for apidoc Amn|char*|CLASS
20 Variable which is setup by C<xsubpp> to indicate the
21 class name for a C++ XS constructor. This is always a C<char*>. See C<THIS>.
23 =for apidoc Amn|(whatever)|RETVAL
24 Variable which is setup by C<xsubpp> to hold the return value for an
25 XSUB. This is always the proper type for the XSUB. See
26 L<perlxs/"The RETVAL Variable">.
28 =for apidoc Amn|(whatever)|THIS
29 Variable which is setup by C<xsubpp> to designate the object in a C++
30 XSUB. This is always the proper type for the C++ object. See C<CLASS> and
31 L<perlxs/"Using XS With C++">.
33 =for apidoc Amn|I32|ax
34 Variable which is setup by C<xsubpp> to indicate the stack base offset,
35 used by the C<ST>, C<XSprePUSH> and C<XSRETURN> macros. The C<dMARK> macro
36 must be called prior to setup the C<MARK> variable.
38 =for apidoc Amn|I32|items
39 Variable which is setup by C<xsubpp> to indicate the number of
40 items on the stack. See L<perlxs/"Variable-length Parameter Lists">.
42 =for apidoc Amn|I32|ix
43 Variable which is setup by C<xsubpp> to indicate which of an
44 XSUB's aliases was used to invoke it. See L<perlxs/"The ALIAS: Keyword">.
46 =for apidoc Am|SV*|ST|int ix
47 Used to access elements on the XSUB's stack.
50 Macro to declare an XSUB and its C parameter list. This is handled by
53 =for apidoc AmU||XS_INTERNAL
54 Macro to declare an XSUB and its C parameter list without exporting the symbols.
55 This is handled by C<xsubpp> and generally preferable over exporting the XSUB
56 symbols unnecessarily. This is handled by C<xsubpp>.
58 =for apidoc AmU||XS_EXTERNAL
59 Macro to declare an XSUB and its C parameter list explicitly exporting the symbols.
60 This is handled by C<xsubpp>.
63 Sets up the C<ax> variable.
64 This is usually handled automatically by C<xsubpp> by calling C<dXSARGS>.
66 =for apidoc Ams||dAXMARK
67 Sets up the C<ax> variable and stack marker variable C<mark>.
68 This is usually handled automatically by C<xsubpp> by calling C<dXSARGS>.
70 =for apidoc Ams||dITEMS
71 Sets up the C<items> variable.
72 This is usually handled automatically by C<xsubpp> by calling C<dXSARGS>.
74 =for apidoc Ams||dXSARGS
75 Sets up stack and mark pointers for an XSUB, calling dSP and dMARK.
76 Sets up the C<ax> and C<items> variables by calling C<dAX> and C<dITEMS>.
77 This is usually handled automatically by C<xsubpp>.
79 =for apidoc Ams||dXSI32
80 Sets up the C<ix> variable for an XSUB which has aliases. This is usually
81 handled automatically by C<xsubpp>.
83 =for apidoc Ams||dUNDERBAR
84 Sets up any variable needed by the C<UNDERBAR> macro. It used to define
85 C<padoff_du>, but it is currently a noop. However, it is strongly advised
86 to still use it for ensuring past and future compatibility.
88 =for apidoc AmU||UNDERBAR
89 The SV* corresponding to the $_ variable. Works even if there
90 is a lexical $_ in scope.
95 #ifndef PERL_UNUSED_ARG
96 # if defined(lint) && defined(S_SPLINT_S) /* www.splint.org */
98 # define PERL_UNUSED_ARG(x) NOTE(ARGUNUSED(x))
100 # define PERL_UNUSED_ARG(x) ((void)x)
103 #ifndef PERL_UNUSED_VAR
104 # define PERL_UNUSED_VAR(x) ((void)x)
107 #define ST(off) PL_stack_base[ax + (off)]
109 /* XSPROTO() is also used by SWIG like this:
111 * typedef XSPROTO(SwigPerlWrapper);
112 * typedef SwigPerlWrapper *SwigPerlWrapperPtr;
114 * This code needs to be compilable under both C and C++.
116 * Don't forget to change the __attribute__unused__ version of XS()
117 * below too if you change XSPROTO() here.
120 /* XSPROTO_INTERNAL and XS_INTERNAL are the static-linkage variants
121 * of the default XSPROTO/XS macros. They are enabled by
122 * a special XS verb that is still tbd.
124 * XSPROTO_EXTERNAL/XS_EXTERNAL are (for now) exactly the same as
125 * XSPROTO/XS, but if the default wrt. linkage changes in future, they
126 * will allow users to explicitly mark XSUBs for exporting their
130 #define XSPROTO_EXTERNAL(name) void name(pTHX_ CV* cv)
131 #define XSPROTO_INTERNAL(name) STATIC void name(pTHX_ CV* cv)
132 #define XSPROTO(name) XSPROTO_EXTERNAL(name)
137 #if defined(__CYGWIN__) && defined(USE_DYNAMIC_LOADING)
138 # define XS_EXTERNAL(name) __declspec(dllexport) XSPROTO_EXTERNAL(name)
139 # define XS_INTERNAL(name) __declspec(dllexport) XSPROTO_INTERNAL(name)
141 #if defined(__SYMBIAN32__)
142 # define XS_EXTERNAL(name) EXPORT_C XSPROTO_EXTERNAL(name)
143 # define XS_INTERNAL(name) EXPORT_C XSPROTO_INTERNAL(name)
146 # if defined(HASATTRIBUTE_UNUSED) && !defined(__cplusplus)
147 # define XS_EXTERNAL(name) void name(pTHX_ CV* cv __attribute__unused__)
148 # define XS_INTERNAL(name) STATIC void name(pTHX_ CV* cv __attribute__unused__)
151 # define XS_EXTERNAL(name) extern "C" XSPROTO_EXTERNAL(name)
152 # define XS_INTERNAL(name) extern "C" XSPROTO_INTERNAL(name)
154 # define XS_EXTERNAL(name) XSPROTO_EXTERNAL(name)
155 # define XS_INTERNAL(name) XSPROTO_INTERNAL(name)
160 /* We currently default to exporting XSUB symbols */
161 #define XS(name) XS_EXTERNAL(name)
162 /* Apparently needed for SWIG: */
163 #define XSPROTO(name) XSPROTO_EXTERNAL(name)
165 #define dAX const I32 ax = (I32)(MARK - PL_stack_base + 1)
169 register SV **mark = PL_stack_base + ax++
171 #define dITEMS I32 items = (I32)(SP - MARK)
173 #if defined(lint) && defined(S_SPLINT_S) /* www.splint.org */
175 NOTE(ARGUNUSED(cv)) \
182 #define dXSTARG SV * const targ = ((PL_op->op_private & OPpENTERSUB_HASTARG) \
183 ? PAD_SV(PL_op->op_targ) : sv_newmortal())
185 /* Should be used before final PUSHi etc. if not in PPCODE section. */
186 #define XSprePUSH (sp = PL_stack_base + ax - 1)
188 #define XSANY CvXSUBANY(cv)
190 #define dXSI32 I32 ix = XSANY.any_i32
193 # define XSINTERFACE_CVT(ret,name) ret (*name)(...)
194 # define XSINTERFACE_CVT_ANON(ret) ret (*)(...)
196 # define XSINTERFACE_CVT(ret,name) ret (*name)()
197 # define XSINTERFACE_CVT_ANON(ret) ret (*)()
199 #define dXSFUNCTION(ret) XSINTERFACE_CVT(ret,XSFUNCTION)
200 #define XSINTERFACE_FUNC(ret,cv,f) ((XSINTERFACE_CVT_ANON(ret))(f))
201 #define XSINTERFACE_FUNC_SET(cv,f) \
202 CvXSUBANY(cv).any_dxptr = (void (*) (pTHX_ void*))(f)
204 #define dUNDERBAR dNOOP
205 #define UNDERBAR find_rundefsv()
207 /* Simple macros to put new mortal values onto the stack. */
208 /* Typically used to return values from XS functions. */
211 =head1 Stack Manipulation Macros
213 =for apidoc Am|void|XST_mIV|int pos|IV iv
214 Place an integer into the specified position C<pos> on the stack. The
215 value is stored in a new mortal SV.
217 =for apidoc Am|void|XST_mNV|int pos|NV nv
218 Place a double into the specified position C<pos> on the stack. The value
219 is stored in a new mortal SV.
221 =for apidoc Am|void|XST_mPV|int pos|char* str
222 Place a copy of a string into the specified position C<pos> on the stack.
223 The value is stored in a new mortal SV.
225 =for apidoc Am|void|XST_mNO|int pos
226 Place C<&PL_sv_no> into the specified position C<pos> on the
229 =for apidoc Am|void|XST_mYES|int pos
230 Place C<&PL_sv_yes> into the specified position C<pos> on the
233 =for apidoc Am|void|XST_mUNDEF|int pos
234 Place C<&PL_sv_undef> into the specified position C<pos> on the
237 =for apidoc Am|void|XSRETURN|int nitems
238 Return from XSUB, indicating number of items on the stack. This is usually
239 handled by C<xsubpp>.
241 =for apidoc Am|void|XSRETURN_IV|IV iv
242 Return an integer from an XSUB immediately. Uses C<XST_mIV>.
244 =for apidoc Am|void|XSRETURN_UV|IV uv
245 Return an integer from an XSUB immediately. Uses C<XST_mUV>.
247 =for apidoc Am|void|XSRETURN_NV|NV nv
248 Return a double from an XSUB immediately. Uses C<XST_mNV>.
250 =for apidoc Am|void|XSRETURN_PV|char* str
251 Return a copy of a string from an XSUB immediately. Uses C<XST_mPV>.
253 =for apidoc Ams||XSRETURN_NO
254 Return C<&PL_sv_no> from an XSUB immediately. Uses C<XST_mNO>.
256 =for apidoc Ams||XSRETURN_YES
257 Return C<&PL_sv_yes> from an XSUB immediately. Uses C<XST_mYES>.
259 =for apidoc Ams||XSRETURN_UNDEF
260 Return C<&PL_sv_undef> from an XSUB immediately. Uses C<XST_mUNDEF>.
262 =for apidoc Ams||XSRETURN_EMPTY
263 Return an empty list from an XSUB immediately.
265 =head1 Variables created by C<xsubpp> and C<xsubpp> internal functions
267 =for apidoc AmU||newXSproto|char* name|XSUBADDR_t f|char* filename|const char *proto
268 Used by C<xsubpp> to hook up XSUBs as Perl subs. Adds Perl prototypes to
271 =for apidoc AmU||XS_VERSION
272 The version identifier for an XS module. This is usually
273 handled automatically by C<ExtUtils::MakeMaker>. See C<XS_VERSION_BOOTCHECK>.
275 =for apidoc Ams||XS_VERSION_BOOTCHECK
276 Macro to verify that a PM module's $VERSION variable matches the XS
277 module's C<XS_VERSION> variable. This is usually handled automatically by
278 C<xsubpp>. See L<perlxs/"The VERSIONCHECK: Keyword">.
280 =for apidoc Ams||XS_APIVERSION_BOOTCHECK
281 Macro to verify that the perl api version an XS module has been compiled against
282 matches the api version of the perl interpreter it's being loaded into.
284 =head1 Simple Exception Handling Macros
286 =for apidoc Ams||dXCPT
287 Set up necessary local variables for exception handling.
288 See L<perlguts/"Exception Handling">.
290 =for apidoc AmU||XCPT_TRY_START
291 Starts a try block. See L<perlguts/"Exception Handling">.
293 =for apidoc AmU||XCPT_TRY_END
294 Ends a try block. See L<perlguts/"Exception Handling">.
296 =for apidoc AmU||XCPT_CATCH
297 Introduces a catch block. See L<perlguts/"Exception Handling">.
299 =for apidoc Ams||XCPT_RETHROW
300 Rethrows a previously caught exception. See L<perlguts/"Exception Handling">.
305 #define XST_mIV(i,v) (ST(i) = sv_2mortal(newSViv(v)) )
306 #define XST_mUV(i,v) (ST(i) = sv_2mortal(newSVuv(v)) )
307 #define XST_mNV(i,v) (ST(i) = sv_2mortal(newSVnv(v)) )
308 #define XST_mPV(i,v) (ST(i) = sv_2mortal(newSVpv(v,0)))
309 #define XST_mPVN(i,v,n) (ST(i) = newSVpvn_flags(v,n, SVs_TEMP))
310 #define XST_mNO(i) (ST(i) = &PL_sv_no )
311 #define XST_mYES(i) (ST(i) = &PL_sv_yes )
312 #define XST_mUNDEF(i) (ST(i) = &PL_sv_undef)
314 #define XSRETURN(off) \
316 const IV tmpXSoff = (off); \
317 PL_stack_sp = PL_stack_base + ax + (tmpXSoff - 1); \
321 #define XSRETURN_IV(v) STMT_START { XST_mIV(0,v); XSRETURN(1); } STMT_END
322 #define XSRETURN_UV(v) STMT_START { XST_mUV(0,v); XSRETURN(1); } STMT_END
323 #define XSRETURN_NV(v) STMT_START { XST_mNV(0,v); XSRETURN(1); } STMT_END
324 #define XSRETURN_PV(v) STMT_START { XST_mPV(0,v); XSRETURN(1); } STMT_END
325 #define XSRETURN_PVN(v,n) STMT_START { XST_mPVN(0,v,n); XSRETURN(1); } STMT_END
326 #define XSRETURN_NO STMT_START { XST_mNO(0); XSRETURN(1); } STMT_END
327 #define XSRETURN_YES STMT_START { XST_mYES(0); XSRETURN(1); } STMT_END
328 #define XSRETURN_UNDEF STMT_START { XST_mUNDEF(0); XSRETURN(1); } STMT_END
329 #define XSRETURN_EMPTY STMT_START { XSRETURN(0); } STMT_END
331 #define newXSproto(a,b,c,d) newXS_flags(a,b,c,d,0)
334 # define XS_VERSION_BOOTCHECK \
335 Perl_xs_version_bootcheck(aTHX_ items, ax, STR_WITH_LEN(XS_VERSION))
337 # define XS_VERSION_BOOTCHECK
340 #define XS_APIVERSION_BOOTCHECK \
341 Perl_xs_apiversion_bootcheck(aTHX_ ST(0), STR_WITH_LEN("v" PERL_API_VERSION_STRING))
344 # define dXCPT dJMPENV; int rEtV = 0
345 # define XCPT_TRY_START JMPENV_PUSH(rEtV); if (rEtV == 0)
346 # define XCPT_TRY_END JMPENV_POP;
347 # define XCPT_CATCH if (rEtV != 0)
348 # define XCPT_RETHROW JMPENV_JUMP(rEtV)
352 The DBM_setFilter & DBM_ckFilter macros are only used by
353 the *DB*_File modules
356 #define DBM_setFilter(db_type,code) \
359 RETVAL = sv_mortalcopy(db_type) ; \
361 if (db_type && (code == &PL_sv_undef)) { \
362 SvREFCNT_dec(db_type) ; \
367 sv_setsv(db_type, code) ; \
369 db_type = newSVsv(code) ; \
373 #define DBM_ckFilter(arg,type,name) \
376 if (db->filtering) { \
377 croak("recursion detected in %s", name) ; \
381 SAVEINT(db->filtering) ; \
382 db->filtering = TRUE ; \
384 if (name[7] == 's') \
385 arg = newSVsv(arg); \
390 (void) perl_call_sv(db->type, G_DISCARD); \
395 if (name[7] == 's'){ \
396 arg = sv_2mortal(arg); \
400 #if 1 /* for compatibility */
401 # define VTBL_sv &PL_vtbl_sv
402 # define VTBL_env &PL_vtbl_env
403 # define VTBL_envelem &PL_vtbl_envelem
404 # define VTBL_sigelem &PL_vtbl_sigelem
405 # define VTBL_pack &PL_vtbl_pack
406 # define VTBL_packelem &PL_vtbl_packelem
407 # define VTBL_dbline &PL_vtbl_dbline
408 # define VTBL_isa &PL_vtbl_isa
409 # define VTBL_isaelem &PL_vtbl_isaelem
410 # define VTBL_arylen &PL_vtbl_arylen
411 # define VTBL_glob &PL_vtbl_glob
412 # define VTBL_mglob &PL_vtbl_mglob
413 # define VTBL_nkeys &PL_vtbl_nkeys
414 # define VTBL_taint &PL_vtbl_taint
415 # define VTBL_substr &PL_vtbl_substr
416 # define VTBL_vec &PL_vtbl_vec
417 # define VTBL_pos &PL_vtbl_pos
418 # define VTBL_bm &PL_vtbl_bm
419 # define VTBL_fm &PL_vtbl_fm
420 # define VTBL_uvar &PL_vtbl_uvar
421 # define VTBL_defelem &PL_vtbl_defelem
422 # define VTBL_regexp &PL_vtbl_regexp
423 # define VTBL_regdata &PL_vtbl_regdata
424 # define VTBL_regdatum &PL_vtbl_regdatum
425 # ifdef USE_LOCALE_COLLATE
426 # define VTBL_collxfrm &PL_vtbl_collxfrm
428 # define VTBL_amagic &PL_vtbl_amagic
429 # define VTBL_amagicelem &PL_vtbl_amagicelem
434 #if defined(PERL_IMPLICIT_CONTEXT) && !defined(PERL_NO_GET_CONTEXT) && !defined(PERL_CORE)
437 # define aTHX PERL_GET_THX
441 #if defined(PERL_IMPLICIT_SYS) && !defined(PERL_CORE)
443 # if defined (NETWARE) && defined (USE_STDIO)
444 # define times PerlProc_times
445 # define setuid PerlProc_setuid
446 # define setgid PerlProc_setgid
447 # define getpid PerlProc_getpid
448 # define pause PerlProc_pause
449 # define exit PerlProc_exit
450 # define _exit PerlProc__exit
467 /* Following symbols were giving redefinition errors while building extensions - sgp 17th Oct 2000 */
477 # undef gethostbyaddr
478 # undef gethostbyname
483 # undef getprotobyname
484 # undef getprotobynumber
486 # undef getservbyname
487 # undef getservbyport
496 /* to avoid warnings: "xyz" redefined */
504 # define mkdir PerlDir_mkdir
505 # define chdir PerlDir_chdir
506 # define rmdir PerlDir_rmdir
507 # define closedir PerlDir_close
508 # define opendir PerlDir_open
509 # define readdir PerlDir_read
510 # define rewinddir PerlDir_rewind
511 # define seekdir PerlDir_seek
512 # define telldir PerlDir_tell
513 # define putenv PerlEnv_putenv
514 # define getenv PerlEnv_getenv
515 # define uname PerlEnv_uname
516 # define stdin PerlSIO_stdin
517 # define stdout PerlSIO_stdout
518 # define stderr PerlSIO_stderr
519 # define fopen PerlSIO_fopen
520 # define fclose PerlSIO_fclose
521 # define feof PerlSIO_feof
522 # define ferror PerlSIO_ferror
523 # define clearerr PerlSIO_clearerr
524 # define getc PerlSIO_getc
525 # define fgets PerlSIO_fgets
526 # define fputc PerlSIO_fputc
527 # define fputs PerlSIO_fputs
528 # define fflush PerlSIO_fflush
529 # define ungetc PerlSIO_ungetc
530 # define fileno PerlSIO_fileno
531 # define fdopen PerlSIO_fdopen
532 # define freopen PerlSIO_freopen
533 # define fread PerlSIO_fread
534 # define fwrite PerlSIO_fwrite
535 # define setbuf PerlSIO_setbuf
536 # define setvbuf PerlSIO_setvbuf
537 # define setlinebuf PerlSIO_setlinebuf
538 # define stdoutf PerlSIO_stdoutf
539 # define vfprintf PerlSIO_vprintf
540 # define ftell PerlSIO_ftell
541 # define fseek PerlSIO_fseek
542 # define fgetpos PerlSIO_fgetpos
543 # define fsetpos PerlSIO_fsetpos
544 # define frewind PerlSIO_rewind
545 # define tmpfile PerlSIO_tmpfile
546 # define access PerlLIO_access
547 # define chmod PerlLIO_chmod
548 # define chsize PerlLIO_chsize
549 # define close PerlLIO_close
550 # define dup PerlLIO_dup
551 # define dup2 PerlLIO_dup2
552 # define flock PerlLIO_flock
553 # define fstat PerlLIO_fstat
554 # define ioctl PerlLIO_ioctl
555 # define isatty PerlLIO_isatty
556 # define link PerlLIO_link
557 # define lseek PerlLIO_lseek
558 # define lstat PerlLIO_lstat
559 # define mktemp PerlLIO_mktemp
560 # define open PerlLIO_open
561 # define read PerlLIO_read
562 # define rename PerlLIO_rename
563 # define setmode PerlLIO_setmode
564 # define stat(buf,sb) PerlLIO_stat(buf,sb)
565 # define tmpnam PerlLIO_tmpnam
566 # define umask PerlLIO_umask
567 # define unlink PerlLIO_unlink
568 # define utime PerlLIO_utime
569 # define write PerlLIO_write
570 # define malloc PerlMem_malloc
571 # define realloc PerlMem_realloc
572 # define free PerlMem_free
573 # define abort PerlProc_abort
574 # define exit PerlProc_exit
575 # define _exit PerlProc__exit
576 # define execl PerlProc_execl
577 # define execv PerlProc_execv
578 # define execvp PerlProc_execvp
579 # define getuid PerlProc_getuid
580 # define geteuid PerlProc_geteuid
581 # define getgid PerlProc_getgid
582 # define getegid PerlProc_getegid
583 # define getlogin PerlProc_getlogin
584 # define kill PerlProc_kill
585 # define killpg PerlProc_killpg
586 # define pause PerlProc_pause
587 # define popen PerlProc_popen
588 # define pclose PerlProc_pclose
589 # define pipe PerlProc_pipe
590 # define setuid PerlProc_setuid
591 # define setgid PerlProc_setgid
592 # define sleep PerlProc_sleep
593 # define times PerlProc_times
594 # define wait PerlProc_wait
595 # define setjmp PerlProc_setjmp
596 # define longjmp PerlProc_longjmp
597 # define signal PerlProc_signal
598 # define getpid PerlProc_getpid
599 # define gettimeofday PerlProc_gettimeofday
600 # define htonl PerlSock_htonl
601 # define htons PerlSock_htons
602 # define ntohl PerlSock_ntohl
603 # define ntohs PerlSock_ntohs
604 # define accept PerlSock_accept
605 # define bind PerlSock_bind
606 # define connect PerlSock_connect
607 # define endhostent PerlSock_endhostent
608 # define endnetent PerlSock_endnetent
609 # define endprotoent PerlSock_endprotoent
610 # define endservent PerlSock_endservent
611 # define gethostbyaddr PerlSock_gethostbyaddr
612 # define gethostbyname PerlSock_gethostbyname
613 # define gethostent PerlSock_gethostent
614 # define gethostname PerlSock_gethostname
615 # define getnetbyaddr PerlSock_getnetbyaddr
616 # define getnetbyname PerlSock_getnetbyname
617 # define getnetent PerlSock_getnetent
618 # define getpeername PerlSock_getpeername
619 # define getprotobyname PerlSock_getprotobyname
620 # define getprotobynumber PerlSock_getprotobynumber
621 # define getprotoent PerlSock_getprotoent
622 # define getservbyname PerlSock_getservbyname
623 # define getservbyport PerlSock_getservbyport
624 # define getservent PerlSock_getservent
625 # define getsockname PerlSock_getsockname
626 # define getsockopt PerlSock_getsockopt
627 # define inet_addr PerlSock_inet_addr
628 # define inet_ntoa PerlSock_inet_ntoa
629 # define listen PerlSock_listen
630 # define recv PerlSock_recv
631 # define recvfrom PerlSock_recvfrom
632 # define select PerlSock_select
633 # define send PerlSock_send
634 # define sendto PerlSock_sendto
635 # define sethostent PerlSock_sethostent
636 # define setnetent PerlSock_setnetent
637 # define setprotoent PerlSock_setprotoent
638 # define setservent PerlSock_setservent
639 # define setsockopt PerlSock_setsockopt
640 # define shutdown PerlSock_shutdown
641 # define socket PerlSock_socket
642 # define socketpair PerlSock_socketpair
643 # endif /* NETWARE && USE_STDIO */
645 # ifdef USE_SOCKETS_AS_HANDLES
651 # define fd_set Perl_fd_set
652 # define FD_SET(n,p) PERL_FD_SET(n,p)
653 # define FD_CLR(n,p) PERL_FD_CLR(n,p)
654 # define FD_ISSET(n,p) PERL_FD_ISSET(n,p)
655 # define FD_ZERO(p) PERL_FD_ZERO(p)
656 # endif /* USE_SOCKETS_AS_HANDLES */
658 # endif /* NO_XSLOCKS */
659 #endif /* PERL_IMPLICIT_SYS && !PERL_CORE */
661 #endif /* _INC_PERL_XSUB_H */ /* include guard */
665 * c-indentation-style: bsd
667 * indent-tabs-mode: t
670 * ex: set ts=8 sts=4 sw=4 noet: