source: trunk/third/perl/perlapi.c @ 20075

Revision 20075, 1.6 KB checked in by zacheiss, 21 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r20074, which included commits to RCS files with non-trunk default branches.
Line 
1/*
2 *    perlapi.c
3 *
4 *    Copyright (C) 1999, 2000, 2001, by Larry Wall and others
5 *
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.
8 *
9 * !!!!!!!   DO NOT EDIT THIS FILE   !!!!!!!
10 * This file is built by embed.pl from data in embed.fnc, embed.pl,
11 * pp.sym, intrpvar.h, perlvars.h and thrdvar.h.
12 * Any changes made here will be lost!
13 *
14 * Edit those files and run 'make regen_headers' to effect changes.
15 *
16 *
17 * Up to the threshold of the door there mounted a flight of twenty-seven
18 * broad stairs, hewn by some unknown art of the same black stone.  This
19 * was the only entrance to the tower.
20 *
21 */
22
23#include "EXTERN.h"
24#include "perl.h"
25#include "perlapi.h"
26
27#if defined (MULTIPLICITY)
28
29/* accessor functions for Perl variables (provides binary compatibility) */
30START_EXTERN_C
31
32#undef PERLVAR
33#undef PERLVARA
34#undef PERLVARI
35#undef PERLVARIC
36
37#define PERLVAR(v,t)    t* Perl_##v##_ptr(pTHX)                         \
38                        { return &(aTHX->v); }
39#define PERLVARA(v,n,t) PL_##v##_t* Perl_##v##_ptr(pTHX)                \
40                        { return &(aTHX->v); }
41
42#define PERLVARI(v,t,i) PERLVAR(v,t)
43#define PERLVARIC(v,t,i) PERLVAR(v, const t)
44
45#include "thrdvar.h"
46#include "intrpvar.h"
47
48#undef PERLVAR
49#undef PERLVARA
50#define PERLVAR(v,t)    t* Perl_##v##_ptr(pTHX)                         \
51                        { return &(PL_##v); }
52#define PERLVARA(v,n,t) PL_##v##_t* Perl_##v##_ptr(pTHX)                \
53                        { return &(PL_##v); }
54#undef PERLVARIC
55#define PERLVARIC(v,t,i)        const t* Perl_##v##_ptr(pTHX)           \
56                        { return (const t *)&(PL_##v); }
57#include "perlvars.h"
58
59#undef PERLVAR
60#undef PERLVARA
61#undef PERLVARI
62#undef PERLVARIC
63
64END_EXTERN_C
65
66#endif /* MULTIPLICITY */
Note: See TracBrowser for help on using the repository browser.