summaryrefslogtreecommitdiff
path: root/perl.h
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1997-11-22 05:27:04 +0000
committerGurusamy Sarathy <gsar@cpan.org>1997-11-22 05:27:04 +0000
commiteece6917ca78f8c79af6254e2c02cc65fcb937c7 (patch)
treebfc6ab21f514842c47c75afdb264774366733fcb /perl.h
parent55d256264fa5ff79990a3e74153691aa2e477d37 (diff)
parent54b9620dd49f76536ba0792f6f471615a414bd6a (diff)
downloadperl-eece6917ca78f8c79af6254e2c02cc65fcb937c7.tar.gz
[win32] Integrate mainline.
p4raw-id: //depot/win32/perl@275
Diffstat (limited to 'perl.h')
-rw-r--r--perl.h38
1 files changed, 11 insertions, 27 deletions
diff --git a/perl.h b/perl.h
index a2f5630d92..d895441235 100644
--- a/perl.h
+++ b/perl.h
@@ -119,7 +119,7 @@ register struct op *op asm(stringify(OP_IN_REGISTER));
# define STANDARD_C 1
#endif
-#if defined(__cplusplus) || defined(WIN32)
+#if defined(__cplusplus) || defined(WIN32) || defined(__sgi)
# define DONT_DECLARE_STD 1
#endif
@@ -468,9 +468,13 @@ register struct op *op asm(stringify(OP_IN_REGISTER));
#ifdef USE_THREADS
# define ERRSV (thr->errsv)
# define ERRHV (thr->errhv)
+# define DEFSV *av_fetch(thr->threadsv, find_threadsv("_"), FALSE)
+# define SAVE_DEFSV save_threadsv(find_threadsv("_"))
#else
# define ERRSV GvSV(errgv)
# define ERRHV GvHV(errgv)
+# define DEFSV GvSV(defgv)
+# define SAVE_DEFSV SAVESPTR(GvSV(defgv))
#endif /* USE_THREADS */
#ifndef errno
@@ -1355,7 +1359,7 @@ int runops_standard _((void));
int runops_debug _((void));
#endif
-#define PER_THREAD_MAGICALS "123456789&`'+/.,\\\";^-%=|~:\001\005!@"
+#define THREADSV_NAMES "_123456789&`'+/.,\\\";^-%=|~:\001\005!@"
/****************/
/* Truly global */
@@ -1373,7 +1377,7 @@ EXT struct thread * eval_owner; /* Owner thread for doeval */
EXT int nthreads; /* Number of threads currently */
EXT perl_mutex threads_mutex; /* Mutex for nthreads and thread list */
EXT perl_cond nthreads_cond; /* Condition variable for nthreads */
-EXT char * per_thread_magicals INIT(PER_THREAD_MAGICALS);
+EXT char * threadsv_names INIT(THREADSV_NAMES);
#ifdef FAKE_THREADS
EXT struct thread * thr; /* Currently executing (fake) thread */
#endif
@@ -1381,7 +1385,7 @@ EXT struct thread * thr; /* Currently executing (fake) thread */
/* VMS doesn't use environ array and NeXT has problems with crt0.o globals */
#if !defined(VMS) && !(defined(NeXT) && defined(__DYNAMIC__))
-#if !defined(DONT_DECLARE_STD) || (defined(__svr4__) && defined(__GNUC__) && defined(sun))
+#if !defined(DONT_DECLARE_STD) || (defined(__svr4__) && defined(__GNUC__) && defined(sun)) || defined(__sgi)
extern char ** environ; /* environment variables supplied via exec */
#endif
#else
@@ -1754,29 +1758,6 @@ EXT U32 hints; /* various compilation flags */
#define HINT_STRICT_VARS 0x00000400
#define HINT_LOCALE 0x00000800
-/**************************************************************************/
-/* This regexp stuff is global since it always happens within 1 expr eval */
-/**************************************************************************/
-
-EXT char * regprecomp; /* uncompiled string. */
-EXT char * regparse; /* Input-scan pointer. */
-EXT char * regxend; /* End of input for compile */
-EXT I32 regnpar; /* () count. */
-EXT char * regcode; /* Code-emit pointer; &regdummy = don't. */
-EXT I32 regsize; /* Code size. */
-EXT I32 regnaughty; /* How bad is this pattern? */
-EXT I32 regsawback; /* Did we see \1, ...? */
-
-EXT char * reginput; /* String-input pointer. */
-EXT char * regbol; /* Beginning of input, for ^ check. */
-EXT char * regeol; /* End of input, for $ check. */
-EXT char ** regstartp; /* Pointer to startp array. */
-EXT char ** regendp; /* Ditto for endp. */
-EXT U32 * reglastparen; /* Similarly for lastparen. */
-EXT char * regtill; /* How far we are required to go. */
-EXT U16 regflags; /* are we folding, multilining? */
-EXT char regprev; /* char before regbol, \n if none */
-
EXT bool do_undump; /* -u or dump seen? */
EXT VOL U32 debug;
@@ -2078,6 +2059,8 @@ EXT MGVTBL vtbl_mutex = {0, 0, 0, 0, magic_mutexfree};
EXT MGVTBL vtbl_defelem = {magic_getdefelem,magic_setdefelem,
0, 0, magic_freedefelem};
+EXT MGVTBL vtbl_regexp = {0,0,0,0, magic_freeregexp};
+
#ifdef USE_LOCALE_COLLATE
EXT MGVTBL vtbl_collxfrm = {0,
magic_setcollxfrm,
@@ -2120,6 +2103,7 @@ EXT MGVTBL vtbl_mutex;
#endif /* USE_THREADS */
EXT MGVTBL vtbl_defelem;
+EXT MGVTBL vtbl_regexp;
#ifdef USE_LOCALE_COLLATE
EXT MGVTBL vtbl_collxfrm;