This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Fwd: [craigberry@mac.com: RE: Broken URL in README.vms]
[perl5.git] / perlapi.c
1 /* !!!!!!!   DO NOT EDIT THIS FILE   !!!!!!!
2    This file is built by embed.pl from data in embed.pl, pp.sym, intrpvar.h,
3    perlvars.h and thrdvar.h.  Any changes made here will be lost!
4 */
5
6 #include "EXTERN.h"
7 #include "perl.h"
8 #include "perlapi.h"
9
10 #if defined (MULTIPLICITY)
11
12 /* accessor functions for Perl variables (provides binary compatibility) */
13 START_EXTERN_C
14
15 #undef PERLVAR
16 #undef PERLVARA
17 #undef PERLVARI
18 #undef PERLVARIC
19
20 #define PERLVAR(v,t)    t* Perl_##v##_ptr(pTHX)                         \
21                         { return &(aTHX->v); }
22 #define PERLVARA(v,n,t) PL_##v##_t* Perl_##v##_ptr(pTHX)                \
23                         { return &(aTHX->v); }
24
25 #define PERLVARI(v,t,i) PERLVAR(v,t)
26 #define PERLVARIC(v,t,i) PERLVAR(v, const t)
27
28 #include "thrdvar.h"
29 #include "intrpvar.h"
30
31 #undef PERLVAR
32 #undef PERLVARA
33 #define PERLVAR(v,t)    t* Perl_##v##_ptr(pTHX)                         \
34                         { return &(PL_##v); }
35 #define PERLVARA(v,n,t) PL_##v##_t* Perl_##v##_ptr(pTHX)                \
36                         { return &(PL_##v); }
37 #undef PERLVARIC
38 #define PERLVARIC(v,t,i)        const t* Perl_##v##_ptr(pTHX)           \
39                         { return (const t *)&(PL_##v); }
40 #include "perlvars.h"
41
42 #undef PERLVAR
43 #undef PERLVARA
44 #undef PERLVARI
45 #undef PERLVARIC
46
47 END_EXTERN_C
48
49 #endif /* MULTIPLICITY */