source: trunk/essentials/dev-lang/perl/NetWare/nw5thread.c@ 3315

Last change on this file since 3315 was 3181, checked in by bird, 19 years ago

perl 5.8.8

File size: 1.5 KB
Line 
1
2/*
3 * Copyright © 2001 Novell, Inc. All Rights Reserved.
4 *
5 * You may distribute under the terms of either the GNU General Public
6 * License or the Artistic License, as specified in the README file.
7 *
8 */
9
10/*
11 * FILENAME : nw5thread.c
12 * DESCRIPTION : Thread related functions.
13 * Author : SGP
14 * Date : January 2001.
15 *
16 */
17
18
19
20#include "EXTERN.h"
21#include "perl.h"
22
23//For Thread Local Storage
24#include "win32ish.h" // For "BOOL", "TRUE" and "FALSE"
25#include "nwtinfo.h"
26
27#ifdef USE_DECLSPEC_THREAD
28__declspec(thread) void *PL_current_context = NULL;
29#endif
30
31
32void
33Perl_set_context(void *t)
34{
35#if defined(USE_5005THREADS) || defined(USE_ITHREADS)
36# ifdef USE_DECLSPEC_THREAD
37 Perl_current_context = t;
38# else
39 fnAddThreadCtx(PL_thr_key, t);
40# endif
41#endif
42}