Fossil SCM

Add the 3 header files from Tcl. Now win32 fossil.exe can be cross-compiled on any system which has a suitble mingw-w64 compiler. E.g. on Ubuntu: * sudo apt-get install mingw-w64 * cd compat;tar xfz <path-to>/openssl-1.0.1e.tar.gz * make -f win/Makefile.mingw.mistachkin PREFIX=i686-w64-mingw32- openssl fossil.exe * i686-w64-mingw32-strip fossil.exe

jan.nijtmans 2013-09-13 21:17 tcl-stubs
Commit d0ef76037b16c877b4672a753b380956b0948e2c
--- a/compat/tcl-8.6/generic/tcl.h
+++ b/compat/tcl-8.6/generic/tcl.h
@@ -0,0 +1,2368 @@
1
+/*
2
+ * tcl.h --
3
+ *
4
+ * This header file describes the externally-visible facilities of the
5
+ * Tcl interpreter.
6
+ *
7
+ * Copyright (c) 1987-1994 The Regents of the University of California.
8
+ * Copyright (c) 1993-1996 Lucent Technologies.
9
+ * Copyright (c) 1994-1998 Sun Microsystems, Inc.
10
+ * Copyright (c) 1998-2000 by Scriptics Corporation.
11
+ * Copyright (c) 2002 by Kevin B. Kenny. All rights reserved.
12
+ *
13
+ * See the file "license.terms" for information on usage and redistribution of
14
+ * this file, and for a DISCLAIMER OF ALL WARRANTIES.
15
+ */
16
+
17
+#ifndef _TCL
18
+#define _TCL
19
+
20
+/*
21
+ * For C++ compilers, use extern "C"
22
+ */
23
+
24
+#ifdef __cplusplus
25
+extern "C" {
26
+#endif
27
+
28
+/*
29
+ * The following defines are used to indicate the various release levels.
30
+ */
31
+
32
+#define TCL_ALPHA_RELEASE 0
33
+#define TCL_BETA_RELEASE 1
34
+#define TCL_FINAL_RELEASE 2
35
+
36
+/*
37
+ * When version numbers change here, must also go into the following files and
38
+ * update the version numbers:
39
+ *
40
+ * library/init.tcl (1 LOC patch)
41
+ * unix/configure.in (2 LOC Major, 2 LOC minor, 1 LOC patch)
42
+ * win/configure.in (as above)
43
+ * win/tcl.m4 (not patchlevel)
44
+ * win/makefile.bc (not patchlevel) 2 LOC
45
+ * README (sections 0 and 2, with and without separator)
46
+ * macosx/Tcl.pbproj/project.pbxproj (not patchlevel) 1 LOC
47
+ * macosx/Tcl.pbproj/default.pbxuser (not patchlevel) 1 LOC
48
+ * macosx/Tcl.xcode/project.pbxproj (not patchlevel) 2 LOC
49
+ * macosx/Tcl.xcode/default.pbxuser (not patchlevel) 1 LOC
50
+ * macosx/Tcl-Common.xcconfig (not patchlevel) 1 LOC
51
+ * win/README (not patchlevel) (sections 0 and 2)
52
+ * unix/tcl.spec (1 LOC patch)
53
+ * tools/tcl.hpj.in (not patchlevel, for windows installer)
54
+ */
55
+
56
+#define TCL_MAJOR_VERSION 8
57
+#define TCL_MINOR_VERSION 6
58
+#define TCL_RELEASE_LEVEL TCL_FINAL_RELEASE
59
+#define TCL_RELEASE_SERIAL 1eader file describes the external/*
60
+ * tcl.h --
61
+ *
62
+ * ThisBA"8.6.1"------------------------------
63
+ * The following structure represents a type facilities of the
64
+ * Tcl interpreter.
65
+ *
66
+ * Copyright (c) 1987-1994 The Regents of the University of California.
67
+ * Copyright (c) 1993-1996 Lucent Technologies.
68
+ * Copyright (c) 1994-1998 Sun Microsystems, Inc.
69
+ * Copyright (c) 1998-2000 by Scriptics Corporation.
70
+ * Copyright (c) 2002 by Kevin B. Kenny. All rights reserved.
71
+ *
72
+ * See the file "license.terms" for information on usage and redistribution of
73
+ * this file, and for a DISCLAIMER OF ALL WARRANTIES.
74
+ */
75
+
76
+#ifndef _TCL
77
+#define _TCL
78
+
79
+/*
80
+ * For C++ compilers, use extern "C"
81
+ */
82
+
83
+#ifdef __cplusplus
84
+extern "C" {
85
+#endif
86
+
87
+/*
88
+ * The following defines are used to indicate the various release levels.
89
+ */
90
+
91
+#define TCL_ALPHA_RELEASE 0
92
+#define TCL_BETA_RELEASE 1
93
+#define TCL_FINAL_RELEASE 2
94
+
95
+/*
96
+ * When version numbers change here, must also go into the following files and
97
+ * update the version numbers:
98
+ *
99
+ * library/init.tcl (1 LOC patch)
100
+ * unix/configure.in (2 LOC Major, 2 LOC minor, 1 LOC patch)
101
+ * win/configure.in (as above)
102
+ * win/tcl.m4 (not patchlevel)
103
+ * win/makefile.bc (not patchlevel) 2 LOC
104
+ * README (sections 0 and 2, with and without separator)
105
+ * macosx/Tcl.pbproj/project.pbxproj (not patchlevel) 1 LOC
106
+ * macosx/Tcl.pbproj/default.pbxuser (not patchlevel) 1 LOC
107
+ * macosx/Tcl.xcode/project.pbxproj (not patchlevel) 2 LOC
108
+ * macosx/Tcl.xcode/default.pbxuser (not patchlevel) 1 LOC
109
+ * macosx/Tcl-Common.xcconfig (not patchlevel) 1 LOC
110
+ * win/README (not patchlevel) (sections 0 and 2)
111
+ * unix/tcl.spec (1 LOC patch)
112
+ * tools/tcl.hpj.in (not patchlevel, for windows installer)
113
+ */
114
+
115
+#define TCL_MAJOR_VERSION 8
116
+#define TCL_MINOR_VERSION 6
117
+#define TCL_RELEASE_LEVEL TCL_FINAL_RELEASE
118
+#define TCL_RELEASE_SERIAL 0
119
+
120
+#define TCL_VERSION "8.6"
121
+#define TCL_PATCH_LEVEL "8.6.0"
122
+
123
+
124
+/*
125
+ *----------------------------------------------------------------------------
126
+ * The following definitions set up the proper options for Windows compilers.
127
+ * We use this method because there is no autoconf equivalent.
128
+ */
129
+
130
+#ifndef __WIN32__
131
+# if defined(_WIN32) || defined(WIN32) || defined(__MINGW32__) || defined(__BORLANDC__) || (defined(__WATCOMC__) && defined(__WINDOWS_386__))
132
+# define __WIN32__
133
+# ifndef WIN32
134
+# define WIN32
135
+# endif
136
+# ifndef _WIN32
137
+# define _WIN32
138
+# endif
139
+# endif
140
+#endif
141
+
142
+/*
143
+ * STRICT: See MSDN Article Q83456
144
+ */
145
+
146
+#ifdef __WIN32__
147
+# ifndef STRICT
148
+# define STRICT
149
+# endif
150
+#endif /* __WIN32__ */
151
+
152
+/*
153
+ * Utility macros: STRINGIFY takes an argument and wraps it in "" (double
154
+ * quotation marks), JOIN joins two arguments.
155
+ */
156
+
157
+#ifndef STRINGIFY
158
+# define STRINGIFY(x) STRINGIFY1(x)
159
+# define STRINGIFY1(x) #x
160
+#endif
161
+#ifndef JOIN
162
+# define JOIN(a,b) JOIN1(a,b)
163
+# define JOIN1(a,b) a##b
164
+#endif
165
+
166
+/*
167
+ * A special definition used to allow this header file to be included from
168
+ * windows resource files so that they can obtain version information.
169
+ * RC_INVOKED is defined by default by the windows RC tool.
170
+ *
171
+ * Resource compilers don't like all the C stuff, like typedefs and function
172
+ * declarations, that occur below, so block them out.
173
+ */
174
+
175
+#ifndef RC_INVOKED
176
+
177
+/*
178
+ * Special macro to define mutexes, that doesn't do anything if we are not
179
+ * using threads.
180
+ */
181
+
182
+#ifdef TCL_THREADS
183
+#define TCL_DECLARE_MUTEX(name) static Tcl_Mutex name;
184
+#else
185
+#define TCL_DECLARE_MUTEX(name)
186
+#endif
187
+
188
+/*
189
+ * Tcl's public routine Tcl_FSSeek() uses the values SEEK_SET, SEEK_CUR, and
190
+ * SEEK_END, all #define'd by stdio.h .
191
+ *
192
+ * Also, many extensions need stdio.h, and they've grown accustomed to tcl.h
193
+ * providing it for them rather than #include-ing it themselves as they
194
+ * should, so also for their sake, we keep the #include to be consistent with
195
+ * prior Tcl releases.
196
+ */
197
+
198
+#include <stdio.h>
199
+
200
+/*
201
+ *----------------------------------------------------------------------------
202
+ * Support for functions with a variable number of arguments.
203
+ *
204
+ * The following TCL_VARARGS* macros are to support old extensions
205
+ * written for older versions of Tcl where the macros permitted
206
+ * support for the varargs.h system as well as stdarg.h .
207
+ *
208
+ * New code should just directly be written to use stdarg.h conventions.
209
+ */
210
+
211
+#include <stdarg.h>
212
+#ifndef TCL_NO_DEPRECATED
213
+# define TCL_VARARGS(type, name) (type name, ...)
214
+# define TCL_VARARGS_DEF(type, name) (type name, ...)
215
+# define TCL_VARARGS_START(type, name, list) (va_start(list, name), name)
216
+#endif
217
+#if defined(__GNUC__) && (__GNUC__ > 2)
218
+# define TCL_FORMAT_PRINTF(a,b) __attribute__ ((__format__ (__printf__, a, b)))
219
+#else
220
+# define TCL_FORMAT_PRINTF(a,b)
221
+#endif
222
+
223
+/*
224
+ * Allow a part of Tcl's API to be explicitly marked as deprecated.
225
+ *
226
+ * Used to make TIP 330/336 generate moans even if people use the
227
+ * compatibility macros. Change your code, guys! We won't support you forever.
228
+ */
229
+
230
+#if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)))
231
+# if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC__MINOR__ >= 5))
232
+# define TCL_DEPRECATED_API(msg) __attribute__ ((__deprecated__ (msg)))
233
+# else
234
+# define TCL_DEPRECATED_API(msg) __attribute__ ((__deprecated__))
235
+# endif
236
+#else
237
+# define TCL_DEPRECATED_API(msg) /* nothing portable */
238
+#endif
239
+
240
+/*
241
+ *----------------------------------------------------------------------------
242
+ * Macros used to declare a function to be exported by a DLL. Used by Windows,
243
+ * maps to no-op declarations on non-Windows systems. The default build on
244
+ * windows is for a DLL, which causes the DLLIMPORT and DLLEXPORT macros to be
245
+ * nonempty. To build a static library, the macro STATIC_BUILD should be
246
+ * defined.
247
+ *
248
+ * Note: when building static but linking dynamically to MSVCRT we must still
249
+ * correctly decorate the C library imported function. Use CRTIMPORT
250
+ * for this purpose. _DLL is defined by the compiler when linking to
251
+ * MSVCRT.
252
+ */
253
+
254
+#if (defined(__WIN32__) && (defined(_MSC_VER) || (__BORLANDC__ >= 0x0550) || defined(__/*
255
+ * tcl.h
256
+# ifndef NO_VOID
257
+# define VOID void
258
+# ((__deprecated__VOID char/*
259
+ * tcl.h --
260
+ *
261
+ * Thiss header file describes the externally-visible facilities of the
262
+ * Tcl interpreter.
263
+ *
264
+ * Copyright (c) 1987-1994 The Regents of the University of California.
265
+ * Copyright (c) 1993-1996 Lucent Technologies.
266
+ * Copyright (c) 1994-1998 Sun Microsystems, Inc.
267
+ * Copyright (c) 1998-2000 by Scriptics Corporation.
268
+ * Copyright (c) 2002 by Kevin B. Kenny. All rights reserved.
269
+ *
270
+ * See the file "license.terms" for information on usage and redistribution of
271
+ * this file, and for a DISCLAIMER OF ALL WARRANTIES.
272
+ */
273
+
274
+#ifndef _TCL
275
+#define _TCL
276
+
277
+/*
278
+ * For C++ compilers, use extern "C"
279
+ */
280
+
281
+#ifdef __cplusplus
282
+extern "C" {
283
+#endif
284
+
285
+/*
286
+ * The following defines are used to indicate the various release levels.
287
+ */
288
+
289
+#define TCL_ALPHA_RELEASE 0
290
+#define TCL_BETA_RELEASE 1
291
+#define TCL_FINAL_RELEASE 2
292
+
293
+/*
294
+ * When version numbers change here, must also go into the following files and
295
+ * update the version numbers:
296
+ *
297
+ * library/init.tcl (1 LOC patch)
298
+ * unix/configure.in (2 LOC Major, 2 LOC minor, 1 LOC patch)
299
+ * win/configure.in (as above)
300
+ * win/tcl.m4 (not patchlevel)
301
+ * win/makefile.bc (not patchlevel) 2 LOC
302
+ * README (sections 0 and 2, with and without separator)
303
+ * macosx/Tcl.pbproj/project.pbxproj (not patchlevel) 1 LOC
304
+ * macosx/Tcl.pbproj/default.pbxuser (not patchlevel) 1 LOC
305
+ * macosx/Tcl.xcode/project.pbxproj (not patchlevel) 2 LOC
306
+ * macosx/Tcl.xcode/default.pbxuser (not patchlevel) 1 LOC
307
+ * macosx/Tcl-Common.xcconfig (not patchlevel) 1 LOC
308
+ * win/README (not patchlevel) (sections 0 and 2)
309
+ * unix/tcl.spec (1 LOC patch)
310
+ * tools/tcl.hpj.in (not patchlevel, for windows installer)
311
+ */
312
+
313
+#define TCL_MAJOR_VERSION 8
314
+#define TCL_MINOR_VERSION 6
315
+#define TCL_RELEASE_LEVEL TCL_FINAL_RELEASE
316
+#define TCL_RELEASE_SERIAL 0
317
+
318
+#define TCL_VERSION "8.6"
319
+#define TCL_PATCH_LEVEL "8.6.0"
320
+
321
+
322
+/*
323
+ *----------------------------------------------------------------------------
324
+ * The following definitions set up the proper options for Windows compilers.
325
+ * We use this method because there is no autoconf equivalent.
326
+ */
327
+
328
+#ifndef __WIN32__
329
+# if defined(_WIN32) || defined(WIN32) || defined(__MINGW32__) || defined(__BORLANDC__) || (defined(__WATCOMC__) && defined(__WINDOWS_386__))
330
+# define __WIN32__
331
+# ifndef WIN32
332
+# define WIN32
333
+# endif
334
+# ifndef _WIN32
335
+# define _WIN32
336
+# endif
337
+# endif
338
+#endif
339
+
340
+/*
341
+ * STRICT: See MSDN Article Q83456
342
+ */
343
+
344
+#ifdef __WIN32__
345
+# ifndef STRICT
346
+# define STRICT
347
+# endif
348
+#endif /* __WIN32__ */
349
+
350
+/*
351
+ * Utility macros: STRINGIFY takes an argument and wraps it in "" (double
352
+ * quotation marks), JOIN joins two arguments.
353
+ */
354
+
355
+#ifndef STRINGIFY
356
+# define STRINGIFY(x) STRINGIFY1(x)
357
+# define STRINGIFY1(x) #x
358
+#endif
359
+#ifndef JOIN
360
+# define JOIN(a,b) JOIN1(a,b)
361
+# define JOIN1(a,b) a##b
362
+#endif
363
+
364
+/*
365
+ * A special definition used to allow this header file to be included from
366
+ * windows resource files so that they can obtain version information.
367
+ * RC_INVOKED is defined by default by the windows RC tool.
368
+ *
369
+ * Resource compilers don't like all the C stuff, like typedefs and function
370
+ * declarations, that occur below, so block them out.
371
+ */
372
+
373
+#ifndef RC_INVOKED
374
+
375
+/*
376
+ * Special macro to define mutexes, that doesn't do anything if we are not
377
+ * using threads.
378
+ */
379
+
380
+#ifdef TCL_THREADS
381
+#define TCL_DECLARE_MUTEX(name) static Tcl_Mutex name;
382
+#else
383
+#define TCL_DECLARE_MUTEX(name)
384
+#endif
385
+
386
+/*
387
+ * Tcl's public routine Tcl_FSSeek() uses the values SEEK_SET, SEEK_CUR, and
388
+ * SEEK_END, all #define'd by stdio.h .
389
+ *
390
+ * Also, many extensions need stdio.h, and they've grown accustomed to tcl.h
391
+ * providing it for them rather than #include-ing it themselves as they
392
+ * should, so also for their sake, we keep the #include to be consistent with
393
+ * prior Tcl releases.
394
+ */
395
+
396
+#include <stdio.h>
397
+
398
+/*
399
+ *----------------------------------------------------------------------------
400
+ * Support for functions with a variable number of arguments.
401
+ *
402
+ * The following TCL_VARARGS* macros are to support old extensions
403
+ * written for older versions of Tcl where the macros permitted
404
+ * support for the varargs.h system as well as stdarg.h .
405
+ *
406
+ * New code should just directly be written to use stdarg.h conventions.
407
+ */
408
+
409
+#include <stdarg.h>
410
+#ifndef TCL_NO_DEPRECATED
411
+# define TCL_VARARGS(type, name) (type name, ...)
412
+# define TCL_VARARGS_DEF(type, name) (type name, ...)
413
+# defi && !defined(__APPLE__ defined(HAVE_STRUCT_STAT64)
414
+ typedef struct stat64 Tcl_StatBuf;
415
+#else
416
+ typedef struct stat Tcl_StatBuf;
417
+#endif
418
+
419
+
420
+/*
421
+ *----------------------------------------------------------------------------
422
+ * Data structures defined opaquely in this module. The definitions below just
423
+ * provide dummy types. A few fields are made visible in Tcl_Interp
424
+ * structures, namely those used for returning a string result from commands.
425
+ * Direct access to the result field is discouraged in Tcl 8.0. The
426
+ * interpreter result is either an object or a string, and the two values are
427
+ * kept consistent unless some C code sets interp->result directly.
428
+ * Programmers should use either the function Tcl_GetObjResult() or
429
+ * Tcl_GetStringResult() to read the interpreter's result. See the SetResult
430
+ * man page for details.
431
+ *
432
+ * Note: any change to the Tcl_Interp definition below must be mirrored in the
433
+ * "real" definition in tclInt.h.
434
+ *
435
+ * Note: Tcl_ObjCmdProc functions do not directly set result and freeProc.
436
+ * Instead, they set a Tcl_Obj member in the "real" structure that can be
437
+ * accessed with Tcl_GetObjResult() and Tcl_SetObjResult().
438
+ */
439
+
440
+typedef struct Tcl_Interp
441
+#ifndef TCL_NO_DEPRECATED
442
+{
443
+ /* TIP #330: Strongly discourage extensions from using the string
444
+ * result. */
445
+#ifdef USE_INTERP_RStringe is a 4-byte gap */
446
+ long long;
447
+ unsigned short st_ino;
448
+ unsigned short st_mode;
449
+ short st_nlink;
450
+ short st_uid;
451
+ short st_gid;
452
+ /* Here is a 2-byte gap */
453
+ dev_t st_rdev;
454
+ /* HerStringe is a 4-byte gap */
455
+ long long st_size;
456
+ struct {long tv_sec;} st_atim;
457
+ struct {long tv_sec;} st_mtim;
458
+ struct {long tv_sec;} st_ctim;
459
+ /* Here is a 4-byte gap */
460
+ } Tcl_StatBuf;
461
+#elif defined(HAVE_STRUCT_STAT64)
462
+ typedef struct stat64 Tcl_StatBuf;
463
+#else
464
+ typedef struct stat Tcl_StatBuf;
465
+#endif
466
+
467
+
468
+/*
469
+ *----------------------------------------------------------------------------
470
+ * Data structures defined opaquely in this module. The definitions below just
471
+ * provide dummy types. A few fields are made visible in Tcl_Interp
472
+ * structures, namely those used for returning a string result from commands.
473
+ * Direct access to the result field is discouraged in Tcl 8.0. The
474
+ * interpreter result is either an object or a string, and the two values are
475
+ * kept consistent unless some C code sets interp->result directly.
476
+ * Programmers should use either the function Tcl_GetObjResult() or
477
+ * Tcl_GetStringResult() to read the interpreter's result. See the SetResult
478
+ * man page for details.
479
+ *
480
+ * Note: any change to the Tcl_Interp definition below must be mirrored in the
481
+ * "real" definition in tclInt.h.
482
+ *
483
+ * Note: Tcl_ObjCmdProc functions do not directly set result and freeProc.
484
+ * Instead, they set a Tcl_Obj member in the "real" structure that can be
485
+ * accessed with Tcl_GetObjResult() and Tcl_SetObjResult().
486
+ */
487
+
488
+typedef struct Tcl_Interp
489
+#ifndef TCL_NO_DEPRECATED
490
+{
491
+ /* TIP #330: Strongly discourage extensions from using the string
492
+ * result. */
493
+#ifdef USE_INTERP_RESULT
494
+ char *result TCL_DEPRECATED_API("use Tcl_GetResult/Tcl_SetResult");
495
+ /* If the last command returned a string
496
+ * result, this points to it. */
497
+ void (*freeProc) (char *blockPtr)
498
+ TCL_DEPRECATED_API("use Tcl_GetResult/Tcl_SetResult");
499
+ /* Zero means the string result is statically
500
+ * allocated. TCL_DYNAMIC means it was
501
+ * allocated with ckalloc and should be freed
502
+ * with ckfree. Other values give the address
503
+ * of function to invoke to free the result.
504
+ * Tcl_Eval must free it before executing next
505
+ * command. */
506
+#else
507
+ char *resultDontUse; /* Don't use in extensions! */
508
+ void (*freeProcDontUse) (char *); /* Don't use in extensions! */
509
+#endif
510
+#ifdef USE_INTERP_ERRORLINE
511
+ int errorLine TCL_DEPRECATED_API("use Tcl_GetErrorLine/Tcl_SetErrorLine");
512
+ /* When TCL_ERROR is returned, this gives the
513
+ * line number within the command where the
514
+ * error occurred (1 if first line). */
515
+#else
516
+ int errorLineDontUse; /* Don't use in extensions! */
517
+#endif
518
+}
519
+#endif /* TCL_NO_DEPRECATED */
520
+Tcl_Interp;
521
+
522
+typedef struct Tcl_AsyncHandler_ *Tcl_AsyncHandler;
523
+typedef struct Tcl_Channel_ *Tcl_Channel;
524
+typedef struct Tcl_ChannelTypeVersion_ *Tcl_ChannelTypeVersion;
525
+typedef struct Tcl_Command_ *Tcl_Command;
526
+typedef struct Tcl_Condition_ *Tcl_Condition;
527
+typedef struct Tcl_Dict_ *Tcl_Dict;
528
+typedef struct Tcl_EncodingState_ *Tcl_EncodingState;
529
+typedef struct Tcl_Encoding_ *Tcl_Encoding;
530
+typedef struct Tcl_Event Tcl_Event;
531
+typedef struct Tcl_InterpState_ *Tcl_InterpState;
532
+typedef struct Tcl_LoadHandle_ *Tcl_LoadHandle;
533
+typedef struct Tcl_Mutex_ *Tcl_Mutex;
534
+typedef struct Tcl_Pid_ *Tcl_Pid;
535
+typedef struct Tcl_RegExp_ *Tcl_RegExp;
536
+typedef struct Tcl_ThreadDataKey_ *Tcl_ThreadDataKey;
537
+typedef struct Tcl_ThreadId_ *Tcl_ThreadId;
538
+typedef struct Tcl_TimerToken_ *Tcl_TimerToken;
539
+typedef struct Tcl_Trace_ *Tcl_Trace;
540
+typedef struct Tcl_Var_ *Tcl_Var;
541
+typedef struct Tcl_ZLibStream_ *Tcl_ZlibStream;
542
+
543
+/*
544
+ *----------------------------------------------------------------------------
545
+ * Definition of the interface to functions implementing threads. A function
546
+ * following this definition is given to each call of 'Tcl_CreateThread' and
547
+ * will be called as the main fuction of the new thread created by that call.
548
+ */
549
+
550
+#if defined __WIN32__
551
+typedef unsigned (__stdcall Tcl_ThreadCreateProc) (ClientData clientData);
552
+#else
553
+typedef void (Tcl_ThreadCreateProc) (ClientData clientData);
554
+#endif
555
+
556
+/*
557
+ * Threading function return types used for abstracting away platform
558
+ * differences when writing a Tcl_ThreadCreateProc. See the NewThread function
559
+ * in generic/tclThreadTest.c for it's usage.
560
+ */
561
+
562
+#if defined __WIN32__
563
+# define Tcl_ThreadCreateType unsigned __stdcall
564
+# define TCL_THREAD_CREATE_RETURN return 0
565
+#else
566
+# define Tcl_ThreadCreateType void
567
+# define TCL_THREAD_CREATE_RETURN
568
+#endif
569
+
570
+/*
571
+ * Definition of values for default stacksize and the possible flags to be
572
+ * given to Tcl_CreateThread.
573
+ */
574
+
575
+#define TCL_THREAD_STACK_DEFAULT (0) /* Use default size for stack. */
576
+#define TCL_THREAD_NOFLAGS (0000) /* Standard flags, default
577
+ * behaviour. */
578
+#define TCL_THREAD_JOINABLE (0001) /* Mark the thread as joinable. */
579
+
580
+/*
581
+ * Flag values passed to Tcl_StringCaseMatch.
582
+ */
583
+
584
+#define TCL_MATCH_NOCASE (1<<0)
585
+
586
+/*
587
+ * Flag values passed to Tcl_GetRegExpFromObj.
588
+ */
589
+
590
+#define TCL_REG_BASIC 000000 /* BREs (convenience). */
591
+#define TCL_REG_EXTENDED 000001 /* EREs. */
592
+#define TCL_REG_ADVF 000002 /* Advanced features in EREs. */
593
+#define TCL_REG_ADVANCED 000003 /* AREs (which are also EREs). */
594
+#define TCL_REG_QUOTE 000004 /* No special characters, none. */
595
+#define TCL_REG_NOCASE 000010 /* Ignore case. */
596
+#define TCL_REG_NOSUB 000020 /* Don't care about subexpressions. */
597
+#define TCL_REG_EXPANDED 000040 /* Expanded format, white space &
598
+ * comments. */
599
+#define TCL_REG_NLSTOP 000100 /* \n doesn't match . or [^ ] */
600
+#define TCL_REG_NLANCH 000200 /* ^ matches after \n, $ before. */
601
+#define TCL_REG_NEWLINE 000300 /* Newlines are line terminators. */
602
+#define TCL_REG_CANMATCH 001000 /* Report details on partial/limited
603
+ * matches. */
604
+
605
+/*
606
+ * Flags values passed to Tcl_RegExpExecObj.
607
+ */
608
+
609
+#define TCL_REG_NOTBOL 0001 /* Beginning of string does not match ^. */
610
+#define TCL_REG_NOTEOL 0002 /* End of string does not match $. */
611
+
612
+/*
613
+ * Structures filled in by Tcl_RegExpInfo. Note that all offset values are
614
+ * relative to the start of the match string, not the beginning of the entire
615
+ * string.
616
+ */
617
+
618
+typedef struct Tcl_RegExpIndices {
619
+ long start; /* Character offset of first character in
620
+ * match. */
621
+ long end; /* Character offset of first character after
622
+ * the match. */
623
+} Tcl_RegExpIndices;
624
+
625
+typedef struct Tcl_RegExpInfo {
626
+ int nsubs; /* Number of subexpressions in the compiled
627
+ * expression. */
628
+ Tcl_RegExpIndices *matches; /* Array of nsubs match offset pairs. */
629
+ long extendStart; /* The offset at which a subsequent match
630
+ * might begin. */
631
+ long reserved; /* Reserved for later use. */
632
+} Tcl_RegExpInfo;
633
+
634
+/*
635
+ * Picky compilers complain if this typdef doesn't appear before the struct's
636
+ * reference in tclDecls.h.
637
+ */
638
+
639
+typedef Tcl_StatBuf *Tcl_Stat_;
640
+typedef struct stat *Tcl_OldStat_;
641
+
642
+/*
643
+ *----------------------------------------------------------------------------
644
+ * When a TCL command returns, the interpreter contains a result from the
645
+ * command. Programmers are strongly encouraged to use one of the functions
646
+ * Tcl_GetObjResult() or Tcl_GetStringResult() to read the interpreter's
647
+ * result. See the SetResult man page for details. Besides this result, the
648
+ * command function returns an integer code, which is one of the following:
649
+ *
650
+ * TCL_OK Command completed normally; the interpreter's result
651
+ * contains the command's result.
652
+ * TCL_ERROR The command couldn't be completed successfully; the
653
+ * interpreter's result describes what went wrong.
654
+ * TCL_RETURN The command requests that the current function return;
655
+ * the interpreter's result contains the function's
656
+ * return value.
657
+ * TCL_BREAK The command requests that the innermost loop be
658
+ * exited; the interpreter's result is meaningless.
659
+ * TCL_CONTINUE Go on to the next iteration of the current loop; the
660
+ * interpreter's result is meaningless.
661
+ */
662
+
663
+#define TCL_OK 0
664
+#define TCL_ERROR 1
665
+#define TCL_RETURN 2
666
+#define TCL_BREAK 3
667
+#define TCL_CONTINUE 4
668
+
669
+#define TCL_RESULT_SIZE 200
670
+
671
+/*
672
+ *----------------------------------------------------------------------------
673
+ * Flags to control what substitutions are performed by Tcl_SubstObj():
674
+ */
675
+
676
+#define TCL_SUBST_COMMANDS 001
677
+#define TCL_SUBST_VARIABLES 002
678
+#define TCL_SUBST_BACKSLASHES 004
679
+#define TCL_SUBST_ALL 007
680
+
681
+/*
682
+ * Argument descriptors for math function callbacks in expressions:
683
+ */
684
+
685
+typedef enum {
686
+ TCL_INT, TCL_DOUBLE, TCL_EITHER, TCL_WIDE_INT
687
+} Tcl_ValueType;
688
+
689
+typedef struct Tcl_Value {
690
+ Tcl_ValueType type; /* Indicates intValue or doubleValue is valid,
691
+ * or both. */
692
+ long intValue; /* Integer value. */
693
+ double doubleValue; /* Double-precision floating value. */
694
+ Tcl_WideInt wideValue; /* Wide (min. 64-bit) integer value. */
695
+} Tcl_Value;
696
+
697
+/*
698
+ * Forward declaration of Tcl_Obj to prevent an error when the forward
699
+ * reference to Tcl_Obj is encountered in the function types declared below.
700
+ */
701
+
702
+struct Tcl_Obj;
703
+
704
+/*
705
+ *----------------------------------------------------------------------------
706
+ * Function types defined by Tcl:
707
+ */
708
+
709
+typedef int (Tcl_AppInitProc) (Tcl_Interp *interp);
710
+typedef int (Tcl_AsyncProc) (ClientData clientData, Tcl_Interp *interp,
711
+ int code);
712
+typedef void (Tcl_ChannelProc) (ClientData clientData, int mask);
713
+typedef void (Tcl_CloseProc) (ClientData data);
714
+typedef void (Tcl_CmdDeleteProc) (ClientData clientData);
715
+typedef int (Tcl_CmdProc) (ClientData clientData, Tcl_Interp *interp,
716
+ int argc, CONST84 char *argv[]);
717
+typedef void (Tcl_CmdTraceProc) (ClientData clientData, Tcl_Interp *interp,
718
+ int level, char *command, Tcl_CmdProc *proc,
719
+ ClientData cmdClientData, int argc, CONST84 char *argv[]);
720
+typedef int (Tcl_CmdObjTraceProc) (ClientData clientData, Tcl_Interp *interp,
721
+ int level, const char *command, Tcl_Command commandInfo, int objc,
722
+ struct Tcl_Obj *const *objv);
723
+typedef void (Tcl_CmdObjTraceDeleteProc) (ClientData clientData);
724
+typedef void (Tcl_DupInternalRepProc) (struct Tcl_Obj *srcPtr,
725
+ struct Tcl_Obj *dupPtr);
726
+typedef int (Tcl_EncodingConvertProc) (ClientData clientData, const char *src,
727
+ int srcLen, int flags, Tcl_EncodingState *statePtr, char *dst,
728
+ int dstLen, int *srcReadPtr, int *dstWrotePtr, int *dstCharsPtr);
729
+typedef void (Tcl_EncodingFreeProc) (ClientData clientData);
730
+typedef int (Tcl_EventProc) (Tcl_Event *evPtr, int flags);
731
+typedef void (Tcl_EventCheckProc) (ClientData clientData, int flags);
732
+typedef int (Tcl_EventDeleteProc) (Tcl_Event *evPtr, ClientData clientData);
733
+typedef void (Tcl_EventSetupProc) (ClientData clientData, int flags);
734
+typedef void (Tcl_ExitProc) (ClientData clientData);
735
+typedef void (Tcl_FileProc) (ClientData clientData, int mask);
736
+typedef void (Tcl_FileFreeProc) (ClientData clientData);
737
+typedef void (Tcl_FreeInternalRepProc) (struct Tcl_Obj *objPtr);
738
+typedef void (Tcl_FreeProc) (char *blockPtr);
739
+typedef void (Tcl_IdleProc) (ClientData clientData);
740
+typedef void (Tcl_InterpDeleteProc) (ClientData clientData,
741
+ Tcl_Interp *interp);
742
+typedef int (Tcl_MathProc) (ClientData clientData, Tcl_Interp *interp,
743
+ Tcl_Value *args, Tcl_Value *resultPtr);
744
+typedef void (Tcl_NamespaceDeleteProc) (ClientData clientData);
745
+typedef int (Tcl_ObjCmdProc) (ClientData clientData, Tcl_Interp *interp,
746
+ int objc, struct Tcl_Obj *const *objv);
747
+typedef int (Tcl_PackageInitProc) (Tcl_Interp *interp);
748
+typedef int (Tcl_PackageUnloadProc) (Tcl_Interp *interp, int flags);
749
+typedef void (Tcl_PanicProc) (const char *format, ...);
750
+typedef void (Tcl_TcpAcceptProc) (ClientData callbackData, Tcl_Channel chan,
751
+ char *address, int port);
752
+typedef void (Tcl_TimerProc) (ClientData clientData);
753
+typedef int (Tcl_SetFromAnyProc) (Tcl_Interp *interp, struct Tcl_Obj *objPtr);
754
+typedef void (Tcl_UpdateStringProc) (struct Tcl_Obj *objPtr);
755
+typedef char * (Tcl_VarTraceProc) (ClientData clientData, Tcl_Interp *interp,
756
+ CONST84 char *part1, CONST84 char *part2, int flags);
757
+typedef void (Tcl_CommandTraceProc) (ClientData clientData, Tcl_Interp *interp,
758
+ const char *oldName, const char *newName, int flags);
759
+typedef void (Tcl_CreateFileHandlerProc) (int fd, int mask, Tcl_FileProc *proc,
760
+ ClientData clientData);
761
+typedef void (Tcl_DeleteFileHandlerProc) (int fd);
762
+typedef void (Tcl_AlertNotifierProc) (ClientData clientData);
763
+typedef void (Tcl_ServiceModeHookProc) (int mode);
764
+typedef ClientData (Tcl_InitNotifierProc) (void);
765
+typedef void (Tcl_FinalizeNotifierProc) (ClientData clientData);
766
+typedef void (Tcl_MainLoopProc) (void);
767
+
768
+
769
+/*
770
+ *----------------------------------------------------------------------------
771
+ * The following structure represents a type of object, which is a particular
772
+ * internal representation for an object plus a set of functions that provide
773
+ * standard operations on objects of that type.
774
+ */
775
+
776
+typedef struct Tcl_ObjType {
777
+ const char *name; /* Name of the type, e.g. "int". */
778
+ Tcl_FreeInternalRepProc *freeIntRepProc;
779
+ /* Called to free any storage for the type's
780
+ * internal rep. NULL if the internal rep does
781
+ * not need freeing. */
782
+ Tcl_DupInternalRepProc *dupIntRepProc;
783
+ /* Called to create a new object as a copy of
784
+ * an existing object. */
785
+ Tcl_UpdateStringProc *updateStringProc;
786
+ /* Called to update the string rep from the
787
+ * type's internal representation. */
788
+ Tcl_SetFromAnyProc *setFromAnyProc;
789
+ /* Called to convert the object's internal rep
790
+ * to this type. Frees the internal rep of the
791
+ * old type. Returns TCL_ERROR on failure. */
792
+} Tcl_ObjType;
793
+
794
+/*
795
+ * One of the following structures exists for each object in the Tcl system.
796
+ * An object stores a value as either a string, some internal representation,
797
+ * or both.
798
+ */
799
+
800
+typedef struct Tcl_Obj {
801
+ int refCount; /* When 0 the object will be freed. */
802
+ char *bytes; /* This points to the first byte of the
803
+ * object's string representation. The array
804
+ * must be followed by a null byte (i.e., at
805
+ * offset length) but may also contain
806
+ * embedded null characters. The array's
807
+ * storage is allocated by ckalloc. NULL means
808
+ * the string rep is invalid and must be
809
+ * regenerated from the internal rep. Clients
810
+ * should use Tcl_GetStringFromObj or
811
+ * Tcl_GetString to get a pointer to the byte
812
+ * array as a readonly value. */
813
+ int length; /* The number of bytes at *bytes, not
814
+ * including the terminating null. */
815
+ const Tcl_ObjType *typePtr; /* Denotes the object's type. Always
816
+ * corresponds to the type of the object's
817
+ * internal rep. NULL indicates the object has
818
+ * no internal rep (has no type). */
819
+ union { /* The internal representation: */
820
+ long longValue; /* - an long integer value. */
821
+ double doubleValue; /* - a double-precision floating value. */
822
+ void *otherValuePtr; /* - another, type-specific value. */
823
+ Tcl_WideInt wideValue; /* - a long long value. */
824
+ struct { /* - internal rep as two pointers. */
825
+ void *ptr1;
826
+ void *ptr2;
827
+ } twoPtrValue;
828
+ struct { /* - internal rep as a pointer and a long,
829
+ * the main use of which is a bignum's
830
+ * tightly packed fields, where the alloc,
831
+ * used and signum flags are packed into a
832
+ * single word with everything else hung
833
+ * off the pointer. */
834
+ void *ptr;
835
+ unsigned long value;
836
+ } ptrAndLongRep;
837
+ } internalRep;
838
+} Tcl_Obj;
839
+
840
+/*
841
+ * Macros to increment and decrement a Tcl_Obj's reference count, and to test
842
+ * whether an object is shared (i.e. has reference count > 1). Note: clients
843
+ * should use Tcl_DecrRefCount() when they are finished using an object, and
844
+ * should never call TclFreeObj() directly. TclFreeObj() is only defined and
845
+ * made public in tcl.h to support Tcl_DecrRefCount's macro definition.
846
+ */
847
+
848
+void Tcl_IncrRefCount(Tcl_Obj *objPtr);
849
+void Tcl_DecrRefCount(Tcl_Obj *objPtr);
850
+int Tcl_IsShared(Tcl_Obj *objPtr);
851
+
852
+
853
+/*
854
+ *----------------------------------------------------------------------------
855
+ * The following structure contains the state needed by Tcl_SaveResult. No-one
856
+ * outside of Tcl should access any of these fields. This structure is
857
+ * typically allocated on the stack.
858
+ */
859
+
860
+typedef struct Tcl_SavedResult {
861
+ char *result;
862
+ Tcl_FreeProc *freeProc;
863
+ Tcl_Obj *objResultPtr;
864
+ char *appendResult;
865
+ int appendAvl;
866
+ int appendUsed;
867
+ char resultSpace[TCL_RESULT_SIZE+1];
868
+} Tcl_SavedResult;
869
+
870
+/*
871
+ *----------------------------------------------------------------------------
872
+ * The following definitions support Tcl's namespace facility. Note: the first
873
+ * five fields must match exactly the fields in a Namespace structure (see
874
+ * tclInt.h).
875
+ */
876
+
877
+typedef struct Tcl_Namespace {
878
+ char *name; /* The namespace's name within its parent
879
+ * namespace. This contains no ::'s. The name
880
+ * of the global namespace is "" although "::"
881
+ * is an synonym. */
882
+ char *fullName; /* The namespace's fully qualified name. This
883
+ * starts with ::. */
884
+ ClientData clientData; /* Arbitrary value associated with this
885
+ * namespace. */
886
+ Tcl_NamespaceDeleteProc *deleteProc;
887
+ /* Function invoked when deleting the
888
+ * namespace to, e.g., free clientData. */
889
+ struct Tcl_Namespace *parentPtr;
890
+ /* Points to the namespace that contains this
891
+ * one. NULL if this is the global
892
+ * namespace. */
893
+} Tcl_Namespace;
894
+
895
+/*
896
+ *----------------------------------------------------------------------------
897
+ * The following structure represents a call frame, or activation record. A
898
+ * call frame defines a naming context for a procedure call: its local scope
899
+ * (for local variables) and its namespace scope (used for non-local
900
+ * variables; often the global :: namespace). A call frame can also define the
901
+ * naming context for a namespace eval or namespace inscope command: the
902
+ * namespace in which the command's code should execute. The Tcl_CallFrame
903
+ * structures exist only while procedures or namespace eval/inscope's are
904
+ * being executed, and provide a Tcl call stack.
905
+ *
906
+ * A call frame is initialized and pushed using Tcl_PushCallFrame and popped
907
+ * using Tcl_PopCallFrame. Storage for a Tcl_CallFrame must be provided by the
908
+ * Tcl_PushCallFrame caller, and callers typically allocate them on the C call
909
+ * stack for efficiency. For this reason, Tcl_CallFrame is defined as a
910
+ * structure and not as an opaque token. However, most Tcl_CallFrame fields
911
+ * are hidden since applications should not access them directly; others are
912
+ * declared as "dummyX".
913
+ *
914
+ * WARNING!! The structure definition must be kept consistent with the
915
+ * CallFrame structure in tclInt.h. If you change one, change the other.
916
+ */
917
+
918
+typedef struct Tcl_CallFrame {
919
+ Tcl_Namespace *nsPtr;
920
+ int dummy1;
921
+ int dummy2;
922
+ void *dummy3;
923
+ void *dummy4;
924
+ void *dummy5;
925
+ int dummy6;
926
+ void *dummy7;
927
+ void *dummy8;
928
+ int dummy9;
929
+ void *dummy10;
930
+ void *dummy11;
931
+ void *dummy12;
932
+ void *dummy13;
933
+} Tcl_CallFrame;
934
+
935
+/*
936
+ *----------------------------------------------------------------------------
937
+ * Information about commands that is returned by Tcl_GetCommandInfo and
938
+ * passed to Tcl_SetCommandInfo. objProc is an objc/objv object-based command
939
+ * function while proc is a traditional Tcl argc/argv string-based function.
940
+ * Tcl_CreateObjCommand and Tcl_CreateCommand ensure that both objProc and
941
+ * proc are non-NULL and can be called to execute the command. However, it may
942
+ * be faster to call one instead of the other. The member isNativeObjectProc
943
+ * is set to 1 if an object-based function was registered by
944
+ * Tcl_CreateObjCommand, and to 0 if a string-based function was registered by
945
+ * Tcl_CreateCommand. The other function is typically set to a compatibility
946
+ * wrapper that does string-to-object or object-to-string argument conversions
947
+ * then calls the other function.
948
+ */
949
+
950
+typedef struct Tcl_CmdInfo {
951
+ int isNativeObjectProc; /* 1 if objProc was registered by a call to
952
+ * Tcl_CreateObjCommand; 0 otherwise.
953
+ * Tcl_SetCmdInfo does not modify this
954
+ * field. */
955
+ Tcl_ObjCmdProc *objProc; /* Command's object-based function. */
956
+ ClientData objClientData; /* ClientData for object proc. */
957
+ Tcl_CmdProc *proc; /* Command's string-based function. */
958
+ ClientData clientData; /* ClientData for string proc. */
959
+ Tcl_CmdDeleteProc *deleteProc;
960
+ /* Function to call when command is
961
+ * deleted. */
962
+ ClientData deleteData; /* Value to pass to deleteProc (usually the
963
+ * same as clientData). */
964
+ Tcl_Namespace *namespacePtr;/* Points to the namespace that contains this
965
+ * command. Note that Tcl_SetCmdInfo will not
966
+ * change a command's namespace; use
967
+ * TclRenameCommand or Tcl_Eval (of 'rename')
968
+ * to do that. */
969
+} Tcl_CmdInfo;
970
+
971
+/*
972
+ *----------------------------------------------------------------------------
973
+ * The structure defined below is used to hold dynamic strings. The only
974
+ * fields that clients should use are string and length, accessible via the
975
+ * macros Tcl_DStringValue and Tcl_DStringLength.
976
+ */
977
+
978
+#define TCL_DSTRING_STATIC_SIZE 200
979
+typedef struct Tcl_DString {
980
+ char *string; /* Points to beginning of string: either
981
+ * staticSpace below or a malloced array. */
982
+ int length; /* Number of non-NULL characters in the
983
+ * string. */
984
+ int spaceAvl; /* Total number of bytes available for the
985
+ * string and its terminating NULL char. */
986
+ char staticSpace[TCL_DSTRING_STATIC_SIZE];
987
+ /* Space to use in common case where string is
988
+ * small. */
989
+} Tcl_DString;
990
+
991
+#define Tcl_DStringLength(dsPtr) ((dsPtr)->length)
992
+#define Tcl_DStringValue(dsPtr) ((dsPtr)->string)
993
+#define Tcl_DStringTrunc Tcl_DStringSetLength
994
+
995
+/*
996
+ * Definitions for the maximum number of digits of precision that may be
997
+ * specified in the "tcl_precision" variable, and the number of bytes of
998
+ * buffer space required by Tcl_PrintDouble.
999
+ */
1000
+
1001
+#define TCL_MAX_PREC 17
1002
+#define TCL_DOUBLE_SPACE (TCL_MAX_PREC+10)
1003
+
1004
+/*
1005
+ * Definition for a number of bytes of buffer space sufficient to hold the
1006
+ * string representation of an integer in base 10 (assuming the existence of
1007
+ * 64-bit integers).
1008
+ */
1009
+
1010
+#define TCL_INTEGER_SPACE 24
1011
+
1012
+/*
1013
+ * Flag values passed to Tcl_ConvertElement.
1014
+ * TCL_DONT_USE_BRACES forces it not to enclose the element in braces, but to
1015
+ * use backslash quoting instead.
1016
+ * TCL_DONT_QUOTE_HASH disables the default quoting of the '#' character. It
1017
+ * is safe to leave the hash unquoted when the element is not the first
1018
+ * element of a list, and this flag can be used by the caller to indicate
1019
+ * that condition.
1020
+ */
1021
+
1022
+#define TCL_DONT_USE_BRACES 1
1023
+#define TCL_DONT_QUOTE_HASH 8
1024
+
1025
+/*
1026
+ * Flag that may be passed to Tcl_GetIndexFromObj to force it to disallow
1027
+ * abbreviated strings.
1028
+ */
1029
+
1030
+#define TCL_EXACT 1
1031
+
1032
+/*
1033
+ *----------------------------------------------------------------------------
1034
+ * Flag values passed to Tcl_RecordAndEval, Tcl_EvalObj, Tcl_EvalObjv.
1035
+ * WARNING: these bit choices must not conflict with the bit choices for
1036
+ * evalFlag bits in tclInt.h!
1037
+ *
1038
+ * Meanings:
1039
+ * TCL_NO_EVAL: Just record this command
1040
+ * TCL_EVAL_GLOBAL: Execute script in global namespace
1041
+ * TCL_EVAL_DIRECT: Do not compile this script
1042
+ * TCL_EVAL_INVOKE: Magical Tcl_EvalObjv mode for aliases/ensembles
1043
+ * o Run in iPtr->lookupNsPtr or global namespace
1044
+ * o Cut out of error traces
1045
+ * o Don't reset the flags controlling ensemble
1046
+ * error message rewriting.
1047
+ * TCL_CANCEL_UNWIND: Magical Tcl_CancelEval mode that causes the
1048
+ * stack for the script in progress to be
1049
+ * completely unwound.
1050
+ * TCL_EVAL_NOERR: Do no exception reporting at all, just return
1051
+ * as the caller will report.
1052
+ */
1053
+
1054
+#define TCL_NO_EVAL 0x010000
1055
+#define TCL_EVAL_GLOBAL 0x020000
1056
+#define TCL_EVAL_DIRECT 0x040000
1057
+#define TCL_EVAL_INVOKE 0x080000
1058
+#define TCL_CANCEL_UNWIND 0x100000
1059
+#define TCL_EVAL_NOERR 0x200000
1060
+
1061
+/*
1062
+ * Special freeProc values that may be passed to Tcl_SetResult (see the man
1063
+ * page for details):
1064
+ */
1065
+
1066
+#define TCL_VOLATILE ((Tcl_FreeProc *) 1)
1067
+#define TCL_STATIC ((Tcl_FreeProc *) 0)
1068
+#define TCL_DYNAMIC ((Tcl_FreeProc *) 3)
1069
+
1070
+/*
1071
+ * Flag values passed to variable-related functions.
1072
+ * WARNING: these bit choices must not conflict with the bit choice for
1073
+ * TCL_CANCEL_UNWIND, above.
1074
+ */
1075
+
1076
+#define TCL_GLOBAL_ONLY 1
1077
+#define TCL_NAMESPACE_ONLY 2
1078
+#define TCL_APPEND_VALUE 4
1079
+#define TCL_LIST_ELEMENT 8
1080
+#define TCL_TRACE_READS 0x10
1081
+#define TCL_TRACE_WRITES 0x20
1082
+#define TCL_TRACE_UNSETS 0x40
1083
+#define TCL_TRACE_DESTROYED 0x80
1084
+#define TCL_INTERP_DESTROYED 0x100
1085
+#define TCL_LEAVE_ERR_MSG 0x200
1086
+#define TCL_TRACE_ARRAY 0x800
1087
+#ifndef TCL_REMOVE_OBSOLETE_TRACES
1088
+/* Required to support old variable/vdelete/vinfo traces. */
1089
+#define TCL_TRACE_OLD_STYLE 0x1000
1090
+#endif
1091
+/* Indicate the semantics of the result of a trace. */
1092
+#define TCL_TRACE_RESULT_DYNAMIC 0x8000
1093
+#define TCL_TRACE_RESULT_OBJECT 0x10000
1094
+
1095
+/*
1096
+ * Flag values for ensemble commands.
1097
+ */
1098
+
1099
+#define TCL_ENSEMBLE_PREFIX 0x02/* Flag value to say whether to allow
1100
+ * unambiguous prefixes of commands or to
1101
+ * require exact matches for command names. */
1102
+
1103
+/*
1104
+ * Flag values passed to command-related functions.
1105
+ */
1106
+
1107
+#define TCL_TRACE_RENAME 0x2000
1108
+#define TCL_TRACE_DELETE 0x4000
1109
+
1110
+#define TCL_ALLOW_INLINE_COMPILATION 0x20000
1111
+
1112
+/*
1113
+ * The TCL_PARSE_PART1 flag is deprecated and has no effect. The part1 is now
1114
+ * always parsed whenever the part2 is NULL. (This is to avoid a common error
1115
+ * when converting code to use the new object based APIs and forgetting to
1116
+ * give the flag)
1117
+ */
1118
+
1119
+#ifndef TCL_NO_DEPRECATED
1120
+# define TCL_PARSE_PART1 0x400
1121
+#endif
1122
+
1123
+/*
1124
+ * Types for linked variables:
1125
+ */
1126
+
1127
+#define TCL_LINK_INT 1
1128
+#define TCL_LINK_DOUBLE 2
1129
+#define TCL_LINK_BOOLEAN 3
1130
+#define TCL_LINK_STRING 4
1131
+#define TCL_LINK_WIDE_INT 5
1132
+#define TCL_LINK_CHAR 6
1133
+#define TCL_LINK_UCHAR 7
1134
+#define TCL_LINK_SHORT 8
1135
+#define TCL_LINK_USHORT 9
1136
+#define TCL_LINK_UINT 10
1137
+#define TCL_LINK_LONG 11
1138
+#define TCL_LINK_ULONG 12
1139
+#define TCL_LINK_FLOAT 13
1140
+#define TCL_LINK_WIDE_UINT 14
1141
+#define TCL_LINK_READ_ONLY 0x80
1142
+
1143
+
1144
+/*
1145
+ *----------------------------------------------------------------------------
1146
+ * Forward declarations of Tcl_HashTable and related types.
1147
+ */
1148
+
1149
+typedef struct Tcl_HashKeyType Tcl_HashKeyType;
1150
+typedef struct Tcl_HashTable Tcl_HashTable;
1151
+typedef struct Tcl_HashEntry Tcl_HashEntry;
1152
+
1153
+typedef unsigned (Tcl_HashKeyProc) (Tcl_HashTable *tablePtr, void *keyPtr);
1154
+typedef int (Tcl_CompareHashKeysProc) (void *keyPtr, Tcl_HashEntry *hPtr);
1155
+typedef Tcl_HashEntry * (Tcl_AllocHashEntryProc) (Tcl_HashTable *tablePtr,
1156
+ void *keyPtr);
1157
+typedef void (Tcl_FreeHashEntryProc) (Tcl_HashEntry *hPtr);
1158
+
1159
+/*
1160
+ * This flag controls whether the hash table stores the hash of a key, or
1161
+ * recalculates it. There should be no reason for turning this flag off as it
1162
+ * is completely binary and source compatible unless you directly access the
1163
+ * bucketPtr member of the Tcl_HashTableEntry structure. This member has been
1164
+ * removed and the space used to store the hash value.
1165
+ */
1166
+
1167
+#ifndef TCL_HASH_KEY_STORE_HASH
1168
+# define TCL_HASH_KEY_STORE_HASH 1
1169
+#endif
1170
+
1171
+/*
1172
+ * Structure definition for an entry in a hash table. No-one outside Tcl
1173
+ * should access any of these fields directly; use the macros defined below.
1174
+ */
1175
+
1176
+struct Tcl_HashEntry {
1177
+ Tcl_HashEntry *nextPtr; /* Pointer to next entry in this hash bucket,
1178
+ * or NULL for end of chain. */
1179
+ Tcl_HashTable *tablePtr; /* Pointer to table containing entry. */
1180
+#if TCL_HASH_KEY_STORE_HASH
1181
+ void *hash; /* Hash value, stored as pointer to ensure
1182
+ * that the offsets of the fields in this
1183
+ * structure are not changed. */
1184
+#else
1185
+ Tcl_HashEntry **bucketPtr; /* Pointer to bucket that points to first
1186
+ * entry in this entry's chain: used for
1187
+ * deleting the entry. */
1188
+#endif
1189
+ ClientData clientData; /* Application stores something here with
1190
+ * Tcl_SetHashValue. */
1191
+ union { /* Key has one of these forms: */
1192
+ char *oneWordValue; /* One-word value for key. */
1193
+ Tcl_Obj *objPtr; /* Tcl_Obj * key value. */
1194
+ int words[1]; /* Multiple integer words for key. The actual
1195
+ * size will be as large as necessary for this
1196
+ * table's keys. */
1197
+ char string[1]; /* String for key. The actual size will be as
1198
+ * large as needed to hold the key. */
1199
+ } key; /* MUST BE LAST FIELD IN RECORD!! */
1200
+};
1201
+
1202
+/*
1203
+ * Flags used in Tcl_HashKeyType.
1204
+ *
1205
+ * TCL_HASH_KEY_RANDOMIZE_HASH -
1206
+ * There are some things, pointers for example
1207
+ * which don't hash well because they do not use
1208
+ * the lower bits. If this flag is set then the
1209
+ * hash table will attempt to rectify this by
1210
+ * randomising the bits and then using the upper
1211
+ * N bits as the index into the table.
1212
+ * TCL_HASH_KEY_SYSTEM_HASH - If this flag is set then all memory internally
1213
+ * allocated for the hash table that is not for an
1214
+ * entry will use the system heap.
1215
+ */
1216
+
1217
+#define TCL_HASH_KEY_RANDOMIZE_HASH 0x1
1218
+#define TCL_HASH_KEY_SYSTEM_HASH 0x2
1219
+
1220
+/*
1221
+ * Structure definition for the methods associated with a hash table key type.
1222
+ */
1223
+
1224
+#define TCL_HASH_KEY_TYPE_VERSION 1
1225
+struct Tcl_HashKeyType {
1226
+ int version; /* Version of the table. If this structure is
1227
+ * extended in future then the version can be
1228
+ * used to distinguish between different
1229
+ * structures. */
1230
+ int flags; /* Flags, see above for details. */
1231
+ Tcl_HashKeyProc *hashKeyProc;
1232
+ /* Calculates a hash value for the key. If
1233
+ * this is NULL then the pointer itself is
1234
+ * used as a hash value. */
1235
+ Tcl_CompareHashKeysProc *compareKeysProc;
1236
+ /* Compares two keys and returns zero if they
1237
+ * do not match, and non-zero if they do. If
1238
+ * this is NULL then the pointers are
1239
+ * compared. */
1240
+ Tcl_AllocHashEntryProc *allocEntryProc;
1241
+ /* Called to allocate memory for a new entry,
1242
+ * i.e. if the key is a string then this could
1243
+ * allocate a single block which contains
1244
+ * enough space for both the entry and the
1245
+ * string. Only the key field of the allocated
1246
+ * Tcl_HashEntry structure needs to be filled
1247
+ * in. If something else needs to be done to
1248
+ * the key, i.e. incrementing a reference
1249
+ * count then that should be done by this
1250
+ * function. If this is NULL then Tcl_Alloc is
1251
+ * used to allocate enough space for a
1252
+ * Tcl_HashEntry and the key pointer is
1253
+ * assigned to key.oneWordValue. */
1254
+ Tcl_FreeHashEntryProc *freeEntryProc;
1255
+ /* Called to free memory associated with an
1256
+ * entry. If something else needs to be done
1257
+ * to the key, i.e. decrementing a reference
1258
+ * count then that should be done by this
1259
+ * function. If this is NULL then Tcl_Free is
1260
+ * used to free the Tcl_HashEntry. */
1261
+};
1262
+
1263
+/*
1264
+ * Structure definition for a hash table. Must be in tcl.h so clients can
1265
+ * allocate space for these structures, but clients should never access any
1266
+ * fields in this structure.
1267
+ */
1268
+
1269
+#define TCL_SMALL_HASH_TABLE 4
1270
+struct Tcl_HashTable {
1271
+ Tcl_HashEntry **buckets; /* Pointer to bucket array. Each element
1272
+ * points to first entry in bucket's hash
1273
+ * chain, or NULL. */
1274
+ Tcl_HashEntry *staticBuckets[TCL_SMALL_HASH_TABLE];
1275
+ /* Bucket array used for small tables (to
1276
+ * avoid mallocs and frees). */
1277
+ int numBuckets; /* Total number of buckets allocated at
1278
+ * **bucketPtr. */
1279
+ int numEntries; /* Total number of entries present in
1280
+ * table. */
1281
+ int rebuildSize; /* Enlarge table when numEntries gets to be
1282
+ * this large. */
1283
+ int downShift; /* Shift count used in hashing function.
1284
+ * Designed to use high-order bits of
1285
+ * randomized keys. */
1286
+ int mask; /* Mask value used in hashing function. */
1287
+ int keyType; /* Type of keys used in this table. It's
1288
+ * either TCL_CUSTOM_KEYS, TCL_STRING_KEYS,
1289
+ * TCL_ONE_WORD_KEYS, or an integer giving the
1290
+ * number of ints that is the size of the
1291
+ * key. */
1292
+ Tcl_HashEntry *(*findProc) (Tcl_HashTable *tablePtr, const char *key);
1293
+ Tcl_HashEntry *(*createProc) (Tcl_HashTable *tablePtr, const char *key,
1294
+ int *newPtr);
1295
+ const Tcl_HashKeyType *typePtr;
1296
+ /* Type of the keys used in the
1297
+ * Tcl_HashTable. */
1298
+};
1299
+
1300
+/*
1301
+ * Structure definition for information used to keep track of searches through
1302
+ * hash tables:
1303
+ */
1304
+
1305
+typedef struct Tcl_HashSearch {
1306
+ Tcl_HashTable *tablePtr; /* Table being searched. */
1307
+ int nextIndex; /* Index of next bucket to be enumerated after
1308
+ * present one. */
1309
+ Tcl_HashEntry *nextEntryPtr;/* Next entry to be enumerated in the current
1310
+ * bucket. */
1311
+} Tcl_HashSearch;
1312
+
1313
+/*
1314
+ * Acceptable key types for hash tables:
1315
+ *
1316
+ * TCL_STRING_KEYS: The keys are strings, they are copied into the
1317
+ * entry.
1318
+ * TCL_ONE_WORD_KEYS: The keys are pointers, the pointer is stored
1319
+ * in the entry.
1320
+ * TCL_CUSTOM_TYPE_KEYS: The keys are arbitrary types which are copied
1321
+ * into the entry.
1322
+ * TCL_CUSTOM_PTR_KEYS: The keys are pointers to arbitrary types, the
1323
+ * pointer is stored in the entry.
1324
+ *
1325
+ * While maintaining binary compatability the above have to be distinct values
1326
+ * as they are used to differentiate between old versions of the hash table
1327
+ * which don't have a typePtr and new ones which do. Once binary compatability
1328
+ * is discarded in favour of making more wide spread changes TCL_STRING_KEYS
1329
+ * can be the same as TCL_CUSTOM_TYPE_KEYS, and TCL_ONE_WORD_KEYS can be the
1330
+ * same as TCL_CUSTOM_PTR_KEYS because they simply determine how the key is
1331
+ * accessed from the entry and not the behaviour.
1332
+ */
1333
+
1334
+#define TCL_STRING_KEYS (0)
1335
+#define TCL_ONE_WORD_KEYS (1)
1336
+#define TCL_CUSTOM_TYPE_KEYS (-2)
1337
+#define TCL_CUSTOM_PTR_KEYS (-1)
1338
+
1339
+/*
1340
+ * Structure definition for information used to keep track of searches through
1341
+ * dictionaries. These fields should not be accessed by code outside
1342
+ * tclDictObj.c
1343
+ */
1344
+
1345
+typedef struct {
1346
+ void *next; /* Search position for underlying hash
1347
+ * table. */
1348
+ int epoch; /* Epoch marker for dictionary being searched,
1349
+ * or -1 if search has terminated. */
1350
+ Tcl_Dict dictionaryPtr; /* Reference to dictionary being searched. */
1351
+} Tcl_DictSearch;
1352
+
1353
+
1354
+/*
1355
+ *----------------------------------------------------------------------------
1356
+ * Flag values to pass to Tcl_DoOneEvent to disable searches for some kinds of
1357
+ * events:
1358
+ */
1359
+
1360
+#define TCL_DONT_WAIT (1<<1)
1361
+#define TCL_WINDOW_EVENTS (1<<2)
1362
+#define TCL_FILE_EVENTS (1<<3)
1363
+#define TCL_TIMER_EVENTS (1<<4)
1364
+#define TCL_IDLE_EVENTS (1<<5) /* WAS 0x10 ???? */
1365
+#define TCL_ALL_EVENTS (~TCL_DONT_WAIT)
1366
+
1367
+/*
1368
+ * The following structure defines a generic event for the Tcl event system.
1369
+ * These are the things that are queued in calls to Tcl_QueueEvent and
1370
+ * serviced later by Tcl_DoOneEvent. There can be many different kinds of
1371
+ * events with different fields, corresponding to window events, timer events,
1372
+ * etc. The structure for a particular event consists of a Tcl_Event header
1373
+ * followed by additional information specific to that event.
1374
+ */
1375
+
1376
+struct Tcl_Event {
1377
+ Tcl_EventProc *proc; /* Function to call to service this event. */
1378
+ struct Tcl_Event *nextPtr; /* Next in list of pending events, or NULL. */
1379
+};
1380
+
1381
+/*
1382
+ * Positions to pass to Tcl_QueueEvent:
1383
+ */
1384
+
1385
+typedef enum {
1386
+ TCL_QUEUE_TAIL, TCL_QUEUE_HEAD, TCL_QUEUE_MARK
1387
+} Tcl_QueuePosition;
1388
+
1389
+/*
1390
+ * Values to pass to Tcl_SetServiceMode to specify the behavior of notifier
1391
+ * event routines.
1392
+ */
1393
+
1394
+#define TCL_SERVICE_NONE 0
1395
+#define TCL_SERVICE_ALL 1
1396
+
1397
+/*
1398
+ * The following structure keeps is used to hold a time value, either as an
1399
+ * absolute time (the number of seconds from the epoch) or as an elapsed time.
1400
+ * On Unix systems the epoch is Midnight Jan 1, 1970 GMT.
1401
+ */
1402
+
1403
+typedef struct Tcl_Time {
1404
+ long sec; /* Seconds. */
1405
+ long usec; /* Microseconds. */
1406
+} Tcl_Time;
1407
+
1408
+typedef void (Tcl_SetTimerProc) (CONST86 Tcl_Time *timePtr);
1409
+typedef int (Tcl_WaitForEventProc) (CONST86 Tcl_Time *timePtr);
1410
+
1411
+/*
1412
+ * TIP #233 (Virtualized Time)
1413
+ */
1414
+
1415
+typedef void (Tcl_GetTimeProc) (Tcl_Time *timebuf, ClientData clientData);
1416
+typedef void (Tcl_ScaleTimeProc) (Tcl_Time *timebuf, ClientData clientData);
1417
+
1418
+/*
1419
+ *----------------------------------------------------------------------------
1420
+ * Bits to pass to Tcl_CreateFileHandler and Tcl_CreateChannelHandler to
1421
+ * indicate what sorts of events are of interest:
1422
+ */
1423
+
1424
+#define TCL_READABLE (1<<1)
1425
+#define TCL_WRITABLE (1<<2)
1426
+#define TCL_EXCEPTION (1<<3)
1427
+
1428
+/*
1429
+ * Flag values to pass to Tcl_OpenCommandChannel to indicate the disposition
1430
+ * of the stdio handles. TCL_STDIN, TCL_STDOUT, TCL_STDERR, are also used in
1431
+ * Tcl_GetStdChannel.
1432
+ */
1433
+
1434
+#define TCL_STDIN (1<<1)
1435
+#define TCL_STDOUT (1<<2)
1436
+#define TCL_STDERR (1<<3)
1437
+#define TCL_ENFORCE_MODE (1<<4)
1438
+
1439
+/*
1440
+ * Bits passed to Tcl_DriverClose2Proc to indicate which side of a channel
1441
+ * should be closed.
1442
+ */
1443
+
1444
+#define TCL_CLOSE_READ (1<<1)
1445
+#define TCL_CLOSE_WRITE (1<<2)
1446
+
1447
+/*
1448
+ * Value to use as the closeProc for a channel that supports the close2Proc
1449
+ * interface.
1450
+ */
1451
+
1452
+#define TCL_CLOSE2PROC ((Tcl_DriverCloseProc *) 1)
1453
+
1454
+/*
1455
+ * Channel version tag. This was introduced in 8.3.2/8.4.
1456
+ */
1457
+
1458
+#define TCL_CHANNEL_VERSION_1 ((Tcl_ChannelTypeVersion) 0x1)
1459
+#define TCL_CHANNEL_VERSION_2 ((Tcl_ChannelTypeVersion) 0x2)
1460
+#define TCL_CHANNEL_VERSION_3 ((Tcl_ChannelTypeVersion) 0x3)
1461
+#define TCL_CHANNEL_VERSION_4 ((Tcl_ChannelTypeVersion) 0x4)
1462
+#define TCL_CHANNEL_VERSION_5 ((Tcl_ChannelTypeVersion) 0x5)
1463
+
1464
+/*
1465
+ * TIP #218: Channel Actions, Ids for Tcl_DriverThreadActionProc.
1466
+ */
1467
+
1468
+#define TCL_CHANNEL_THREAD_INSERT (0)
1469
+#define TCL_CHANNEL_THREAD_REMOVE (1)
1470
+
1471
+/*
1472
+ * Typedefs for the various operations in a channel type:
1473
+ */
1474
+
1475
+typedef int (Tcl_DriverBlockModeProc) (ClientData instanceData, int mode);
1476
+typedef int (Tcl_DriverCloseProc) (ClientData instanceData,
1477
+ Tcl_Interp *interp);
1478
+typedef int (Tcl_DriverClose2Proc) (ClientData instanceData,
1479
+ Tcl_Interp *interp, int flags);
1480
+typedef int (Tcl_DriverInputProc) (ClientData instanceData, char *buf,
1481
+ int toRead, int *errorCodePtr);
1482
+typedef int (Tcl_DriverOutputProc) (ClientData instanceData,
1483
+ CONST84 char *buf, int toWrite, int *errorCodePtr);
1484
+typedef int (Tcl_DriverSeekProc) (ClientData instanceData, long offset,
1485
+ int mode, int *errorCodePtr);
1486
+typedef int (Tcl_DriverSetOptionProc) (ClientData instanceData,
1487
+ Tcl_Interp *interp, const char *optionName,
1488
+ const char *value);
1489
+typedef int (Tcl_DriverGetOptionProc) (ClientData instanceData,
1490
+ Tcl_Interp *interp, CONST84 char *optionName,
1491
+ Tcl_DString *dsPtr);
1492
+typedef void (Tcl_DriverWatchProc) (ClientData instanceData, int mask);
1493
+typedef int (Tcl_DriverGetHandleProc) (ClientData instanceData,
1494
+ int direction, ClientData *handlePtr);
1495
+typedef int (Tcl_DriverFlushProc) (ClientData instanceData);
1496
+typedef int (Tcl_DriverHandlerProc) (ClientData instanceData,
1497
+ int interestMask);
1498
+typedef Tcl_WideInt (Tcl_DriverWideSeekProc) (ClientData instanceData,
1499
+ Tcl_WideInt offset, int mode, int *errorCodePtr);
1500
+/*
1501
+ * TIP #218, Channel Thread Actions
1502
+ */
1503
+typedef void (Tcl_DriverThreadActionProc) (ClientData instanceData,
1504
+ int action);
1505
+/*
1506
+ * TIP #208, File Truncation (etc.)
1507
+ */
1508
+typedef int (Tcl_DriverTruncateProc) (ClientData instanceData,
1509
+ Tcl_WideInt length);
1510
+
1511
+/*
1512
+ * struct Tcl_ChannelType:
1513
+ *
1514
+ * One such structure exists for each type (kind) of channel. It collects
1515
+ * together in one place all the functions that are part of the specific
1516
+ * channel type.
1517
+ *
1518
+ * It is recommend that the Tcl_Channel* functions are used to access elements
1519
+ * of this structure, instead of direct accessing.
1520
+ */
1521
+
1522
+typedef struct Tcl_ChannelType {
1523
+ const char *typeName; /* The name of the channel type in Tcl
1524
+ * commands. This storage is owned by channel
1525
+ * type. */
1526
+ Tcl_ChannelTypeVersion version;
1527
+ /* Version of the channel type. */
1528
+ Tcl_DriverCloseProc *closeProc;
1529
+ /* Function to call to close the channel, or
1530
+ * TCL_CLOSE2PROC if the close2Proc should be
1531
+ * used instead. */
1532
+ Tcl_DriverInputProc *inputProc;
1533
+ /* Function to call for input on channel. */
1534
+ Tcl_DriverOutputProc *outputProc;
1535
+ /* Function to call for output on channel. */
1536
+ Tcl_DriverSeekProc *seekProc;
1537
+ /* Function to call to seek on the channel.
1538
+ * May be NULL. */
1539
+ Tcl_DriverSetOptionProc *setOptionProc;
1540
+ /* Set an option on a channel. */
1541
+ Tcl_DriverGetOptionProc *getOptionProc;
1542
+ /* Get an option from a channel. */
1543
+ Tcl_DriverWatchProc *watchProc;
1544
+ /* Set up the notifier to watch for events on
1545
+ * this channel. */
1546
+ Tcl_DriverGetHandleProc *getHandleProc;
1547
+ /* Get an OS handle from the channel or NULL
1548
+ * if not supported. */
1549
+ Tcl_DriverClose2Proc *close2Proc;
1550
+ /* Function to call to close the channel if
1551
+ * the device supports closing the read &
1552
+ * write sides independently. */
1553
+ Tcl_DriverBlockModeProc *blockModeProc;
1554
+ /* Set blocking mode for the raw channel. May
1555
+ * be NULL. */
1556
+ /*
1557
+ * Only valid in TCL_CHANNEL_VERSION_2 channels or later.
1558
+ */
1559
+ Tcl_DriverFlushProc *flushProc;
1560
+ /* Function to call to flush a channel. May be
1561
+ * NULL. */
1562
+ Tcl_DriverHandlerProc *handlerProc;
1563
+ /* Function to call to handle a channel event.
1564
+ * This will be passed up the stacked channel
1565
+ * chain. */
1566
+ /*
1567
+ * Only valid in TCL_CHANNEL_VERSION_3 channels or later.
1568
+ */
1569
+ Tcl_DriverWideSeekProc *wideSeekProc;
1570
+ /* Function to call to seek on the channel
1571
+ * which can handle 64-bit offsets. May be
1572
+ * NULL, and must be NULL if seekProc is
1573
+ * NULL. */
1574
+ /*
1575
+ * Only valid in TCL_CHANNEL_VERSION_4 channels or later.
1576
+ * TIP #218, Channel Thread Actions.
1577
+ */
1578
+ Tcl_DriverThreadActionProc *threadActionProc;
1579
+ /* Function to call to notify the driver of
1580
+ * thread specific activity for a channel. May
1581
+ * be NULL. */
1582
+ /*
1583
+ * Only valid in TCL_CHANNEL_VERSION_5 channels or later.
1584
+ * TIP #208, File Truncation.
1585
+ */
1586
+ Tcl_DriverTruncateProc *truncateProc;
1587
+ /* Function to call to truncate the underlying
1588
+ * file to a particular length. May be NULL if
1589
+ * the channel does not support truncation. */
1590
+} Tcl_ChannelType;
1591
+
1592
+/*
1593
+ * The following flags determine whether the blockModeProc above should set
1594
+ * the channel into blocking or nonblocking mode. They are passed as arguments
1595
+ * to the blockModeProc function in the above structure.
1596
+ */
1597
+
1598
+#define TCL_MODE_BLOCKING 0 /* Put channel into blocking mode. */
1599
+#define TCL_MODE_NONBLOCKING 1 /* Put channel into nonblocking
1600
+ * mode. */
1601
+
1602
+/*
1603
+ *----------------------------------------------------------------------------
1604
+ * Enum for different types of file paths.
1605
+ */
1606
+
1607
+typedef enum Tcl_PathType {
1608
+ TCL_PATH_ABSOLUTE,
1609
+ TCL_PATH_RELATIVE,
1610
+ TCL_PATH_VOLUME_RELATIVE
1611
+} Tcl_PathType;
1612
+
1613
+/*
1614
+ * The following structure is used to pass glob type data amongst the various
1615
+ * glob routines and Tcl_FSMatchInDirectory.
1616
+ */
1617
+
1618
+typedef struct Tcl_GlobTypeData {
1619
+ int type; /* Corresponds to bcdpfls as in 'find -t'. */
1620
+ int perm; /* Corresponds to file permissions. */
1621
+ Tcl_Obj *macType; /* Acceptable Mac type. */
1622
+ Tcl_Obj *macCreator; /* Acceptable Mac creator. */
1623
+} Tcl_GlobTypeData;
1624
+
1625
+/*
1626
+ * Type and permission definitions for glob command.
1627
+ */
1628
+
1629
+#define TCL_GLOB_TYPE_BLOCK (1<<0)
1630
+#define TCL_GLOB_TYPE_CHAR (1<<1)
1631
+#define TCL_GLOB_TYPE_DIR (1<<2)
1632
+#define TCL_GLOB_TYPE_PIPE (1<<3)
1633
+#define TCL_GLOB_TYPE_FILE (1<<4)
1634
+#define TCL_GLOB_TYPE_LINK (1<<5)
1635
+#define TCL_GLOB_TYPE_SOCK (1<<6)
1636
+#define TCL_GLOB_TYPE_MOUNT (1<<7)
1637
+
1638
+#define TCL_GLOB_PERM_RONLY (1<<0)
1639
+#define TCL_GLOB_PERM_HIDDEN (1<<1)
1640
+#define TCL_GLOB_PERM_R (1<<2)
1641
+#define TCL_GLOB_PERM_W (1<<3)
1642
+#define TCL_GLOB_PERM_X (1<<4)
1643
+
1644
+/*
1645
+ * Flags for the unload callback function.
1646
+ */
1647
+
1648
+#define TCL_UNLOAD_DETACH_FROM_INTERPRETER (1<<0)
1649
+#define TCL_UNLOAD_DETACH_FROM_PROCESS (1<<1)
1650
+
1651
+/*
1652
+ * Typedefs for the various filesystem operations:
1653
+ */
1654
+
1655
+typedef int (Tcl_FSStatProc) (Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1656
+typedef int (Tcl_FSAccessProc) (Tcl_Obj *pathPtr, int mode);
1657
+typedef Tcl_Channel (Tcl_FSOpenFileChannelProc) (Tcl_Interp *interp,
1658
+ Tcl_Obj *pathPtr, int mode, int permissions);
1659
+typedef int (Tcl_FSMatchInDirectoryProc) (Tcl_Interp *interp, Tcl_Obj *result,
1660
+ Tcl_Obj *pathPtr, const char *pattern, Tcl_GlobTypeData *types);
1661
+typedef Tcl_Obj * (Tcl_FSGetCwdProc) (Tcl_Interp *interp);
1662
+typedef int (Tcl_FSChdirProc) (Tcl_Obj *pathPtr);
1663
+typedef int (Tcl_FSLstatProc) (Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1664
+typedef int (Tcl_FSCreateDirectoryProc) (Tcl_Obj *pathPtr);
1665
+typedef int (Tcl_FSDeleteFileProc) (Tcl_Obj *pathPtr);
1666
+typedef int (Tcl_FSCopyDirectoryProc) (Tcl_Obj *srcPathPtr,
1667
+ Tcl_Obj *destPathPtr, Tcl_Obj **errorPtr);
1668
+typedef int (Tcl_FSCopyFileProc) (Tcl_Obj *srcPathPtr, Tcl_Obj *destPathPtr);
1669
+typedef int (Tcl_FSRemoveDirectoryProc) (Tcl_Obj *pathPtr, int recursive,
1670
+ Tcl_Obj **errorPtr);
1671
+typedef int (Tcl_FSRenameFileProc) (Tcl_Obj *srcPathPtr, Tcl_Obj *destPathPtr);
1672
+typedef void (Tcl_FSUnloadFileProc) (Tcl_LoadHandle loadHandle);
1673
+typedef Tcl_Obj * (Tcl_FSListVolumesProc) (void);
1674
+/* We have to declare the utime structure here. */
1675
+struct utimbuf;
1676
+typedef int (Tcl_FSUtimeProc) (Tcl_Obj *pathPtr, struct utimbuf *tval);
1677
+typedef int (Tcl_FSNormalizePathProc) (Tcl_Interp *interp, Tcl_Obj *pathPtr,
1678
+ int nextCheckpoint);
1679
+typedef int (Tcl_FSFileAttrsGetProc) (Tcl_Interp *interp, int index,
1680
+ Tcl_Obj *pathPtr, Tcl_Obj **objPtrRef);
1681
+typedef const char *CONST86 * (Tcl_FSFileAttrStringsProc) (Tcl_Obj *pathPtr,
1682
+ Tcl_Obj **objPtrRef);
1683
+typedef int (Tcl_FSFileAttrsSetProc) (Tcl_Interp *interp, int index,
1684
+ Tcl_Obj *pathPtr, Tcl_Obj *objPtr);
1685
+typedef Tcl_Obj * (Tcl_FSLinkProc) (Tcl_Obj *pathPtr, Tcl_Obj *toPtr,
1686
+ int linkType);
1687
+typedef int (Tcl_FSLoadFileProc) (Tcl_Interp *interp, Tcl_Obj *pathPtr,
1688
+ Tcl_LoadHandle *handlePtr, Tcl_FSUnloadFileProc **unloadProcPtr);
1689
+typedef int (Tcl_FSPathInFilesystemProc) (Tcl_Obj *pathPtr,
1690
+ ClientData *clientDataPtr);
1691
+typedef Tcl_Obj * (Tcl_FSFilesystemPathTypeProc) (Tcl_Obj *pathPtr);
1692
+typedef Tcl_Obj * (Tcl_FSFilesystemSeparatorProc) (Tcl_Obj *pathPtr);
1693
+typedef void (Tcl_FSFreeInternalRepProc) (ClientData clientData);
1694
+typedef ClientData (Tcl_FSDupInternalRepProc) (ClientData clientData);
1695
+typedef Tcl_Obj * (Tcl_FSInternalToNormalizedProc) (ClientData clientData);
1696
+typedef ClientData (Tcl_FSCreateInternalRepProc) (Tcl_Obj *pathPtr);
1697
+
1698
+typedef struct Tcl_FSVersion_ *Tcl_FSVersion;
1699
+
1700
+/*
1701
+ *----------------------------------------------------------------------------
1702
+ * Data structures related to hooking into the filesystem
1703
+ */
1704
+
1705
+/*
1706
+ * Filesystem version tag. This was introduced in 8.4.
1707
+ */
1708
+
1709
+#define TCL_FILESYSTEM_VERSION_1 ((Tcl_FSVersion) 0x1)
1710
+
1711
+/*
1712
+ * struct Tcl_Filesystem:
1713
+ *
1714
+ * One such structure exists for each type (kind) of filesystem. It collects
1715
+ * together in one place all the functions that are part of the specific
1716
+ * filesystem. Tcl always accesses the filesystem through one of these
1717
+ * structures.
1718
+ *
1719
+ * Not all entries need be non-NULL; any which are NULL are simply ignored.
1720
+ * However, a complete filesystem should provide all of these functions. The
1721
+ * explanations in the structure show the importance of each function.
1722
+ */
1723
+
1724
+typedef struct Tcl_Filesystem {
1725
+ const char *typeName; /* The name of the filesystem. */
1726
+ int structureLength; /* Length of this structure, so future binary
1727
+ * compatibility can be assured. */
1728
+ Tcl_FSVersion version; /* Version of the filesystem type. */
1729
+ Tcl_FSPathInFilesystemProc *pathInFilesystemProc;
1730
+ /* Function to check whether a path is in this
1731
+ * filesystem. This is the most important
1732
+ * filesystem function. */
1733
+ Tcl_FSDupInternalRepProc *dupInternalRepProc;
1734
+ /* Function to duplicate internal fs rep. May
1735
+ * be NULL (but then fs is less efficient). */
1736
+ Tcl_FSFreeInternalRepProc *freeInternalRepProc;
1737
+ /* Function to free internal fs rep. Must be
1738
+ * implemented if internal representations
1739
+ * need freeing, otherwise it can be NULL. */
1740
+ Tcl_FSInternalToNormalizedProc *internalToNormalizedProc;
1741
+ /* Function to convert internal representation
1742
+ * to a normalized path. Only required if the
1743
+ * fs creates pure path objects with no
1744
+ * string/path representation. */
1745
+ Tcl_FSCreateInternalRepProc *createInternalRepProc;
1746
+ /* Function to create a filesystem-specific
1747
+ * internal representation. May be NULL if
1748
+ * paths have no internal representation, or
1749
+ * if the Tcl_FSPathInFilesystemProc for this
1750
+ * filesystem always immediately creates an
1751
+ * internal representation for paths it
1752
+ * accepts. */
1753
+ Tcl_FSNormalizePathProc *normalizePathProc;
1754
+ /* Function to normalize a path. Should be
1755
+ * implemented for all filesystems which can
1756
+ * have multiple string representations for
1757
+ * the same path object. */
1758
+ Tcl_FSFilesystemPathTypeProc *filesystemPathTypeProc;
1759
+ /* Function to determine the type of a path in
1760
+ * this filesystem. May be NULL. */
1761
+ Tcl_FSFilesystemSeparatorProc *filesystemSeparatorProc;
1762
+ /* Function to return the separator
1763
+ * character(s) for this filesystem. Must be
1764
+ * implemented. */
1765
+ Tcl_FSStatProc *statProc; /* Function to process a 'Tcl_FSStat()' call.
1766
+ * Must be implemented for any reasonable
1767
+ * filesystem. */
1768
+ Tcl_FSAccessProc *accessProc;
1769
+ /* Function to process a 'Tcl_FSAccess()'
1770
+ * call. Must be implemented for any
1771
+ * reasonable filesystem. */
1772
+ Tcl_FSOpenFileChannelProc *openFileChannelProc;
1773
+ /* Function to process a
1774
+ * 'Tcl_FSOpenFileChannel()' call. Must be
1775
+ * implemented for any reasonable
1776
+ * filesystem. */
1777
+ Tcl_FSMatchInDirectoryProc *matchInDirectoryProc;
1778
+ /* Function to process a
1779
+ * 'Tcl_FSMatchInDirectory()'. If not
1780
+ * implemented, then glob and recursive copy
1781
+ * functionality will be lacking in the
1782
+ * filesystem. */
1783
+ Tcl_FSUtimeProc *utimeProc; /* Function to process a 'Tcl_FSUtime()' call.
1784
+ * Required to allow setting (not reading) of
1785
+ * times with 'file mtime', 'file atime' and
1786
+ * the open-r/open-w/fcopy implementation of
1787
+ * 'file copy'. */
1788
+ Tcl_FSLinkProc *linkProc; /* Function to process a 'Tcl_FSLink()' call.
1789
+ * Should be implemented only if the
1790
+ * filesystem supports links (reading or
1791
+ * creating). */
1792
+ Tcl_FSListVolumesProc *listVolumesProc;
1793
+ /* Function to list any filesystem volumes
1794
+ * added by this filesystem. Should be
1795
+ * implemented only if the filesystem adds
1796
+ * volumes at the head of the filesystem. */
1797
+ Tcl_FSFileAttrStringsProc *fileAttrStringsProc;
1798
+ /* Function to list all attributes strings
1799
+ * which are valid for this filesystem. If not
1800
+ * implemented the filesystem will not support
1801
+ * the 'file attributes' command. This allows
1802
+ * arbitrary additional information to be
1803
+ * attached to files in the filesystem. */
1804
+ Tcl_FSFileAttrsGetProc *fileAttrsGetProc;
1805
+ /* Function to process a
1806
+ * 'Tcl_FSFileAttrsGet()' call, used by 'file
1807
+ * attributes'. */
1808
+ Tcl_FSFileAttrsSetProc *fileAttrsSetProc;
1809
+ /* Function to process a
1810
+ * 'Tcl_FSFileAttrsSet()' call, used by 'file
1811
+ * attributes'. */
1812
+ Tcl_FSCreateDirectoryProc *createDirectoryProc;
1813
+ /* Function to process a
1814
+ * 'Tcl_FSCreateDirectory()' call. Should be
1815
+ * implemented unless the FS is read-only. */
1816
+ Tcl_FSRemoveDirectoryProc *removeDirectoryProc;
1817
+ /* Function to process a
1818
+ * 'Tcl_FSRemoveDirectory()' call. Should be
1819
+ * implemented unless the FS is read-only. */
1820
+ Tcl_FSDeleteFileProc *deleteFileProc;
1821
+ /* Function to process a 'Tcl_FSDeleteFile()'
1822
+ * call. Should be implemented unless the FS
1823
+ * is read-only. */
1824
+ Tcl_FSCopyFileProc *copyFileProc;
1825
+ /* Function to process a 'Tcl_FSCopyFile()'
1826
+ * call. If not implemented Tcl will fall back
1827
+ * on open-r, open-w and fcopy as a copying
1828
+ * mechanism, for copying actions initiated in
1829
+ * Tcl (not C). */
1830
+ Tcl_FSRenameFileProc *renameFileProc;
1831
+ /* Function to process a 'Tcl_FSRenameFile()'
1832
+ * call. If not implemented, Tcl will fall
1833
+ * back on a copy and delete mechanism, for
1834
+ * rename actions initiated in Tcl (not C). */
1835
+ Tcl_FSCopyDirectoryProc *copyDirectoryProc;
1836
+ /* Function to process a
1837
+ * 'Tcl_FSCopyDirectory()' call. If not
1838
+ * implemented, Tcl will fall back on a
1839
+ * recursive create-dir, file copy mechanism,
1840
+ * for copying actions initiated in Tcl (not
1841
+ * C). */
1842
+ Tcl_FSLstatProc *lstatProc; /* Function to process a 'Tcl_FSLstat()' call.
1843
+ * If not implemented, Tcl will attempt to use
1844
+ * the 'statProc' defined above instead. */
1845
+ Tcl_FSLoadFileProc *loadFileProc;
1846
+ /* Function to process a 'Tcl_FSLoadFile()'
1847
+ * call. If not implemented, Tcl will fall
1848
+ * back on a copy to native-temp followed by a
1849
+ * Tcl_FSLoadFile on that temporary copy. */
1850
+ Tcl_FSGetCwdProc *getCwdProc;
1851
+ /* Function to process a 'Tcl_FSGetCwd()'
1852
+ * call. Most filesystems need not implement
1853
+ * this. It will usually only be called once,
1854
+ * if 'getcwd' is called before 'chdir'. May
1855
+ * be NULL. */
1856
+ Tcl_FSChdirProc *chdirProc; /* Function to process a 'Tcl_FSChdir()' call.
1857
+ * If filesystems do not implement this, it
1858
+ * will be emulated by a series of directory
1859
+ * access checks. Otherwise, virtual
1860
+ * filesystems which do implement it need only
1861
+ * respond with a positive return result if
1862
+ * the dirName is a valid directory in their
1863
+ * filesystem. They need not remember the
1864
+ * result, since that will be automatically
1865
+ * remembered for use by GetCwd. Real
1866
+ * filesystems should carry out the correct
1867
+ * action (i.e. call the correct system
1868
+ * 'chdir' api). If not implemented, then 'cd'
1869
+ * and 'pwd' will fail inside the
1870
+ * filesystem. */
1871
+} Tcl_Filesystem;
1872
+
1873
+/*
1874
+ * The following definitions are used as values for the 'linkAction' flag to
1875
+ * Tcl_FSLink, or the linkProc of any filesystem. Any combination of flags can
1876
+ * be given. For link creation, the linkProc should create a link which
1877
+ * matches any of the types given.
1878
+ *
1879
+ * TCL_CREATE_SYMBOLIC_LINK - Create a symbolic or soft link.
1880
+ * TCL_CREATE_HARD_LINK - Create a hard link.
1881
+ */
1882
+
1883
+#define TCL_CREATE_SYMBOLIC_LINK 0x01
1884
+#define TCL_CREATE_HARD_LINK 0x02
1885
+
1886
+/*
1887
+ *----------------------------------------------------------------------------
1888
+ * The following structure represents the Notifier functions that you can
1889
+ * override with the Tcl_SetNotifier call.
1890
+ */
1891
+
1892
+typedef struct Tcl_NotifierProcs {
1893
+ Tcl_SetTimerProc *setTimerProc;
1894
+ Tcl_WaitForEventProc *waitForEventProc;
1895
+ Tcl_CreateFileHandlerProc *createFileHandlerProc;
1896
+ Tcl_DeleteFileHandlerProc *deleteFileHandlerProc;
1897
+ Tcl_InitNotifierProc *initNotifierProc;
1898
+ Tcl_FinalizeNotifierProc *finalizeNotifierProc;
1899
+ Tcl_AlertNotifierProc *alertNotifierProc;
1900
+ Tcl_ServiceModeHookProc *serviceModeHookProc;
1901
+} Tcl_NotifierProcs;
1902
+
1903
+
1904
+/*
1905
+ *----------------------------------------------------------------------------
1906
+ * The following data structures and declarations are for the new Tcl parser.
1907
+ *
1908
+ * For each word of a command, and for each piece of a word such as a variable
1909
+ * reference, one of the following structures is created to describe the
1910
+ * token.
1911
+ */
1912
+
1913
+typedef struct Tcl_Token {
1914
+ int type; /* Type of token, such as TCL_TOKEN_WORD; see
1915
+ * below for valid types. */
1916
+ const char *start; /* First character in token. */
1917
+ int size; /* Number of bytes in token. */
1918
+ int numComponents; /* If this token is composed of other tokens,
1919
+ * this field tells how many of them there are
1920
+ * (including components of components, etc.).
1921
+ * The component tokens immediately follow
1922
+ * this one. */
1923
+} Tcl_Token;
1924
+
1925
+/*
1926
+ * Type values defined for Tcl_Token structures. These values are defined as
1927
+ * mask bits so that it's easy to check for collections of types.
1928
+ *
1929
+ * TCL_TOKEN_WORD - The token describes one word of a command,
1930
+ * from the first non-blank character of the word
1931
+ * (which may be " or {) up to but not including
1932
+ * the space, semicolon, or bracket that
1933
+ * terminates the word. NumComponents counts the
1934
+ * total number of sub-tokens that make up the
1935
+ * word. This includes, for example, sub-tokens
1936
+ * of TCL_TOKEN_VARIABLE tokens.
1937
+ * TCL_TOKEN_SIMPLE_WORD - This token is just like TCL_TOKEN_WORD except
1938
+ * that the word is guaranteed to consist of a
1939
+ * single TCL_TOKEN_TEXT sub-token.
1940
+ * TCL_TOKEN_TEXT - The token describes a range of literal text
1941
+ * that is part of a word. NumComponents is
1942
+ * always 0.
1943
+ * TCL_TOKEN_BS - The token describes a backslash sequence that
1944
+ * must be collapsed. NumComponents is always 0.
1945
+ * TCL_TOKEN_COMMAND - The token describes a command whose result
1946
+ * must be substituted into the word. The token
1947
+ * includes the enclosing brackets. NumComponents
1948
+ * is always 0.
1949
+ * TCL_TOKEN_VARIABLE - The token describes a variable substitution,
1950
+ * including the dollar sign, variable name, and
1951
+ * array index (if there is one) up through the
1952
+ * right parentheses. NumComponents tells how
1953
+ * many additional tokens follow to represent the
1954
+ * variable name. The first token will be a
1955
+ * TCL_TOKEN_TEXT token that describes the
1956
+ * variable name. If the variable is an array
1957
+ * reference then there will be one or more
1958
+ * additional tokens, of type TCL_TOKEN_TEXT,
1959
+ * TCL_TOKEN_BS, TCL_TOKEN_COMMAND, and
1960
+ * TCL_TOKEN_VARIABLE, that describe the array
1961
+ * index; numComponents counts the total number
1962
+ * of nested tokens that make up the variable
1963
+ * reference, including sub-tokens of
1964
+ * TCL_TOKEN_VARIABLE tokens.
1965
+ * TCL_TOKEN_SUB_EXPR - The token describes one subexpression of an
1966
+ * expression, from the first non-blank character
1967
+ * of the subexpression up to but not including
1968
+ * the space, brace, or bracket that terminates
1969
+ * the subexpression. NumComponents counts the
1970
+ * total number of following subtokens that make
1971
+ * up the subexpression; this includes all
1972
+ * subtokens for any nested TCL_TOKEN_SUB_EXPR
1973
+ * tokens. For example, a numeric value used as a
1974
+ * primitive operand is described by a
1975
+ * TCL_TOKEN_SUB_EXPR token followed by a
1976
+ * TCL_TOKEN_TEXT token. A binary subexpression
1977
+ * is described by a TCL_TOKEN_SUB_EXPR token
1978
+ * followed by the TCL_TOKEN_OPERATOR token for
1979
+ * the operator, then TCL_TOKEN_SUB_EXPR tokens
1980
+ * for the left then the right operands.
1981
+ * TCL_TOKEN_OPERATOR - The token describes one expression operator.
1982
+ * An operator might be the name of a math
1983
+ * function such as "abs". A TCL_TOKEN_OPERATOR
1984
+ * token is always preceeded by one
1985
+ * TCL_TOKEN_SUB_EXPR token for the operator's
1986
+ * subexpression, and is followed by zero or more
1987
+ * TCL_TOKEN_SUB_EXPR tokens for the operator's
1988
+ * operands. NumComponents is always 0.
1989
+ * TCL_TOKEN_EXPAND_WORD - This token is just like TCL_TOKEN_WORD except
1990
+ * that it marks a word that began with the
1991
+ * literal character prefix "{*}". This word is
1992
+ * marked to be expanded - that is, broken into
1993
+ * words after substitution is complete.
1994
+ */
1995
+
1996
+#define TCL_TOKEN_WORD 1
1997
+#define TCL_TOKEN_SIMPLE_WORD 2
1998
+#define TCL_TOKEN_TEXT 4
1999
+#define TCL_TOKEN_BS 8
2000
+#define TCL_TOKEN_COMMAND 16
2001
+#define TCL_TOKEN_VARIABLE 32
2002
+#define TCL_TOKEN_SUB_EXPR 64
2003
+#define TCL_TOKEN_OPERATOR 128
2004
+#define TCL_TOKEN_EXPAND_WORD 256
2005
+
2006
+/*
2007
+ * Parsing error types. On any parsing error, one of these values will be
2008
+ * stored in the error field of the Tcl_Parse structure defined below.
2009
+ */
2010
+
2011
+#define TCL_PARSE_SUCCESS 0
2012
+#define TCL_PARSE_QUOTE_EXTRA 1
2013
+#define TCL_PARSE_BRACE_EXTRA 2
2014
+#define TCL_PARSE_MISSING_BRACE 3
2015
+#define TCL_PARSE_MISSING_BRACKET 4
2016
+#define TCL_PARSE_MISSING_PAREN 5
2017
+#define TCL_PARSE_MISSING_QUOTE 6
2018
+#define TCL_PARSE_MISSING_VAR_BRACE 7
2019
+#define TCL_PARSE_SYNTAX 8
2020
+#define TCL_PARSE_BAD_NUMBER 9
2021
+
2022
+/*
2023
+ * A structure of the following type is filled in by Tcl_ParseCommand. It
2024
+ * describes a single command parsed from an input string.
2025
+ */
2026
+
2027
+#define NUM_STATIC_TOKENS 20
2028
+
2029
+typedef struct Tcl_Parse {
2030
+ const char *commentStart; /* Pointer to # that begins the first of one
2031
+ * or more comments preceding the command. */
2032
+ int commentSize; /* Number of bytes in comments (up through
2033
+ * newline character that terminates the last
2034
+ * comment). If there were no comments, this
2035
+ * field is 0. */
2036
+ const char *commandStart; /* First character in first word of
2037
+ * command. */
2038
+ int commandSize; /* Number of bytes in command, including first
2039
+ * character of first word, up through the
2040
+ * terminating newline, close bracket, or
2041
+ * semicolon. */
2042
+ int numWords; /* Total number of words in command. May be
2043
+ * 0. */
2044
+ Tcl_Token *tokenPtr; /* Pointer to first token representing the
2045
+ * words of the command. Initially points to
2046
+ * staticTokens, but may change to point to
2047
+ * malloc-ed space if command exceeds space in
2048
+ * staticTokens. */
2049
+ int numTokens; /* Total number of tokens in command. */
2050
+ int tokensAvailable; /* Total number of tokens available at
2051
+ * *tokenPtr. */
2052
+ int errorType; /* One of the parsing error types defined
2053
+ * above. */
2054
+
2055
+ /*
2056
+ * The fields below are intended only for the private use of the parser.
2057
+ * They should not be used by functions that invoke Tcl_ParseCommand.
2058
+ */
2059
+
2060
+ const char *string; /* The original command string passed to
2061
+ * Tcl_ParseCommand. */
2062
+ const char *end; /* Points to the character just after the last
2063
+ * one in the command string. */
2064
+ Tcl_Interp *interp; /* Interpreter to use for error reporting, or
2065
+ * NULL. */
2066
+ const char *term; /* Points to character in string that
2067
+ * terminated most recent token. Filled in by
2068
+ * ParseTokens. If an error occurs, points to
2069
+ * beginning of region where the error
2070
+ * occurred (e.g. the open brace if the close
2071
+ * brace is missing). */
2072
+ int incomplete; /* This field is set to 1 by Tcl_ParseCommand
2073
+ * if the command appears to be incomplete.
2074
+ * This information is used by
2075
+ * Tcl_CommandComplete. */
2076
+ Tcl_Token staticTokens[NUM_STATIC_TOKENS];
2077
+ /* Initial space for tokens for command. This
2078
+ * space should be large enough to accommodate
2079
+ * most commands; dynamic space is allocated
2080
+ * for very large commands that don't fit
2081
+ * here. */
2082
+} Tcl_Parse;
2083
+
2084
+
2085
+/*
2086
+ *----------------------------------------------------------------------------
2087
+ * The following structure represents a user-defined encoding. It collects
2088
+ * together all the functions that are used by the specific encoding.
2089
+ */
2090
+
2091
+typedef struct Tcl_EncodingType {
2092
+ const char *encodingName; /* The name of the encoding, e.g. "euc-jp".
2093
+ * This name is the unique key for this
2094
+ * encoding type. */
2095
+ Tcl_EncodingConvertProc *toUtfProc;
2096
+ /* Function to convert from external encoding
2097
+ * into UTF-8. */
2098
+ Tcl_EncodingConvertProc *fromUtfProc;
2099
+ /* Function to convert from UTF-8 into
2100
+ * external encoding. */
2101
+ Tcl_EncodingFreeProc *freeProc;
2102
+ /* If non-NULL, function to call when this
2103
+ * encoding is deleted. */
2104
+ ClientData clientData; /* Arbitrary value associated with encoding
2105
+ * type. Passed to conversion functions. */
2106
+ int nullSize; /* Number of zero bytes that signify
2107
+ * end-of-string in this encoding. This number
2108
+ * is used to determine the source string
2109
+ * length when the srcLen argument is
2110
+ * negative. Must be 1 or 2. */
2111
+} Tcl_EncodingType;
2112
+
2113
+/*
2114
+ * The following definitions are used as values for the conversion control
2115
+ * flags argument when converting text from one character set to another:
2116
+ *
2117
+ * TCL_ENCODING_START - Signifies that the source buffer is the first
2118
+ * block in a (potentially multi-block) input
2119
+ * stream. Tells the conversion function to reset
2120
+ * to an initial state and perform any
2121
+ * initialization that needs to occur before the
2122
+ * first byte is converted. If the source buffer
2123
+ * contains the entire input stream to be
2124
+ * converted, this flag should be set.
2125
+ * TCL_ENCODING_END - Signifies that the source buffer is the last
2126
+ * block in a (potentially multi-block) input
2127
+ * stream. Tells the conversion routine to
2128
+ * perform any finalization that needs to occur
2129
+ * after the last byte is converted and then to
2130
+ * reset to an initial state. If the source
2131
+ * buffer contains the entire input stream to be
2132
+ * converted, this flag should be set.
2133
+ * TCL_ENCODING_STOPONERROR - If set, then the converter will return
2134
+ * immediately upon encountering an invalid byte
2135
+ * sequence or a source character that has no
2136
+ * mapping in the target encoding. If clear, then
2137
+ * the converter will skip the problem,
2138
+ * substituting one or more "close" characters in
2139
+ * the destination buffer and then continue to
2140
+ * convert the source.
2141
+ */
2142
+
2143
+#define TCL_ENCODING_START 0x01
2144
+#define TCL_ENCODING_END 0x02
2145
+#define TCL_ENCODING_STOPONERROR 0x04
2146
+
2147
+/*
2148
+ * The following definitions are the error codes returned by the conversion
2149
+ * routines:
2150
+ *
2151
+ * TCL_OK - All characters were converted.
2152
+ * TCL_CONVERT_NOSPACE - The output buffer would not have been large
2153
+ * enough for all of the converted data; as many
2154
+ * characters as could fit were converted though.
2155
+ * TCL_CONVERT_MULTIBYTE - The last few bytes in the source string were
2156
+ * the beginning of a multibyte sequence, but
2157
+ * more bytes were needed to complete this
2158
+ * sequence. A subsequent call to the conversion
2159
+ * routine should pass the beginning of this
2160
+ * unconverted sequence plus additional bytes
2161
+ * from the source stream to properly convert the
2162
+ * formerly split-up multibyte sequence.
2163
+ * TCL_CONVERT_SYNTAX - The source stream contained an invalid
2164
+ * character sequence. This may occur if the
2165
+ * input stream has been damaged or if the input
2166
+ * encoding method was misidentified. This error
2167
+ * is reported only if TCL_ENCODING_STOPONERROR
2168
+ * was specified.
2169
+ * TCL_CONVERT_UNKNOWN - The source string contained a character that
2170
+ * could not be represented in the target
2171
+ * encoding. This error is reported only if
2172
+ * TCL_ENCODING_STOPONERROR was specified.
2173
+ */
2174
+
2175
+#define TCL_CONVERT_MULTIBYTE (-1)
2176
+#define TCL_CONVERT_SYNTAX (-2)
2177
+#define TCL_CONVERT_UNKNOWN (-3)
2178
+#define TCL_CONVERT_NOSPACE (-4)
2179
+
2180
+/*
2181
+ * The maximum number of bytes that are necessary to represent a single
2182
+ * Unicode character in UTF-8. The valid values should be 3, 4 or 6
2183
+ * (or perhaps 1 if we want to support a non-unicode enabled core). If 3 or
2184
+ * 4, then Tcl_UniChar must be 2-bytes in size (UCS-2) (the default). If 6,
2185
+ * then Tcl_UniChar must be 4-bytes in size (UCS-4). At this time UCS-2 mode
2186
+ * is the default and recommended mode. UCS-4 is experimental and not
2187
+ * recommended. It works for the core, but most extensions expect UCS-2.
2188
+ */
2189
+
2190
+#ifndef TCL_UTF_MAX
2191
+#define TCL_UTF_MAX 3
2192
+#endif
2193
+
2194
+/*
2195
+ * This represents a Unicode character. Any changes to this should also be
2196
+ * reflected in regcustom.h.
2197
+ */
2198
+
2199
+#if TCL_UTF_MAX > 4
2200
+ /*
2201
+ * unsigned int isn't 100% accurate as it should be a strict 4-byte value
2202
+ * (perhaps wchar_t). 64-bit systems may have troubles. The size of this
2203
+ * value must be reflected correctly in regcustom.h and
2204
+ * in tclEncoding.c.
2205
+ * XXX: Tcl is currently UCS-2 and planning UTF-16 for the Unicode
2206
+ * XXX: string rep that Tcl_UniChar represents. Changing the size
2207
+ * XXX: of Tcl_UniChar is /not/ supported.
2208
+ */
2209
+typedef unsigned int Tcl_UniChar;
2210
+#else
2211
+typedef unsigned short Tcl_UniChar;
2212
+#endif
2213
+
2214
+
2215
+/*
2216
+ *----------------------------------------------------------------------------
2217
+ * TIP #59: The following structure is used in calls 'Tcl_RegisterConfig' to
2218
+ * provide the system with the embedded configuration data.
2219
+ */
2220
+
2221
+typedef struct Tcl_Config {
2222
+ const char *key; /* Configuration key to register. ASCII
2223
+ * encoded, thus UTF-8. */
2224
+ const char *value; /* The value associated with the key. System
2225
+ * encoding. */
2226
+} Tcl_Config;
2227
+
2228
+/*
2229
+ *----------------------------------------------------------------------------
2230
+ * Flags for TIP#143 limits, detailing which limits are active in an
2231
+ * interpreter. Used for Tcl_{Add,Remove}LimitHandler type argument.
2232
+ */
2233
+
2234
+#define TCL_LIMIT_COMMANDS 0x01
2235
+#define TCL_LIMIT_TIME 0x02
2236
+
2237
+/*
2238
+ * Structure containing information about a limit handler to be called when a
2239
+ * command- or time-limit is exceeded by an interpreter.
2240
+ */
2241
+
2242
+typedef void (Tcl_LimitHandlerProc) (ClientData clientData, Tcl_Interp *interp);
2243
+typedef void (Tcl_LimitHandlerDeleteProc) (ClientData clientData);
2244
+
2245
+/*
2246
+ *----------------------------------------------------------------------------
2247
+ * Override definitions for libtommath.
2248
+ */
2249
+
2250
+typedef struct mp_int mp_int;
2251
+#define MP_INT_DECLARED
2252
+typedef unsigned int mp_digit;
2253
+#define MP_DIGIT_DECLARED
2254
+
2255
+/*
2256
+ *----------------------------------------------------------------------------
2257
+ * Definitions needed for Tcl_ParseArgvObj routines.
2258
+ * Based on tkArgv.c.
2259
+ * Modifications from the original are copyright (c) Sam Bromley 2006
2260
+ */
2261
+
2262
+typedef struct {
2263
+ int type; /* Indicates the option type; see below. */
2264
+ const char *keyStr; /* The key string that flags the option in the
2265
+ * argv array. */
2266
+ void *srcPtr; /* Value to be used in setting dst; usage
2267
+ * depends on type.*/
2268
+ void *dstPtr; /* Address of value to be modified; usage
2269
+ * depends on type.*/
2270
+ const char *helpStr; /* Documentation message describing this
2271
+ * option. */
2272
+ ClientData clientData; /* Word to pass to function callbacks. */
2273
+} Tcl_ArgvInfo;
2274
+
2275
+/*
2276
+ * Legal values for the type field of a Tcl_ArgInfo: see the user
2277
+ * documentation for details.
2278
+ */
2279
+
2280
+#define TCL_ARGV_CONSTANT 15
2281
+#define TCL_ARGV_INT 16
2282
+#define TCL_ARGV_STRING 17
2283
+#define TCL_ARGV_REST 18
2284
+#define TCL_ARGV_FLOAT 19
2285
+#define TCL_ARGV_FUNC 20
2286
+#define TCL_ARGV_GENFUNC 21
2287
+#define TCL_ARGV_HELP 22
2288
+#define TCL_ARGV_END 23
2289
+
2290
+/*
2291
+ * Types of callback functions for the TCL_ARGV_FUNC and TCL_ARGV_GENFUNC
2292
+ * argument types:
2293
+ */
2294
+
2295
+typedef int (Tcl_ArgvFuncProc)(ClientData clientData, Tcl_Obj *objPtr,
2296
+ void *dstPtr);
2297
+typedef int (Tcl_ArgvGenFuncProc)(ClientData clientData, Tcl_Interp *interp,
2298
+ int objc, Tcl_Obj *const *objv, void *dstPtr);
2299
+
2300
+/*
2301
+ * Shorthand for commonly used argTable entries.
2302
+ */
2303
+
2304
+#define TCL_ARGV_AUTO_HELP \
2305
+ {TCL_ARGV_HELP, "-help", NULL, NULL, \
2306
+ "Print summary of command-line options and abort", NULL}
2307
+#define TCL_ARGV_AUTO_REST \
2308
+ {TCL_ARGV_REST, "--", NULL, NULL, \
2309
+ "Marks the end of the options", NULL}
2310
+#define TCL_ARGV_TABLE_END \
2311
+ {TCL_ARGV_END, NULL, NULL, NULL, NULL, NULL}
2312
+
2313
+/*
2314
+ *----------------------------------------------------------------------------
2315
+ * Definitions needed for Tcl_Zlib routines. [TIP #234]
2316
+ *
2317
+ * Constants for the format flags describing what sort of data format is
2318
+ * desired/expected for the Tcl_ZlibDeflate, Tcl_ZlibInflate and
2319
+ * Tcl_ZlibStreamInit functions.
2320
+ */
2321
+
2322
+#define TCL_ZLIB_FORMAT_RAW 1
2323
+#define TCL_ZLIB_FORMAT_ZLIB 2
2324
+#define TCL_ZLIB_FORMAT_GZIP 4
2325
+#define TCL_ZLIB_FORMAT_AUTO 8
2326
+
2327
+/*
2328
+ * Constants that describe whether the stream is to operate in compressing or
2329
+ * decompressing mode.
2330
+ */
2331
+
2332
+#define TCL_ZLIB_STREAM_DEFLATE 16
2333
+#define TCL_ZLIB_STREAM_INFLATE 32
2334
+
2335
+/*
2336
+ * Constants giving compression levels. Use of TCL_ZLIB_COMPRESS_DEFAULT is
2337
+ * recommended.
2338
+ */
2339
+
2340
+#define TCL_ZLIB_COMPRESS_NONE 0
2341
+#define TCL_ZLIB_COMPRESS_FAST 1
2342
+#define TCL_ZLIB_COMPRESS_BEST 9
2343
+#define TCL_ZLIB_COMPRESS_DEFAULT (-1)
2344
+
2345
+/*
2346
+ * Constants for types of flushing, used with Tcl_ZlibFlush.
2347
+ */
2348
+
2349
+#define TCL_ZLIB_NO_FLUSH 0
2350
+#define TCL_ZLIB_FLUSH 2
2351
+#define TCL_ZLIB_FULLFLUSH 3
2352
+#define ----------------------------------------------------------------------------
2353
+ * The following declarations either map ckalloc and ckfree to malloc and
2354
+ * free, or they map them to functions with all sorts of debugging hooks
2355
+ * defined in tclCkalloc.c.
2356
+ */
2357
+
2358
+#ifdef TCL_MEM_DEBUG
2359
+
2360
+# voidine ckalloc(x) \
2361
+ ((VOID *) Tcl_DbCkalloc((unsigned)(x), __FILE__, __LINE__))
2362
+# define ckfree(x) \
2363
+ Tcl_DbCkfree((char *)(x), __FILE__, __LINE__)
2364
+# defvoid *) Tcl_DbCkrealloc((char *)(x), (unsigned)(y), __FILE__, __LINE__))
2365
+# definevoid *) Tcl_AttemptDbCkalloc((unsigned)(x), __FILE__, __LINE__))
2366
+# def Include platform specific
2367
+ * via the stubsPlatDecls.h"--------------------------------------------------------
2368
+ * The structure defined below is
--- a/compat/tcl-8.6/generic/tcl.h
+++ b/compat/tcl-8.6/generic/tcl.h
@@ -0,0 +1,2368 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
--- a/compat/tcl-8.6/generic/tcl.h
+++ b/compat/tcl-8.6/generic/tcl.h
@@ -0,0 +1,2368 @@
1 /*
2 * tcl.h --
3 *
4 * This header file describes the externally-visible facilities of the
5 * Tcl interpreter.
6 *
7 * Copyright (c) 1987-1994 The Regents of the University of California.
8 * Copyright (c) 1993-1996 Lucent Technologies.
9 * Copyright (c) 1994-1998 Sun Microsystems, Inc.
10 * Copyright (c) 1998-2000 by Scriptics Corporation.
11 * Copyright (c) 2002 by Kevin B. Kenny. All rights reserved.
12 *
13 * See the file "license.terms" for information on usage and redistribution of
14 * this file, and for a DISCLAIMER OF ALL WARRANTIES.
15 */
16
17 #ifndef _TCL
18 #define _TCL
19
20 /*
21 * For C++ compilers, use extern "C"
22 */
23
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27
28 /*
29 * The following defines are used to indicate the various release levels.
30 */
31
32 #define TCL_ALPHA_RELEASE 0
33 #define TCL_BETA_RELEASE 1
34 #define TCL_FINAL_RELEASE 2
35
36 /*
37 * When version numbers change here, must also go into the following files and
38 * update the version numbers:
39 *
40 * library/init.tcl (1 LOC patch)
41 * unix/configure.in (2 LOC Major, 2 LOC minor, 1 LOC patch)
42 * win/configure.in (as above)
43 * win/tcl.m4 (not patchlevel)
44 * win/makefile.bc (not patchlevel) 2 LOC
45 * README (sections 0 and 2, with and without separator)
46 * macosx/Tcl.pbproj/project.pbxproj (not patchlevel) 1 LOC
47 * macosx/Tcl.pbproj/default.pbxuser (not patchlevel) 1 LOC
48 * macosx/Tcl.xcode/project.pbxproj (not patchlevel) 2 LOC
49 * macosx/Tcl.xcode/default.pbxuser (not patchlevel) 1 LOC
50 * macosx/Tcl-Common.xcconfig (not patchlevel) 1 LOC
51 * win/README (not patchlevel) (sections 0 and 2)
52 * unix/tcl.spec (1 LOC patch)
53 * tools/tcl.hpj.in (not patchlevel, for windows installer)
54 */
55
56 #define TCL_MAJOR_VERSION 8
57 #define TCL_MINOR_VERSION 6
58 #define TCL_RELEASE_LEVEL TCL_FINAL_RELEASE
59 #define TCL_RELEASE_SERIAL 1eader file describes the external/*
60 * tcl.h --
61 *
62 * ThisBA"8.6.1"------------------------------
63 * The following structure represents a type facilities of the
64 * Tcl interpreter.
65 *
66 * Copyright (c) 1987-1994 The Regents of the University of California.
67 * Copyright (c) 1993-1996 Lucent Technologies.
68 * Copyright (c) 1994-1998 Sun Microsystems, Inc.
69 * Copyright (c) 1998-2000 by Scriptics Corporation.
70 * Copyright (c) 2002 by Kevin B. Kenny. All rights reserved.
71 *
72 * See the file "license.terms" for information on usage and redistribution of
73 * this file, and for a DISCLAIMER OF ALL WARRANTIES.
74 */
75
76 #ifndef _TCL
77 #define _TCL
78
79 /*
80 * For C++ compilers, use extern "C"
81 */
82
83 #ifdef __cplusplus
84 extern "C" {
85 #endif
86
87 /*
88 * The following defines are used to indicate the various release levels.
89 */
90
91 #define TCL_ALPHA_RELEASE 0
92 #define TCL_BETA_RELEASE 1
93 #define TCL_FINAL_RELEASE 2
94
95 /*
96 * When version numbers change here, must also go into the following files and
97 * update the version numbers:
98 *
99 * library/init.tcl (1 LOC patch)
100 * unix/configure.in (2 LOC Major, 2 LOC minor, 1 LOC patch)
101 * win/configure.in (as above)
102 * win/tcl.m4 (not patchlevel)
103 * win/makefile.bc (not patchlevel) 2 LOC
104 * README (sections 0 and 2, with and without separator)
105 * macosx/Tcl.pbproj/project.pbxproj (not patchlevel) 1 LOC
106 * macosx/Tcl.pbproj/default.pbxuser (not patchlevel) 1 LOC
107 * macosx/Tcl.xcode/project.pbxproj (not patchlevel) 2 LOC
108 * macosx/Tcl.xcode/default.pbxuser (not patchlevel) 1 LOC
109 * macosx/Tcl-Common.xcconfig (not patchlevel) 1 LOC
110 * win/README (not patchlevel) (sections 0 and 2)
111 * unix/tcl.spec (1 LOC patch)
112 * tools/tcl.hpj.in (not patchlevel, for windows installer)
113 */
114
115 #define TCL_MAJOR_VERSION 8
116 #define TCL_MINOR_VERSION 6
117 #define TCL_RELEASE_LEVEL TCL_FINAL_RELEASE
118 #define TCL_RELEASE_SERIAL 0
119
120 #define TCL_VERSION "8.6"
121 #define TCL_PATCH_LEVEL "8.6.0"
122
123
124 /*
125 *----------------------------------------------------------------------------
126 * The following definitions set up the proper options for Windows compilers.
127 * We use this method because there is no autoconf equivalent.
128 */
129
130 #ifndef __WIN32__
131 # if defined(_WIN32) || defined(WIN32) || defined(__MINGW32__) || defined(__BORLANDC__) || (defined(__WATCOMC__) && defined(__WINDOWS_386__))
132 # define __WIN32__
133 # ifndef WIN32
134 # define WIN32
135 # endif
136 # ifndef _WIN32
137 # define _WIN32
138 # endif
139 # endif
140 #endif
141
142 /*
143 * STRICT: See MSDN Article Q83456
144 */
145
146 #ifdef __WIN32__
147 # ifndef STRICT
148 # define STRICT
149 # endif
150 #endif /* __WIN32__ */
151
152 /*
153 * Utility macros: STRINGIFY takes an argument and wraps it in "" (double
154 * quotation marks), JOIN joins two arguments.
155 */
156
157 #ifndef STRINGIFY
158 # define STRINGIFY(x) STRINGIFY1(x)
159 # define STRINGIFY1(x) #x
160 #endif
161 #ifndef JOIN
162 # define JOIN(a,b) JOIN1(a,b)
163 # define JOIN1(a,b) a##b
164 #endif
165
166 /*
167 * A special definition used to allow this header file to be included from
168 * windows resource files so that they can obtain version information.
169 * RC_INVOKED is defined by default by the windows RC tool.
170 *
171 * Resource compilers don't like all the C stuff, like typedefs and function
172 * declarations, that occur below, so block them out.
173 */
174
175 #ifndef RC_INVOKED
176
177 /*
178 * Special macro to define mutexes, that doesn't do anything if we are not
179 * using threads.
180 */
181
182 #ifdef TCL_THREADS
183 #define TCL_DECLARE_MUTEX(name) static Tcl_Mutex name;
184 #else
185 #define TCL_DECLARE_MUTEX(name)
186 #endif
187
188 /*
189 * Tcl's public routine Tcl_FSSeek() uses the values SEEK_SET, SEEK_CUR, and
190 * SEEK_END, all #define'd by stdio.h .
191 *
192 * Also, many extensions need stdio.h, and they've grown accustomed to tcl.h
193 * providing it for them rather than #include-ing it themselves as they
194 * should, so also for their sake, we keep the #include to be consistent with
195 * prior Tcl releases.
196 */
197
198 #include <stdio.h>
199
200 /*
201 *----------------------------------------------------------------------------
202 * Support for functions with a variable number of arguments.
203 *
204 * The following TCL_VARARGS* macros are to support old extensions
205 * written for older versions of Tcl where the macros permitted
206 * support for the varargs.h system as well as stdarg.h .
207 *
208 * New code should just directly be written to use stdarg.h conventions.
209 */
210
211 #include <stdarg.h>
212 #ifndef TCL_NO_DEPRECATED
213 # define TCL_VARARGS(type, name) (type name, ...)
214 # define TCL_VARARGS_DEF(type, name) (type name, ...)
215 # define TCL_VARARGS_START(type, name, list) (va_start(list, name), name)
216 #endif
217 #if defined(__GNUC__) && (__GNUC__ > 2)
218 # define TCL_FORMAT_PRINTF(a,b) __attribute__ ((__format__ (__printf__, a, b)))
219 #else
220 # define TCL_FORMAT_PRINTF(a,b)
221 #endif
222
223 /*
224 * Allow a part of Tcl's API to be explicitly marked as deprecated.
225 *
226 * Used to make TIP 330/336 generate moans even if people use the
227 * compatibility macros. Change your code, guys! We won't support you forever.
228 */
229
230 #if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)))
231 # if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC__MINOR__ >= 5))
232 # define TCL_DEPRECATED_API(msg) __attribute__ ((__deprecated__ (msg)))
233 # else
234 # define TCL_DEPRECATED_API(msg) __attribute__ ((__deprecated__))
235 # endif
236 #else
237 # define TCL_DEPRECATED_API(msg) /* nothing portable */
238 #endif
239
240 /*
241 *----------------------------------------------------------------------------
242 * Macros used to declare a function to be exported by a DLL. Used by Windows,
243 * maps to no-op declarations on non-Windows systems. The default build on
244 * windows is for a DLL, which causes the DLLIMPORT and DLLEXPORT macros to be
245 * nonempty. To build a static library, the macro STATIC_BUILD should be
246 * defined.
247 *
248 * Note: when building static but linking dynamically to MSVCRT we must still
249 * correctly decorate the C library imported function. Use CRTIMPORT
250 * for this purpose. _DLL is defined by the compiler when linking to
251 * MSVCRT.
252 */
253
254 #if (defined(__WIN32__) && (defined(_MSC_VER) || (__BORLANDC__ >= 0x0550) || defined(__/*
255 * tcl.h
256 # ifndef NO_VOID
257 # define VOID void
258 # ((__deprecated__VOID char/*
259 * tcl.h --
260 *
261 * Thiss header file describes the externally-visible facilities of the
262 * Tcl interpreter.
263 *
264 * Copyright (c) 1987-1994 The Regents of the University of California.
265 * Copyright (c) 1993-1996 Lucent Technologies.
266 * Copyright (c) 1994-1998 Sun Microsystems, Inc.
267 * Copyright (c) 1998-2000 by Scriptics Corporation.
268 * Copyright (c) 2002 by Kevin B. Kenny. All rights reserved.
269 *
270 * See the file "license.terms" for information on usage and redistribution of
271 * this file, and for a DISCLAIMER OF ALL WARRANTIES.
272 */
273
274 #ifndef _TCL
275 #define _TCL
276
277 /*
278 * For C++ compilers, use extern "C"
279 */
280
281 #ifdef __cplusplus
282 extern "C" {
283 #endif
284
285 /*
286 * The following defines are used to indicate the various release levels.
287 */
288
289 #define TCL_ALPHA_RELEASE 0
290 #define TCL_BETA_RELEASE 1
291 #define TCL_FINAL_RELEASE 2
292
293 /*
294 * When version numbers change here, must also go into the following files and
295 * update the version numbers:
296 *
297 * library/init.tcl (1 LOC patch)
298 * unix/configure.in (2 LOC Major, 2 LOC minor, 1 LOC patch)
299 * win/configure.in (as above)
300 * win/tcl.m4 (not patchlevel)
301 * win/makefile.bc (not patchlevel) 2 LOC
302 * README (sections 0 and 2, with and without separator)
303 * macosx/Tcl.pbproj/project.pbxproj (not patchlevel) 1 LOC
304 * macosx/Tcl.pbproj/default.pbxuser (not patchlevel) 1 LOC
305 * macosx/Tcl.xcode/project.pbxproj (not patchlevel) 2 LOC
306 * macosx/Tcl.xcode/default.pbxuser (not patchlevel) 1 LOC
307 * macosx/Tcl-Common.xcconfig (not patchlevel) 1 LOC
308 * win/README (not patchlevel) (sections 0 and 2)
309 * unix/tcl.spec (1 LOC patch)
310 * tools/tcl.hpj.in (not patchlevel, for windows installer)
311 */
312
313 #define TCL_MAJOR_VERSION 8
314 #define TCL_MINOR_VERSION 6
315 #define TCL_RELEASE_LEVEL TCL_FINAL_RELEASE
316 #define TCL_RELEASE_SERIAL 0
317
318 #define TCL_VERSION "8.6"
319 #define TCL_PATCH_LEVEL "8.6.0"
320
321
322 /*
323 *----------------------------------------------------------------------------
324 * The following definitions set up the proper options for Windows compilers.
325 * We use this method because there is no autoconf equivalent.
326 */
327
328 #ifndef __WIN32__
329 # if defined(_WIN32) || defined(WIN32) || defined(__MINGW32__) || defined(__BORLANDC__) || (defined(__WATCOMC__) && defined(__WINDOWS_386__))
330 # define __WIN32__
331 # ifndef WIN32
332 # define WIN32
333 # endif
334 # ifndef _WIN32
335 # define _WIN32
336 # endif
337 # endif
338 #endif
339
340 /*
341 * STRICT: See MSDN Article Q83456
342 */
343
344 #ifdef __WIN32__
345 # ifndef STRICT
346 # define STRICT
347 # endif
348 #endif /* __WIN32__ */
349
350 /*
351 * Utility macros: STRINGIFY takes an argument and wraps it in "" (double
352 * quotation marks), JOIN joins two arguments.
353 */
354
355 #ifndef STRINGIFY
356 # define STRINGIFY(x) STRINGIFY1(x)
357 # define STRINGIFY1(x) #x
358 #endif
359 #ifndef JOIN
360 # define JOIN(a,b) JOIN1(a,b)
361 # define JOIN1(a,b) a##b
362 #endif
363
364 /*
365 * A special definition used to allow this header file to be included from
366 * windows resource files so that they can obtain version information.
367 * RC_INVOKED is defined by default by the windows RC tool.
368 *
369 * Resource compilers don't like all the C stuff, like typedefs and function
370 * declarations, that occur below, so block them out.
371 */
372
373 #ifndef RC_INVOKED
374
375 /*
376 * Special macro to define mutexes, that doesn't do anything if we are not
377 * using threads.
378 */
379
380 #ifdef TCL_THREADS
381 #define TCL_DECLARE_MUTEX(name) static Tcl_Mutex name;
382 #else
383 #define TCL_DECLARE_MUTEX(name)
384 #endif
385
386 /*
387 * Tcl's public routine Tcl_FSSeek() uses the values SEEK_SET, SEEK_CUR, and
388 * SEEK_END, all #define'd by stdio.h .
389 *
390 * Also, many extensions need stdio.h, and they've grown accustomed to tcl.h
391 * providing it for them rather than #include-ing it themselves as they
392 * should, so also for their sake, we keep the #include to be consistent with
393 * prior Tcl releases.
394 */
395
396 #include <stdio.h>
397
398 /*
399 *----------------------------------------------------------------------------
400 * Support for functions with a variable number of arguments.
401 *
402 * The following TCL_VARARGS* macros are to support old extensions
403 * written for older versions of Tcl where the macros permitted
404 * support for the varargs.h system as well as stdarg.h .
405 *
406 * New code should just directly be written to use stdarg.h conventions.
407 */
408
409 #include <stdarg.h>
410 #ifndef TCL_NO_DEPRECATED
411 # define TCL_VARARGS(type, name) (type name, ...)
412 # define TCL_VARARGS_DEF(type, name) (type name, ...)
413 # defi && !defined(__APPLE__ defined(HAVE_STRUCT_STAT64)
414 typedef struct stat64 Tcl_StatBuf;
415 #else
416 typedef struct stat Tcl_StatBuf;
417 #endif
418
419
420 /*
421 *----------------------------------------------------------------------------
422 * Data structures defined opaquely in this module. The definitions below just
423 * provide dummy types. A few fields are made visible in Tcl_Interp
424 * structures, namely those used for returning a string result from commands.
425 * Direct access to the result field is discouraged in Tcl 8.0. The
426 * interpreter result is either an object or a string, and the two values are
427 * kept consistent unless some C code sets interp->result directly.
428 * Programmers should use either the function Tcl_GetObjResult() or
429 * Tcl_GetStringResult() to read the interpreter's result. See the SetResult
430 * man page for details.
431 *
432 * Note: any change to the Tcl_Interp definition below must be mirrored in the
433 * "real" definition in tclInt.h.
434 *
435 * Note: Tcl_ObjCmdProc functions do not directly set result and freeProc.
436 * Instead, they set a Tcl_Obj member in the "real" structure that can be
437 * accessed with Tcl_GetObjResult() and Tcl_SetObjResult().
438 */
439
440 typedef struct Tcl_Interp
441 #ifndef TCL_NO_DEPRECATED
442 {
443 /* TIP #330: Strongly discourage extensions from using the string
444 * result. */
445 #ifdef USE_INTERP_RStringe is a 4-byte gap */
446 long long;
447 unsigned short st_ino;
448 unsigned short st_mode;
449 short st_nlink;
450 short st_uid;
451 short st_gid;
452 /* Here is a 2-byte gap */
453 dev_t st_rdev;
454 /* HerStringe is a 4-byte gap */
455 long long st_size;
456 struct {long tv_sec;} st_atim;
457 struct {long tv_sec;} st_mtim;
458 struct {long tv_sec;} st_ctim;
459 /* Here is a 4-byte gap */
460 } Tcl_StatBuf;
461 #elif defined(HAVE_STRUCT_STAT64)
462 typedef struct stat64 Tcl_StatBuf;
463 #else
464 typedef struct stat Tcl_StatBuf;
465 #endif
466
467
468 /*
469 *----------------------------------------------------------------------------
470 * Data structures defined opaquely in this module. The definitions below just
471 * provide dummy types. A few fields are made visible in Tcl_Interp
472 * structures, namely those used for returning a string result from commands.
473 * Direct access to the result field is discouraged in Tcl 8.0. The
474 * interpreter result is either an object or a string, and the two values are
475 * kept consistent unless some C code sets interp->result directly.
476 * Programmers should use either the function Tcl_GetObjResult() or
477 * Tcl_GetStringResult() to read the interpreter's result. See the SetResult
478 * man page for details.
479 *
480 * Note: any change to the Tcl_Interp definition below must be mirrored in the
481 * "real" definition in tclInt.h.
482 *
483 * Note: Tcl_ObjCmdProc functions do not directly set result and freeProc.
484 * Instead, they set a Tcl_Obj member in the "real" structure that can be
485 * accessed with Tcl_GetObjResult() and Tcl_SetObjResult().
486 */
487
488 typedef struct Tcl_Interp
489 #ifndef TCL_NO_DEPRECATED
490 {
491 /* TIP #330: Strongly discourage extensions from using the string
492 * result. */
493 #ifdef USE_INTERP_RESULT
494 char *result TCL_DEPRECATED_API("use Tcl_GetResult/Tcl_SetResult");
495 /* If the last command returned a string
496 * result, this points to it. */
497 void (*freeProc) (char *blockPtr)
498 TCL_DEPRECATED_API("use Tcl_GetResult/Tcl_SetResult");
499 /* Zero means the string result is statically
500 * allocated. TCL_DYNAMIC means it was
501 * allocated with ckalloc and should be freed
502 * with ckfree. Other values give the address
503 * of function to invoke to free the result.
504 * Tcl_Eval must free it before executing next
505 * command. */
506 #else
507 char *resultDontUse; /* Don't use in extensions! */
508 void (*freeProcDontUse) (char *); /* Don't use in extensions! */
509 #endif
510 #ifdef USE_INTERP_ERRORLINE
511 int errorLine TCL_DEPRECATED_API("use Tcl_GetErrorLine/Tcl_SetErrorLine");
512 /* When TCL_ERROR is returned, this gives the
513 * line number within the command where the
514 * error occurred (1 if first line). */
515 #else
516 int errorLineDontUse; /* Don't use in extensions! */
517 #endif
518 }
519 #endif /* TCL_NO_DEPRECATED */
520 Tcl_Interp;
521
522 typedef struct Tcl_AsyncHandler_ *Tcl_AsyncHandler;
523 typedef struct Tcl_Channel_ *Tcl_Channel;
524 typedef struct Tcl_ChannelTypeVersion_ *Tcl_ChannelTypeVersion;
525 typedef struct Tcl_Command_ *Tcl_Command;
526 typedef struct Tcl_Condition_ *Tcl_Condition;
527 typedef struct Tcl_Dict_ *Tcl_Dict;
528 typedef struct Tcl_EncodingState_ *Tcl_EncodingState;
529 typedef struct Tcl_Encoding_ *Tcl_Encoding;
530 typedef struct Tcl_Event Tcl_Event;
531 typedef struct Tcl_InterpState_ *Tcl_InterpState;
532 typedef struct Tcl_LoadHandle_ *Tcl_LoadHandle;
533 typedef struct Tcl_Mutex_ *Tcl_Mutex;
534 typedef struct Tcl_Pid_ *Tcl_Pid;
535 typedef struct Tcl_RegExp_ *Tcl_RegExp;
536 typedef struct Tcl_ThreadDataKey_ *Tcl_ThreadDataKey;
537 typedef struct Tcl_ThreadId_ *Tcl_ThreadId;
538 typedef struct Tcl_TimerToken_ *Tcl_TimerToken;
539 typedef struct Tcl_Trace_ *Tcl_Trace;
540 typedef struct Tcl_Var_ *Tcl_Var;
541 typedef struct Tcl_ZLibStream_ *Tcl_ZlibStream;
542
543 /*
544 *----------------------------------------------------------------------------
545 * Definition of the interface to functions implementing threads. A function
546 * following this definition is given to each call of 'Tcl_CreateThread' and
547 * will be called as the main fuction of the new thread created by that call.
548 */
549
550 #if defined __WIN32__
551 typedef unsigned (__stdcall Tcl_ThreadCreateProc) (ClientData clientData);
552 #else
553 typedef void (Tcl_ThreadCreateProc) (ClientData clientData);
554 #endif
555
556 /*
557 * Threading function return types used for abstracting away platform
558 * differences when writing a Tcl_ThreadCreateProc. See the NewThread function
559 * in generic/tclThreadTest.c for it's usage.
560 */
561
562 #if defined __WIN32__
563 # define Tcl_ThreadCreateType unsigned __stdcall
564 # define TCL_THREAD_CREATE_RETURN return 0
565 #else
566 # define Tcl_ThreadCreateType void
567 # define TCL_THREAD_CREATE_RETURN
568 #endif
569
570 /*
571 * Definition of values for default stacksize and the possible flags to be
572 * given to Tcl_CreateThread.
573 */
574
575 #define TCL_THREAD_STACK_DEFAULT (0) /* Use default size for stack. */
576 #define TCL_THREAD_NOFLAGS (0000) /* Standard flags, default
577 * behaviour. */
578 #define TCL_THREAD_JOINABLE (0001) /* Mark the thread as joinable. */
579
580 /*
581 * Flag values passed to Tcl_StringCaseMatch.
582 */
583
584 #define TCL_MATCH_NOCASE (1<<0)
585
586 /*
587 * Flag values passed to Tcl_GetRegExpFromObj.
588 */
589
590 #define TCL_REG_BASIC 000000 /* BREs (convenience). */
591 #define TCL_REG_EXTENDED 000001 /* EREs. */
592 #define TCL_REG_ADVF 000002 /* Advanced features in EREs. */
593 #define TCL_REG_ADVANCED 000003 /* AREs (which are also EREs). */
594 #define TCL_REG_QUOTE 000004 /* No special characters, none. */
595 #define TCL_REG_NOCASE 000010 /* Ignore case. */
596 #define TCL_REG_NOSUB 000020 /* Don't care about subexpressions. */
597 #define TCL_REG_EXPANDED 000040 /* Expanded format, white space &
598 * comments. */
599 #define TCL_REG_NLSTOP 000100 /* \n doesn't match . or [^ ] */
600 #define TCL_REG_NLANCH 000200 /* ^ matches after \n, $ before. */
601 #define TCL_REG_NEWLINE 000300 /* Newlines are line terminators. */
602 #define TCL_REG_CANMATCH 001000 /* Report details on partial/limited
603 * matches. */
604
605 /*
606 * Flags values passed to Tcl_RegExpExecObj.
607 */
608
609 #define TCL_REG_NOTBOL 0001 /* Beginning of string does not match ^. */
610 #define TCL_REG_NOTEOL 0002 /* End of string does not match $. */
611
612 /*
613 * Structures filled in by Tcl_RegExpInfo. Note that all offset values are
614 * relative to the start of the match string, not the beginning of the entire
615 * string.
616 */
617
618 typedef struct Tcl_RegExpIndices {
619 long start; /* Character offset of first character in
620 * match. */
621 long end; /* Character offset of first character after
622 * the match. */
623 } Tcl_RegExpIndices;
624
625 typedef struct Tcl_RegExpInfo {
626 int nsubs; /* Number of subexpressions in the compiled
627 * expression. */
628 Tcl_RegExpIndices *matches; /* Array of nsubs match offset pairs. */
629 long extendStart; /* The offset at which a subsequent match
630 * might begin. */
631 long reserved; /* Reserved for later use. */
632 } Tcl_RegExpInfo;
633
634 /*
635 * Picky compilers complain if this typdef doesn't appear before the struct's
636 * reference in tclDecls.h.
637 */
638
639 typedef Tcl_StatBuf *Tcl_Stat_;
640 typedef struct stat *Tcl_OldStat_;
641
642 /*
643 *----------------------------------------------------------------------------
644 * When a TCL command returns, the interpreter contains a result from the
645 * command. Programmers are strongly encouraged to use one of the functions
646 * Tcl_GetObjResult() or Tcl_GetStringResult() to read the interpreter's
647 * result. See the SetResult man page for details. Besides this result, the
648 * command function returns an integer code, which is one of the following:
649 *
650 * TCL_OK Command completed normally; the interpreter's result
651 * contains the command's result.
652 * TCL_ERROR The command couldn't be completed successfully; the
653 * interpreter's result describes what went wrong.
654 * TCL_RETURN The command requests that the current function return;
655 * the interpreter's result contains the function's
656 * return value.
657 * TCL_BREAK The command requests that the innermost loop be
658 * exited; the interpreter's result is meaningless.
659 * TCL_CONTINUE Go on to the next iteration of the current loop; the
660 * interpreter's result is meaningless.
661 */
662
663 #define TCL_OK 0
664 #define TCL_ERROR 1
665 #define TCL_RETURN 2
666 #define TCL_BREAK 3
667 #define TCL_CONTINUE 4
668
669 #define TCL_RESULT_SIZE 200
670
671 /*
672 *----------------------------------------------------------------------------
673 * Flags to control what substitutions are performed by Tcl_SubstObj():
674 */
675
676 #define TCL_SUBST_COMMANDS 001
677 #define TCL_SUBST_VARIABLES 002
678 #define TCL_SUBST_BACKSLASHES 004
679 #define TCL_SUBST_ALL 007
680
681 /*
682 * Argument descriptors for math function callbacks in expressions:
683 */
684
685 typedef enum {
686 TCL_INT, TCL_DOUBLE, TCL_EITHER, TCL_WIDE_INT
687 } Tcl_ValueType;
688
689 typedef struct Tcl_Value {
690 Tcl_ValueType type; /* Indicates intValue or doubleValue is valid,
691 * or both. */
692 long intValue; /* Integer value. */
693 double doubleValue; /* Double-precision floating value. */
694 Tcl_WideInt wideValue; /* Wide (min. 64-bit) integer value. */
695 } Tcl_Value;
696
697 /*
698 * Forward declaration of Tcl_Obj to prevent an error when the forward
699 * reference to Tcl_Obj is encountered in the function types declared below.
700 */
701
702 struct Tcl_Obj;
703
704 /*
705 *----------------------------------------------------------------------------
706 * Function types defined by Tcl:
707 */
708
709 typedef int (Tcl_AppInitProc) (Tcl_Interp *interp);
710 typedef int (Tcl_AsyncProc) (ClientData clientData, Tcl_Interp *interp,
711 int code);
712 typedef void (Tcl_ChannelProc) (ClientData clientData, int mask);
713 typedef void (Tcl_CloseProc) (ClientData data);
714 typedef void (Tcl_CmdDeleteProc) (ClientData clientData);
715 typedef int (Tcl_CmdProc) (ClientData clientData, Tcl_Interp *interp,
716 int argc, CONST84 char *argv[]);
717 typedef void (Tcl_CmdTraceProc) (ClientData clientData, Tcl_Interp *interp,
718 int level, char *command, Tcl_CmdProc *proc,
719 ClientData cmdClientData, int argc, CONST84 char *argv[]);
720 typedef int (Tcl_CmdObjTraceProc) (ClientData clientData, Tcl_Interp *interp,
721 int level, const char *command, Tcl_Command commandInfo, int objc,
722 struct Tcl_Obj *const *objv);
723 typedef void (Tcl_CmdObjTraceDeleteProc) (ClientData clientData);
724 typedef void (Tcl_DupInternalRepProc) (struct Tcl_Obj *srcPtr,
725 struct Tcl_Obj *dupPtr);
726 typedef int (Tcl_EncodingConvertProc) (ClientData clientData, const char *src,
727 int srcLen, int flags, Tcl_EncodingState *statePtr, char *dst,
728 int dstLen, int *srcReadPtr, int *dstWrotePtr, int *dstCharsPtr);
729 typedef void (Tcl_EncodingFreeProc) (ClientData clientData);
730 typedef int (Tcl_EventProc) (Tcl_Event *evPtr, int flags);
731 typedef void (Tcl_EventCheckProc) (ClientData clientData, int flags);
732 typedef int (Tcl_EventDeleteProc) (Tcl_Event *evPtr, ClientData clientData);
733 typedef void (Tcl_EventSetupProc) (ClientData clientData, int flags);
734 typedef void (Tcl_ExitProc) (ClientData clientData);
735 typedef void (Tcl_FileProc) (ClientData clientData, int mask);
736 typedef void (Tcl_FileFreeProc) (ClientData clientData);
737 typedef void (Tcl_FreeInternalRepProc) (struct Tcl_Obj *objPtr);
738 typedef void (Tcl_FreeProc) (char *blockPtr);
739 typedef void (Tcl_IdleProc) (ClientData clientData);
740 typedef void (Tcl_InterpDeleteProc) (ClientData clientData,
741 Tcl_Interp *interp);
742 typedef int (Tcl_MathProc) (ClientData clientData, Tcl_Interp *interp,
743 Tcl_Value *args, Tcl_Value *resultPtr);
744 typedef void (Tcl_NamespaceDeleteProc) (ClientData clientData);
745 typedef int (Tcl_ObjCmdProc) (ClientData clientData, Tcl_Interp *interp,
746 int objc, struct Tcl_Obj *const *objv);
747 typedef int (Tcl_PackageInitProc) (Tcl_Interp *interp);
748 typedef int (Tcl_PackageUnloadProc) (Tcl_Interp *interp, int flags);
749 typedef void (Tcl_PanicProc) (const char *format, ...);
750 typedef void (Tcl_TcpAcceptProc) (ClientData callbackData, Tcl_Channel chan,
751 char *address, int port);
752 typedef void (Tcl_TimerProc) (ClientData clientData);
753 typedef int (Tcl_SetFromAnyProc) (Tcl_Interp *interp, struct Tcl_Obj *objPtr);
754 typedef void (Tcl_UpdateStringProc) (struct Tcl_Obj *objPtr);
755 typedef char * (Tcl_VarTraceProc) (ClientData clientData, Tcl_Interp *interp,
756 CONST84 char *part1, CONST84 char *part2, int flags);
757 typedef void (Tcl_CommandTraceProc) (ClientData clientData, Tcl_Interp *interp,
758 const char *oldName, const char *newName, int flags);
759 typedef void (Tcl_CreateFileHandlerProc) (int fd, int mask, Tcl_FileProc *proc,
760 ClientData clientData);
761 typedef void (Tcl_DeleteFileHandlerProc) (int fd);
762 typedef void (Tcl_AlertNotifierProc) (ClientData clientData);
763 typedef void (Tcl_ServiceModeHookProc) (int mode);
764 typedef ClientData (Tcl_InitNotifierProc) (void);
765 typedef void (Tcl_FinalizeNotifierProc) (ClientData clientData);
766 typedef void (Tcl_MainLoopProc) (void);
767
768
769 /*
770 *----------------------------------------------------------------------------
771 * The following structure represents a type of object, which is a particular
772 * internal representation for an object plus a set of functions that provide
773 * standard operations on objects of that type.
774 */
775
776 typedef struct Tcl_ObjType {
777 const char *name; /* Name of the type, e.g. "int". */
778 Tcl_FreeInternalRepProc *freeIntRepProc;
779 /* Called to free any storage for the type's
780 * internal rep. NULL if the internal rep does
781 * not need freeing. */
782 Tcl_DupInternalRepProc *dupIntRepProc;
783 /* Called to create a new object as a copy of
784 * an existing object. */
785 Tcl_UpdateStringProc *updateStringProc;
786 /* Called to update the string rep from the
787 * type's internal representation. */
788 Tcl_SetFromAnyProc *setFromAnyProc;
789 /* Called to convert the object's internal rep
790 * to this type. Frees the internal rep of the
791 * old type. Returns TCL_ERROR on failure. */
792 } Tcl_ObjType;
793
794 /*
795 * One of the following structures exists for each object in the Tcl system.
796 * An object stores a value as either a string, some internal representation,
797 * or both.
798 */
799
800 typedef struct Tcl_Obj {
801 int refCount; /* When 0 the object will be freed. */
802 char *bytes; /* This points to the first byte of the
803 * object's string representation. The array
804 * must be followed by a null byte (i.e., at
805 * offset length) but may also contain
806 * embedded null characters. The array's
807 * storage is allocated by ckalloc. NULL means
808 * the string rep is invalid and must be
809 * regenerated from the internal rep. Clients
810 * should use Tcl_GetStringFromObj or
811 * Tcl_GetString to get a pointer to the byte
812 * array as a readonly value. */
813 int length; /* The number of bytes at *bytes, not
814 * including the terminating null. */
815 const Tcl_ObjType *typePtr; /* Denotes the object's type. Always
816 * corresponds to the type of the object's
817 * internal rep. NULL indicates the object has
818 * no internal rep (has no type). */
819 union { /* The internal representation: */
820 long longValue; /* - an long integer value. */
821 double doubleValue; /* - a double-precision floating value. */
822 void *otherValuePtr; /* - another, type-specific value. */
823 Tcl_WideInt wideValue; /* - a long long value. */
824 struct { /* - internal rep as two pointers. */
825 void *ptr1;
826 void *ptr2;
827 } twoPtrValue;
828 struct { /* - internal rep as a pointer and a long,
829 * the main use of which is a bignum's
830 * tightly packed fields, where the alloc,
831 * used and signum flags are packed into a
832 * single word with everything else hung
833 * off the pointer. */
834 void *ptr;
835 unsigned long value;
836 } ptrAndLongRep;
837 } internalRep;
838 } Tcl_Obj;
839
840 /*
841 * Macros to increment and decrement a Tcl_Obj's reference count, and to test
842 * whether an object is shared (i.e. has reference count > 1). Note: clients
843 * should use Tcl_DecrRefCount() when they are finished using an object, and
844 * should never call TclFreeObj() directly. TclFreeObj() is only defined and
845 * made public in tcl.h to support Tcl_DecrRefCount's macro definition.
846 */
847
848 void Tcl_IncrRefCount(Tcl_Obj *objPtr);
849 void Tcl_DecrRefCount(Tcl_Obj *objPtr);
850 int Tcl_IsShared(Tcl_Obj *objPtr);
851
852
853 /*
854 *----------------------------------------------------------------------------
855 * The following structure contains the state needed by Tcl_SaveResult. No-one
856 * outside of Tcl should access any of these fields. This structure is
857 * typically allocated on the stack.
858 */
859
860 typedef struct Tcl_SavedResult {
861 char *result;
862 Tcl_FreeProc *freeProc;
863 Tcl_Obj *objResultPtr;
864 char *appendResult;
865 int appendAvl;
866 int appendUsed;
867 char resultSpace[TCL_RESULT_SIZE+1];
868 } Tcl_SavedResult;
869
870 /*
871 *----------------------------------------------------------------------------
872 * The following definitions support Tcl's namespace facility. Note: the first
873 * five fields must match exactly the fields in a Namespace structure (see
874 * tclInt.h).
875 */
876
877 typedef struct Tcl_Namespace {
878 char *name; /* The namespace's name within its parent
879 * namespace. This contains no ::'s. The name
880 * of the global namespace is "" although "::"
881 * is an synonym. */
882 char *fullName; /* The namespace's fully qualified name. This
883 * starts with ::. */
884 ClientData clientData; /* Arbitrary value associated with this
885 * namespace. */
886 Tcl_NamespaceDeleteProc *deleteProc;
887 /* Function invoked when deleting the
888 * namespace to, e.g., free clientData. */
889 struct Tcl_Namespace *parentPtr;
890 /* Points to the namespace that contains this
891 * one. NULL if this is the global
892 * namespace. */
893 } Tcl_Namespace;
894
895 /*
896 *----------------------------------------------------------------------------
897 * The following structure represents a call frame, or activation record. A
898 * call frame defines a naming context for a procedure call: its local scope
899 * (for local variables) and its namespace scope (used for non-local
900 * variables; often the global :: namespace). A call frame can also define the
901 * naming context for a namespace eval or namespace inscope command: the
902 * namespace in which the command's code should execute. The Tcl_CallFrame
903 * structures exist only while procedures or namespace eval/inscope's are
904 * being executed, and provide a Tcl call stack.
905 *
906 * A call frame is initialized and pushed using Tcl_PushCallFrame and popped
907 * using Tcl_PopCallFrame. Storage for a Tcl_CallFrame must be provided by the
908 * Tcl_PushCallFrame caller, and callers typically allocate them on the C call
909 * stack for efficiency. For this reason, Tcl_CallFrame is defined as a
910 * structure and not as an opaque token. However, most Tcl_CallFrame fields
911 * are hidden since applications should not access them directly; others are
912 * declared as "dummyX".
913 *
914 * WARNING!! The structure definition must be kept consistent with the
915 * CallFrame structure in tclInt.h. If you change one, change the other.
916 */
917
918 typedef struct Tcl_CallFrame {
919 Tcl_Namespace *nsPtr;
920 int dummy1;
921 int dummy2;
922 void *dummy3;
923 void *dummy4;
924 void *dummy5;
925 int dummy6;
926 void *dummy7;
927 void *dummy8;
928 int dummy9;
929 void *dummy10;
930 void *dummy11;
931 void *dummy12;
932 void *dummy13;
933 } Tcl_CallFrame;
934
935 /*
936 *----------------------------------------------------------------------------
937 * Information about commands that is returned by Tcl_GetCommandInfo and
938 * passed to Tcl_SetCommandInfo. objProc is an objc/objv object-based command
939 * function while proc is a traditional Tcl argc/argv string-based function.
940 * Tcl_CreateObjCommand and Tcl_CreateCommand ensure that both objProc and
941 * proc are non-NULL and can be called to execute the command. However, it may
942 * be faster to call one instead of the other. The member isNativeObjectProc
943 * is set to 1 if an object-based function was registered by
944 * Tcl_CreateObjCommand, and to 0 if a string-based function was registered by
945 * Tcl_CreateCommand. The other function is typically set to a compatibility
946 * wrapper that does string-to-object or object-to-string argument conversions
947 * then calls the other function.
948 */
949
950 typedef struct Tcl_CmdInfo {
951 int isNativeObjectProc; /* 1 if objProc was registered by a call to
952 * Tcl_CreateObjCommand; 0 otherwise.
953 * Tcl_SetCmdInfo does not modify this
954 * field. */
955 Tcl_ObjCmdProc *objProc; /* Command's object-based function. */
956 ClientData objClientData; /* ClientData for object proc. */
957 Tcl_CmdProc *proc; /* Command's string-based function. */
958 ClientData clientData; /* ClientData for string proc. */
959 Tcl_CmdDeleteProc *deleteProc;
960 /* Function to call when command is
961 * deleted. */
962 ClientData deleteData; /* Value to pass to deleteProc (usually the
963 * same as clientData). */
964 Tcl_Namespace *namespacePtr;/* Points to the namespace that contains this
965 * command. Note that Tcl_SetCmdInfo will not
966 * change a command's namespace; use
967 * TclRenameCommand or Tcl_Eval (of 'rename')
968 * to do that. */
969 } Tcl_CmdInfo;
970
971 /*
972 *----------------------------------------------------------------------------
973 * The structure defined below is used to hold dynamic strings. The only
974 * fields that clients should use are string and length, accessible via the
975 * macros Tcl_DStringValue and Tcl_DStringLength.
976 */
977
978 #define TCL_DSTRING_STATIC_SIZE 200
979 typedef struct Tcl_DString {
980 char *string; /* Points to beginning of string: either
981 * staticSpace below or a malloced array. */
982 int length; /* Number of non-NULL characters in the
983 * string. */
984 int spaceAvl; /* Total number of bytes available for the
985 * string and its terminating NULL char. */
986 char staticSpace[TCL_DSTRING_STATIC_SIZE];
987 /* Space to use in common case where string is
988 * small. */
989 } Tcl_DString;
990
991 #define Tcl_DStringLength(dsPtr) ((dsPtr)->length)
992 #define Tcl_DStringValue(dsPtr) ((dsPtr)->string)
993 #define Tcl_DStringTrunc Tcl_DStringSetLength
994
995 /*
996 * Definitions for the maximum number of digits of precision that may be
997 * specified in the "tcl_precision" variable, and the number of bytes of
998 * buffer space required by Tcl_PrintDouble.
999 */
1000
1001 #define TCL_MAX_PREC 17
1002 #define TCL_DOUBLE_SPACE (TCL_MAX_PREC+10)
1003
1004 /*
1005 * Definition for a number of bytes of buffer space sufficient to hold the
1006 * string representation of an integer in base 10 (assuming the existence of
1007 * 64-bit integers).
1008 */
1009
1010 #define TCL_INTEGER_SPACE 24
1011
1012 /*
1013 * Flag values passed to Tcl_ConvertElement.
1014 * TCL_DONT_USE_BRACES forces it not to enclose the element in braces, but to
1015 * use backslash quoting instead.
1016 * TCL_DONT_QUOTE_HASH disables the default quoting of the '#' character. It
1017 * is safe to leave the hash unquoted when the element is not the first
1018 * element of a list, and this flag can be used by the caller to indicate
1019 * that condition.
1020 */
1021
1022 #define TCL_DONT_USE_BRACES 1
1023 #define TCL_DONT_QUOTE_HASH 8
1024
1025 /*
1026 * Flag that may be passed to Tcl_GetIndexFromObj to force it to disallow
1027 * abbreviated strings.
1028 */
1029
1030 #define TCL_EXACT 1
1031
1032 /*
1033 *----------------------------------------------------------------------------
1034 * Flag values passed to Tcl_RecordAndEval, Tcl_EvalObj, Tcl_EvalObjv.
1035 * WARNING: these bit choices must not conflict with the bit choices for
1036 * evalFlag bits in tclInt.h!
1037 *
1038 * Meanings:
1039 * TCL_NO_EVAL: Just record this command
1040 * TCL_EVAL_GLOBAL: Execute script in global namespace
1041 * TCL_EVAL_DIRECT: Do not compile this script
1042 * TCL_EVAL_INVOKE: Magical Tcl_EvalObjv mode for aliases/ensembles
1043 * o Run in iPtr->lookupNsPtr or global namespace
1044 * o Cut out of error traces
1045 * o Don't reset the flags controlling ensemble
1046 * error message rewriting.
1047 * TCL_CANCEL_UNWIND: Magical Tcl_CancelEval mode that causes the
1048 * stack for the script in progress to be
1049 * completely unwound.
1050 * TCL_EVAL_NOERR: Do no exception reporting at all, just return
1051 * as the caller will report.
1052 */
1053
1054 #define TCL_NO_EVAL 0x010000
1055 #define TCL_EVAL_GLOBAL 0x020000
1056 #define TCL_EVAL_DIRECT 0x040000
1057 #define TCL_EVAL_INVOKE 0x080000
1058 #define TCL_CANCEL_UNWIND 0x100000
1059 #define TCL_EVAL_NOERR 0x200000
1060
1061 /*
1062 * Special freeProc values that may be passed to Tcl_SetResult (see the man
1063 * page for details):
1064 */
1065
1066 #define TCL_VOLATILE ((Tcl_FreeProc *) 1)
1067 #define TCL_STATIC ((Tcl_FreeProc *) 0)
1068 #define TCL_DYNAMIC ((Tcl_FreeProc *) 3)
1069
1070 /*
1071 * Flag values passed to variable-related functions.
1072 * WARNING: these bit choices must not conflict with the bit choice for
1073 * TCL_CANCEL_UNWIND, above.
1074 */
1075
1076 #define TCL_GLOBAL_ONLY 1
1077 #define TCL_NAMESPACE_ONLY 2
1078 #define TCL_APPEND_VALUE 4
1079 #define TCL_LIST_ELEMENT 8
1080 #define TCL_TRACE_READS 0x10
1081 #define TCL_TRACE_WRITES 0x20
1082 #define TCL_TRACE_UNSETS 0x40
1083 #define TCL_TRACE_DESTROYED 0x80
1084 #define TCL_INTERP_DESTROYED 0x100
1085 #define TCL_LEAVE_ERR_MSG 0x200
1086 #define TCL_TRACE_ARRAY 0x800
1087 #ifndef TCL_REMOVE_OBSOLETE_TRACES
1088 /* Required to support old variable/vdelete/vinfo traces. */
1089 #define TCL_TRACE_OLD_STYLE 0x1000
1090 #endif
1091 /* Indicate the semantics of the result of a trace. */
1092 #define TCL_TRACE_RESULT_DYNAMIC 0x8000
1093 #define TCL_TRACE_RESULT_OBJECT 0x10000
1094
1095 /*
1096 * Flag values for ensemble commands.
1097 */
1098
1099 #define TCL_ENSEMBLE_PREFIX 0x02/* Flag value to say whether to allow
1100 * unambiguous prefixes of commands or to
1101 * require exact matches for command names. */
1102
1103 /*
1104 * Flag values passed to command-related functions.
1105 */
1106
1107 #define TCL_TRACE_RENAME 0x2000
1108 #define TCL_TRACE_DELETE 0x4000
1109
1110 #define TCL_ALLOW_INLINE_COMPILATION 0x20000
1111
1112 /*
1113 * The TCL_PARSE_PART1 flag is deprecated and has no effect. The part1 is now
1114 * always parsed whenever the part2 is NULL. (This is to avoid a common error
1115 * when converting code to use the new object based APIs and forgetting to
1116 * give the flag)
1117 */
1118
1119 #ifndef TCL_NO_DEPRECATED
1120 # define TCL_PARSE_PART1 0x400
1121 #endif
1122
1123 /*
1124 * Types for linked variables:
1125 */
1126
1127 #define TCL_LINK_INT 1
1128 #define TCL_LINK_DOUBLE 2
1129 #define TCL_LINK_BOOLEAN 3
1130 #define TCL_LINK_STRING 4
1131 #define TCL_LINK_WIDE_INT 5
1132 #define TCL_LINK_CHAR 6
1133 #define TCL_LINK_UCHAR 7
1134 #define TCL_LINK_SHORT 8
1135 #define TCL_LINK_USHORT 9
1136 #define TCL_LINK_UINT 10
1137 #define TCL_LINK_LONG 11
1138 #define TCL_LINK_ULONG 12
1139 #define TCL_LINK_FLOAT 13
1140 #define TCL_LINK_WIDE_UINT 14
1141 #define TCL_LINK_READ_ONLY 0x80
1142
1143
1144 /*
1145 *----------------------------------------------------------------------------
1146 * Forward declarations of Tcl_HashTable and related types.
1147 */
1148
1149 typedef struct Tcl_HashKeyType Tcl_HashKeyType;
1150 typedef struct Tcl_HashTable Tcl_HashTable;
1151 typedef struct Tcl_HashEntry Tcl_HashEntry;
1152
1153 typedef unsigned (Tcl_HashKeyProc) (Tcl_HashTable *tablePtr, void *keyPtr);
1154 typedef int (Tcl_CompareHashKeysProc) (void *keyPtr, Tcl_HashEntry *hPtr);
1155 typedef Tcl_HashEntry * (Tcl_AllocHashEntryProc) (Tcl_HashTable *tablePtr,
1156 void *keyPtr);
1157 typedef void (Tcl_FreeHashEntryProc) (Tcl_HashEntry *hPtr);
1158
1159 /*
1160 * This flag controls whether the hash table stores the hash of a key, or
1161 * recalculates it. There should be no reason for turning this flag off as it
1162 * is completely binary and source compatible unless you directly access the
1163 * bucketPtr member of the Tcl_HashTableEntry structure. This member has been
1164 * removed and the space used to store the hash value.
1165 */
1166
1167 #ifndef TCL_HASH_KEY_STORE_HASH
1168 # define TCL_HASH_KEY_STORE_HASH 1
1169 #endif
1170
1171 /*
1172 * Structure definition for an entry in a hash table. No-one outside Tcl
1173 * should access any of these fields directly; use the macros defined below.
1174 */
1175
1176 struct Tcl_HashEntry {
1177 Tcl_HashEntry *nextPtr; /* Pointer to next entry in this hash bucket,
1178 * or NULL for end of chain. */
1179 Tcl_HashTable *tablePtr; /* Pointer to table containing entry. */
1180 #if TCL_HASH_KEY_STORE_HASH
1181 void *hash; /* Hash value, stored as pointer to ensure
1182 * that the offsets of the fields in this
1183 * structure are not changed. */
1184 #else
1185 Tcl_HashEntry **bucketPtr; /* Pointer to bucket that points to first
1186 * entry in this entry's chain: used for
1187 * deleting the entry. */
1188 #endif
1189 ClientData clientData; /* Application stores something here with
1190 * Tcl_SetHashValue. */
1191 union { /* Key has one of these forms: */
1192 char *oneWordValue; /* One-word value for key. */
1193 Tcl_Obj *objPtr; /* Tcl_Obj * key value. */
1194 int words[1]; /* Multiple integer words for key. The actual
1195 * size will be as large as necessary for this
1196 * table's keys. */
1197 char string[1]; /* String for key. The actual size will be as
1198 * large as needed to hold the key. */
1199 } key; /* MUST BE LAST FIELD IN RECORD!! */
1200 };
1201
1202 /*
1203 * Flags used in Tcl_HashKeyType.
1204 *
1205 * TCL_HASH_KEY_RANDOMIZE_HASH -
1206 * There are some things, pointers for example
1207 * which don't hash well because they do not use
1208 * the lower bits. If this flag is set then the
1209 * hash table will attempt to rectify this by
1210 * randomising the bits and then using the upper
1211 * N bits as the index into the table.
1212 * TCL_HASH_KEY_SYSTEM_HASH - If this flag is set then all memory internally
1213 * allocated for the hash table that is not for an
1214 * entry will use the system heap.
1215 */
1216
1217 #define TCL_HASH_KEY_RANDOMIZE_HASH 0x1
1218 #define TCL_HASH_KEY_SYSTEM_HASH 0x2
1219
1220 /*
1221 * Structure definition for the methods associated with a hash table key type.
1222 */
1223
1224 #define TCL_HASH_KEY_TYPE_VERSION 1
1225 struct Tcl_HashKeyType {
1226 int version; /* Version of the table. If this structure is
1227 * extended in future then the version can be
1228 * used to distinguish between different
1229 * structures. */
1230 int flags; /* Flags, see above for details. */
1231 Tcl_HashKeyProc *hashKeyProc;
1232 /* Calculates a hash value for the key. If
1233 * this is NULL then the pointer itself is
1234 * used as a hash value. */
1235 Tcl_CompareHashKeysProc *compareKeysProc;
1236 /* Compares two keys and returns zero if they
1237 * do not match, and non-zero if they do. If
1238 * this is NULL then the pointers are
1239 * compared. */
1240 Tcl_AllocHashEntryProc *allocEntryProc;
1241 /* Called to allocate memory for a new entry,
1242 * i.e. if the key is a string then this could
1243 * allocate a single block which contains
1244 * enough space for both the entry and the
1245 * string. Only the key field of the allocated
1246 * Tcl_HashEntry structure needs to be filled
1247 * in. If something else needs to be done to
1248 * the key, i.e. incrementing a reference
1249 * count then that should be done by this
1250 * function. If this is NULL then Tcl_Alloc is
1251 * used to allocate enough space for a
1252 * Tcl_HashEntry and the key pointer is
1253 * assigned to key.oneWordValue. */
1254 Tcl_FreeHashEntryProc *freeEntryProc;
1255 /* Called to free memory associated with an
1256 * entry. If something else needs to be done
1257 * to the key, i.e. decrementing a reference
1258 * count then that should be done by this
1259 * function. If this is NULL then Tcl_Free is
1260 * used to free the Tcl_HashEntry. */
1261 };
1262
1263 /*
1264 * Structure definition for a hash table. Must be in tcl.h so clients can
1265 * allocate space for these structures, but clients should never access any
1266 * fields in this structure.
1267 */
1268
1269 #define TCL_SMALL_HASH_TABLE 4
1270 struct Tcl_HashTable {
1271 Tcl_HashEntry **buckets; /* Pointer to bucket array. Each element
1272 * points to first entry in bucket's hash
1273 * chain, or NULL. */
1274 Tcl_HashEntry *staticBuckets[TCL_SMALL_HASH_TABLE];
1275 /* Bucket array used for small tables (to
1276 * avoid mallocs and frees). */
1277 int numBuckets; /* Total number of buckets allocated at
1278 * **bucketPtr. */
1279 int numEntries; /* Total number of entries present in
1280 * table. */
1281 int rebuildSize; /* Enlarge table when numEntries gets to be
1282 * this large. */
1283 int downShift; /* Shift count used in hashing function.
1284 * Designed to use high-order bits of
1285 * randomized keys. */
1286 int mask; /* Mask value used in hashing function. */
1287 int keyType; /* Type of keys used in this table. It's
1288 * either TCL_CUSTOM_KEYS, TCL_STRING_KEYS,
1289 * TCL_ONE_WORD_KEYS, or an integer giving the
1290 * number of ints that is the size of the
1291 * key. */
1292 Tcl_HashEntry *(*findProc) (Tcl_HashTable *tablePtr, const char *key);
1293 Tcl_HashEntry *(*createProc) (Tcl_HashTable *tablePtr, const char *key,
1294 int *newPtr);
1295 const Tcl_HashKeyType *typePtr;
1296 /* Type of the keys used in the
1297 * Tcl_HashTable. */
1298 };
1299
1300 /*
1301 * Structure definition for information used to keep track of searches through
1302 * hash tables:
1303 */
1304
1305 typedef struct Tcl_HashSearch {
1306 Tcl_HashTable *tablePtr; /* Table being searched. */
1307 int nextIndex; /* Index of next bucket to be enumerated after
1308 * present one. */
1309 Tcl_HashEntry *nextEntryPtr;/* Next entry to be enumerated in the current
1310 * bucket. */
1311 } Tcl_HashSearch;
1312
1313 /*
1314 * Acceptable key types for hash tables:
1315 *
1316 * TCL_STRING_KEYS: The keys are strings, they are copied into the
1317 * entry.
1318 * TCL_ONE_WORD_KEYS: The keys are pointers, the pointer is stored
1319 * in the entry.
1320 * TCL_CUSTOM_TYPE_KEYS: The keys are arbitrary types which are copied
1321 * into the entry.
1322 * TCL_CUSTOM_PTR_KEYS: The keys are pointers to arbitrary types, the
1323 * pointer is stored in the entry.
1324 *
1325 * While maintaining binary compatability the above have to be distinct values
1326 * as they are used to differentiate between old versions of the hash table
1327 * which don't have a typePtr and new ones which do. Once binary compatability
1328 * is discarded in favour of making more wide spread changes TCL_STRING_KEYS
1329 * can be the same as TCL_CUSTOM_TYPE_KEYS, and TCL_ONE_WORD_KEYS can be the
1330 * same as TCL_CUSTOM_PTR_KEYS because they simply determine how the key is
1331 * accessed from the entry and not the behaviour.
1332 */
1333
1334 #define TCL_STRING_KEYS (0)
1335 #define TCL_ONE_WORD_KEYS (1)
1336 #define TCL_CUSTOM_TYPE_KEYS (-2)
1337 #define TCL_CUSTOM_PTR_KEYS (-1)
1338
1339 /*
1340 * Structure definition for information used to keep track of searches through
1341 * dictionaries. These fields should not be accessed by code outside
1342 * tclDictObj.c
1343 */
1344
1345 typedef struct {
1346 void *next; /* Search position for underlying hash
1347 * table. */
1348 int epoch; /* Epoch marker for dictionary being searched,
1349 * or -1 if search has terminated. */
1350 Tcl_Dict dictionaryPtr; /* Reference to dictionary being searched. */
1351 } Tcl_DictSearch;
1352
1353
1354 /*
1355 *----------------------------------------------------------------------------
1356 * Flag values to pass to Tcl_DoOneEvent to disable searches for some kinds of
1357 * events:
1358 */
1359
1360 #define TCL_DONT_WAIT (1<<1)
1361 #define TCL_WINDOW_EVENTS (1<<2)
1362 #define TCL_FILE_EVENTS (1<<3)
1363 #define TCL_TIMER_EVENTS (1<<4)
1364 #define TCL_IDLE_EVENTS (1<<5) /* WAS 0x10 ???? */
1365 #define TCL_ALL_EVENTS (~TCL_DONT_WAIT)
1366
1367 /*
1368 * The following structure defines a generic event for the Tcl event system.
1369 * These are the things that are queued in calls to Tcl_QueueEvent and
1370 * serviced later by Tcl_DoOneEvent. There can be many different kinds of
1371 * events with different fields, corresponding to window events, timer events,
1372 * etc. The structure for a particular event consists of a Tcl_Event header
1373 * followed by additional information specific to that event.
1374 */
1375
1376 struct Tcl_Event {
1377 Tcl_EventProc *proc; /* Function to call to service this event. */
1378 struct Tcl_Event *nextPtr; /* Next in list of pending events, or NULL. */
1379 };
1380
1381 /*
1382 * Positions to pass to Tcl_QueueEvent:
1383 */
1384
1385 typedef enum {
1386 TCL_QUEUE_TAIL, TCL_QUEUE_HEAD, TCL_QUEUE_MARK
1387 } Tcl_QueuePosition;
1388
1389 /*
1390 * Values to pass to Tcl_SetServiceMode to specify the behavior of notifier
1391 * event routines.
1392 */
1393
1394 #define TCL_SERVICE_NONE 0
1395 #define TCL_SERVICE_ALL 1
1396
1397 /*
1398 * The following structure keeps is used to hold a time value, either as an
1399 * absolute time (the number of seconds from the epoch) or as an elapsed time.
1400 * On Unix systems the epoch is Midnight Jan 1, 1970 GMT.
1401 */
1402
1403 typedef struct Tcl_Time {
1404 long sec; /* Seconds. */
1405 long usec; /* Microseconds. */
1406 } Tcl_Time;
1407
1408 typedef void (Tcl_SetTimerProc) (CONST86 Tcl_Time *timePtr);
1409 typedef int (Tcl_WaitForEventProc) (CONST86 Tcl_Time *timePtr);
1410
1411 /*
1412 * TIP #233 (Virtualized Time)
1413 */
1414
1415 typedef void (Tcl_GetTimeProc) (Tcl_Time *timebuf, ClientData clientData);
1416 typedef void (Tcl_ScaleTimeProc) (Tcl_Time *timebuf, ClientData clientData);
1417
1418 /*
1419 *----------------------------------------------------------------------------
1420 * Bits to pass to Tcl_CreateFileHandler and Tcl_CreateChannelHandler to
1421 * indicate what sorts of events are of interest:
1422 */
1423
1424 #define TCL_READABLE (1<<1)
1425 #define TCL_WRITABLE (1<<2)
1426 #define TCL_EXCEPTION (1<<3)
1427
1428 /*
1429 * Flag values to pass to Tcl_OpenCommandChannel to indicate the disposition
1430 * of the stdio handles. TCL_STDIN, TCL_STDOUT, TCL_STDERR, are also used in
1431 * Tcl_GetStdChannel.
1432 */
1433
1434 #define TCL_STDIN (1<<1)
1435 #define TCL_STDOUT (1<<2)
1436 #define TCL_STDERR (1<<3)
1437 #define TCL_ENFORCE_MODE (1<<4)
1438
1439 /*
1440 * Bits passed to Tcl_DriverClose2Proc to indicate which side of a channel
1441 * should be closed.
1442 */
1443
1444 #define TCL_CLOSE_READ (1<<1)
1445 #define TCL_CLOSE_WRITE (1<<2)
1446
1447 /*
1448 * Value to use as the closeProc for a channel that supports the close2Proc
1449 * interface.
1450 */
1451
1452 #define TCL_CLOSE2PROC ((Tcl_DriverCloseProc *) 1)
1453
1454 /*
1455 * Channel version tag. This was introduced in 8.3.2/8.4.
1456 */
1457
1458 #define TCL_CHANNEL_VERSION_1 ((Tcl_ChannelTypeVersion) 0x1)
1459 #define TCL_CHANNEL_VERSION_2 ((Tcl_ChannelTypeVersion) 0x2)
1460 #define TCL_CHANNEL_VERSION_3 ((Tcl_ChannelTypeVersion) 0x3)
1461 #define TCL_CHANNEL_VERSION_4 ((Tcl_ChannelTypeVersion) 0x4)
1462 #define TCL_CHANNEL_VERSION_5 ((Tcl_ChannelTypeVersion) 0x5)
1463
1464 /*
1465 * TIP #218: Channel Actions, Ids for Tcl_DriverThreadActionProc.
1466 */
1467
1468 #define TCL_CHANNEL_THREAD_INSERT (0)
1469 #define TCL_CHANNEL_THREAD_REMOVE (1)
1470
1471 /*
1472 * Typedefs for the various operations in a channel type:
1473 */
1474
1475 typedef int (Tcl_DriverBlockModeProc) (ClientData instanceData, int mode);
1476 typedef int (Tcl_DriverCloseProc) (ClientData instanceData,
1477 Tcl_Interp *interp);
1478 typedef int (Tcl_DriverClose2Proc) (ClientData instanceData,
1479 Tcl_Interp *interp, int flags);
1480 typedef int (Tcl_DriverInputProc) (ClientData instanceData, char *buf,
1481 int toRead, int *errorCodePtr);
1482 typedef int (Tcl_DriverOutputProc) (ClientData instanceData,
1483 CONST84 char *buf, int toWrite, int *errorCodePtr);
1484 typedef int (Tcl_DriverSeekProc) (ClientData instanceData, long offset,
1485 int mode, int *errorCodePtr);
1486 typedef int (Tcl_DriverSetOptionProc) (ClientData instanceData,
1487 Tcl_Interp *interp, const char *optionName,
1488 const char *value);
1489 typedef int (Tcl_DriverGetOptionProc) (ClientData instanceData,
1490 Tcl_Interp *interp, CONST84 char *optionName,
1491 Tcl_DString *dsPtr);
1492 typedef void (Tcl_DriverWatchProc) (ClientData instanceData, int mask);
1493 typedef int (Tcl_DriverGetHandleProc) (ClientData instanceData,
1494 int direction, ClientData *handlePtr);
1495 typedef int (Tcl_DriverFlushProc) (ClientData instanceData);
1496 typedef int (Tcl_DriverHandlerProc) (ClientData instanceData,
1497 int interestMask);
1498 typedef Tcl_WideInt (Tcl_DriverWideSeekProc) (ClientData instanceData,
1499 Tcl_WideInt offset, int mode, int *errorCodePtr);
1500 /*
1501 * TIP #218, Channel Thread Actions
1502 */
1503 typedef void (Tcl_DriverThreadActionProc) (ClientData instanceData,
1504 int action);
1505 /*
1506 * TIP #208, File Truncation (etc.)
1507 */
1508 typedef int (Tcl_DriverTruncateProc) (ClientData instanceData,
1509 Tcl_WideInt length);
1510
1511 /*
1512 * struct Tcl_ChannelType:
1513 *
1514 * One such structure exists for each type (kind) of channel. It collects
1515 * together in one place all the functions that are part of the specific
1516 * channel type.
1517 *
1518 * It is recommend that the Tcl_Channel* functions are used to access elements
1519 * of this structure, instead of direct accessing.
1520 */
1521
1522 typedef struct Tcl_ChannelType {
1523 const char *typeName; /* The name of the channel type in Tcl
1524 * commands. This storage is owned by channel
1525 * type. */
1526 Tcl_ChannelTypeVersion version;
1527 /* Version of the channel type. */
1528 Tcl_DriverCloseProc *closeProc;
1529 /* Function to call to close the channel, or
1530 * TCL_CLOSE2PROC if the close2Proc should be
1531 * used instead. */
1532 Tcl_DriverInputProc *inputProc;
1533 /* Function to call for input on channel. */
1534 Tcl_DriverOutputProc *outputProc;
1535 /* Function to call for output on channel. */
1536 Tcl_DriverSeekProc *seekProc;
1537 /* Function to call to seek on the channel.
1538 * May be NULL. */
1539 Tcl_DriverSetOptionProc *setOptionProc;
1540 /* Set an option on a channel. */
1541 Tcl_DriverGetOptionProc *getOptionProc;
1542 /* Get an option from a channel. */
1543 Tcl_DriverWatchProc *watchProc;
1544 /* Set up the notifier to watch for events on
1545 * this channel. */
1546 Tcl_DriverGetHandleProc *getHandleProc;
1547 /* Get an OS handle from the channel or NULL
1548 * if not supported. */
1549 Tcl_DriverClose2Proc *close2Proc;
1550 /* Function to call to close the channel if
1551 * the device supports closing the read &
1552 * write sides independently. */
1553 Tcl_DriverBlockModeProc *blockModeProc;
1554 /* Set blocking mode for the raw channel. May
1555 * be NULL. */
1556 /*
1557 * Only valid in TCL_CHANNEL_VERSION_2 channels or later.
1558 */
1559 Tcl_DriverFlushProc *flushProc;
1560 /* Function to call to flush a channel. May be
1561 * NULL. */
1562 Tcl_DriverHandlerProc *handlerProc;
1563 /* Function to call to handle a channel event.
1564 * This will be passed up the stacked channel
1565 * chain. */
1566 /*
1567 * Only valid in TCL_CHANNEL_VERSION_3 channels or later.
1568 */
1569 Tcl_DriverWideSeekProc *wideSeekProc;
1570 /* Function to call to seek on the channel
1571 * which can handle 64-bit offsets. May be
1572 * NULL, and must be NULL if seekProc is
1573 * NULL. */
1574 /*
1575 * Only valid in TCL_CHANNEL_VERSION_4 channels or later.
1576 * TIP #218, Channel Thread Actions.
1577 */
1578 Tcl_DriverThreadActionProc *threadActionProc;
1579 /* Function to call to notify the driver of
1580 * thread specific activity for a channel. May
1581 * be NULL. */
1582 /*
1583 * Only valid in TCL_CHANNEL_VERSION_5 channels or later.
1584 * TIP #208, File Truncation.
1585 */
1586 Tcl_DriverTruncateProc *truncateProc;
1587 /* Function to call to truncate the underlying
1588 * file to a particular length. May be NULL if
1589 * the channel does not support truncation. */
1590 } Tcl_ChannelType;
1591
1592 /*
1593 * The following flags determine whether the blockModeProc above should set
1594 * the channel into blocking or nonblocking mode. They are passed as arguments
1595 * to the blockModeProc function in the above structure.
1596 */
1597
1598 #define TCL_MODE_BLOCKING 0 /* Put channel into blocking mode. */
1599 #define TCL_MODE_NONBLOCKING 1 /* Put channel into nonblocking
1600 * mode. */
1601
1602 /*
1603 *----------------------------------------------------------------------------
1604 * Enum for different types of file paths.
1605 */
1606
1607 typedef enum Tcl_PathType {
1608 TCL_PATH_ABSOLUTE,
1609 TCL_PATH_RELATIVE,
1610 TCL_PATH_VOLUME_RELATIVE
1611 } Tcl_PathType;
1612
1613 /*
1614 * The following structure is used to pass glob type data amongst the various
1615 * glob routines and Tcl_FSMatchInDirectory.
1616 */
1617
1618 typedef struct Tcl_GlobTypeData {
1619 int type; /* Corresponds to bcdpfls as in 'find -t'. */
1620 int perm; /* Corresponds to file permissions. */
1621 Tcl_Obj *macType; /* Acceptable Mac type. */
1622 Tcl_Obj *macCreator; /* Acceptable Mac creator. */
1623 } Tcl_GlobTypeData;
1624
1625 /*
1626 * Type and permission definitions for glob command.
1627 */
1628
1629 #define TCL_GLOB_TYPE_BLOCK (1<<0)
1630 #define TCL_GLOB_TYPE_CHAR (1<<1)
1631 #define TCL_GLOB_TYPE_DIR (1<<2)
1632 #define TCL_GLOB_TYPE_PIPE (1<<3)
1633 #define TCL_GLOB_TYPE_FILE (1<<4)
1634 #define TCL_GLOB_TYPE_LINK (1<<5)
1635 #define TCL_GLOB_TYPE_SOCK (1<<6)
1636 #define TCL_GLOB_TYPE_MOUNT (1<<7)
1637
1638 #define TCL_GLOB_PERM_RONLY (1<<0)
1639 #define TCL_GLOB_PERM_HIDDEN (1<<1)
1640 #define TCL_GLOB_PERM_R (1<<2)
1641 #define TCL_GLOB_PERM_W (1<<3)
1642 #define TCL_GLOB_PERM_X (1<<4)
1643
1644 /*
1645 * Flags for the unload callback function.
1646 */
1647
1648 #define TCL_UNLOAD_DETACH_FROM_INTERPRETER (1<<0)
1649 #define TCL_UNLOAD_DETACH_FROM_PROCESS (1<<1)
1650
1651 /*
1652 * Typedefs for the various filesystem operations:
1653 */
1654
1655 typedef int (Tcl_FSStatProc) (Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1656 typedef int (Tcl_FSAccessProc) (Tcl_Obj *pathPtr, int mode);
1657 typedef Tcl_Channel (Tcl_FSOpenFileChannelProc) (Tcl_Interp *interp,
1658 Tcl_Obj *pathPtr, int mode, int permissions);
1659 typedef int (Tcl_FSMatchInDirectoryProc) (Tcl_Interp *interp, Tcl_Obj *result,
1660 Tcl_Obj *pathPtr, const char *pattern, Tcl_GlobTypeData *types);
1661 typedef Tcl_Obj * (Tcl_FSGetCwdProc) (Tcl_Interp *interp);
1662 typedef int (Tcl_FSChdirProc) (Tcl_Obj *pathPtr);
1663 typedef int (Tcl_FSLstatProc) (Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1664 typedef int (Tcl_FSCreateDirectoryProc) (Tcl_Obj *pathPtr);
1665 typedef int (Tcl_FSDeleteFileProc) (Tcl_Obj *pathPtr);
1666 typedef int (Tcl_FSCopyDirectoryProc) (Tcl_Obj *srcPathPtr,
1667 Tcl_Obj *destPathPtr, Tcl_Obj **errorPtr);
1668 typedef int (Tcl_FSCopyFileProc) (Tcl_Obj *srcPathPtr, Tcl_Obj *destPathPtr);
1669 typedef int (Tcl_FSRemoveDirectoryProc) (Tcl_Obj *pathPtr, int recursive,
1670 Tcl_Obj **errorPtr);
1671 typedef int (Tcl_FSRenameFileProc) (Tcl_Obj *srcPathPtr, Tcl_Obj *destPathPtr);
1672 typedef void (Tcl_FSUnloadFileProc) (Tcl_LoadHandle loadHandle);
1673 typedef Tcl_Obj * (Tcl_FSListVolumesProc) (void);
1674 /* We have to declare the utime structure here. */
1675 struct utimbuf;
1676 typedef int (Tcl_FSUtimeProc) (Tcl_Obj *pathPtr, struct utimbuf *tval);
1677 typedef int (Tcl_FSNormalizePathProc) (Tcl_Interp *interp, Tcl_Obj *pathPtr,
1678 int nextCheckpoint);
1679 typedef int (Tcl_FSFileAttrsGetProc) (Tcl_Interp *interp, int index,
1680 Tcl_Obj *pathPtr, Tcl_Obj **objPtrRef);
1681 typedef const char *CONST86 * (Tcl_FSFileAttrStringsProc) (Tcl_Obj *pathPtr,
1682 Tcl_Obj **objPtrRef);
1683 typedef int (Tcl_FSFileAttrsSetProc) (Tcl_Interp *interp, int index,
1684 Tcl_Obj *pathPtr, Tcl_Obj *objPtr);
1685 typedef Tcl_Obj * (Tcl_FSLinkProc) (Tcl_Obj *pathPtr, Tcl_Obj *toPtr,
1686 int linkType);
1687 typedef int (Tcl_FSLoadFileProc) (Tcl_Interp *interp, Tcl_Obj *pathPtr,
1688 Tcl_LoadHandle *handlePtr, Tcl_FSUnloadFileProc **unloadProcPtr);
1689 typedef int (Tcl_FSPathInFilesystemProc) (Tcl_Obj *pathPtr,
1690 ClientData *clientDataPtr);
1691 typedef Tcl_Obj * (Tcl_FSFilesystemPathTypeProc) (Tcl_Obj *pathPtr);
1692 typedef Tcl_Obj * (Tcl_FSFilesystemSeparatorProc) (Tcl_Obj *pathPtr);
1693 typedef void (Tcl_FSFreeInternalRepProc) (ClientData clientData);
1694 typedef ClientData (Tcl_FSDupInternalRepProc) (ClientData clientData);
1695 typedef Tcl_Obj * (Tcl_FSInternalToNormalizedProc) (ClientData clientData);
1696 typedef ClientData (Tcl_FSCreateInternalRepProc) (Tcl_Obj *pathPtr);
1697
1698 typedef struct Tcl_FSVersion_ *Tcl_FSVersion;
1699
1700 /*
1701 *----------------------------------------------------------------------------
1702 * Data structures related to hooking into the filesystem
1703 */
1704
1705 /*
1706 * Filesystem version tag. This was introduced in 8.4.
1707 */
1708
1709 #define TCL_FILESYSTEM_VERSION_1 ((Tcl_FSVersion) 0x1)
1710
1711 /*
1712 * struct Tcl_Filesystem:
1713 *
1714 * One such structure exists for each type (kind) of filesystem. It collects
1715 * together in one place all the functions that are part of the specific
1716 * filesystem. Tcl always accesses the filesystem through one of these
1717 * structures.
1718 *
1719 * Not all entries need be non-NULL; any which are NULL are simply ignored.
1720 * However, a complete filesystem should provide all of these functions. The
1721 * explanations in the structure show the importance of each function.
1722 */
1723
1724 typedef struct Tcl_Filesystem {
1725 const char *typeName; /* The name of the filesystem. */
1726 int structureLength; /* Length of this structure, so future binary
1727 * compatibility can be assured. */
1728 Tcl_FSVersion version; /* Version of the filesystem type. */
1729 Tcl_FSPathInFilesystemProc *pathInFilesystemProc;
1730 /* Function to check whether a path is in this
1731 * filesystem. This is the most important
1732 * filesystem function. */
1733 Tcl_FSDupInternalRepProc *dupInternalRepProc;
1734 /* Function to duplicate internal fs rep. May
1735 * be NULL (but then fs is less efficient). */
1736 Tcl_FSFreeInternalRepProc *freeInternalRepProc;
1737 /* Function to free internal fs rep. Must be
1738 * implemented if internal representations
1739 * need freeing, otherwise it can be NULL. */
1740 Tcl_FSInternalToNormalizedProc *internalToNormalizedProc;
1741 /* Function to convert internal representation
1742 * to a normalized path. Only required if the
1743 * fs creates pure path objects with no
1744 * string/path representation. */
1745 Tcl_FSCreateInternalRepProc *createInternalRepProc;
1746 /* Function to create a filesystem-specific
1747 * internal representation. May be NULL if
1748 * paths have no internal representation, or
1749 * if the Tcl_FSPathInFilesystemProc for this
1750 * filesystem always immediately creates an
1751 * internal representation for paths it
1752 * accepts. */
1753 Tcl_FSNormalizePathProc *normalizePathProc;
1754 /* Function to normalize a path. Should be
1755 * implemented for all filesystems which can
1756 * have multiple string representations for
1757 * the same path object. */
1758 Tcl_FSFilesystemPathTypeProc *filesystemPathTypeProc;
1759 /* Function to determine the type of a path in
1760 * this filesystem. May be NULL. */
1761 Tcl_FSFilesystemSeparatorProc *filesystemSeparatorProc;
1762 /* Function to return the separator
1763 * character(s) for this filesystem. Must be
1764 * implemented. */
1765 Tcl_FSStatProc *statProc; /* Function to process a 'Tcl_FSStat()' call.
1766 * Must be implemented for any reasonable
1767 * filesystem. */
1768 Tcl_FSAccessProc *accessProc;
1769 /* Function to process a 'Tcl_FSAccess()'
1770 * call. Must be implemented for any
1771 * reasonable filesystem. */
1772 Tcl_FSOpenFileChannelProc *openFileChannelProc;
1773 /* Function to process a
1774 * 'Tcl_FSOpenFileChannel()' call. Must be
1775 * implemented for any reasonable
1776 * filesystem. */
1777 Tcl_FSMatchInDirectoryProc *matchInDirectoryProc;
1778 /* Function to process a
1779 * 'Tcl_FSMatchInDirectory()'. If not
1780 * implemented, then glob and recursive copy
1781 * functionality will be lacking in the
1782 * filesystem. */
1783 Tcl_FSUtimeProc *utimeProc; /* Function to process a 'Tcl_FSUtime()' call.
1784 * Required to allow setting (not reading) of
1785 * times with 'file mtime', 'file atime' and
1786 * the open-r/open-w/fcopy implementation of
1787 * 'file copy'. */
1788 Tcl_FSLinkProc *linkProc; /* Function to process a 'Tcl_FSLink()' call.
1789 * Should be implemented only if the
1790 * filesystem supports links (reading or
1791 * creating). */
1792 Tcl_FSListVolumesProc *listVolumesProc;
1793 /* Function to list any filesystem volumes
1794 * added by this filesystem. Should be
1795 * implemented only if the filesystem adds
1796 * volumes at the head of the filesystem. */
1797 Tcl_FSFileAttrStringsProc *fileAttrStringsProc;
1798 /* Function to list all attributes strings
1799 * which are valid for this filesystem. If not
1800 * implemented the filesystem will not support
1801 * the 'file attributes' command. This allows
1802 * arbitrary additional information to be
1803 * attached to files in the filesystem. */
1804 Tcl_FSFileAttrsGetProc *fileAttrsGetProc;
1805 /* Function to process a
1806 * 'Tcl_FSFileAttrsGet()' call, used by 'file
1807 * attributes'. */
1808 Tcl_FSFileAttrsSetProc *fileAttrsSetProc;
1809 /* Function to process a
1810 * 'Tcl_FSFileAttrsSet()' call, used by 'file
1811 * attributes'. */
1812 Tcl_FSCreateDirectoryProc *createDirectoryProc;
1813 /* Function to process a
1814 * 'Tcl_FSCreateDirectory()' call. Should be
1815 * implemented unless the FS is read-only. */
1816 Tcl_FSRemoveDirectoryProc *removeDirectoryProc;
1817 /* Function to process a
1818 * 'Tcl_FSRemoveDirectory()' call. Should be
1819 * implemented unless the FS is read-only. */
1820 Tcl_FSDeleteFileProc *deleteFileProc;
1821 /* Function to process a 'Tcl_FSDeleteFile()'
1822 * call. Should be implemented unless the FS
1823 * is read-only. */
1824 Tcl_FSCopyFileProc *copyFileProc;
1825 /* Function to process a 'Tcl_FSCopyFile()'
1826 * call. If not implemented Tcl will fall back
1827 * on open-r, open-w and fcopy as a copying
1828 * mechanism, for copying actions initiated in
1829 * Tcl (not C). */
1830 Tcl_FSRenameFileProc *renameFileProc;
1831 /* Function to process a 'Tcl_FSRenameFile()'
1832 * call. If not implemented, Tcl will fall
1833 * back on a copy and delete mechanism, for
1834 * rename actions initiated in Tcl (not C). */
1835 Tcl_FSCopyDirectoryProc *copyDirectoryProc;
1836 /* Function to process a
1837 * 'Tcl_FSCopyDirectory()' call. If not
1838 * implemented, Tcl will fall back on a
1839 * recursive create-dir, file copy mechanism,
1840 * for copying actions initiated in Tcl (not
1841 * C). */
1842 Tcl_FSLstatProc *lstatProc; /* Function to process a 'Tcl_FSLstat()' call.
1843 * If not implemented, Tcl will attempt to use
1844 * the 'statProc' defined above instead. */
1845 Tcl_FSLoadFileProc *loadFileProc;
1846 /* Function to process a 'Tcl_FSLoadFile()'
1847 * call. If not implemented, Tcl will fall
1848 * back on a copy to native-temp followed by a
1849 * Tcl_FSLoadFile on that temporary copy. */
1850 Tcl_FSGetCwdProc *getCwdProc;
1851 /* Function to process a 'Tcl_FSGetCwd()'
1852 * call. Most filesystems need not implement
1853 * this. It will usually only be called once,
1854 * if 'getcwd' is called before 'chdir'. May
1855 * be NULL. */
1856 Tcl_FSChdirProc *chdirProc; /* Function to process a 'Tcl_FSChdir()' call.
1857 * If filesystems do not implement this, it
1858 * will be emulated by a series of directory
1859 * access checks. Otherwise, virtual
1860 * filesystems which do implement it need only
1861 * respond with a positive return result if
1862 * the dirName is a valid directory in their
1863 * filesystem. They need not remember the
1864 * result, since that will be automatically
1865 * remembered for use by GetCwd. Real
1866 * filesystems should carry out the correct
1867 * action (i.e. call the correct system
1868 * 'chdir' api). If not implemented, then 'cd'
1869 * and 'pwd' will fail inside the
1870 * filesystem. */
1871 } Tcl_Filesystem;
1872
1873 /*
1874 * The following definitions are used as values for the 'linkAction' flag to
1875 * Tcl_FSLink, or the linkProc of any filesystem. Any combination of flags can
1876 * be given. For link creation, the linkProc should create a link which
1877 * matches any of the types given.
1878 *
1879 * TCL_CREATE_SYMBOLIC_LINK - Create a symbolic or soft link.
1880 * TCL_CREATE_HARD_LINK - Create a hard link.
1881 */
1882
1883 #define TCL_CREATE_SYMBOLIC_LINK 0x01
1884 #define TCL_CREATE_HARD_LINK 0x02
1885
1886 /*
1887 *----------------------------------------------------------------------------
1888 * The following structure represents the Notifier functions that you can
1889 * override with the Tcl_SetNotifier call.
1890 */
1891
1892 typedef struct Tcl_NotifierProcs {
1893 Tcl_SetTimerProc *setTimerProc;
1894 Tcl_WaitForEventProc *waitForEventProc;
1895 Tcl_CreateFileHandlerProc *createFileHandlerProc;
1896 Tcl_DeleteFileHandlerProc *deleteFileHandlerProc;
1897 Tcl_InitNotifierProc *initNotifierProc;
1898 Tcl_FinalizeNotifierProc *finalizeNotifierProc;
1899 Tcl_AlertNotifierProc *alertNotifierProc;
1900 Tcl_ServiceModeHookProc *serviceModeHookProc;
1901 } Tcl_NotifierProcs;
1902
1903
1904 /*
1905 *----------------------------------------------------------------------------
1906 * The following data structures and declarations are for the new Tcl parser.
1907 *
1908 * For each word of a command, and for each piece of a word such as a variable
1909 * reference, one of the following structures is created to describe the
1910 * token.
1911 */
1912
1913 typedef struct Tcl_Token {
1914 int type; /* Type of token, such as TCL_TOKEN_WORD; see
1915 * below for valid types. */
1916 const char *start; /* First character in token. */
1917 int size; /* Number of bytes in token. */
1918 int numComponents; /* If this token is composed of other tokens,
1919 * this field tells how many of them there are
1920 * (including components of components, etc.).
1921 * The component tokens immediately follow
1922 * this one. */
1923 } Tcl_Token;
1924
1925 /*
1926 * Type values defined for Tcl_Token structures. These values are defined as
1927 * mask bits so that it's easy to check for collections of types.
1928 *
1929 * TCL_TOKEN_WORD - The token describes one word of a command,
1930 * from the first non-blank character of the word
1931 * (which may be " or {) up to but not including
1932 * the space, semicolon, or bracket that
1933 * terminates the word. NumComponents counts the
1934 * total number of sub-tokens that make up the
1935 * word. This includes, for example, sub-tokens
1936 * of TCL_TOKEN_VARIABLE tokens.
1937 * TCL_TOKEN_SIMPLE_WORD - This token is just like TCL_TOKEN_WORD except
1938 * that the word is guaranteed to consist of a
1939 * single TCL_TOKEN_TEXT sub-token.
1940 * TCL_TOKEN_TEXT - The token describes a range of literal text
1941 * that is part of a word. NumComponents is
1942 * always 0.
1943 * TCL_TOKEN_BS - The token describes a backslash sequence that
1944 * must be collapsed. NumComponents is always 0.
1945 * TCL_TOKEN_COMMAND - The token describes a command whose result
1946 * must be substituted into the word. The token
1947 * includes the enclosing brackets. NumComponents
1948 * is always 0.
1949 * TCL_TOKEN_VARIABLE - The token describes a variable substitution,
1950 * including the dollar sign, variable name, and
1951 * array index (if there is one) up through the
1952 * right parentheses. NumComponents tells how
1953 * many additional tokens follow to represent the
1954 * variable name. The first token will be a
1955 * TCL_TOKEN_TEXT token that describes the
1956 * variable name. If the variable is an array
1957 * reference then there will be one or more
1958 * additional tokens, of type TCL_TOKEN_TEXT,
1959 * TCL_TOKEN_BS, TCL_TOKEN_COMMAND, and
1960 * TCL_TOKEN_VARIABLE, that describe the array
1961 * index; numComponents counts the total number
1962 * of nested tokens that make up the variable
1963 * reference, including sub-tokens of
1964 * TCL_TOKEN_VARIABLE tokens.
1965 * TCL_TOKEN_SUB_EXPR - The token describes one subexpression of an
1966 * expression, from the first non-blank character
1967 * of the subexpression up to but not including
1968 * the space, brace, or bracket that terminates
1969 * the subexpression. NumComponents counts the
1970 * total number of following subtokens that make
1971 * up the subexpression; this includes all
1972 * subtokens for any nested TCL_TOKEN_SUB_EXPR
1973 * tokens. For example, a numeric value used as a
1974 * primitive operand is described by a
1975 * TCL_TOKEN_SUB_EXPR token followed by a
1976 * TCL_TOKEN_TEXT token. A binary subexpression
1977 * is described by a TCL_TOKEN_SUB_EXPR token
1978 * followed by the TCL_TOKEN_OPERATOR token for
1979 * the operator, then TCL_TOKEN_SUB_EXPR tokens
1980 * for the left then the right operands.
1981 * TCL_TOKEN_OPERATOR - The token describes one expression operator.
1982 * An operator might be the name of a math
1983 * function such as "abs". A TCL_TOKEN_OPERATOR
1984 * token is always preceeded by one
1985 * TCL_TOKEN_SUB_EXPR token for the operator's
1986 * subexpression, and is followed by zero or more
1987 * TCL_TOKEN_SUB_EXPR tokens for the operator's
1988 * operands. NumComponents is always 0.
1989 * TCL_TOKEN_EXPAND_WORD - This token is just like TCL_TOKEN_WORD except
1990 * that it marks a word that began with the
1991 * literal character prefix "{*}". This word is
1992 * marked to be expanded - that is, broken into
1993 * words after substitution is complete.
1994 */
1995
1996 #define TCL_TOKEN_WORD 1
1997 #define TCL_TOKEN_SIMPLE_WORD 2
1998 #define TCL_TOKEN_TEXT 4
1999 #define TCL_TOKEN_BS 8
2000 #define TCL_TOKEN_COMMAND 16
2001 #define TCL_TOKEN_VARIABLE 32
2002 #define TCL_TOKEN_SUB_EXPR 64
2003 #define TCL_TOKEN_OPERATOR 128
2004 #define TCL_TOKEN_EXPAND_WORD 256
2005
2006 /*
2007 * Parsing error types. On any parsing error, one of these values will be
2008 * stored in the error field of the Tcl_Parse structure defined below.
2009 */
2010
2011 #define TCL_PARSE_SUCCESS 0
2012 #define TCL_PARSE_QUOTE_EXTRA 1
2013 #define TCL_PARSE_BRACE_EXTRA 2
2014 #define TCL_PARSE_MISSING_BRACE 3
2015 #define TCL_PARSE_MISSING_BRACKET 4
2016 #define TCL_PARSE_MISSING_PAREN 5
2017 #define TCL_PARSE_MISSING_QUOTE 6
2018 #define TCL_PARSE_MISSING_VAR_BRACE 7
2019 #define TCL_PARSE_SYNTAX 8
2020 #define TCL_PARSE_BAD_NUMBER 9
2021
2022 /*
2023 * A structure of the following type is filled in by Tcl_ParseCommand. It
2024 * describes a single command parsed from an input string.
2025 */
2026
2027 #define NUM_STATIC_TOKENS 20
2028
2029 typedef struct Tcl_Parse {
2030 const char *commentStart; /* Pointer to # that begins the first of one
2031 * or more comments preceding the command. */
2032 int commentSize; /* Number of bytes in comments (up through
2033 * newline character that terminates the last
2034 * comment). If there were no comments, this
2035 * field is 0. */
2036 const char *commandStart; /* First character in first word of
2037 * command. */
2038 int commandSize; /* Number of bytes in command, including first
2039 * character of first word, up through the
2040 * terminating newline, close bracket, or
2041 * semicolon. */
2042 int numWords; /* Total number of words in command. May be
2043 * 0. */
2044 Tcl_Token *tokenPtr; /* Pointer to first token representing the
2045 * words of the command. Initially points to
2046 * staticTokens, but may change to point to
2047 * malloc-ed space if command exceeds space in
2048 * staticTokens. */
2049 int numTokens; /* Total number of tokens in command. */
2050 int tokensAvailable; /* Total number of tokens available at
2051 * *tokenPtr. */
2052 int errorType; /* One of the parsing error types defined
2053 * above. */
2054
2055 /*
2056 * The fields below are intended only for the private use of the parser.
2057 * They should not be used by functions that invoke Tcl_ParseCommand.
2058 */
2059
2060 const char *string; /* The original command string passed to
2061 * Tcl_ParseCommand. */
2062 const char *end; /* Points to the character just after the last
2063 * one in the command string. */
2064 Tcl_Interp *interp; /* Interpreter to use for error reporting, or
2065 * NULL. */
2066 const char *term; /* Points to character in string that
2067 * terminated most recent token. Filled in by
2068 * ParseTokens. If an error occurs, points to
2069 * beginning of region where the error
2070 * occurred (e.g. the open brace if the close
2071 * brace is missing). */
2072 int incomplete; /* This field is set to 1 by Tcl_ParseCommand
2073 * if the command appears to be incomplete.
2074 * This information is used by
2075 * Tcl_CommandComplete. */
2076 Tcl_Token staticTokens[NUM_STATIC_TOKENS];
2077 /* Initial space for tokens for command. This
2078 * space should be large enough to accommodate
2079 * most commands; dynamic space is allocated
2080 * for very large commands that don't fit
2081 * here. */
2082 } Tcl_Parse;
2083
2084
2085 /*
2086 *----------------------------------------------------------------------------
2087 * The following structure represents a user-defined encoding. It collects
2088 * together all the functions that are used by the specific encoding.
2089 */
2090
2091 typedef struct Tcl_EncodingType {
2092 const char *encodingName; /* The name of the encoding, e.g. "euc-jp".
2093 * This name is the unique key for this
2094 * encoding type. */
2095 Tcl_EncodingConvertProc *toUtfProc;
2096 /* Function to convert from external encoding
2097 * into UTF-8. */
2098 Tcl_EncodingConvertProc *fromUtfProc;
2099 /* Function to convert from UTF-8 into
2100 * external encoding. */
2101 Tcl_EncodingFreeProc *freeProc;
2102 /* If non-NULL, function to call when this
2103 * encoding is deleted. */
2104 ClientData clientData; /* Arbitrary value associated with encoding
2105 * type. Passed to conversion functions. */
2106 int nullSize; /* Number of zero bytes that signify
2107 * end-of-string in this encoding. This number
2108 * is used to determine the source string
2109 * length when the srcLen argument is
2110 * negative. Must be 1 or 2. */
2111 } Tcl_EncodingType;
2112
2113 /*
2114 * The following definitions are used as values for the conversion control
2115 * flags argument when converting text from one character set to another:
2116 *
2117 * TCL_ENCODING_START - Signifies that the source buffer is the first
2118 * block in a (potentially multi-block) input
2119 * stream. Tells the conversion function to reset
2120 * to an initial state and perform any
2121 * initialization that needs to occur before the
2122 * first byte is converted. If the source buffer
2123 * contains the entire input stream to be
2124 * converted, this flag should be set.
2125 * TCL_ENCODING_END - Signifies that the source buffer is the last
2126 * block in a (potentially multi-block) input
2127 * stream. Tells the conversion routine to
2128 * perform any finalization that needs to occur
2129 * after the last byte is converted and then to
2130 * reset to an initial state. If the source
2131 * buffer contains the entire input stream to be
2132 * converted, this flag should be set.
2133 * TCL_ENCODING_STOPONERROR - If set, then the converter will return
2134 * immediately upon encountering an invalid byte
2135 * sequence or a source character that has no
2136 * mapping in the target encoding. If clear, then
2137 * the converter will skip the problem,
2138 * substituting one or more "close" characters in
2139 * the destination buffer and then continue to
2140 * convert the source.
2141 */
2142
2143 #define TCL_ENCODING_START 0x01
2144 #define TCL_ENCODING_END 0x02
2145 #define TCL_ENCODING_STOPONERROR 0x04
2146
2147 /*
2148 * The following definitions are the error codes returned by the conversion
2149 * routines:
2150 *
2151 * TCL_OK - All characters were converted.
2152 * TCL_CONVERT_NOSPACE - The output buffer would not have been large
2153 * enough for all of the converted data; as many
2154 * characters as could fit were converted though.
2155 * TCL_CONVERT_MULTIBYTE - The last few bytes in the source string were
2156 * the beginning of a multibyte sequence, but
2157 * more bytes were needed to complete this
2158 * sequence. A subsequent call to the conversion
2159 * routine should pass the beginning of this
2160 * unconverted sequence plus additional bytes
2161 * from the source stream to properly convert the
2162 * formerly split-up multibyte sequence.
2163 * TCL_CONVERT_SYNTAX - The source stream contained an invalid
2164 * character sequence. This may occur if the
2165 * input stream has been damaged or if the input
2166 * encoding method was misidentified. This error
2167 * is reported only if TCL_ENCODING_STOPONERROR
2168 * was specified.
2169 * TCL_CONVERT_UNKNOWN - The source string contained a character that
2170 * could not be represented in the target
2171 * encoding. This error is reported only if
2172 * TCL_ENCODING_STOPONERROR was specified.
2173 */
2174
2175 #define TCL_CONVERT_MULTIBYTE (-1)
2176 #define TCL_CONVERT_SYNTAX (-2)
2177 #define TCL_CONVERT_UNKNOWN (-3)
2178 #define TCL_CONVERT_NOSPACE (-4)
2179
2180 /*
2181 * The maximum number of bytes that are necessary to represent a single
2182 * Unicode character in UTF-8. The valid values should be 3, 4 or 6
2183 * (or perhaps 1 if we want to support a non-unicode enabled core). If 3 or
2184 * 4, then Tcl_UniChar must be 2-bytes in size (UCS-2) (the default). If 6,
2185 * then Tcl_UniChar must be 4-bytes in size (UCS-4). At this time UCS-2 mode
2186 * is the default and recommended mode. UCS-4 is experimental and not
2187 * recommended. It works for the core, but most extensions expect UCS-2.
2188 */
2189
2190 #ifndef TCL_UTF_MAX
2191 #define TCL_UTF_MAX 3
2192 #endif
2193
2194 /*
2195 * This represents a Unicode character. Any changes to this should also be
2196 * reflected in regcustom.h.
2197 */
2198
2199 #if TCL_UTF_MAX > 4
2200 /*
2201 * unsigned int isn't 100% accurate as it should be a strict 4-byte value
2202 * (perhaps wchar_t). 64-bit systems may have troubles. The size of this
2203 * value must be reflected correctly in regcustom.h and
2204 * in tclEncoding.c.
2205 * XXX: Tcl is currently UCS-2 and planning UTF-16 for the Unicode
2206 * XXX: string rep that Tcl_UniChar represents. Changing the size
2207 * XXX: of Tcl_UniChar is /not/ supported.
2208 */
2209 typedef unsigned int Tcl_UniChar;
2210 #else
2211 typedef unsigned short Tcl_UniChar;
2212 #endif
2213
2214
2215 /*
2216 *----------------------------------------------------------------------------
2217 * TIP #59: The following structure is used in calls 'Tcl_RegisterConfig' to
2218 * provide the system with the embedded configuration data.
2219 */
2220
2221 typedef struct Tcl_Config {
2222 const char *key; /* Configuration key to register. ASCII
2223 * encoded, thus UTF-8. */
2224 const char *value; /* The value associated with the key. System
2225 * encoding. */
2226 } Tcl_Config;
2227
2228 /*
2229 *----------------------------------------------------------------------------
2230 * Flags for TIP#143 limits, detailing which limits are active in an
2231 * interpreter. Used for Tcl_{Add,Remove}LimitHandler type argument.
2232 */
2233
2234 #define TCL_LIMIT_COMMANDS 0x01
2235 #define TCL_LIMIT_TIME 0x02
2236
2237 /*
2238 * Structure containing information about a limit handler to be called when a
2239 * command- or time-limit is exceeded by an interpreter.
2240 */
2241
2242 typedef void (Tcl_LimitHandlerProc) (ClientData clientData, Tcl_Interp *interp);
2243 typedef void (Tcl_LimitHandlerDeleteProc) (ClientData clientData);
2244
2245 /*
2246 *----------------------------------------------------------------------------
2247 * Override definitions for libtommath.
2248 */
2249
2250 typedef struct mp_int mp_int;
2251 #define MP_INT_DECLARED
2252 typedef unsigned int mp_digit;
2253 #define MP_DIGIT_DECLARED
2254
2255 /*
2256 *----------------------------------------------------------------------------
2257 * Definitions needed for Tcl_ParseArgvObj routines.
2258 * Based on tkArgv.c.
2259 * Modifications from the original are copyright (c) Sam Bromley 2006
2260 */
2261
2262 typedef struct {
2263 int type; /* Indicates the option type; see below. */
2264 const char *keyStr; /* The key string that flags the option in the
2265 * argv array. */
2266 void *srcPtr; /* Value to be used in setting dst; usage
2267 * depends on type.*/
2268 void *dstPtr; /* Address of value to be modified; usage
2269 * depends on type.*/
2270 const char *helpStr; /* Documentation message describing this
2271 * option. */
2272 ClientData clientData; /* Word to pass to function callbacks. */
2273 } Tcl_ArgvInfo;
2274
2275 /*
2276 * Legal values for the type field of a Tcl_ArgInfo: see the user
2277 * documentation for details.
2278 */
2279
2280 #define TCL_ARGV_CONSTANT 15
2281 #define TCL_ARGV_INT 16
2282 #define TCL_ARGV_STRING 17
2283 #define TCL_ARGV_REST 18
2284 #define TCL_ARGV_FLOAT 19
2285 #define TCL_ARGV_FUNC 20
2286 #define TCL_ARGV_GENFUNC 21
2287 #define TCL_ARGV_HELP 22
2288 #define TCL_ARGV_END 23
2289
2290 /*
2291 * Types of callback functions for the TCL_ARGV_FUNC and TCL_ARGV_GENFUNC
2292 * argument types:
2293 */
2294
2295 typedef int (Tcl_ArgvFuncProc)(ClientData clientData, Tcl_Obj *objPtr,
2296 void *dstPtr);
2297 typedef int (Tcl_ArgvGenFuncProc)(ClientData clientData, Tcl_Interp *interp,
2298 int objc, Tcl_Obj *const *objv, void *dstPtr);
2299
2300 /*
2301 * Shorthand for commonly used argTable entries.
2302 */
2303
2304 #define TCL_ARGV_AUTO_HELP \
2305 {TCL_ARGV_HELP, "-help", NULL, NULL, \
2306 "Print summary of command-line options and abort", NULL}
2307 #define TCL_ARGV_AUTO_REST \
2308 {TCL_ARGV_REST, "--", NULL, NULL, \
2309 "Marks the end of the options", NULL}
2310 #define TCL_ARGV_TABLE_END \
2311 {TCL_ARGV_END, NULL, NULL, NULL, NULL, NULL}
2312
2313 /*
2314 *----------------------------------------------------------------------------
2315 * Definitions needed for Tcl_Zlib routines. [TIP #234]
2316 *
2317 * Constants for the format flags describing what sort of data format is
2318 * desired/expected for the Tcl_ZlibDeflate, Tcl_ZlibInflate and
2319 * Tcl_ZlibStreamInit functions.
2320 */
2321
2322 #define TCL_ZLIB_FORMAT_RAW 1
2323 #define TCL_ZLIB_FORMAT_ZLIB 2
2324 #define TCL_ZLIB_FORMAT_GZIP 4
2325 #define TCL_ZLIB_FORMAT_AUTO 8
2326
2327 /*
2328 * Constants that describe whether the stream is to operate in compressing or
2329 * decompressing mode.
2330 */
2331
2332 #define TCL_ZLIB_STREAM_DEFLATE 16
2333 #define TCL_ZLIB_STREAM_INFLATE 32
2334
2335 /*
2336 * Constants giving compression levels. Use of TCL_ZLIB_COMPRESS_DEFAULT is
2337 * recommended.
2338 */
2339
2340 #define TCL_ZLIB_COMPRESS_NONE 0
2341 #define TCL_ZLIB_COMPRESS_FAST 1
2342 #define TCL_ZLIB_COMPRESS_BEST 9
2343 #define TCL_ZLIB_COMPRESS_DEFAULT (-1)
2344
2345 /*
2346 * Constants for types of flushing, used with Tcl_ZlibFlush.
2347 */
2348
2349 #define TCL_ZLIB_NO_FLUSH 0
2350 #define TCL_ZLIB_FLUSH 2
2351 #define TCL_ZLIB_FULLFLUSH 3
2352 #define ----------------------------------------------------------------------------
2353 * The following declarations either map ckalloc and ckfree to malloc and
2354 * free, or they map them to functions with all sorts of debugging hooks
2355 * defined in tclCkalloc.c.
2356 */
2357
2358 #ifdef TCL_MEM_DEBUG
2359
2360 # voidine ckalloc(x) \
2361 ((VOID *) Tcl_DbCkalloc((unsigned)(x), __FILE__, __LINE__))
2362 # define ckfree(x) \
2363 Tcl_DbCkfree((char *)(x), __FILE__, __LINE__)
2364 # defvoid *) Tcl_DbCkrealloc((char *)(x), (unsigned)(y), __FILE__, __LINE__))
2365 # definevoid *) Tcl_AttemptDbCkalloc((unsigned)(x), __FILE__, __LINE__))
2366 # def Include platform specific
2367 * via the stubsPlatDecls.h"--------------------------------------------------------
2368 * The structure defined below is
--- a/compat/tcl-8.6/generic/tclDecls.h
+++ b/compat/tcl-8.6/generic/tclDecls.h
@@ -0,0 +1,1787 @@
1
+/*
2
+ * tclDecls.h --
3
+ *
4
+ * Declarations of functions in the platform independent public Tcl API.
5
+ *
6
+ * Copyright (c) 1998-1999 by Scriptics Corporation.
7
+ *
8
+ * See the file "license.terms" for information on usage and redistribution
9
+ * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
10
+ */
11
+
12
+#ifndef _TCLDECLS
13
+#define _TCLDECLS
14
+
15
+#undef TCL_STORAGE_CLASS
16
+#ifdef BUILD_tcl
17
+# define TCL_STORAGE_CLASS DLLEXPORT
18
+#else
19
+# ifdef USE_TCL_STUBS
20
+# define TCL_STORAGE_CLASS
21
+# else
22
+# define TCL_STORAGE_CLASS DLLIMPORT
23
+# endif
24
+#endif
25
+
26
+/*
27
+ * WARNING: This file is automatically generated by the tools/genStubs.tcl
28
+ * script. Any modifications to the function declarations below should be made
29
+ * in the generic/tcl.decls script.
30
+ */
31
+
32
+/* !BEGIN!: Do not edit below this line. */
33
+
34
+/*
35
+ * Exported function declarations:
36
+ */
37
+
38
+/* 0 */
39
+EXTERN int Tcl_PkgProvideEx(Tcl_Interp *interp,
40
+ const char *name, const char *version,
41
+ const void *clientData);
42
+/* 1 */
43
+EXTERN CONST84_RETURN char * Tcl_PkgRequireEx(Tcl_Interp *interp,
44
+ const char *name, const char *version,
45
+ int exact, void *clientDataPtr);
46
+/* 2 */
47
+EXTERN void Tcl_Panic(const char *format, ...) TCL_FORMAT_PRINTF(1, 2);
48
+/* 3 */
49
+EXTERN char * Tcl_Alloc(unsigned int size);
50
+/* 4 */
51
+EXTERN void Tcl_Free(char *ptr);
52
+/* 5 */
53
+EXTERN char * Tcl_Realloc(char *ptr, unsigned int size);
54
+/* 6 */
55
+EXTERN char * Tcl_DbCkalloc(unsigned int size, const char *file,
56
+ int line);
57
+/* 7 */
58
+EXTERN void Tcl_DbCkfree(char *ptr, const char *file, int line);
59
+/* 8 */
60
+EXTERN char * Tcl_DbCkrealloc(char *ptr, unsigned int size,
61
+ const char *file, int line);
62
+#if !defined(__WIN32__) && !defined(MAC_OSX_TCL) /* UNIX */
63
+/* 9 */
64
+EXTERN void Tcl_CreateFileHandler(int fd, int mask,
65
+ Tcl_FileProc *proc, ClientData clientData);
66
+#endif /* UNIX */
67
+#ifdef MAC_OSX_TCL /* MACOSX */
68
+/* 9 */
69
+EXTERN void Tcl_CreateFileHandler(int fd, int mask,
70
+ Tcl_FileProc *proc, ClientData clientData);
71
+#endif /* MACOSX */
72
+#if !defined(__WIN32__) && !defined(MAC_OSX_TCL) /* UNIX */
73
+/* 10 */
74
+EXTERN void Tcl_DeleteFileHandler(int fd);
75
+#endif /* UNIX */
76
+#ifdef MAC_OSX_TCL /* MACOSX */
77
+/* 10 */
78
+EXTERN void Tcl_DeleteFileHandler(int fd);
79
+#endif /* MACOSX */
80
+/* 11 */
81
+EXTERN void Tcl_SetTimer(const Tcl_Time *timePtr);
82
+/* 12 */
83
+EXTERN void Tcl_Sleep(int ms);
84
+/* 13 */
85
+EXTERN int Tcl_WaitForEvent(const Tcl_Time *timePtr);
86
+/* 14 */
87
+EXTERN int Tcl_AppendAllObjTypes(Tcl_Interp *interp,
88
+ Tcl_Obj *objPtr);
89
+/* 15 */
90
+EXTERN void Tcl_AppendStringsToObj(Tcl_Obj *objPtr, ...);
91
+/* 16 */
92
+EXTERN void Tcl_AppendToObj(Tcl_Obj *objPtr, const char *bytes,
93
+ int length);
94
+/* 17 */
95
+EXTERN Tcl_Obj * Tcl_ConcatObj(int objc, Tcl_Obj *const objv[]);
96
+/* 18 */
97
+EXTERN int Tcl_ConvertToType(Tcl_Interp *interp,
98
+ Tcl_Obj *objPtr, const Tcl_ObjType *typePtr);
99
+/* 19 */
100
+EXTERN void Tcl_DbDecrRefCount(Tcl_Obj *objPtr, const char *file,
101
+ int line);
102
+/* 20 */
103
+EXTERN void Tcl_DbIncrRefCount(Tcl_Obj *objPtr, const char *file,
104
+ int line);
105
+/* 21 */
106
+EXTERN int Tcl_DbIsShared(Tcl_Obj *objPtr, const char *file,
107
+ int line);
108
+/* 22 */
109
+EXTERN Tcl_Obj * Tcl_DbNewBooleanObj(int boolValue, const char *file,
110
+ int line);
111
+/* 23 */
112
+EXTERN Tcl_Obj * Tcl_DbNewByteArrayObj(const unsigned char *bytes,
113
+ int length, const char *file, int line);
114
+/* 24 */
115
+EXTERN Tcl_Obj * Tcl_DbNewDoubleObj(double doubleValue,
116
+ const char *file, int line);
117
+/* 25 */
118
+EXTERN Tcl_Obj * Tcl_DbNewListObj(int objc, Tcl_Obj *const *objv,
119
+ const char *file, int line);
120
+/* 26 */
121
+EXTERN Tcl_Obj * Tcl_DbNewLongObj(long longValue, const char *file,
122
+ int line);
123
+/* 27 */
124
+EXTERN Tcl_Obj * Tcl_DbNewObj(const char *file, int line);
125
+/* 28 */
126
+EXTERN Tcl_Obj * Tcl_DbNewStringObj(const char *bytes, int length,
127
+ const char *file, int line);
128
+/* 29 */
129
+EXTERN Tcl_Obj * Tcl_DuplicateObj(Tcl_Obj *objPtr);
130
+/* 30 */
131
+EXTERN void TclFreeObj(Tcl_Obj *objPtr);
132
+/* 31 */
133
+EXTERN int Tcl_GetBoolean(Tcl_Interp *interp, const char *src,
134
+ int *boolPtr);
135
+/* 32 */
136
+EXTERN int Tcl_GetBooleanFromObj(Tcl_Interp *interp,
137
+ Tcl_Obj *objPtr, int *boolPtr);
138
+/* 33 */
139
+EXTERN unsigned char * Tcl_GetByteArrayFromObj(Tcl_Obj *objPtr,
140
+ int *lengthPtr);
141
+/* 34 */
142
+EXTERN int Tcl_GetDouble(Tcl_Interp *interp, const char *src,
143
+ double *doublePtr);
144
+/* 35 */
145
+EXTERN int Tcl_GetDoubleFromObj(Tcl_Interp *interp,
146
+ Tcl_Obj *objPtr, double *doublePtr);
147
+/* 36 */
148
+EXTERN int Tcl_GetIndexFromObj(Tcl_Interp *interp,
149
+ Tcl_Obj *objPtr,
150
+ CONST84 char *const *tablePtr,
151
+ const char *msg, int flags, int *indexPtr);
152
+/* 37 */
153
+EXTERN int Tcl_GetInt(Tcl_Interp *interp, const char *src,
154
+ int *intPtr);
155
+/* 38 */
156
+EXTERN int Tcl_GetIntFromObj(Tcl_Interp *interp,
157
+ Tcl_Obj *objPtr, int *intPtr);
158
+/* 39 */
159
+EXTERN int Tcl_GetLongFromObj(Tcl_Interp *interp,
160
+ Tcl_Obj *objPtr, long *longPtr);
161
+/* 40 */
162
+EXTERN CONST86 Tcl_ObjType * Tcl_GetObjType(const char *typeName);
163
+/* 41 */
164
+EXTERN char * Tcl_GetStringFromObj(Tcl_Obj *objPtr, int *lengthPtr);
165
+/* 42 */
166
+EXTERN void Tcl_InvalidateStringRep(Tcl_Obj *objPtr);
167
+/* 43 */
168
+EXTERN int Tcl_ListObjAppendList(Tcl_Interp *interp,
169
+ Tcl_Obj *listPtr, Tcl_Obj *elemListPtr);
170
+/* 44 */
171
+EXTERN int Tcl_ListObjAppendElement(Tcl_Interp *interp,
172
+ Tcl_Obj *listPtr, Tcl_Obj *objPtr);
173
+/* 45 */
174
+EXTERN int Tcl_ListObjGetElements(Tcl_Interp *interp,
175
+ Tcl_Obj *listPtr, int *objcPtr,
176
+ Tcl_Obj ***objvPtr);
177
+/* 46 */
178
+EXTERN int Tcl_ListObjIndex(Tcl_Interp *interp,
179
+ Tcl_Obj *listPtr, int index,
180
+ Tcl_Obj **objPtrPtr);
181
+/* 47 */
182
+EXTERN int Tcl_ListObjLength(Tcl_Interp *interp,
183
+ Tcl_Obj *listPtr, int *lengthPtr);
184
+/* 48 */
185
+EXTERN int Tcl_ListObjReplace(Tcl_Interp *interp,
186
+ Tcl_Obj *listPtr, int first, int count,
187
+ int objc, Tcl_Obj *const objv[]);
188
+/* 49 */
189
+EXTERN Tcl_Obj * Tcl_NewBooleanObj(int boolValue);
190
+/* 50 */
191
+EXTERN Tcl_Obj * Tcl_NewByteArrayObj(const unsigned char *bytes,
192
+ int length);
193
+/* 51 */
194
+EXTERN Tcl_Obj * Tcl_NewDoubleObj(double doubleValue);
195
+/* 52 */
196
+EXTERN Tcl_Obj * Tcl_NewIntObj(int intValue);
197
+/* 53 */
198
+EXTERN Tcl_Obj * Tcl_NewListObj(int objc, Tcl_Obj *const objv[]);
199
+/* 54 */
200
+EXTERN Tcl_Obj * Tcl_NewLongObj(long longValue);
201
+/* 55 */
202
+EXTERN Tcl_Obj * Tcl_NewObj(void);
203
+/* 56 */
204
+EXTERN Tcl_Obj * Tcl_NewStringObj(const char *bytes, int length);
205
+/* 57 */
206
+EXTERN void Tcl_SetBooleanObj(Tcl_Obj *objPtr, int boolValue);
207
+/* 58 */
208
+EXTERN unsigned char * Tcl_SetByteArrayLength(Tcl_Obj *objPtr, int length);
209
+/* 59 */
210
+EXTERN void Tcl_SetByteArrayObj(Tcl_Obj *objPtr,
211
+ const unsigned char *bytes, int length);
212
+/* 60 */
213
+EXTERN void Tcl_SetDoubleObj(Tcl_Obj *objPtr, double doubleValue);
214
+/* 61 */
215
+EXTERN void Tcl_SetIntObj(Tcl_Obj *objPtr, int intValue);
216
+/* 62 */
217
+EXTERN void Tcl_SetListObj(Tcl_Obj *objPtr, int objc,
218
+ Tcl_Obj *const objv[]);
219
+/* 63 */
220
+EXTERN void Tcl_SetLongObj(Tcl_Obj *objPtr, long longValue);
221
+/* 64 */
222
+EXTERN void Tcl_SetObjLength(Tcl_Obj *objPtr, int length);
223
+/* 65 */
224
+EXTERN void Tcl_SetStringObj(Tcl_Obj *objPtr, const char *bytes,
225
+ int length);
226
+/* 66 */
227
+EXTERN void Tcl_AddErrorInfo(Tcl_Interp *interp,
228
+ const char *message);
229
+/* 67 */
230
+EXTERN void Tcl_AddObjErrorInfo(Tcl_Interp *interp,
231
+ const char *message, int length);
232
+/* 68 */
233
+EXTERN void Tcl_AllowExceptions(Tcl_Interp *interp);
234
+/* 69 */
235
+EXTERN void Tcl_AppendElement(Tcl_Interp *interp,
236
+ const char *element);
237
+/* 70 */
238
+EXTERN void Tcl_AppendResult(Tcl_Interp *interp, ...);
239
+/* 71 */
240
+EXTERN Tcl_AsyncHandler Tcl_AsyncCreate(Tcl_AsyncProc *proc,
241
+ ClientData clientData);
242
+/* 72 */
243
+EXTERN void Tcl_AsyncDelete(Tcl_AsyncHandler async);
244
+/* 73 */
245
+EXTERN int Tcl_AsyncInvoke(Tcl_Interp *interp, int code);
246
+/* 74 */
247
+EXTERN void Tcl_AsyncMark(Tcl_AsyncHandler async);
248
+/* 75 */
249
+EXTERN int Tcl_AsyncReady(void);
250
+/* 76 */
251
+EXTERN void Tcl_BackgroundError(Tcl_Interp *interp);
252
+/* 77 */
253
+EXTERN char Tcl_Backslash(const char *src, int *readPtr);
254
+/* 78 */
255
+EXTERN int Tcl_BadChannelOption(Tcl_Interp *interp,
256
+ const char *optionName,
257
+ const char *optionList);
258
+/* 79 */
259
+EXTERN void Tcl_CallWhenDeleted(Tcl_Interp *interp,
260
+ Tcl_InterpDeleteProc *proc,
261
+ ClientData clientData);
262
+/* 80 */
263
+EXTERN void Tcl_CancelIdleCall(Tcl_IdleProc *idleProc,
264
+ ClientData clientData);
265
+/* 81 */
266
+EXTERN int Tcl_Close(Tcl_Interp *interp, Tcl_Channel chan);
267
+/* 82 */
268
+EXTERN int Tcl_CommandComplete(const char *cmd);
269
+/* 83 */
270
+EXTERN char * Tcl_Concat(int argc, CONST84 char *const *argv);
271
+/* 84 */
272
+EXTERN int Tcl_ConvertElement(const char *src, char *dst,
273
+ int flags);
274
+/* 85 */
275
+EXTERN int Tcl_ConvertCountedElement(const char *src,
276
+ int length, char *dst, int flags);
277
+/* 86 */
278
+EXTERN int Tcl_CreateAlias(Tcl_Interp *slave,
279
+ const char *slaveCmd, Tcl_Interp *target,
280
+ const char *targetCmd, int argc,
281
+ CONST84 char *const *argv);
282
+/* 87 */
283
+EXTERN int Tcl_CreateAliasObj(Tcl_Interp *slave,
284
+ const char *slaveCmd, Tcl_Interp *target,
285
+ const char *targetCmd, int objc,
286
+ Tcl_Obj *const objv[]);
287
+/* 88 */
288
+EXTERN Tcl_Channel Tcl_CreateChannel(const Tcl_ChannelType *typePtr,
289
+ const char *chanName,
290
+ ClientData instanceData, int mask);
291
+/* 89 */
292
+EXTERN void Tcl_CreateChannelHandler(Tcl_Channel chan, int mask,
293
+ Tcl_ChannelProc *proc, ClientData clientData);
294
+/* 90 */
295
+EXTERN void Tcl_CreateCloseHandler(Tcl_Channel chan,
296
+ Tcl_CloseProc *proc, ClientData clientData);
297
+/* 91 */
298
+EXTERN Tcl_Command Tcl_CreateCommand(Tcl_Interp *interp,
299
+ const char *cmdName, Tcl_CmdProc *proc,
300
+ ClientData clientData,
301
+ Tcl_CmdDeleteProc *deleteProc);
302
+/* 92 */
303
+EXTERN void Tcl_CreateEventSource(Tcl_EventSetupProc *setupProc,
304
+ Tcl_EventCheckProc *checkProc,
305
+ ClientData clientData);
306
+/* 93 */
307
+EXTERN void Tcl_CreateExitHandler(Tcl_ExitProc *proc,
308
+ ClientData clientData);
309
+/* 94 */
310
+EXTERN Tcl_Interp * Tcl_CreateInterp(void);
311
+/* 95 */
312
+EXTERN void Tcl_CreateMathFunc(Tcl_Interp *interp,
313
+ const char *name, int numArgs,
314
+ Tcl_ValueType *argTypes, Tcl_MathProc *proc,
315
+ ClientData clientData);
316
+/* 96 */
317
+EXTERN Tcl_Command Tcl_CreateObjCommand(Tcl_Interp *interp,
318
+ const char *cmdName, Tcl_ObjCmdProc *proc,
319
+ ClientData clientData,
320
+ Tcl_CmdDeleteProc *deleteProc);
321
+/* 97 */
322
+EXTERN Tcl_Interp * Tcl_CreateSlave(Tcl_Interp *interp,
323
+ const char *slaveName, int isSafe);
324
+/* 98 */
325
+EXTERN Tcl_TimerToken Tcl_CreateTimerHandler(int milliseconds,
326
+ Tcl_TimerProc *proc, ClientData clientData);
327
+/* 99 */
328
+EXTERN Tcl_Trace Tcl_CreateTrace(Tcl_Interp *interp, int level,
329
+ Tcl_CmdTraceProc *proc,
330
+ ClientData clientData);
331
+/* 100 */
332
+EXTERN void Tcl_DeleteAssocData(Tcl_Interp *interp,
333
+ const char *name);
334
+/* 101 */
335
+EXTERN void Tcl_DeleteChannelHandler(Tcl_Channel chan,
336
+ Tcl_ChannelProc *proc, ClientData clientData);
337
+/* 102 */
338
+EXTERN void Tcl_DeleteCloseHandler(Tcl_Channel chan,
339
+ Tcl_CloseProc *proc, ClientData clientData);
340
+/* 103 */
341
+EXTERN int Tcl_DeleteCommand(Tcl_Interp *interp,
342
+ const char *cmdName);
343
+/* 104 */
344
+EXTERN int Tcl_DeleteCommandFromToken(Tcl_Interp *interp,
345
+ Tcl_Command command);
346
+/* 105 */
347
+EXTERN void Tcl_DeleteEvents(Tcl_EventDeleteProc *proc,
348
+ ClientData clientData);
349
+/* 106 */
350
+EXTERN void Tcl_DeleteEventSource(Tcl_EventSetupProc *setupProc,
351
+ Tcl_EventCheckProc *checkProc,
352
+ ClientData clientData);
353
+/* 107 */
354
+EXTERN void Tcl_DeleteExitHandler(Tcl_ExitProc *proc,
355
+ ClientData clientData);
356
+/* 108 */
357
+EXTERN void Tcl_DeleteHashEntry(Tcl_HashEntry *entryPtr);
358
+/* 109 */
359
+EXTERN void Tcl_DeleteHashTable(Tcl_HashTable *tablePtr);
360
+/* 110 */
361
+EXTERN void Tcl_DeleteInterp(Tcl_Interp *interp);
362
+/* 111 */
363
+EXTERN void Tcl_DetachPids(int numPids, Tcl_Pid *pidPtr);
364
+/* 112 */
365
+EXTERN void Tcl_DeleteTimerHandler(Tcl_TimerToken token);
366
+/* 113 */
367
+EXTERN void Tcl_DeleteTrace(Tcl_Interp *interp, Tcl_Trace trace);
368
+/* 114 */
369
+EXTERN void Tcl_DontCallWhenDeleted(Tcl_Interp *interp,
370
+ Tcl_InterpDeleteProc *proc,
371
+ ClientData clientData);
372
+/* 115 */
373
+EXTERN int Tcl_DoOneEvent(int flags);
374
+/* 116 */
375
+EXTERN void Tcl_DoWhenIdle(Tcl_IdleProc *proc,
376
+ ClientData clientData);
377
+/* 117 */
378
+EXTERN char * Tcl_DStringAppend(Tcl_DString *dsPtr,
379
+ const char *bytes, int length);
380
+/* 118 */
381
+EXTERN char * Tcl_DStringAppendElement(Tcl_DString *dsPtr,
382
+ const char *element);
383
+/* 119 */
384
+EXTERN void Tcl_DStringEndSublist(Tcl_DString *dsPtr);
385
+/* 120 */
386
+EXTERN void Tcl_DStringFree(Tcl_DString *dsPtr);
387
+/* 121 */
388
+EXTERN void Tcl_DStringGetResult(Tcl_Interp *interp,
389
+ Tcl_DString *dsPtr);
390
+/* 122 */
391
+EXTERN void Tcl_DStringInit(Tcl_DString *dsPtr);
392
+/* 123 */
393
+EXTERN void Tcl_DStringResult(Tcl_Interp *interp,
394
+ Tcl_DString *dsPtr);
395
+/* 124 */
396
+EXTERN void Tcl_DStringSetLength(Tcl_DString *dsPtr, int length);
397
+/* 125 */
398
+EXTERN void Tcl_DStringStartSublist(Tcl_DString *dsPtr);
399
+/* 126 */
400
+EXTERN int Tcl_Eof(Tcl_Channel chan);
401
+/* 127 */
402
+EXTERN CONST84_RETURN char * Tcl_ErrnoId(void);
403
+/* 128 */
404
+EXTERN CONST84_RETURN char * Tcl_ErrnoMsg(int err);
405
+/* 129 */
406
+EXTERN int Tcl_Eval(Tcl_Interp *interp, const char *script);
407
+/* 130 */
408
+EXTERN int Tcl_EvalFile(Tcl_Interp *interp,
409
+ const char *fileName);
410
+/* 131 */
411
+EXTERN int Tcl_EvalObj(Tcl_Interp *interp, Tcl_Obj *objPtr);
412
+/* 132 */
413
+EXTERN void Tcl_EventuallyFree(ClientData clientData,
414
+ Tcl_FreeProc *freeProc);
415
+/* 133 */
416
+EXTERN void Tcl_Exit(int status);
417
+/* 134 */
418
+EXTERN int Tcl_ExposeCommand(Tcl_Interp *interp,
419
+ const char *hiddenCmdToken,
420
+ const char *cmdName);
421
+/* 135 */
422
+EXTERN int Tcl_ExprBoolean(Tcl_Interp *interp, const char *expr,
423
+ int *ptr);
424
+/* 136 */
425
+EXTERN int Tcl_ExprBooleanObj(Tcl_Interp *interp,
426
+ Tcl_Obj *objPtr, int *ptr);
427
+/* 137 */
428
+EXTERN int Tcl_ExprDouble(Tcl_Interp *interp, const char *expr,
429
+ double *ptr);
430
+/* 138 */
431
+EXTERN int Tcl_ExprDoubleObj(Tcl_Interp *interp,
432
+ Tcl_Obj *objPtr, double *ptr);
433
+/* 139 */
434
+EXTERN int Tcl_ExprLong(Tcl_Interp *interp, const char *expr,
435
+ long *ptr);
436
+/* 140 */
437
+EXTERN int Tcl_ExprLongObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
438
+ long *ptr);
439
+/* 141 */
440
+EXTERN int Tcl_ExprObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
441
+ Tcl_Obj **resultPtrPtr);
442
+/* 142 */
443
+EXTERN int Tcl_ExprString(Tcl_Interp *interp, const char *expr);
444
+/* 143 */
445
+EXTERN void Tcl_Finalize(void);
446
+/* 144 */
447
+EXTERN void Tcl_FindExecutable(const char *argv0);
448
+/* 145 */
449
+EXTERN Tcl_HashEntry * Tcl_FirstHashEntry(Tcl_HashTable *tablePtr,
450
+ Tcl_HashSearch *searchPtr);
451
+/* 146 */
452
+EXTERN int Tcl_Flush(Tcl_Channel chan);
453
+/* 147 */
454
+EXTERN void Tcl_FreeResult(Tcl_Interp *interp);
455
+/* 148 */
456
+EXTERN int Tcl_GetAlias(Tcl_Interp *interp,
457
+ const char *slaveCmd,
458
+ Tcl_Interp **targetInterpPtr,
459
+ CONST84 char **targetCmdPtr, int *argcPtr,
460
+ CONST84 char ***argvPtr);
461
+/* 149 */
462
+EXTERN int Tcl_GetAliasObj(Tcl_Interp *interp,
463
+ const char *slaveCmd,
464
+ Tcl_Interp **targetInterpPtr,
465
+ CONST84 char **targetCmdPtr, int *objcPtr,
466
+ Tcl_Obj ***objv);
467
+/* 150 */
468
+EXTERN ClientData Tcl_GetAssocData(Tcl_Interp *interp,
469
+ const char *name,
470
+ Tcl_InterpDeleteProc **procPtr);
471
+/* 151 */
472
+EXTERN Tcl_Channel Tcl_GetChannel(Tcl_Interp *interp,
473
+ const char *chanName, int *modePtr);
474
+/* 152 */
475
+EXTERN int Tcl_GetChannelBufferSize(Tcl_Channel chan);
476
+/* 153 */
477
+EXTERN int Tcl_GetChannelHandle(Tcl_Channel chan, int direction,
478
+ ClientData *handlePtr);
479
+/* 154 */
480
+EXTERN ClientData Tcl_GetChannelInstanceData(Tcl_Channel chan);
481
+/* 155 */
482
+EXTERN int Tcl_GetChannelMode(Tcl_Channel chan);
483
+/* 156 */
484
+EXTERN CONST84_RETURN char * Tcl_GetChannelName(Tcl_Channel chan);
485
+/* 157 */
486
+EXTERN int Tcl_GetChannelOption(Tcl_Interp *interp,
487
+ Tcl_Channel chan, const char *optionName,
488
+ Tcl_DString *dsPtr);
489
+/* 158 */
490
+EXTERN CONST86 Tcl_ChannelType * Tcl_GetChannelType(Tcl_Channel chan);
491
+/* 159 */
492
+EXTERN int Tcl_GetCommandInfo(Tcl_Interp *interp,
493
+ const char *cmdName, Tcl_CmdInfo *infoPtr);
494
+/* 160 */
495
+EXTERN CONST84_RETURN char * Tcl_GetCommandName(Tcl_Interp *interp,
496
+ Tcl_Command command);
497
+/* 161 */
498
+EXTERN int Tcl_GetErrno(void);
499
+/* 162 */
500
+EXTERN CONST84_RETURN char * Tcl_GetHostName(void);
501
+/* 163 */
502
+EXTERN int Tcl_GetInterpPath(Tcl_Interp *askInterp,
503
+ Tcl_Interp *slaveInterp);
504
+/* 164 */
505
+EXTERN Tcl_Interp * Tcl_GetMaster(Tcl_Interp *interp);
506
+/* 165 */
507
+EXTERN const char * Tcl_GetNameOfExecutable(void);
508
+/* 166 */
509
+EXTERN Tcl_Obj * Tcl_GetObjResult(Tcl_Interp *interp);
510
+#if !defined(__WIN32__) && !defined(MAC_OSX_TCL) /* UNIX */
511
+/* 167 */
512
+EXTERN int Tcl_GetOpenFile(Tcl_Interp *interp,
513
+ const char *chanID, int forWriting,
514
+ int checkUsage, ClientData *filePtr);
515
+#endif /* UNIX */
516
+#ifdef MAC_OSX_TCL /* MACOSX */
517
+/* 167 */
518
+EXTERN int Tcl_GetOpenFile(Tcl_Interp *interp,
519
+ const char *chanID, int forWriting,
520
+ int checkUsage, ClientData *filePtr);
521
+#endif /* MACOSX */
522
+/* 168 */
523
+EXTERN Tcl_PathType Tcl_GetPathType(const char *path);
524
+/* 169 */
525
+EXTERN int Tcl_Gets(Tcl_Channel chan, Tcl_DString *dsPtr);
526
+/* 170 */
527
+EXTERN int Tcl_GetsObj(Tcl_Channel chan, Tcl_Obj *objPtr);
528
+/* 171 */
529
+EXTERN int Tcl_GetServiceMode(void);
530
+/* 172 */
531
+EXTERN Tcl_Interp * Tcl_GetSlave(Tcl_Interp *interp,
532
+ const char *slaveName);
533
+/* 173 */
534
+EXTERN Tcl_Channel Tcl_GetStdChannel(int type);
535
+/* 174 */
536
+EXTERN CONST84_RETURN char * Tcl_GetStringResult(Tcl_Interp *interp);
537
+/* 175 */
538
+EXTERN CONST84_RETURN char * Tcl_GetVar(Tcl_Interp *interp,
539
+ const char *varName, int flags);
540
+/* 176 */
541
+EXTERN CONST84_RETURN char * Tcl_GetVar2(Tcl_Interp *interp,
542
+ const char *part1, const char *part2,
543
+ int flags);
544
+/* 177 */
545
+EXTERN int Tcl_GlobalEval(Tcl_Interp *interp,
546
+ const char *command);
547
+/* 178 */
548
+EXTERN int Tcl_GlobalEvalObj(Tcl_Interp *interp,
549
+ Tcl_Obj *objPtr);
550
+/* 179 */
551
+EXTERN int Tcl_HideCommand(Tcl_Interp *interp,
552
+ const char *cmdName,
553
+ const char *hiddenCmdToken);
554
+/* 180 */
555
+EXTERN int Tcl_Init(Tcl_Interp *interp);
556
+/* 181 */
557
+EXTERN void Tcl_InitHashTable(Tcl_HashTable *tablePtr,
558
+ int keyType);
559
+/* 182 */
560
+EXTERN int Tcl_InputBlocked(Tcl_Channel chan);
561
+/* 183 */
562
+EXTERN int Tcl_InputBuffered(Tcl_Channel chan);
563
+/* 184 */
564
+EXTERN int Tcl_InterpDeleted(Tcl_Interp *interp);
565
+/* 185 */
566
+EXTERN int Tcl_IsSafe(Tcl_Interp *interp);
567
+/* 186 */
568
+EXTERN char * Tcl_JoinPath(int argc, CONST84 char *const *argv,
569
+ Tcl_DString *resultPtr);
570
+/* 187 */
571
+EXTERN int Tcl_LinkVar(Tcl_Interp *interp, const char *varName,
572
+ char *addr, int type);
573
+/* Slot 188 is reserved */
574
+/* 189 */
575
+EXTERN Tcl_Channel Tcl_MakeFileChannel(ClientData handle, int mode);
576
+/* 190 */
577
+EXTERN int Tcl_MakeSafe(Tcl_Interp *interp);
578
+/* 191 */
579
+EXTERN Tcl_Channel Tcl_MakeTcpClientChannel(ClientData tcpSocket);
580
+/* 192 */
581
+EXTERN char * Tcl_Merge(int argc, CONST84 char *const *argv);
582
+/* 193 */
583
+EXTERN Tcl_HashEntry * Tcl_NextHashEntry(Tcl_HashSearch *searchPtr);
584
+/* 194 */
585
+EXTERN void Tcl_NotifyChannel(Tcl_Channel channel, int mask);
586
+/* 195 */
587
+EXTERN Tcl_Obj * Tcl_ObjGetVar2(Tcl_Interp *interp, Tcl_Obj *part1Ptr,
588
+ Tcl_Obj *part2Ptr, int flags);
589
+/* 196 */
590
+EXTERN Tcl_Obj * Tcl_ObjSetVar2(Tcl_Interp *interp, Tcl_Obj *part1Ptr,
591
+ Tcl_Obj *part2Ptr, Tcl_Obj *newValuePtr,
592
+ int flags);
593
+/* 197 */
594
+EXTERN Tcl_Channel Tcl_OpenCommandChannel(Tcl_Interp *interp, int argc,
595
+ CONST84 char **argv, int flags);
596
+/* 198 */
597
+EXTERN Tcl_Channel Tcl_OpenFileChannel(Tcl_Interp *interp,
598
+ const char *fileName, const char *modeString,
599
+ int permissions);
600
+/* 199 */
601
+EXTERN Tcl_Channel Tcl_OpenTcpClient(Tcl_Interp *interp, int port,
602
+ const char *address, const char *myaddr,
603
+ int myport, int async);
604
+/* 200 */
605
+EXTERN Tcl_Channel Tcl_OpenTcpServer(Tcl_Interp *interp, int port,
606
+ const char *host,
607
+ Tcl_TcpAcceptProc *acceptProc,
608
+ ClientData callbackData);
609
+/* 201 */
610
+EXTERN void Tcl_Preserve(ClientData data);
611
+/* 202 */
612
+EXTERN void Tcl_PrintDouble(Tcl_Interp *interp, double value,
613
+ char *dst);
614
+/* 203 */
615
+EXTERN int Tcl_PutEnv(const char *assignment);
616
+/* 204 */
617
+EXTERN CONST84_RETURN char * Tcl_PosixError(Tcl_Interp *interp);
618
+/* 205 */
619
+EXTERN void Tcl_QueueEvent(Tcl_Event *evPtr,
620
+ Tcl_QueuePosition position);
621
+/* 206 */
622
+EXTERN int Tcl_Read(Tcl_Channel chan, char *bufPtr, int toRead);
623
+/* 207 */
624
+EXTERN void Tcl_ReapDetachedProcs(void);
625
+/* 208 */
626
+EXTERN int Tcl_RecordAndEval(Tcl_Interp *interp,
627
+ const char *cmd, int flags);
628
+/* 209 */
629
+EXTERN int Tcl_RecordAndEvalObj(Tcl_Interp *interp,
630
+ Tcl_Obj *cmdPtr, int flags);
631
+/* 210 */
632
+EXTERN void Tcl_RegisterChannel(Tcl_Interp *interp,
633
+ Tcl_Channel chan);
634
+/* 211 */
635
+EXTERN void Tcl_RegisterObjType(const Tcl_ObjType *typePtr);
636
+/* 212 */
637
+EXTERN Tcl_RegExp Tcl_RegExpCompile(Tcl_Interp *interp,
638
+ const char *pattern);
639
+/* 213 */
640
+EXTERN int Tcl_RegExpExec(Tcl_Interp *interp, Tcl_RegExp regexp,
641
+ const char *text, const char *start);
642
+/* 214 */
643
+EXTERN int Tcl_RegExpMatch(Tcl_Interp *interp, const char *text,
644
+ const char *pattern);
645
+/* 215 */
646
+EXTERN void Tcl_RegExpRange(Tcl_RegExp regexp, int index,
647
+ CONST84 char **startPtr,
648
+ CONST84 char **endPtr);
649
+/* 216 */
650
+EXTERN void Tcl_Release(ClientData clientData);
651
+/* 217 */
652
+EXTERN void Tcl_ResetResult(Tcl_Interp *interp);
653
+/* 218 */
654
+EXTERN int Tcl_ScanElement(const char *src, int *flagPtr);
655
+/* 219 */
656
+EXTERN int Tcl_ScanCountedElement(const char *src, int length,
657
+ int *flagPtr);
658
+/* 220 */
659
+EXTERN int Tcl_SeekOld(Tcl_Channel chan, int offset, int mode);
660
+/* 221 */
661
+EXTERN int Tcl_ServiceAll(void);
662
+/* 222 */
663
+EXTERN int Tcl_ServiceEvent(int flags);
664
+/* 223 */
665
+EXTERN void Tcl_SetAssocData(Tcl_Interp *interp,
666
+ const char *name, Tcl_InterpDeleteProc *proc,
667
+ ClientData clientData);
668
+/* 224 */
669
+EXTERN void Tcl_SetChannelBufferSize(Tcl_Channel chan, int sz);
670
+/* 225 */
671
+EXTERN int Tcl_SetChannelOption(Tcl_Interp *interp,
672
+ Tcl_Channel chan, const char *optionName,
673
+ const char *newValue);
674
+/* 226 */
675
+EXTERN int Tcl_SetCommandInfo(Tcl_Interp *interp,
676
+ const char *cmdName,
677
+ const Tcl_CmdInfo *infoPtr);
678
+/* 227 */
679
+EXTERN void Tcl_SetErrno(int err);
680
+/* 228 */
681
+EXTERN void Tcl_SetErrorCode(Tcl_Interp *interp, ...);
682
+/* 229 */
683
+EXTERN void Tcl_SetMaxBlockTime(const Tcl_Time *timePtr);
684
+/* 230 */
685
+EXTERN void Tcl_SetPanicProc(Tcl_PanicProc *panicProc);
686
+/* 231 */
687
+EXTERN int Tcl_SetRecursionLimit(Tcl_Interp *interp, int depth);
688
+/* 232 */
689
+EXTERN void Tcl_SetResult(Tcl_Interp *interp, char *result,
690
+ Tcl_FreeProc *freeProc);
691
+/* 233 */
692
+EXTERN int Tcl_SetServiceMode(int mode);
693
+/* 234 */
694
+EXTERN void Tcl_SetObjErrorCode(Tcl_Interp *interp,
695
+ Tcl_Obj *errorObjPtr);
696
+/* 235 */
697
+EXTERN void Tcl_SetObjResult(Tcl_Interp *interp,
698
+ Tcl_Obj *resultObjPtr);
699
+/* 236 */
700
+EXTERN void Tcl_SetStdChannel(Tcl_Channel channel, int type);
701
+/* 237 */
702
+EXTERN CONST84_RETURN char * Tcl_SetVar(Tcl_Interp *interp,
703
+ const char *varName, const char *newValue,
704
+ int flags);
705
+/* 238 */
706
+EXTERN CONST84_RETURN char * Tcl_SetVar2(Tcl_Interp *interp,
707
+ const char *part1, const char *part2,
708
+ const char *newValue, int flags);
709
+/* 239 */
710
+EXTERN CONST84_RETURN char * Tcl_SignalId(int sig);
711
+/* 240 */
712
+EXTERN CONST84_RETURN char * Tcl_SignalMsg(int sig);
713
+/* 241 */
714
+EXTERN void Tcl_SourceRCFile(Tcl_Interp *interp);
715
+/* 242 */
716
+EXTERN int Tcl_SplitList(Tcl_Interp *interp,
717
+ const char *listStr, int *argcPtr,
718
+ CONST84 char ***argvPtr);
719
+/* 243 */
720
+EXTERN void Tcl_SplitPath(const char *path, int *argcPtr,
721
+ CONST84 char ***argvPtr);
722
+/* 244 */
723
+EXTERN void Tcl_StaticPackage(Tcl_Interp *interp,
724
+ const char *pkgName,
725
+ Tcl_PackageInitProc *initProc,
726
+ Tcl_PackageInitProc *safeInitProc);
727
+/* 245 */
728
+EXTERN int Tcl_StringMatch(const char *str, const char *pattern);
729
+/* 246 */
730
+EXTERN int Tcl_TellOld(Tcl_Channel chan);
731
+/* 247 */
732
+EXTERN int Tcl_TraceVar(Tcl_Interp *interp, const char *varName,
733
+ int flags, Tcl_VarTraceProc *proc,
734
+ ClientData clientData);
735
+/* 248 */
736
+EXTERN int Tcl_TraceVar2(Tcl_Interp *interp, const char *part1,
737
+ const char *part2, int flags,
738
+ Tcl_VarTraceProc *proc,
739
+ ClientData clientData);
740
+/* 249 */
741
+EXTERN char * Tcl_TranslateFileName(Tcl_Interp *interp,
742
+ const char *name, Tcl_DString *bufferPtr);
743
+/* 250 */
744
+EXTERN int Tcl_Ungets(Tcl_Channel chan, const char *str,
745
+ int len, int atHead);
746
+/* 251 */
747
+EXTERN void Tcl_UnlinkVar(Tcl_Interp *interp,
748
+ const char *varName);
749
+/* 252 */
750
+EXTERN int Tcl_UnregisterChannel(Tcl_Interp *interp,
751
+ Tcl_Channel chan);
752
+/* 253 */
753
+EXTERN int Tcl_UnsetVar(Tcl_Interp *interp, const char *varName,
754
+ int flags);
755
+/* 254 */
756
+EXTERN int Tcl_UnsetVar2(Tcl_Interp *interp, const char *part1,
757
+ const char *part2, int flags);
758
+/* 255 */
759
+EXTERN void Tcl_UntraceVar(Tcl_Interp *interp,
760
+ const char *varName, int flags,
761
+ Tcl_VarTraceProc *proc,
762
+ ClientData clientData);
763
+/* 256 */
764
+EXTERN void Tcl_UntraceVar2(Tcl_Interp *interp,
765
+ const char *part1, const char *part2,
766
+ int flags, Tcl_VarTraceProc *proc,
767
+ ClientData clientData);
768
+/* 257 */
769
+EXTERN void Tcl_UpdateLinkedVar(Tcl_Interp *interp,
770
+ const char *varName);
771
+/* 258 */
772
+EXTERN int Tcl_UpVar(Tcl_Interp *interp, const char *frameName,
773
+ const char *varName, const char *localName,
774
+ int flags);
775
+/* 259 */
776
+EXTERN int Tcl_UpVar2(Tcl_Interp *interp, const char *frameName,
777
+ const char *part1, const char *part2,
778
+ const char *localName, int flags);
779
+/* 260 */
780
+EXTERN int Tcl_VarEval(Tcl_Interp *interp, ...);
781
+/* 261 */
782
+EXTERN ClientData Tcl_VarTraceInfo(Tcl_Interp *interp,
783
+ const char *varName, int flags,
784
+ Tcl_VarTraceProc *procPtr,
785
+ ClientData prevClientData);
786
+/* 262 */
787
+EXTERN ClientData Tcl_VarTraceInfo2(Tcl_Interp *interp,
788
+ const char *part1, const char *part2,
789
+ int flags, Tcl_VarTraceProc *procPtr,
790
+ ClientData prevClientData);
791
+/* 263 */
792
+EXTERN int Tcl_Write(Tcl_Channel chan, const char *s, int slen);
793
+/* 264 */
794
+EXTERN void Tcl_WrongNumArgs(Tcl_Interp *interp, int objc,
795
+ Tcl_Obj *const objv[], const char *message);
796
+/* 265 */
797
+EXTERN int Tcl_DumpActiveMemory(const char *fileName);
798
+/* 266 */
799
+EXTERN void Tcl_ValidateAllMemory(const char *file, int line);
800
+/* 267 */
801
+EXTERN void Tcl_AppendResultVA(Tcl_Interp *interp,
802
+ va_list argList);
803
+/* 268 */
804
+EXTERN void Tcl_AppendStringsToObjVA(Tcl_Obj *objPtr,
805
+ va_list argList);
806
+/* 269 */
807
+EXTERN char * Tcl_HashStats(Tcl_HashTable *tablePtr);
808
+/* 270 */
809
+EXTERN CONST84_RETURN char * Tcl_ParseVar(Tcl_Interp *interp,
810
+ const char *start, CONST84 char **termPtr);
811
+/* 271 */
812
+EXTERN CONST84_RETURN char * Tcl_PkgPresent(Tcl_Interp *interp,
813
+ const char *name, const char *version,
814
+ int exact);
815
+/* 272 */
816
+EXTERN CONST84_RETURN char * Tcl_PkgPresentEx(Tcl_Interp *interp,
817
+ const char *name, const char *version,
818
+ int exact, void *clientDataPtr);
819
+/* 273 */
820
+EXTERN int Tcl_PkgProvide(Tcl_Interp *interp, const char *name,
821
+ const char *version);
822
+/* 274 */
823
+EXTERN CONST84_RETURN char * Tcl_PkgRequire(Tcl_Interp *interp,
824
+ const char *name, const char *version,
825
+ int exact);
826
+/* 275 */
827
+EXTERN void Tcl_SetErrorCodeVA(Tcl_Interp *interp,
828
+ va_list argList);
829
+/* 276 */
830
+EXTERN int Tcl_VarEvalVA(Tcl_Interp *interp, va_list argList);
831
+/* 277 */
832
+EXTERN Tcl_Pid Tcl_WaitPid(Tcl_Pid pid, int *statPtr, int options);
833
+/* 278 */
834
+EXTERN void Tcl_PanicVA(const char *format, va_list argList);
835
+/* 279 */
836
+EXTERN void Tcl_GetVersion(int *major, int *minor,
837
+ int *patchLevel, int *type);
838
+/* 280 */
839
+EXTERN void Tcl_InitMemory(Tcl_Interp *interp);
840
+/* 281 */
841
+EXTERN Tcl_Channel Tcl_StackChannel(Tcl_Interp *interp,
842
+ const Tcl_ChannelType *typePtr,
843
+ ClientData instanceData, int mask,
844
+ Tcl_Channel prevChan);
845
+/* 282 */
846
+EXTERN int Tcl_UnstackChannel(Tcl_Interp *interp,
847
+ Tcl_Channel chan);
848
+/* 283 */
849
+EXTERN Tcl_Channel Tcl_GetStackedChannel(Tcl_Channel chan);
850
+/* 284 */
851
+EXTERN void Tcl_SetMainLoop(Tcl_MainLoopProc *proc);
852
+/* Slot 285 is reserved */
853
+/* 286 */
854
+EXTERN void Tcl_AppendObjToObj(Tcl_Obj *objPtr,
855
+ Tcl_Obj *appendObjPtr);
856
+/* 287 */
857
+EXTERN Tcl_Encoding Tcl_CreateEncoding(const Tcl_EncodingType *typePtr);
858
+/* 288 */
859
+EXTERN void Tcl_CreateThreadExitHandler(Tcl_ExitProc *proc,
860
+ ClientData clientData);
861
+/* 289 */
862
+EXTERN void Tcl_DeleteThreadExitHandler(Tcl_ExitProc *proc,
863
+ ClientData clientData);
864
+/* 290 */
865
+EXTERN void Tcl_DiscardResult(Tcl_SavedResult *statePtr);
866
+/* 291 */
867
+EXTERN int Tcl_EvalEx(Tcl_Interp *interp, const char *script,
868
+ int numBytes, int flags);
869
+/* 292 */
870
+EXTERN int Tcl_EvalObjv(Tcl_Interp *interp, int objc,
871
+ Tcl_Obj *const objv[], int flags);
872
+/* 293 */
873
+EXTERN int Tcl_EvalObjEx(Tcl_Interp *interp, Tcl_Obj *objPtr,
874
+ int flags);
875
+/* 294 */
876
+EXTERN void Tcl_ExitThread(int status);
877
+/* 295 */
878
+EXTERN int Tcl_ExternalToUtf(Tcl_Interp *interp,
879
+ Tcl_Encoding encoding, const char *src,
880
+ int srcLen, int flags,
881
+ Tcl_EncodingState *statePtr, char *dst,
882
+ int dstLen, int *srcReadPtr,
883
+ int *dstWrotePtr, int *dstCharsPtr);
884
+/* 296 */
885
+EXTERN char * Tcl_ExternalToUtfDString(Tcl_Encoding encoding,
886
+ const char *src, int srcLen,
887
+ Tcl_DString *dsPtr);
888
+/* 297 */
889
+EXTERN void Tcl_FinalizeThread(void);
890
+/* 298 */
891
+EXTERN void Tcl_FinalizeNotifier(ClientData clientData);
892
+/* 299 */
893
+EXTERN void Tcl_FreeEncoding(Tcl_Encoding encoding);
894
+/* 300 */
895
+EXTERN Tcl_ThreadId Tcl_GetCurrentThread(void);
896
+/* 301 */
897
+EXTERN Tcl_Encoding Tcl_GetEncoding(Tcl_Interp *interp, const char *name);
898
+/* 302 */
899
+EXTERN CONST84_RETURN char * Tcl_GetEncodingName(Tcl_Encoding encoding);
900
+/* 303 */
901
+EXTERN void Tcl_GetEncodingNames(Tcl_Interp *interp);
902
+/* 304 */
903
+EXTERN int Tcl_GetIndexFromObjStruct(Tcl_Interp *interp,
904
+ Tcl_Obj *objPtr, const void *tablePtr,
905
+ int offset, const char *msg, int flags,
906
+ int *indexPtr);
907
+/* 305 */
908
+EXTERN void * Tcl_GetThreadData(Tcl_ThreadDataKey *keyPtr,
909
+ int size);
910
+/* 306 */
911
+EXTERN Tcl_Obj * Tcl_GetVar2Ex(Tcl_Interp *interp, const char *part1,
912
+ const char *part2, int flags);
913
+/* 307 */
914
+EXTERN ClientData Tcl_InitNotifier(void);
915
+/* 308 */
916
+EXTERN void Tcl_MutexLock(Tcl_Mutex *mutexPtr);
917
+/* 309 */
918
+EXTERN void Tcl_MutexUnlock(Tcl_Mutex *mutexPtr);
919
+/* 310 */
920
+EXTERN void Tcl_ConditionNotify(Tcl_Condition *condPtr);
921
+/* 311 */
922
+EXTERN void Tcl_ConditionWait(Tcl_Condition *condPtr,
923
+ Tcl_Mutex *mutexPtr, const Tcl_Time *timePtr);
924
+/* 312 */
925
+EXTERN int Tcl_NumUtfChars(const char *src, int length);
926
+/* 313 */
927
+EXTERN int Tcl_ReadChars(Tcl_Channel channel, Tcl_Obj *objPtr,
928
+ int charsToRead, int appendFlag);
929
+/* 314 */
930
+EXTERN void Tcl_RestoreResult(Tcl_Interp *interp,
931
+ Tcl_SavedResult *statePtr);
932
+/* 315 */
933
+EXTERN void Tcl_SaveResult(Tcl_Interp *interp,
934
+ Tcl_SavedResult *statePtr);
935
+/* 316 */
936
+EXTERN int Tcl_SetSystemEncoding(Tcl_Interp *interp,
937
+ const char *name);
938
+/* 317 */
939
+EXTERN Tcl_Obj * Tcl_SetVar2Ex(Tcl_Interp *interp, const char *part1,
940
+ const char *part2, Tcl_Obj *newValuePtr,
941
+ int flags);
942
+/* 318 */
943
+EXTERN void Tcl_ThreadAlert(Tcl_ThreadId threadId);
944
+/* 319 */
945
+EXTERN void Tcl_ThreadQueueEvent(Tcl_ThreadId threadId,
946
+ Tcl_Event *evPtr, Tcl_QueuePosition position);
947
+/* 320 */
948
+EXTERN Tcl_UniChar Tcl_UniCharAtIndex(const char *src, int index);
949
+/* 321 */
950
+EXTERN Tcl_UniChar Tcl_UniCharToLower(int ch);
951
+/* 322 */
952
+EXTERN Tcl_UniChar Tcl_UniCharToTitle(int ch);
953
+/* 323 */
954
+EXTERN Tcl_UniChar Tcl_UniCharToUpper(int ch);
955
+/* 324 */
956
+EXTERN int Tcl_UniCharToUtf(int ch, char *buf);
957
+/* 325 */
958
+EXTERN CONST84_RETURN char * Tcl_UtfAtIndex(const char *src, int index);
959
+/* 326 */
960
+EXTERN int Tcl_UtfCharComplete(const char *src, int length);
961
+/* 327 */
962
+EXTERN int Tcl_UtfBackslash(const char *src, int *readPtr,
963
+ char *dst);
964
+/* 328 */
965
+EXTERN CONST84_RETURN char * Tcl_UtfFindFirst(const char *src, int ch);
966
+/* 329 */
967
+EXTERN CONST84_RETURN char * Tcl_UtfFindLast(const char *src, int ch);
968
+/* 330 */
969
+EXTERN CONST84_RETURN char * Tcl_UtfNext(const char *src);
970
+/* 331 */
971
+EXTERN CONST84_RETURN char * Tcl_UtfPrev(const char *src, const char *start);
972
+/* 332 */
973
+EXTERN int Tcl_UtfToExternal(Tcl_Interp *interp,
974
+ Tcl_Encoding encoding, const char *src,
975
+ int srcLen, int flags,
976
+ Tcl_EncodingState *statePtr, char *dst,
977
+ int dstLen, int *srcReadPtr,
978
+ int *dstWrotePtr, int *dstCharsPtr);
979
+/* 333 */
980
+EXTERN char * Tcl_UtfToExternalDString(Tcl_Encoding encoding,
981
+ const char *src, int srcLen,
982
+ Tcl_DString *dsPtr);
983
+/* 334 */
984
+EXTERN int Tcl_UtfToLower(char *src);
985
+/* 335 */
986
+EXTERN int Tcl_UtfToTitle(char *src);
987
+/* 336 */
988
+EXTERN int Tcl_UtfToUniChar(const char *src, Tcl_UniChar *chPtr);
989
+/* 337 */
990
+EXTERN int Tcl_UtfToUpper(char *src);
991
+/* 338 */
992
+EXTERN int Tcl_WriteChars(Tcl_Channel chan, const char *src,
993
+ int srcLen);
994
+/* 339 */
995
+EXTERN int Tcl_WriteObj(Tcl_Channel chan, Tcl_Obj *objPtr);
996
+/* 340 */
997
+EXTERN char * Tcl_GetString(Tcl_Obj *objPtr);
998
+/* 341 */
999
+EXTERN CONST84_RETURN char * Tcl_GetDefaultEncodingDir(void);
1000
+/* 342 */
1001
+EXTERN void Tcl_SetDefaultEncodingDir(const char *path);
1002
+/* 343 */
1003
+EXTERN void Tcl_AlertNotifier(ClientData clientData);
1004
+/* 344 */
1005
+EXTERN void Tcl_ServiceModeHook(int mode);
1006
+/* 345 */
1007
+EXTERN int Tcl_UniCharIsAlnum(int ch);
1008
+/* 346 */
1009
+EXTERN int Tcl_UniCharIsAlpha(int ch);
1010
+/* 347 */
1011
+EXTERN int Tcl_UniCharIsDigit(int ch);
1012
+/* 348 */
1013
+EXTERN int Tcl_UniCharIsLower(int ch);
1014
+/* 349 */
1015
+EXTERN int Tcl_UniCharIsSpace(int ch);
1016
+/* 350 */
1017
+EXTERN int Tcl_UniCharIsUpper(int ch);
1018
+/* 351 */
1019
+EXTERN int Tcl_UniCharIsWordChar(int ch);
1020
+/* 352 */
1021
+EXTERN int Tcl_UniCharLen(const Tcl_UniChar *uniStr);
1022
+/* 353 */
1023
+EXTERN int Tcl_UniCharNcmp(const Tcl_UniChar *ucs,
1024
+ const Tcl_UniChar *uct,
1025
+ unsigned long numChars);
1026
+/* 354 */
1027
+EXTERN char * Tcl_UniCharToUtfDString(const Tcl_UniChar *uniStr,
1028
+ int uniLength, Tcl_DString *dsPtr);
1029
+/* 355 */
1030
+EXTERN Tcl_UniChar * Tcl_UtfToUniCharDString(const char *src, int length,
1031
+ Tcl_DString *dsPtr);
1032
+/* 356 */
1033
+EXTERN Tcl_RegExp Tcl_GetRegExpFromObj(Tcl_Interp *interp,
1034
+ Tcl_Obj *patObj, int flags);
1035
+/* 357 */
1036
+EXTERN Tcl_Obj * Tcl_EvalTokens(Tcl_Interp *interp,
1037
+ Tcl_Token *tokenPtr, int count);
1038
+/* 358 */
1039
+EXTERN void Tcl_FreeParse(Tcl_Parse *parsePtr);
1040
+/* 359 */
1041
+EXTERN void Tcl_LogCommandInfo(Tcl_Interp *interp,
1042
+ const char *script, const char *command,
1043
+ int length);
1044
+/* 360 */
1045
+EXTERN int Tcl_ParseBraces(Tcl_Interp *interp,
1046
+ const char *start, int numBytes,
1047
+ Tcl_Parse *parsePtr, int append,
1048
+ CONST84 char **termPtr);
1049
+/* 361 */
1050
+EXTERN int Tcl_ParseCommand(Tcl_Interp *interp,
1051
+ const char *start, int numBytes, int nested,
1052
+ Tcl_Parse *parsePtr);
1053
+/* 362 */
1054
+EXTERN int Tcl_ParseExpr(Tcl_Interp *interp, const char *start,
1055
+ int numBytes, Tcl_Parse *parsePtr);
1056
+/* 363 */
1057
+EXTERN int Tcl_ParseQuotedString(Tcl_Interp *interp,
1058
+ const char *start, int numBytes,
1059
+ Tcl_Parse *parsePtr, int append,
1060
+ CONST84 char **termPtr);
1061
+/* 364 */
1062
+EXTERN int Tcl_ParseVarName(Tcl_Interp *interp,
1063
+ const char *start, int numBytes,
1064
+ Tcl_Parse *parsePtr, int append);
1065
+/* 365 */
1066
+EXTERN char * Tcl_GetCwd(Tcl_Interp *interp, Tcl_DString *cwdPtr);
1067
+/* 366 */
1068
+EXTERN int Tcl_Chdir(const char *dirName);
1069
+/* 367 */
1070
+EXTERN int Tcl_Access(const char *path, int mode);
1071
+/* 368 */
1072
+EXTERN int Tcl_Stat(const char *path, struct stat *bufPtr);
1073
+/* 369 */
1074
+EXTERN int Tcl_UtfNcmp(const char *s1, const char *s2,
1075
+ unsigned long n);
1076
+/* 370 */
1077
+EXTERN int Tcl_UtfNcasecmp(const char *s1, const char *s2,
1078
+ unsigned long n);
1079
+/* 371 */
1080
+EXTERN int Tcl_StringCaseMatch(const char *str,
1081
+ const char *pattern, int nocase);
1082
+/* 372 */
1083
+EXTERN int Tcl_UniCharIsControl(int ch);
1084
+/* 373 */
1085
+EXTERN int Tcl_UniCharIsGraph(int ch);
1086
+/* 374 */
1087
+EXTERN int Tcl_UniCharIsPrint(int ch);
1088
+/* 375 */
1089
+EXTERN int Tcl_UniCharIsPunct(int ch);
1090
+/* 376 */
1091
+EXTERN int Tcl_RegExpExecObj(Tcl_Interp *interp,
1092
+ Tcl_RegExp regexp, Tcl_Obj *textObj,
1093
+ int offset, int nmatches, int flags);
1094
+/* 377 */
1095
+EXTERN void Tcl_RegExpGetInfo(Tcl_RegExp regexp,
1096
+ Tcl_RegExpInfo *infoPtr);
1097
+/* 378 */
1098
+EXTERN Tcl_Obj * Tcl_NewUnicodeObj(const Tcl_UniChar *unicode,
1099
+ int numChars);
1100
+/* 379 */
1101
+EXTERN void Tcl_SetUnicodeObj(Tcl_Obj *objPtr,
1102
+ const Tcl_UniChar *unicode, int numChars);
1103
+/* 380 */
1104
+EXTERN int Tcl_GetCharLength(Tcl_Obj *objPtr);
1105
+/* 381 */
1106
+EXTERN Tcl_UniChar Tcl_GetUniChar(Tcl_Obj *objPtr, int index);
1107
+/* 382 */
1108
+EXTERN Tcl_UniChar * Tcl_GetUnicode(Tcl_Obj *objPtr);
1109
+/* 383 */
1110
+EXTERN Tcl_Obj * Tcl_GetRange(Tcl_Obj *objPtr, int first, int last);
1111
+/* 384 */
1112
+EXTERN void Tcl_AppendUnicodeToObj(Tcl_Obj *objPtr,
1113
+ const Tcl_UniChar *unicode, int length);
1114
+/* 385 */
1115
+EXTERN int Tcl_RegExpMatchObj(Tcl_Interp *interp,
1116
+ Tcl_Obj *textObj, Tcl_Obj *patternObj);
1117
+/* 386 */
1118
+EXTERN void Tcl_SetNotifier(Tcl_NotifierProcs *notifierProcPtr);
1119
+/* 387 */
1120
+EXTERN Tcl_Mutex * Tcl_GetAllocMutex(void);
1121
+/* 388 */
1122
+EXTERN int Tcl_GetChannelNames(Tcl_Interp *interp);
1123
+/* 389 */
1124
+EXTERN int Tcl_GetChannelNamesEx(Tcl_Interp *interp,
1125
+ const char *pattern);
1126
+/* 390 */
1127
+EXTERN int Tcl_ProcObjCmd(ClientData clientData,
1128
+ Tcl_Interp *interp, int objc,
1129
+ Tcl_Obj *const objv[]);
1130
+/* 391 */
1131
+EXTERN void Tcl_ConditionFinalize(Tcl_Condition *condPtr);
1132
+/* 392 */
1133
+EXTERN void Tcl_MutexFinalize(Tcl_Mutex *mutex);
1134
+/* 393 */
1135
+EXTERN int Tcl_CreateThread(Tcl_ThreadId *idPtr,
1136
+ Tcl_ThreadCreateProc *proc,
1137
+ ClientData clientData, int stackSize,
1138
+ int flags);
1139
+/* 394 */
1140
+EXTERN int Tcl_ReadRaw(Tcl_Channel chan, char *dst,
1141
+ int bytesToRead);
1142
+/* 395 */
1143
+EXTERN int Tcl_WriteRaw(Tcl_Channel chan, const char *src,
1144
+ int srcLen);
1145
+/* 396 */
1146
+EXTERN Tcl_Channel Tcl_GetTopChannel(Tcl_Channel chan);
1147
+/* 397 */
1148
+EXTERN int Tcl_ChannelBuffered(Tcl_Channel chan);
1149
+/* 398 */
1150
+EXTERN CONST84_RETURN char * Tcl_ChannelName(
1151
+ const Tcl_ChannelType *chanTypePtr);
1152
+/* 399 */
1153
+EXTERN Tcl_ChannelTypeVersion Tcl_ChannelVersion(
1154
+ const Tcl_ChannelType *chanTypePtr);
1155
+/* 400 */
1156
+EXTERN Tcl_DriverBlockModeProc * Tcl_ChannelBlockModeProc(
1157
+ const Tcl_ChannelType *chanTypePtr);
1158
+/* 401 */
1159
+EXTERN Tcl_DriverCloseProc * Tcl_ChannelCloseProc(
1160
+ const Tcl_ChannelType *chanTypePtr);
1161
+/* 402 */
1162
+EXTERN Tcl_DriverClose2Proc * Tcl_ChannelClose2Proc(
1163
+ const Tcl_ChannelType *chanTypePtr);
1164
+/* 403 */
1165
+EXTERN Tcl_DriverInputProc * Tcl_ChannelInputProc(
1166
+ const Tcl_ChannelType *chanTypePtr);
1167
+/* 404 */
1168
+EXTERN Tcl_DriverOutputProc * Tcl_ChannelOutputProc(
1169
+ const Tcl_ChannelType *chanTypePtr);
1170
+/* 405 */
1171
+EXTERN Tcl_DriverSeekProc * Tcl_ChannelSeekProc(
1172
+ const Tcl_ChannelType *chanTypePtr);
1173
+/* 406 */
1174
+EXTERN Tcl_DriverSetOptionProc * Tcl_ChannelSetOptionProc(
1175
+ const Tcl_ChannelType *chanTypePtr);
1176
+/* 407 */
1177
+EXTERN Tcl_DriverGetOptionProc * Tcl_ChannelGetOptionProc(
1178
+ const Tcl_ChannelType *chanTypePtr);
1179
+/* 408 */
1180
+EXTERN Tcl_DriverWatchProc * Tcl_ChannelWatchProc(
1181
+ const Tcl_ChannelType *chanTypePtr);
1182
+/* 409 */
1183
+EXTERN Tcl_DriverGetHandleProc * Tcl_ChannelGetHandleProc(
1184
+ const Tcl_ChannelType *chanTypePtr);
1185
+/* 410 */
1186
+EXTERN Tcl_DriverFlushProc * Tcl_ChannelFlushProc(
1187
+ const Tcl_ChannelType *chanTypePtr);
1188
+/* 411 */
1189
+EXTERN Tcl_DriverHandlerProc * Tcl_ChannelHandlerProc(
1190
+ const Tcl_ChannelType *chanTypePtr);
1191
+/* 412 */
1192
+EXTERN int Tcl_JoinThread(Tcl_ThreadId threadId, int *result);
1193
+/* 413 */
1194
+EXTERN int Tcl_IsChannelShared(Tcl_Channel channel);
1195
+/* 414 */
1196
+EXTERN int Tcl_IsChannelRegistered(Tcl_Interp *interp,
1197
+ Tcl_Channel channel);
1198
+/* 415 */
1199
+EXTERN void Tcl_CutChannel(Tcl_Channel channel);
1200
+/* 416 */
1201
+EXTERN void Tcl_SpliceChannel(Tcl_Channel channel);
1202
+/* 417 */
1203
+EXTERN void Tcl_ClearChannelHandlers(Tcl_Channel channel);
1204
+/* 418 */
1205
+EXTERN int Tcl_IsChannelExisting(const char *channelName);
1206
+/* 419 */
1207
+EXTERN int Tcl_UniCharNcasecmp(const Tcl_UniChar *ucs,
1208
+ const Tcl_UniChar *uct,
1209
+ unsigned long numChars);
1210
+/* 420 */
1211
+EXTERN int Tcl_UniCharCaseMatch(const Tcl_UniChar *uniStr,
1212
+ const Tcl_UniChar *uniPattern, int nocase);
1213
+/* 421 */
1214
+EXTERN Tcl_HashEntry * Tcl_FindHashEntry(Tcl_HashTable *tablePtr,
1215
+ const void *key);
1216
+/* 422 */
1217
+EXTERN Tcl_HashEntry * Tcl_CreateHashEntry(Tcl_HashTable *tablePtr,
1218
+ const void *key, int *newPtr);
1219
+/* 423 */
1220
+EXTERN void Tcl_InitCustomHashTable(Tcl_HashTable *tablePtr,
1221
+ int keyType, const Tcl_HashKeyType *typePtr);
1222
+/* 424 */
1223
+EXTERN void Tcl_InitObjHashTable(Tcl_HashTable *tablePtr);
1224
+/* 425 */
1225
+EXTERN ClientData Tcl_CommandTraceInfo(Tcl_Interp *interp,
1226
+ const char *varName, int flags,
1227
+ Tcl_CommandTraceProc *procPtr,
1228
+ ClientData prevClientData);
1229
+/* 426 */
1230
+EXTERN int Tcl_TraceCommand(Tcl_Interp *interp,
1231
+ const char *varName, int flags,
1232
+ Tcl_CommandTraceProc *proc,
1233
+ ClientData clientData);
1234
+/* 427 */
1235
+EXTERN void Tcl_UntraceCommand(Tcl_Interp *interp,
1236
+ const char *varName, int flags,
1237
+ Tcl_CommandTraceProc *proc,
1238
+ ClientData clientData);
1239
+/* 428 */
1240
+EXTERN char * Tcl_AttemptAlloc(unsigned int size);
1241
+/* 429 */
1242
+EXTERN char * Tcl_AttemptDbCkalloc(unsigned int size,
1243
+ const char *file, int line);
1244
+/* 430 */
1245
+EXTERN char * Tcl_AttemptRealloc(char *ptr, unsigned int size);
1246
+/* 431 */
1247
+EXTERN char * Tcl_AttemptDbCkrealloc(char *ptr, unsigned int size,
1248
+ const char *file, int line);
1249
+/* 432 */
1250
+EXTERN int Tcl_AttemptSetObjLength(Tcl_Obj *objPtr, int length);
1251
+/* 433 */
1252
+EXTERN Tcl_ThreadId Tcl_GetChannelThread(Tcl_Channel channel);
1253
+/* 434 */
1254
+EXTERN Tcl_UniChar * Tcl_GetUnicodeFromObj(Tcl_Obj *objPtr,
1255
+ int *lengthPtr);
1256
+/* 435 */
1257
+EXTERN int Tcl_GetMathFuncInfo(Tcl_Interp *interp,
1258
+ const char *name, int *numArgsPtr,
1259
+ Tcl_ValueType **argTypesPtr,
1260
+ Tcl_MathProc **procPtr,
1261
+ ClientData *clientDataPtr);
1262
+/* 436 */
1263
+EXTERN Tcl_Obj * Tcl_ListMathFuncs(Tcl_Interp *interp,
1264
+ const char *pattern);
1265
+/* 437 */
1266
+EXTERN Tcl_Obj * Tcl_SubstObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
1267
+ int flags);
1268
+/* 438 */
1269
+EXTERN int Tcl_DetachChannel(Tcl_Interp *interp,
1270
+ Tcl_Channel channel);
1271
+/* 439 */
1272
+EXTERN int Tcl_IsStandardChannel(Tcl_Channel channel);
1273
+/* 440 */
1274
+EXTERN int Tcl_FSCopyFile(Tcl_Obj *srcPathPtr,
1275
+ Tcl_Obj *destPathPtr);
1276
+/* 441 */
1277
+EXTERN int Tcl_FSCopyDirectory(Tcl_Obj *srcPathPtr,
1278
+ Tcl_Obj *destPathPtr, Tcl_Obj **errorPtr);
1279
+/* 442 */
1280
+EXTERN int Tcl_FSCreateDirectory(Tcl_Obj *pathPtr);
1281
+/* 443 */
1282
+EXTERN int Tcl_FSDeleteFile(Tcl_Obj *pathPtr);
1283
+/* 444 */
1284
+EXTERN int Tcl_FSLoadFile(Tcl_Interp *interp, Tcl_Obj *pathPtr,
1285
+ const char *sym1, const char *sym2,
1286
+ Tcl_PackageInitProc **proc1Ptr,
1287
+ Tcl_PackageInitProc **proc2Ptr,
1288
+ Tcl_LoadHandle *handlePtr,
1289
+ Tcl_FSUnloadFileProc **unloadProcPtr);
1290
+/* 445 */
1291
+EXTERN int Tcl_FSMatchInDirectory(Tcl_Interp *interp,
1292
+ Tcl_Obj *result, Tcl_Obj *pathPtr,
1293
+ const char *pattern, Tcl_GlobTypeData *types);
1294
+/* 446 */
1295
+EXTERN Tcl_Obj * Tcl_FSLink(Tcl_Obj *pathPtr, Tcl_Obj *toPtr,
1296
+ int linkAction);
1297
+/* 447 */
1298
+EXTERN int Tcl_FSRemoveDirectory(Tcl_Obj *pathPtr,
1299
+ int recursive, Tcl_Obj **errorPtr);
1300
+/* 448 */
1301
+EXTERN int Tcl_FSRenameFile(Tcl_Obj *srcPathPtr,
1302
+ Tcl_Obj *destPathPtr);
1303
+/* 449 */
1304
+EXTERN int Tcl_FSLstat(Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1305
+/* 450 */
1306
+EXTERN int Tcl_FSUtime(Tcl_Obj *pathPtr, struct utimbuf *tval);
1307
+/* 451 */
1308
+EXTERN int Tcl_FSFileAttrsGet(Tcl_Interp *interp, int index,
1309
+ Tcl_Obj *pathPtr, Tcl_Obj **objPtrRef);
1310
+/* 452 */
1311
+EXTERN int Tcl_FSFileAttrsSet(Tcl_Interp *interp, int index,
1312
+ Tcl_Obj *pathPtr, Tcl_Obj *objPtr);
1313
+/* 453 */
1314
+EXTERN const char *CONST86 * Tcl_FSFileAttrStrings(Tcl_Obj *pathPtr,
1315
+ Tcl_Obj **objPtrRef);
1316
+/* 454 */
1317
+EXTERN int Tcl_FSStat(Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1318
+/* 455 */
1319
+EXTERN int Tcl_FSAccess(Tcl_Obj *pathPtr, int mode);
1320
+/* 456 */
1321
+EXTERN Tcl_Channel Tcl_FSOpenFileChannel(Tcl_Interp *interp,
1322
+ Tcl_Obj *pathPtr, const char *modeString,
1323
+ int permissions);
1324
+/* 457 */
1325
+EXTERN Tcl_Obj * Tcl_FSGetCwd(Tcl_Interp *interp);
1326
+/* 458 */
1327
+EXTERN int Tcl_FSChdir(Tcl_Obj *pathPtr);
1328
+/* 459 */
1329
+EXTERN int Tcl_FSConvertToPathType(Tcl_Interp *interp,
1330
+ Tcl_Obj *pathPtr);
1331
+/* 460 */
1332
+EXTERN Tcl_Obj * Tcl_FSJoinPath(Tcl_Obj *listObj, int elements);
1333
+/* 461 */
1334
+EXTERN Tcl_Obj * Tcl_FSSplitPath(Tcl_Obj *pathPtr, int *lenPtr);
1335
+/* 462 */
1336
+EXTERN int Tcl_FSEqualPaths(Tcl_Obj *firstPtr,
1337
+ Tcl_Obj *secondPtr);
1338
+/* 463 */
1339
+EXTERN Tcl_Obj * Tcl_FSGetNormalizedPath(Tcl_Interp *interp,
1340
+ Tcl_Obj *pathPtr);
1341
+/* 464 */
1342
+EXTERN Tcl_Obj * Tcl_FSJoinToPath(Tcl_Obj *pathPtr, int objc,
1343
+ Tcl_Obj *const objv[]);
1344
+/* 465 */
1345
+EXTERN ClientData Tcl_FSGetInternalRep(Tcl_Obj *pathPtr,
1346
+ const Tcl_Filesystem *fsPtr);
1347
+/* 466 */
1348
+EXTERN Tcl_Obj * Tcl_FSGetTranslatedPath(Tcl_Interp *interp,
1349
+ Tcl_Obj *pathPtr);
1350
+/* 467 */
1351
+EXTERN int Tcl_FSEvalFile(Tcl_Interp *interp, Tcl_Obj *fileName);
1352
+/* 468 */
1353
+EXTERN Tcl_Obj * Tcl_FSNewNativePath(
1354
+ const Tcl_Filesystem *fromFilesystem,
1355
+ ClientData clientData);
1356
+/* 469 */
1357
+EXTERN const void * Tcl_FSGetNativePath(Tcl_Obj *pathPtr);
1358
+/* 470 */
1359
+EXTERN Tcl_Obj * Tcl_FSFileSystemInfo(Tcl_Obj *pathPtr);
1360
+/* 471 */
1361
+EXTERN Tcl_Obj * Tcl_FSPathSeparator(Tcl_Obj *pathPtr);
1362
+/* 472 */
1363
+EXTERN Tcl_Obj * Tcl_FSListVolumes(void);
1364
+/* 473 */
1365
+EXTERN int Tcl_FSRegister(ClientData clientData,
1366
+ const Tcl_Filesystem *fsPtr);
1367
+/* 474 */
1368
+EXTERN int Tcl_FSUnregister(const Tcl_Filesystem *fsPtr);
1369
+/* 475 */
1370
+EXTERN ClientData Tcl_FSData(const Tcl_Filesystem *fsPtr);
1371
+/* 476 */
1372
+EXTERN const char * Tcl_FSGetTranslatedStringPath(Tcl_Interp *interp,
1373
+ Tcl_Obj *pathPtr);
1374
+/* 477 */
1375
+EXTERN CONST86 Tcl_Filesystem * Tcl_FSGetFileSystemForPath(Tcl_Obj *pathPtr);
1376
+/* 478 */
1377
+EXTERN Tcl_PathType Tcl_FSGetPathType(Tcl_Obj *pathPtr);
1378
+/* 479 */
1379
+EXTERN int Tcl_OutputBuffered(Tcl_Channel chan);
1380
+/* 480 */
1381
+EXTERN void Tcl_FSMountsChanged(const Tcl_Filesystem *fsPtr);
1382
+/* 481 */
1383
+EXTERN int Tcl_EvalTokensStandard(Tcl_Interp *interp,
1384
+ Tcl_Token *tokenPtr, int count);
1385
+/* 482 */
1386
+EXTERN void Tcl_GetTime(Tcl_Time *timeBuf);
1387
+/* 483 */
1388
+EXTERN Tcl_Trace Tcl_CreateObjTrace(Tcl_Interp *interp, int level,
1389
+ int flags, Tcl_CmdObjTraceProc *objProc,
1390
+ ClientData clientData,
1391
+ Tcl_CmdObjTraceDeleteProc *delProc);
1392
+/* 484 */
1393
+EXTERN int Tcl_GetCommandInfoFromToken(Tcl_Command token,
1394
+ Tcl_CmdInfo *infoPtr);
1395
+/* 485 */
1396
+EXTERN int Tcl_SetCommandInfoFromToken(Tcl_Command token,
1397
+ const Tcl_CmdInfo *infoPtr);
1398
+/* 486 */
1399
+EXTERN Tcl_Obj * Tcl_DbNewWideIntObj(Tcl_WideInt wideValue,
1400
+ const char *file, int line);
1401
+/* 487 */
1402
+EXTERN int Tcl_GetWideIntFromObj(Tcl_Interp *interp,
1403
+ Tcl_Obj *objPtr, Tcl_WideInt *widePtr);
1404
+/* 488 */
1405
+EXTERN Tcl_Obj * Tcl_NewWideIntObj(Tcl_WideInt wideValue);
1406
+/* 489 */
1407
+EXTERN void Tcl_SetWideIntObj(Tcl_Obj *objPtr,
1408
+ Tcl_WideInt wideValue);
1409
+/* 490 */
1410
+EXTERN Tcl_StatBuf * Tcl_AllocStatBuf(void);
1411
+/* 491 */
1412
+EXTERN Tcl_WideInt Tcl_Seek(Tcl_Channel chan, Tcl_WideInt offset,
1413
+ int mode);
1414
+/* 492 */
1415
+EXTERN Tcl_WideInt Tcl_Tell(Tcl_Channel chan);
1416
+/* 493 */
1417
+EXTERN Tcl_DriverWideSeekProc * Tcl_ChannelWideSeekProc(
1418
+ const Tcl_ChannelType *chanTypePtr);
1419
+/* 494 */
1420
+EXTERN int Tcl_DictObjPut(Tcl_Interp *interp, Tcl_Obj *dictPtr,
1421
+ Tcl_Obj *keyPtr, Tcl_Obj *valuePtr);
1422
+/* 495 */
1423
+EXTERN int Tcl_DictObjGet(Tcl_Interp *interp, Tcl_Obj *dictPtr,
1424
+ Tcl_Obj *keyPtr, Tcl_Obj **valuePtrPtr);
1425
+/* 496 */
1426
+EXTERN int Tcl_DictObjRemove(Tcl_Interp *interp,
1427
+ Tcl_Obj *dictPtr, Tcl_Obj *keyPtr);
1428
+/* 497 */
1429
+EXTERN int Tcl_DictObjSize(Tcl_Interp *interp, Tcl_Obj *dictPtr,
1430
+ int *sizePtr);
1431
+/* 498 */
1432
+EXTERN int Tcl_DictObjFirst(Tcl_Interp *interp,
1433
+ Tcl_Obj *dictPtr, Tcl_DictSearch *searchPtr,
1434
+ Tcl_Obj **keyPtrPtr, Tcl_Obj **valuePtrPtr,
1435
+ int *donePtr);
1436
+/* 499 */
1437
+EXTERN void Tcl_DictObjNext(Tcl_DictSearch *searchPtr,
1438
+ Tcl_Obj **keyPtrPtr, Tcl_Obj **valuePtrPtr,
1439
+ int *donePtr);
1440
+/* 500 */
1441
+EXTERN void Tcl_DictObjDone(Tcl_DictSearch *searchPtr);
1442
+/* 501 */
1443
+EXTERN int Tcl_DictObjPutKeyList(Tcl_Interp *interp,
1444
+ Tcl_Obj *dictPtr, int keyc,
1445
+ Tcl_Obj *const *keyv, Tcl_Obj *valuePtr);
1446
+/* 502 */
1447
+EXTERN int Tcl_DictObjRemoveKeyList(Tcl_Interp *interp,
1448
+ Tcl_Obj *dictPtr, int keyc,
1449
+ Tcl_Obj *const *keyv);
1450
+/* 503 */
1451
+EXTERN Tcl_Obj * Tcl_NewDictObj(void);
1452
+/* 504 */
1453
+EXTERN Tcl_Obj * Tcl_DbNewDictObj(const char *file, int line);
1454
+/* 505 */
1455
+EXTERN void Tcl_RegisterConfig(Tcl_Interp *interp,
1456
+ const char *pkgName,
1457
+ const Tcl_Config *configuration,
1458
+ const char *valEncoding);
1459
+/* 506 */
1460
+EXTERN Tcl_Namespace * Tcl_CreateNamespace(Tcl_Interp *interp,
1461
+ const char *name, ClientData clientData,
1462
+ Tcl_NamespaceDeleteProc *deleteProc);
1463
+/* 507 */
1464
+EXTERN void Tcl_DeleteNamespace(Tcl_Namespace *nsPtr);
1465
+/* 508 */
1466
+EXTERN int Tcl_AppendExportList(Tcl_Interp *interp,
1467
+ Tcl_Namespace *nsPtr, Tcl_Obj *objPtr);
1468
+/* 509 */
1469
+EXTERN int Tcl_Export(Tcl_Interp *interp, Tcl_Namespace *nsPtr,
1470
+ const char *pattern, int resetListFirst);
1471
+/* 510 */
1472
+EXTERN int Tcl_Import(Tcl_Interp *interp, Tcl_Namespace *nsPtr,
1473
+ const char *pattern, int allowOverwrite);
1474
+/* 511 */
1475
+EXTERN int Tcl_ForgetImport(Tcl_Interp *interp,
1476
+ Tcl_Namespace *nsPtr, const char *pattern);
1477
+/* 512 */
1478
+EXTERN Tcl_Namespace * Tcl_GetCurrentNamespace(Tcl_Interp *interp);
1479
+/* 513 */
1480
+EXTERN Tcl_Namespace * Tcl_GetGlobalNamespace(Tcl_Interp *interp);
1481
+/* 514 */
1482
+EXTERN Tcl_Namespace * Tcl_FindNamespace(Tcl_Interp *interp,
1483
+ const char *name,
1484
+ Tcl_Namespace *contextNsPtr, int flags);
1485
+/* 515 */
1486
+EXTERN Tcl_Command Tcl_FindCommand(Tcl_Interp *interp, const char *name,
1487
+ Tcl_Namespace *contextNsPtr, int flags);
1488
+/* 516 */
1489
+EXTERN Tcl_Command Tcl_GetCommandFromObj(Tcl_Interp *interp,
1490
+ Tcl_Obj *objPtr);
1491
+/* 517 */
1492
+EXTERN void Tcl_GetCommandFullName(Tcl_Interp *interp,
1493
+ Tcl_Command command, Tcl_Obj *objPtr);
1494
+/* 518 */
1495
+EXTERN int Tcl_FSEvalFileEx(Tcl_Interp *interp,
1496
+ Tcl_Obj *fileName, const char *encodingName);
1497
+/* 519 */
1498
+EXTERN Tcl_ExitProc * Tcl_SetExitProc(Tcl_ExitProc *proc);
1499
+/* 520 */
1500
+EXTERN void Tcl_LimitAddHandler(Tcl_Interp *interp, int type,
1501
+ Tcl_LimitHandlerProc *handlerProc,
1502
+ ClientData clientData,
1503
+ Tcl_LimitHandlerDeleteProc *deleteProc);
1504
+/* 521 */
1505
+EXTERN void Tcl_LimitRemoveHandler(Tcl_Interp *interp, int type,
1506
+ Tcl_LimitHandlerProc *handlerProc,
1507
+ ClientData clientData);
1508
+/* 522 */
1509
+EXTERN int Tcl_LimitReady(Tcl_Interp *interp);
1510
+/* 523 */
1511
+EXTERN int Tcl_LimitCheck(Tcl_Interp *interp);
1512
+/* 524 */
1513
+EXTERN int Tcl_LimitExceeded(Tcl_Interp *interp);
1514
+/* 525 */
1515
+EXTERN void Tcl_LimitSetCommands(Tcl_Interp *interp,
1516
+ int commandLimit);
1517
+/* 526 */
1518
+EXTERN void Tcl_LimitSetTime(Tcl_Interp *interp,
1519
+ Tcl_Time *timeLimitPtr);
1520
+/* 527 */
1521
+EXTERN void Tcl_LimitSetGranularity(Tcl_Interp *interp, int type,
1522
+ int granularity);
1523
+/* 528 */
1524
+EXTERN int Tcl_LimitTypeEnabled(Tcl_Interp *interp, int type);
1525
+/* 529 */
1526
+EXTERN int Tcl_LimitTypeExceeded(Tcl_Interp *interp, int type);
1527
+/* 530 */
1528
+EXTERN void Tcl_LimitTypeSet(Tcl_Interp *interp, int type);
1529
+/* 531 */
1530
+EXTERN void Tcl_LimitTypeReset(Tcl_Interp *interp, int type);
1531
+/* 532 */
1532
+EXTERN int Tcl_LimitGetCommands(Tcl_Interp *interp);
1533
+/* 533 */
1534
+EXTERN void Tcl_LimitGetTime(Tcl_Interp *interp,
1535
+ Tcl_Time *timeLimitPtr);
1536
+/* 534 */
1537
+EXTERN int Tcl_LimitGetGranularity(Tcl_Interp *interp, int type);
1538
+/* 535 */
1539
+EXTERN Tcl_InterpState Tcl_SaveInterpState(Tcl_Interp *interp, int status);
1540
+/* 536 */
1541
+EXTERN int Tcl_RestoreInterpState(Tcl_Interp *interp,
1542
+ Tcl_InterpState state);
1543
+/* 537 */
1544
+EXTERN void Tcl_DiscardInterpState(Tcl_InterpState state);
1545
+/* 538 */
1546
+EXTERN int Tcl_SetReturnOptions(Tcl_Interp *interp,
1547
+ Tcl_Obj *options);
1548
+/* 539 */
1549
+EXTERN Tcl_Obj * Tcl_GetReturnOptions(Tcl_Interp *interp, int result);
1550
+/* 540 */
1551
+EXTERN int Tcl_IsEnsemble(Tcl_Command token);
1552
+/* 541 */
1553
+EXTERN Tcl_Command Tcl_CreateEnsemble(Tcl_Interp *interp,
1554
+ const char *name,
1555
+ Tcl_Namespace *namespacePtr, int flags);
1556
+/* 542 */
1557
+EXTERN Tcl_Command Tcl_FindEnsemble(Tcl_Interp *interp,
1558
+ Tcl_Obj *cmdNameObj, int flags);
1559
+/* 543 */
1560
+EXTERN int Tcl_SetEnsembleSubcommandList(Tcl_Interp *interp,
1561
+ Tcl_Command token, Tcl_Obj *subcmdList);
1562
+/* 544 */
1563
+EXTERN int Tcl_SetEnsembleMappingDict(Tcl_Interp *interp,
1564
+ Tcl_Command token, Tcl_Obj *mapDict);
1565
+/* 545 */
1566
+EXTERN int Tcl_SetEnsembleUnknownHandler(Tcl_Interp *interp,
1567
+ Tcl_Command token, Tcl_Obj *unknownList);
1568
+/* 546 */
1569
+EXTERN int Tcl_SetEnsembleFlags(Tcl_Interp *interp,
1570
+ Tcl_Command token, int flags);
1571
+/* 547 */
1572
+EXTERN int Tcl_GetEnsembleSubcommandList(Tcl_Interp *interp,
1573
+ Tcl_Command token, Tcl_Obj **subcmdListPtr);
1574
+/* 548 */
1575
+EXTERN int Tcl_GetEnsembleMappingDict(Tcl_Interp *interp,
1576
+ Tcl_Command token, Tcl_Obj **mapDictPtr);
1577
+/* 549 */
1578
+EXTERN int Tcl_GetEnsembleUnknownHandler(Tcl_Interp *interp,
1579
+ Tcl_Command token, Tcl_Obj **unknownListPtr);
1580
+/* 550 */
1581
+EXTERN int Tcl_GetEnsembleFlags(Tcl_Interp *interp,
1582
+ Tcl_Command token, int *flagsPtr);
1583
+/* 551 */
1584
+EXTERN int Tcl_GetEnsembleNamespace(Tcl_Interp *interp,
1585
+ Tcl_Command token,
1586
+ Tcl_Namespace **namespacePtrPtr);
1587
+/* 552 */
1588
+EXTERN void Tcl_SetTimeProc(Tcl_GetTimeProc *getProc,
1589
+ Tcl_ScaleTimeProc *scaleProc,
1590
+ ClientData clientData);
1591
+/* 553 */
1592
+EXTERN void Tcl_QueryTimeProc(Tcl_GetTimeProc **getProc,
1593
+ Tcl_ScaleTimeProc **scaleProc,
1594
+ ClientData *clientData);
1595
+/* 554 */
1596
+EXTERN Tcl_DriverThreadActionProc * Tcl_ChannelThreadActionProc(
1597
+ const Tcl_ChannelType *chanTypePtr);
1598
+/* 555 */
1599
+EXTERN Tcl_Obj * Tcl_NewBignumObj(mp_int *value);
1600
+/* 556 */
1601
+EXTERN Tcl_Obj * Tcl_DbNewBignumObj(mp_int *value, const char *file,
1602
+ int line);
1603
+/* 557 */
1604
+EXTERN void Tcl_SetBignumObj(Tcl_Obj *obj, mp_int *value);
1605
+/* 558 */
1606
+EXTERN int Tcl_GetBignumFromObj(Tcl_Interp *interp,
1607
+ Tcl_Obj *obj, mp_int *value);
1608
+/* 559 */
1609
+EXTERN int Tcl_TakeBignumFromObj(Tcl_Interp *interp,
1610
+ Tcl_Obj *obj, mp_int *value);
1611
+/* 560 */
1612
+EXTERN int Tcl_TruncateChannel(Tcl_Channel chan,
1613
+ Tcl_WideInt length);
1614
+/* 561 */
1615
+EXTERN Tcl_DriverTruncateProc * Tcl_ChannelTruncateProc(
1616
+ const Tcl_ChannelType *chanTypePtr);
1617
+/* 562 */
1618
+EXTERN void Tcl_SetChannelErrorInterp(Tcl_Interp *interp,
1619
+ Tcl_Obj *msg);
1620
+/* 563 */
1621
+EXTERN void Tcl_GetChannelErrorInterp(Tcl_Interp *interp,
1622
+ Tcl_Obj **msg);
1623
+/* 564 */
1624
+EXTERN void Tcl_SetChannelError(Tcl_Channel chan, Tcl_Obj *msg);
1625
+/* 565 */
1626
+EXTERN void Tcl_GetChannelError(Tcl_Channel chan, Tcl_Obj **msg);
1627
+/* 566 */
1628
+EXTERN int Tcl_InitBignumFromDouble(Tcl_Interp *interp,
1629
+ double initval, mp_int *toInit);
1630
+/* 567 */
1631
+EXTERN Tcl_Obj * Tcl_GetNamespaceUnknownHandler(Tcl_Interp *interp,
1632
+ Tcl_Namespace *nsPtr);
1633
+/* 568 */
1634
+EXTERN int Tcl_SetNamespaceUnknownHandler(Tcl_Interp *interp,
1635
+ Tcl_NamespObjSetVar2
1636
+ Tcl_Namespace *nsPtr, Tcl_Obj *handlerPtr);
1637
+/* 569 */
1638
+EXTERN int Tcl_GetEncodingFromObj(Tcl_Interp *interp,
1639
+ Tcl_Obj *objPtr, Tcl_Encoding *encodingPtr);
1640
+/* 570 */
1641
+EXTERN Tcl_Obj * Tcl_GetEncodingSearchPath(void);
1642
+/* 571 */
1643
+EXTERN int Tcl_SetEncodingSearchPath(Tcl_Obj *searchPath);
1644
+/* 572 */
1645
+EXTERN const char * Tcl_GetEncodingNameFromEnvironment(
1646
+ Tcl_DString *bufPtr);
1647
+/* 573 */
1648
+EXTERN int Tcl_PkgRequireProc(Tcl_Interp *interp,
1649
+ const char define Tcl_ObjSEnvironment(
1650
+ Tcl_DString *bufPtr);
1651
+/* 573 */
1652
+EXTERN int Tcl_PkgRequireProc(Tcl_Interp *interp,
1653
+ const char *name, int objc,
1654
+ Tcl_Obj *const objv[], void *clientDataPtr);
1655
+/* 574 */
1656
+EXTERN void Tcl_AppendObjToErrorInfo(Tcl_Interp *interp,
1657
+ Tcl_Obj *objPtr);
1658
+/* 575 */
1659
+EXTERN void Tcl_AppendLimitedToObj(Tcl_Obj *objPtr,
1660
+ const char *bytes, int length, int limit,
1661
+ const char *ellipsis);
1662
+/* 576 */
1663
+EXTERN Tcl_Obj * Tcl_Format(Tcl_Interp *interp, const char *format,
1664
+ int objc, Tcl_Obj *const objv[]);
1665
+/* 577 */
1666
+EXTERN int Tcl_AppendFormatToObj(Tcl_Interp *interp,
1667
+ Tcl_Obj *objPtr, const char *format,
1668
+ int objc, Tcl_Obj *const objv[]);
1669
+/* 578 */
1670
+EXTERN Tcl_Obj * Tcl_ObjPrintf(const char *format, ...) TCL_FORMAT_PRINTF(1, 2);
1671
+/* 579 */
1672
+EXTERN void Tcl_AppendPrintfToObj(Tcl_Obj *objPtr,
1673
+ const char *format, ...) TCL_FORMAT_PRINTF(2, 3);
1674
+/* 580 */
1675
+EXTERN int Tcl_CancelEval(Tcl_Interp *interp,
1676
+ Tcl_Obj *resultObjPtr, ClientData clientData,
1677
+ int flags);
1678
+/* 581 */
1679
+EXTERN int Tcl_Canceled(Tcl_Interp *interp, int flags);
1680
+/* 582 */
1681
+EXTERN int Tcl_CreatePipe(Tcl_Interp *interp,
1682
+ Tcl_Channel *rchan, Tcl_Channel *wchan,
1683
+ int flags);
1684
+/* 583 */
1685
+EXTERN Tcl_Command Tcl_NRCreateCommand(Tcl_Interp *interp,
1686
+ const char *cmdName, Tcl_ObjCmdProc *proc,
1687
+ Tcl_ObjCmdProc *nreProc,
1688
+ ClientData clientData,
1689
+ Tcl_CmdDeleteProc *deleteProc);
1690
+/* 584 */
1691
+EXTERN int Tcl_NREvalObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
1692
+ int flags);
1693
+/* 585 */
1694
+EXTERN int Tcl_NREvalObjv(Tcl_Interp *interp, int objc,
1695
+ Tcl_Obj *const objv[], int flags);
1696
+/* 586 */
1697
+EXTERN int Tcl_NRCmdSwap(Tcl_Interp *interp, Tcl_Command cmd,
1698
+ int objc, Tcl_Obj *const objv[], int flags);
1699
+/* 587 */
1700
+EXTERN void Tcl_NRAddCallback(Tcl_Interp *interp,
1701
+ Tcl_NRPostProc *postProcPtr,
1702
+ ClientData data0, ClientData data1,
1703
+ ClientData data2, ClientData data3);
1704
+/* 588 */
1705
+EXTERN int Tcl_NRCallObjProc(Tcl_Interp *interp,
1706
+ Tcl_ObjCmdProc *objProc,
1707
+ ClientData clientData, int objc,
1708
+ Tcl_Obj *const objv[]);
1709
+/* 589 */
1710
+EXTERN unsigned Tcl_GetFSDeviceFromStat(const Tcl_StatBuf *statPtr);
1711
+/* 590 */
1712
+EXTERN unsigned Tcl_GetFSInodeFromStat(const Tcl_StatBuf *statPtr);
1713
+/* 591 */
1714
+EXTERN unsigned Tcl_GetModeFromStat(const Tcl_StatBuf *statPtr);
1715
+/* 592 */
1716
+EXTERN int Tcl_GetLinkCountFromStat(const Tcl_StatBuf *statPtr);
1717
+/* 593 */
1718
+EXTERN int Tcl_GetUserIdFromStat(const Tcl_StatBuf *statPtr);
1719
+/* 594 */
1720
+EXTERN int Tcl_GetGroupIdFromStat(const Tcl_StatBuf *statPtr);
1721
+/* 595 */
1722
+EXTERN int Tcl_GetDeviceTypeFromStat(const Tcl_StatBuf *statPtr);
1723
+/* 596 */
1724
+EXTERN Tcl_WideInt Tcl_GetAccessTimeFromStat(const Tcl_StatBuf *statPtr);
1725
+/* 597 */
1726
+EXTERN Tcl_WideInt Tcl_GetModificationTimeFromStat(
1727
+ const Tcl_StatBuf *statPtr);
1728
+/* 598 */
1729
+EXTERN Tcl_WideInt Tcl_GetChangeTimeFromStat(const Tcl_StatBuf *statPtr);
1730
+/* 599 */
1731
+EXTERN Tcl_WideUInt Tcl_GetSizeFromStat(const Tcl_StatBuf *statPtr);
1732
+/* 600 */
1733
+EXTERN Tcl_WideUInt Tcl_GetBlocksFromStat(const Tcl_StatBuf *statPtr);
1734
+/* 601 */
1735
+EXTERN unsigned Tcl_GetBlockSizeFromStat(const Tcl_StatBuf *statPtr);
1736
+/* 602 */
1737
+EXTERN int Tcl_SetEnsembleParameterList(Tcl_Interp *interp,
1738
+ Tcl_Command token, Tcl_Obj *paramList);
1739
+/* 603 */
1740
+EXTERN int Tcl_GetEnsembleParameterList(Tcl_Interp *interp,
1741
+ Tcl_Command token, Tcl_Obj **paramListPtr);
1742
+/* 604 */
1743
+EXTERN int Tcl_ParseArgsObjv(Tcl_Interp *interp,
1744
+ const Tcl_ArgvInfo *argTable, int *objcPtr,
1745
+ Tcl_Obj *const *objv, Tcl_Obj ***remObjv);
1746
+/* 605 */
1747
+EXTERN int Tcl_GetErrorLine(Tcl_Interp *interp);
1748
+/* 606 */
1749
+EXTERN void Tcl_SetErrorLine(Tcl_Interp *interp, int lineNum);
1750
+/* 607 */
1751
+EXTERN void Tcl_TransferResult(Tcl_Interp *sourceInterp,
1752
+ int result, Tcl_Interp *targetInterp);
1753
+/* 608 */
1754
+EXTERN int Tcl_InterpActive(Tcl_Interp *interp);
1755
+/* 609 */
1756
+EXTERN void Tcl_BackgroundException(Tcl_Interp *interp, int code);
1757
+/* 610 */
1758
+EXTERN int Tcl_ZlibDeflate(Tcl_Interp *interp, int format,
1759
+ Tcl_Obj *data, int level,
1760
+ Tcl_Obj *gzipHeaderDictObj);
1761
+/* 611 */
1762
+EXTERN int Tcl_ZlibInflate(Tcl_Interp *interp, int format,
1763
+ Tcl_Obj *data, int buffersize,
1764
+ Tcl_Obj *gzipHeaderDictObj);
1765
+/* 612 */
1766
+EXTERN unsigned int Tcl_ZlibCRC32(unsigned int crc,
1767
+ const unsigned char *buf, int len);
1768
+/* 613 */
1769
+EXTERN unsigned int Tcl_ZlibAdler32(unsigned int adler,
1770
+ const unsigned char *buf, int len);
1771
+/* 614 */
1772
+EXTERN int Tcl_ZlibStreamInit(Tcl_Interp *interp, int mode,
1773
+ int format, int level, Tcl_Obj *dictObj,
1774
+ Tcl_ZlibStream *zshandle);
1775
+/* 615 */
1776
+EXTERN Tcl_Obj * Tcl_ZlibStreamGetCommandName(Tcl_ZlibStream zshandle);
1777
+/* 616 */
1778
+EXTERN int Tcl_ZlibStreamEof(Tcl_ZlibStream zshandle);
1779
+/* 617 */
1780
+EXTERN int Tcl_ZlibStreamChecksum(Tcl_ZlibStream zshandle);
1781
+/* 618 */
1782
+EXTERN int Tcl_ZlibStreamPut(Tcl_ZlibStream zshandle,
1783
+ Tcl_Obj *data, int flush);
1784
+/* 619 */
1785
+EXTERN int Tcl_ZlibStreamGet(Tcl_ZlibStream zshandle,
1786
+ Tcl_Obj *data, int count);
1787
+/*
--- a/compat/tcl-8.6/generic/tclDecls.h
+++ b/compat/tcl-8.6/generic/tclDecls.h
@@ -0,0 +1,1787 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
--- a/compat/tcl-8.6/generic/tclDecls.h
+++ b/compat/tcl-8.6/generic/tclDecls.h
@@ -0,0 +1,1787 @@
1 /*
2 * tclDecls.h --
3 *
4 * Declarations of functions in the platform independent public Tcl API.
5 *
6 * Copyright (c) 1998-1999 by Scriptics Corporation.
7 *
8 * See the file "license.terms" for information on usage and redistribution
9 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
10 */
11
12 #ifndef _TCLDECLS
13 #define _TCLDECLS
14
15 #undef TCL_STORAGE_CLASS
16 #ifdef BUILD_tcl
17 # define TCL_STORAGE_CLASS DLLEXPORT
18 #else
19 # ifdef USE_TCL_STUBS
20 # define TCL_STORAGE_CLASS
21 # else
22 # define TCL_STORAGE_CLASS DLLIMPORT
23 # endif
24 #endif
25
26 /*
27 * WARNING: This file is automatically generated by the tools/genStubs.tcl
28 * script. Any modifications to the function declarations below should be made
29 * in the generic/tcl.decls script.
30 */
31
32 /* !BEGIN!: Do not edit below this line. */
33
34 /*
35 * Exported function declarations:
36 */
37
38 /* 0 */
39 EXTERN int Tcl_PkgProvideEx(Tcl_Interp *interp,
40 const char *name, const char *version,
41 const void *clientData);
42 /* 1 */
43 EXTERN CONST84_RETURN char * Tcl_PkgRequireEx(Tcl_Interp *interp,
44 const char *name, const char *version,
45 int exact, void *clientDataPtr);
46 /* 2 */
47 EXTERN void Tcl_Panic(const char *format, ...) TCL_FORMAT_PRINTF(1, 2);
48 /* 3 */
49 EXTERN char * Tcl_Alloc(unsigned int size);
50 /* 4 */
51 EXTERN void Tcl_Free(char *ptr);
52 /* 5 */
53 EXTERN char * Tcl_Realloc(char *ptr, unsigned int size);
54 /* 6 */
55 EXTERN char * Tcl_DbCkalloc(unsigned int size, const char *file,
56 int line);
57 /* 7 */
58 EXTERN void Tcl_DbCkfree(char *ptr, const char *file, int line);
59 /* 8 */
60 EXTERN char * Tcl_DbCkrealloc(char *ptr, unsigned int size,
61 const char *file, int line);
62 #if !defined(__WIN32__) && !defined(MAC_OSX_TCL) /* UNIX */
63 /* 9 */
64 EXTERN void Tcl_CreateFileHandler(int fd, int mask,
65 Tcl_FileProc *proc, ClientData clientData);
66 #endif /* UNIX */
67 #ifdef MAC_OSX_TCL /* MACOSX */
68 /* 9 */
69 EXTERN void Tcl_CreateFileHandler(int fd, int mask,
70 Tcl_FileProc *proc, ClientData clientData);
71 #endif /* MACOSX */
72 #if !defined(__WIN32__) && !defined(MAC_OSX_TCL) /* UNIX */
73 /* 10 */
74 EXTERN void Tcl_DeleteFileHandler(int fd);
75 #endif /* UNIX */
76 #ifdef MAC_OSX_TCL /* MACOSX */
77 /* 10 */
78 EXTERN void Tcl_DeleteFileHandler(int fd);
79 #endif /* MACOSX */
80 /* 11 */
81 EXTERN void Tcl_SetTimer(const Tcl_Time *timePtr);
82 /* 12 */
83 EXTERN void Tcl_Sleep(int ms);
84 /* 13 */
85 EXTERN int Tcl_WaitForEvent(const Tcl_Time *timePtr);
86 /* 14 */
87 EXTERN int Tcl_AppendAllObjTypes(Tcl_Interp *interp,
88 Tcl_Obj *objPtr);
89 /* 15 */
90 EXTERN void Tcl_AppendStringsToObj(Tcl_Obj *objPtr, ...);
91 /* 16 */
92 EXTERN void Tcl_AppendToObj(Tcl_Obj *objPtr, const char *bytes,
93 int length);
94 /* 17 */
95 EXTERN Tcl_Obj * Tcl_ConcatObj(int objc, Tcl_Obj *const objv[]);
96 /* 18 */
97 EXTERN int Tcl_ConvertToType(Tcl_Interp *interp,
98 Tcl_Obj *objPtr, const Tcl_ObjType *typePtr);
99 /* 19 */
100 EXTERN void Tcl_DbDecrRefCount(Tcl_Obj *objPtr, const char *file,
101 int line);
102 /* 20 */
103 EXTERN void Tcl_DbIncrRefCount(Tcl_Obj *objPtr, const char *file,
104 int line);
105 /* 21 */
106 EXTERN int Tcl_DbIsShared(Tcl_Obj *objPtr, const char *file,
107 int line);
108 /* 22 */
109 EXTERN Tcl_Obj * Tcl_DbNewBooleanObj(int boolValue, const char *file,
110 int line);
111 /* 23 */
112 EXTERN Tcl_Obj * Tcl_DbNewByteArrayObj(const unsigned char *bytes,
113 int length, const char *file, int line);
114 /* 24 */
115 EXTERN Tcl_Obj * Tcl_DbNewDoubleObj(double doubleValue,
116 const char *file, int line);
117 /* 25 */
118 EXTERN Tcl_Obj * Tcl_DbNewListObj(int objc, Tcl_Obj *const *objv,
119 const char *file, int line);
120 /* 26 */
121 EXTERN Tcl_Obj * Tcl_DbNewLongObj(long longValue, const char *file,
122 int line);
123 /* 27 */
124 EXTERN Tcl_Obj * Tcl_DbNewObj(const char *file, int line);
125 /* 28 */
126 EXTERN Tcl_Obj * Tcl_DbNewStringObj(const char *bytes, int length,
127 const char *file, int line);
128 /* 29 */
129 EXTERN Tcl_Obj * Tcl_DuplicateObj(Tcl_Obj *objPtr);
130 /* 30 */
131 EXTERN void TclFreeObj(Tcl_Obj *objPtr);
132 /* 31 */
133 EXTERN int Tcl_GetBoolean(Tcl_Interp *interp, const char *src,
134 int *boolPtr);
135 /* 32 */
136 EXTERN int Tcl_GetBooleanFromObj(Tcl_Interp *interp,
137 Tcl_Obj *objPtr, int *boolPtr);
138 /* 33 */
139 EXTERN unsigned char * Tcl_GetByteArrayFromObj(Tcl_Obj *objPtr,
140 int *lengthPtr);
141 /* 34 */
142 EXTERN int Tcl_GetDouble(Tcl_Interp *interp, const char *src,
143 double *doublePtr);
144 /* 35 */
145 EXTERN int Tcl_GetDoubleFromObj(Tcl_Interp *interp,
146 Tcl_Obj *objPtr, double *doublePtr);
147 /* 36 */
148 EXTERN int Tcl_GetIndexFromObj(Tcl_Interp *interp,
149 Tcl_Obj *objPtr,
150 CONST84 char *const *tablePtr,
151 const char *msg, int flags, int *indexPtr);
152 /* 37 */
153 EXTERN int Tcl_GetInt(Tcl_Interp *interp, const char *src,
154 int *intPtr);
155 /* 38 */
156 EXTERN int Tcl_GetIntFromObj(Tcl_Interp *interp,
157 Tcl_Obj *objPtr, int *intPtr);
158 /* 39 */
159 EXTERN int Tcl_GetLongFromObj(Tcl_Interp *interp,
160 Tcl_Obj *objPtr, long *longPtr);
161 /* 40 */
162 EXTERN CONST86 Tcl_ObjType * Tcl_GetObjType(const char *typeName);
163 /* 41 */
164 EXTERN char * Tcl_GetStringFromObj(Tcl_Obj *objPtr, int *lengthPtr);
165 /* 42 */
166 EXTERN void Tcl_InvalidateStringRep(Tcl_Obj *objPtr);
167 /* 43 */
168 EXTERN int Tcl_ListObjAppendList(Tcl_Interp *interp,
169 Tcl_Obj *listPtr, Tcl_Obj *elemListPtr);
170 /* 44 */
171 EXTERN int Tcl_ListObjAppendElement(Tcl_Interp *interp,
172 Tcl_Obj *listPtr, Tcl_Obj *objPtr);
173 /* 45 */
174 EXTERN int Tcl_ListObjGetElements(Tcl_Interp *interp,
175 Tcl_Obj *listPtr, int *objcPtr,
176 Tcl_Obj ***objvPtr);
177 /* 46 */
178 EXTERN int Tcl_ListObjIndex(Tcl_Interp *interp,
179 Tcl_Obj *listPtr, int index,
180 Tcl_Obj **objPtrPtr);
181 /* 47 */
182 EXTERN int Tcl_ListObjLength(Tcl_Interp *interp,
183 Tcl_Obj *listPtr, int *lengthPtr);
184 /* 48 */
185 EXTERN int Tcl_ListObjReplace(Tcl_Interp *interp,
186 Tcl_Obj *listPtr, int first, int count,
187 int objc, Tcl_Obj *const objv[]);
188 /* 49 */
189 EXTERN Tcl_Obj * Tcl_NewBooleanObj(int boolValue);
190 /* 50 */
191 EXTERN Tcl_Obj * Tcl_NewByteArrayObj(const unsigned char *bytes,
192 int length);
193 /* 51 */
194 EXTERN Tcl_Obj * Tcl_NewDoubleObj(double doubleValue);
195 /* 52 */
196 EXTERN Tcl_Obj * Tcl_NewIntObj(int intValue);
197 /* 53 */
198 EXTERN Tcl_Obj * Tcl_NewListObj(int objc, Tcl_Obj *const objv[]);
199 /* 54 */
200 EXTERN Tcl_Obj * Tcl_NewLongObj(long longValue);
201 /* 55 */
202 EXTERN Tcl_Obj * Tcl_NewObj(void);
203 /* 56 */
204 EXTERN Tcl_Obj * Tcl_NewStringObj(const char *bytes, int length);
205 /* 57 */
206 EXTERN void Tcl_SetBooleanObj(Tcl_Obj *objPtr, int boolValue);
207 /* 58 */
208 EXTERN unsigned char * Tcl_SetByteArrayLength(Tcl_Obj *objPtr, int length);
209 /* 59 */
210 EXTERN void Tcl_SetByteArrayObj(Tcl_Obj *objPtr,
211 const unsigned char *bytes, int length);
212 /* 60 */
213 EXTERN void Tcl_SetDoubleObj(Tcl_Obj *objPtr, double doubleValue);
214 /* 61 */
215 EXTERN void Tcl_SetIntObj(Tcl_Obj *objPtr, int intValue);
216 /* 62 */
217 EXTERN void Tcl_SetListObj(Tcl_Obj *objPtr, int objc,
218 Tcl_Obj *const objv[]);
219 /* 63 */
220 EXTERN void Tcl_SetLongObj(Tcl_Obj *objPtr, long longValue);
221 /* 64 */
222 EXTERN void Tcl_SetObjLength(Tcl_Obj *objPtr, int length);
223 /* 65 */
224 EXTERN void Tcl_SetStringObj(Tcl_Obj *objPtr, const char *bytes,
225 int length);
226 /* 66 */
227 EXTERN void Tcl_AddErrorInfo(Tcl_Interp *interp,
228 const char *message);
229 /* 67 */
230 EXTERN void Tcl_AddObjErrorInfo(Tcl_Interp *interp,
231 const char *message, int length);
232 /* 68 */
233 EXTERN void Tcl_AllowExceptions(Tcl_Interp *interp);
234 /* 69 */
235 EXTERN void Tcl_AppendElement(Tcl_Interp *interp,
236 const char *element);
237 /* 70 */
238 EXTERN void Tcl_AppendResult(Tcl_Interp *interp, ...);
239 /* 71 */
240 EXTERN Tcl_AsyncHandler Tcl_AsyncCreate(Tcl_AsyncProc *proc,
241 ClientData clientData);
242 /* 72 */
243 EXTERN void Tcl_AsyncDelete(Tcl_AsyncHandler async);
244 /* 73 */
245 EXTERN int Tcl_AsyncInvoke(Tcl_Interp *interp, int code);
246 /* 74 */
247 EXTERN void Tcl_AsyncMark(Tcl_AsyncHandler async);
248 /* 75 */
249 EXTERN int Tcl_AsyncReady(void);
250 /* 76 */
251 EXTERN void Tcl_BackgroundError(Tcl_Interp *interp);
252 /* 77 */
253 EXTERN char Tcl_Backslash(const char *src, int *readPtr);
254 /* 78 */
255 EXTERN int Tcl_BadChannelOption(Tcl_Interp *interp,
256 const char *optionName,
257 const char *optionList);
258 /* 79 */
259 EXTERN void Tcl_CallWhenDeleted(Tcl_Interp *interp,
260 Tcl_InterpDeleteProc *proc,
261 ClientData clientData);
262 /* 80 */
263 EXTERN void Tcl_CancelIdleCall(Tcl_IdleProc *idleProc,
264 ClientData clientData);
265 /* 81 */
266 EXTERN int Tcl_Close(Tcl_Interp *interp, Tcl_Channel chan);
267 /* 82 */
268 EXTERN int Tcl_CommandComplete(const char *cmd);
269 /* 83 */
270 EXTERN char * Tcl_Concat(int argc, CONST84 char *const *argv);
271 /* 84 */
272 EXTERN int Tcl_ConvertElement(const char *src, char *dst,
273 int flags);
274 /* 85 */
275 EXTERN int Tcl_ConvertCountedElement(const char *src,
276 int length, char *dst, int flags);
277 /* 86 */
278 EXTERN int Tcl_CreateAlias(Tcl_Interp *slave,
279 const char *slaveCmd, Tcl_Interp *target,
280 const char *targetCmd, int argc,
281 CONST84 char *const *argv);
282 /* 87 */
283 EXTERN int Tcl_CreateAliasObj(Tcl_Interp *slave,
284 const char *slaveCmd, Tcl_Interp *target,
285 const char *targetCmd, int objc,
286 Tcl_Obj *const objv[]);
287 /* 88 */
288 EXTERN Tcl_Channel Tcl_CreateChannel(const Tcl_ChannelType *typePtr,
289 const char *chanName,
290 ClientData instanceData, int mask);
291 /* 89 */
292 EXTERN void Tcl_CreateChannelHandler(Tcl_Channel chan, int mask,
293 Tcl_ChannelProc *proc, ClientData clientData);
294 /* 90 */
295 EXTERN void Tcl_CreateCloseHandler(Tcl_Channel chan,
296 Tcl_CloseProc *proc, ClientData clientData);
297 /* 91 */
298 EXTERN Tcl_Command Tcl_CreateCommand(Tcl_Interp *interp,
299 const char *cmdName, Tcl_CmdProc *proc,
300 ClientData clientData,
301 Tcl_CmdDeleteProc *deleteProc);
302 /* 92 */
303 EXTERN void Tcl_CreateEventSource(Tcl_EventSetupProc *setupProc,
304 Tcl_EventCheckProc *checkProc,
305 ClientData clientData);
306 /* 93 */
307 EXTERN void Tcl_CreateExitHandler(Tcl_ExitProc *proc,
308 ClientData clientData);
309 /* 94 */
310 EXTERN Tcl_Interp * Tcl_CreateInterp(void);
311 /* 95 */
312 EXTERN void Tcl_CreateMathFunc(Tcl_Interp *interp,
313 const char *name, int numArgs,
314 Tcl_ValueType *argTypes, Tcl_MathProc *proc,
315 ClientData clientData);
316 /* 96 */
317 EXTERN Tcl_Command Tcl_CreateObjCommand(Tcl_Interp *interp,
318 const char *cmdName, Tcl_ObjCmdProc *proc,
319 ClientData clientData,
320 Tcl_CmdDeleteProc *deleteProc);
321 /* 97 */
322 EXTERN Tcl_Interp * Tcl_CreateSlave(Tcl_Interp *interp,
323 const char *slaveName, int isSafe);
324 /* 98 */
325 EXTERN Tcl_TimerToken Tcl_CreateTimerHandler(int milliseconds,
326 Tcl_TimerProc *proc, ClientData clientData);
327 /* 99 */
328 EXTERN Tcl_Trace Tcl_CreateTrace(Tcl_Interp *interp, int level,
329 Tcl_CmdTraceProc *proc,
330 ClientData clientData);
331 /* 100 */
332 EXTERN void Tcl_DeleteAssocData(Tcl_Interp *interp,
333 const char *name);
334 /* 101 */
335 EXTERN void Tcl_DeleteChannelHandler(Tcl_Channel chan,
336 Tcl_ChannelProc *proc, ClientData clientData);
337 /* 102 */
338 EXTERN void Tcl_DeleteCloseHandler(Tcl_Channel chan,
339 Tcl_CloseProc *proc, ClientData clientData);
340 /* 103 */
341 EXTERN int Tcl_DeleteCommand(Tcl_Interp *interp,
342 const char *cmdName);
343 /* 104 */
344 EXTERN int Tcl_DeleteCommandFromToken(Tcl_Interp *interp,
345 Tcl_Command command);
346 /* 105 */
347 EXTERN void Tcl_DeleteEvents(Tcl_EventDeleteProc *proc,
348 ClientData clientData);
349 /* 106 */
350 EXTERN void Tcl_DeleteEventSource(Tcl_EventSetupProc *setupProc,
351 Tcl_EventCheckProc *checkProc,
352 ClientData clientData);
353 /* 107 */
354 EXTERN void Tcl_DeleteExitHandler(Tcl_ExitProc *proc,
355 ClientData clientData);
356 /* 108 */
357 EXTERN void Tcl_DeleteHashEntry(Tcl_HashEntry *entryPtr);
358 /* 109 */
359 EXTERN void Tcl_DeleteHashTable(Tcl_HashTable *tablePtr);
360 /* 110 */
361 EXTERN void Tcl_DeleteInterp(Tcl_Interp *interp);
362 /* 111 */
363 EXTERN void Tcl_DetachPids(int numPids, Tcl_Pid *pidPtr);
364 /* 112 */
365 EXTERN void Tcl_DeleteTimerHandler(Tcl_TimerToken token);
366 /* 113 */
367 EXTERN void Tcl_DeleteTrace(Tcl_Interp *interp, Tcl_Trace trace);
368 /* 114 */
369 EXTERN void Tcl_DontCallWhenDeleted(Tcl_Interp *interp,
370 Tcl_InterpDeleteProc *proc,
371 ClientData clientData);
372 /* 115 */
373 EXTERN int Tcl_DoOneEvent(int flags);
374 /* 116 */
375 EXTERN void Tcl_DoWhenIdle(Tcl_IdleProc *proc,
376 ClientData clientData);
377 /* 117 */
378 EXTERN char * Tcl_DStringAppend(Tcl_DString *dsPtr,
379 const char *bytes, int length);
380 /* 118 */
381 EXTERN char * Tcl_DStringAppendElement(Tcl_DString *dsPtr,
382 const char *element);
383 /* 119 */
384 EXTERN void Tcl_DStringEndSublist(Tcl_DString *dsPtr);
385 /* 120 */
386 EXTERN void Tcl_DStringFree(Tcl_DString *dsPtr);
387 /* 121 */
388 EXTERN void Tcl_DStringGetResult(Tcl_Interp *interp,
389 Tcl_DString *dsPtr);
390 /* 122 */
391 EXTERN void Tcl_DStringInit(Tcl_DString *dsPtr);
392 /* 123 */
393 EXTERN void Tcl_DStringResult(Tcl_Interp *interp,
394 Tcl_DString *dsPtr);
395 /* 124 */
396 EXTERN void Tcl_DStringSetLength(Tcl_DString *dsPtr, int length);
397 /* 125 */
398 EXTERN void Tcl_DStringStartSublist(Tcl_DString *dsPtr);
399 /* 126 */
400 EXTERN int Tcl_Eof(Tcl_Channel chan);
401 /* 127 */
402 EXTERN CONST84_RETURN char * Tcl_ErrnoId(void);
403 /* 128 */
404 EXTERN CONST84_RETURN char * Tcl_ErrnoMsg(int err);
405 /* 129 */
406 EXTERN int Tcl_Eval(Tcl_Interp *interp, const char *script);
407 /* 130 */
408 EXTERN int Tcl_EvalFile(Tcl_Interp *interp,
409 const char *fileName);
410 /* 131 */
411 EXTERN int Tcl_EvalObj(Tcl_Interp *interp, Tcl_Obj *objPtr);
412 /* 132 */
413 EXTERN void Tcl_EventuallyFree(ClientData clientData,
414 Tcl_FreeProc *freeProc);
415 /* 133 */
416 EXTERN void Tcl_Exit(int status);
417 /* 134 */
418 EXTERN int Tcl_ExposeCommand(Tcl_Interp *interp,
419 const char *hiddenCmdToken,
420 const char *cmdName);
421 /* 135 */
422 EXTERN int Tcl_ExprBoolean(Tcl_Interp *interp, const char *expr,
423 int *ptr);
424 /* 136 */
425 EXTERN int Tcl_ExprBooleanObj(Tcl_Interp *interp,
426 Tcl_Obj *objPtr, int *ptr);
427 /* 137 */
428 EXTERN int Tcl_ExprDouble(Tcl_Interp *interp, const char *expr,
429 double *ptr);
430 /* 138 */
431 EXTERN int Tcl_ExprDoubleObj(Tcl_Interp *interp,
432 Tcl_Obj *objPtr, double *ptr);
433 /* 139 */
434 EXTERN int Tcl_ExprLong(Tcl_Interp *interp, const char *expr,
435 long *ptr);
436 /* 140 */
437 EXTERN int Tcl_ExprLongObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
438 long *ptr);
439 /* 141 */
440 EXTERN int Tcl_ExprObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
441 Tcl_Obj **resultPtrPtr);
442 /* 142 */
443 EXTERN int Tcl_ExprString(Tcl_Interp *interp, const char *expr);
444 /* 143 */
445 EXTERN void Tcl_Finalize(void);
446 /* 144 */
447 EXTERN void Tcl_FindExecutable(const char *argv0);
448 /* 145 */
449 EXTERN Tcl_HashEntry * Tcl_FirstHashEntry(Tcl_HashTable *tablePtr,
450 Tcl_HashSearch *searchPtr);
451 /* 146 */
452 EXTERN int Tcl_Flush(Tcl_Channel chan);
453 /* 147 */
454 EXTERN void Tcl_FreeResult(Tcl_Interp *interp);
455 /* 148 */
456 EXTERN int Tcl_GetAlias(Tcl_Interp *interp,
457 const char *slaveCmd,
458 Tcl_Interp **targetInterpPtr,
459 CONST84 char **targetCmdPtr, int *argcPtr,
460 CONST84 char ***argvPtr);
461 /* 149 */
462 EXTERN int Tcl_GetAliasObj(Tcl_Interp *interp,
463 const char *slaveCmd,
464 Tcl_Interp **targetInterpPtr,
465 CONST84 char **targetCmdPtr, int *objcPtr,
466 Tcl_Obj ***objv);
467 /* 150 */
468 EXTERN ClientData Tcl_GetAssocData(Tcl_Interp *interp,
469 const char *name,
470 Tcl_InterpDeleteProc **procPtr);
471 /* 151 */
472 EXTERN Tcl_Channel Tcl_GetChannel(Tcl_Interp *interp,
473 const char *chanName, int *modePtr);
474 /* 152 */
475 EXTERN int Tcl_GetChannelBufferSize(Tcl_Channel chan);
476 /* 153 */
477 EXTERN int Tcl_GetChannelHandle(Tcl_Channel chan, int direction,
478 ClientData *handlePtr);
479 /* 154 */
480 EXTERN ClientData Tcl_GetChannelInstanceData(Tcl_Channel chan);
481 /* 155 */
482 EXTERN int Tcl_GetChannelMode(Tcl_Channel chan);
483 /* 156 */
484 EXTERN CONST84_RETURN char * Tcl_GetChannelName(Tcl_Channel chan);
485 /* 157 */
486 EXTERN int Tcl_GetChannelOption(Tcl_Interp *interp,
487 Tcl_Channel chan, const char *optionName,
488 Tcl_DString *dsPtr);
489 /* 158 */
490 EXTERN CONST86 Tcl_ChannelType * Tcl_GetChannelType(Tcl_Channel chan);
491 /* 159 */
492 EXTERN int Tcl_GetCommandInfo(Tcl_Interp *interp,
493 const char *cmdName, Tcl_CmdInfo *infoPtr);
494 /* 160 */
495 EXTERN CONST84_RETURN char * Tcl_GetCommandName(Tcl_Interp *interp,
496 Tcl_Command command);
497 /* 161 */
498 EXTERN int Tcl_GetErrno(void);
499 /* 162 */
500 EXTERN CONST84_RETURN char * Tcl_GetHostName(void);
501 /* 163 */
502 EXTERN int Tcl_GetInterpPath(Tcl_Interp *askInterp,
503 Tcl_Interp *slaveInterp);
504 /* 164 */
505 EXTERN Tcl_Interp * Tcl_GetMaster(Tcl_Interp *interp);
506 /* 165 */
507 EXTERN const char * Tcl_GetNameOfExecutable(void);
508 /* 166 */
509 EXTERN Tcl_Obj * Tcl_GetObjResult(Tcl_Interp *interp);
510 #if !defined(__WIN32__) && !defined(MAC_OSX_TCL) /* UNIX */
511 /* 167 */
512 EXTERN int Tcl_GetOpenFile(Tcl_Interp *interp,
513 const char *chanID, int forWriting,
514 int checkUsage, ClientData *filePtr);
515 #endif /* UNIX */
516 #ifdef MAC_OSX_TCL /* MACOSX */
517 /* 167 */
518 EXTERN int Tcl_GetOpenFile(Tcl_Interp *interp,
519 const char *chanID, int forWriting,
520 int checkUsage, ClientData *filePtr);
521 #endif /* MACOSX */
522 /* 168 */
523 EXTERN Tcl_PathType Tcl_GetPathType(const char *path);
524 /* 169 */
525 EXTERN int Tcl_Gets(Tcl_Channel chan, Tcl_DString *dsPtr);
526 /* 170 */
527 EXTERN int Tcl_GetsObj(Tcl_Channel chan, Tcl_Obj *objPtr);
528 /* 171 */
529 EXTERN int Tcl_GetServiceMode(void);
530 /* 172 */
531 EXTERN Tcl_Interp * Tcl_GetSlave(Tcl_Interp *interp,
532 const char *slaveName);
533 /* 173 */
534 EXTERN Tcl_Channel Tcl_GetStdChannel(int type);
535 /* 174 */
536 EXTERN CONST84_RETURN char * Tcl_GetStringResult(Tcl_Interp *interp);
537 /* 175 */
538 EXTERN CONST84_RETURN char * Tcl_GetVar(Tcl_Interp *interp,
539 const char *varName, int flags);
540 /* 176 */
541 EXTERN CONST84_RETURN char * Tcl_GetVar2(Tcl_Interp *interp,
542 const char *part1, const char *part2,
543 int flags);
544 /* 177 */
545 EXTERN int Tcl_GlobalEval(Tcl_Interp *interp,
546 const char *command);
547 /* 178 */
548 EXTERN int Tcl_GlobalEvalObj(Tcl_Interp *interp,
549 Tcl_Obj *objPtr);
550 /* 179 */
551 EXTERN int Tcl_HideCommand(Tcl_Interp *interp,
552 const char *cmdName,
553 const char *hiddenCmdToken);
554 /* 180 */
555 EXTERN int Tcl_Init(Tcl_Interp *interp);
556 /* 181 */
557 EXTERN void Tcl_InitHashTable(Tcl_HashTable *tablePtr,
558 int keyType);
559 /* 182 */
560 EXTERN int Tcl_InputBlocked(Tcl_Channel chan);
561 /* 183 */
562 EXTERN int Tcl_InputBuffered(Tcl_Channel chan);
563 /* 184 */
564 EXTERN int Tcl_InterpDeleted(Tcl_Interp *interp);
565 /* 185 */
566 EXTERN int Tcl_IsSafe(Tcl_Interp *interp);
567 /* 186 */
568 EXTERN char * Tcl_JoinPath(int argc, CONST84 char *const *argv,
569 Tcl_DString *resultPtr);
570 /* 187 */
571 EXTERN int Tcl_LinkVar(Tcl_Interp *interp, const char *varName,
572 char *addr, int type);
573 /* Slot 188 is reserved */
574 /* 189 */
575 EXTERN Tcl_Channel Tcl_MakeFileChannel(ClientData handle, int mode);
576 /* 190 */
577 EXTERN int Tcl_MakeSafe(Tcl_Interp *interp);
578 /* 191 */
579 EXTERN Tcl_Channel Tcl_MakeTcpClientChannel(ClientData tcpSocket);
580 /* 192 */
581 EXTERN char * Tcl_Merge(int argc, CONST84 char *const *argv);
582 /* 193 */
583 EXTERN Tcl_HashEntry * Tcl_NextHashEntry(Tcl_HashSearch *searchPtr);
584 /* 194 */
585 EXTERN void Tcl_NotifyChannel(Tcl_Channel channel, int mask);
586 /* 195 */
587 EXTERN Tcl_Obj * Tcl_ObjGetVar2(Tcl_Interp *interp, Tcl_Obj *part1Ptr,
588 Tcl_Obj *part2Ptr, int flags);
589 /* 196 */
590 EXTERN Tcl_Obj * Tcl_ObjSetVar2(Tcl_Interp *interp, Tcl_Obj *part1Ptr,
591 Tcl_Obj *part2Ptr, Tcl_Obj *newValuePtr,
592 int flags);
593 /* 197 */
594 EXTERN Tcl_Channel Tcl_OpenCommandChannel(Tcl_Interp *interp, int argc,
595 CONST84 char **argv, int flags);
596 /* 198 */
597 EXTERN Tcl_Channel Tcl_OpenFileChannel(Tcl_Interp *interp,
598 const char *fileName, const char *modeString,
599 int permissions);
600 /* 199 */
601 EXTERN Tcl_Channel Tcl_OpenTcpClient(Tcl_Interp *interp, int port,
602 const char *address, const char *myaddr,
603 int myport, int async);
604 /* 200 */
605 EXTERN Tcl_Channel Tcl_OpenTcpServer(Tcl_Interp *interp, int port,
606 const char *host,
607 Tcl_TcpAcceptProc *acceptProc,
608 ClientData callbackData);
609 /* 201 */
610 EXTERN void Tcl_Preserve(ClientData data);
611 /* 202 */
612 EXTERN void Tcl_PrintDouble(Tcl_Interp *interp, double value,
613 char *dst);
614 /* 203 */
615 EXTERN int Tcl_PutEnv(const char *assignment);
616 /* 204 */
617 EXTERN CONST84_RETURN char * Tcl_PosixError(Tcl_Interp *interp);
618 /* 205 */
619 EXTERN void Tcl_QueueEvent(Tcl_Event *evPtr,
620 Tcl_QueuePosition position);
621 /* 206 */
622 EXTERN int Tcl_Read(Tcl_Channel chan, char *bufPtr, int toRead);
623 /* 207 */
624 EXTERN void Tcl_ReapDetachedProcs(void);
625 /* 208 */
626 EXTERN int Tcl_RecordAndEval(Tcl_Interp *interp,
627 const char *cmd, int flags);
628 /* 209 */
629 EXTERN int Tcl_RecordAndEvalObj(Tcl_Interp *interp,
630 Tcl_Obj *cmdPtr, int flags);
631 /* 210 */
632 EXTERN void Tcl_RegisterChannel(Tcl_Interp *interp,
633 Tcl_Channel chan);
634 /* 211 */
635 EXTERN void Tcl_RegisterObjType(const Tcl_ObjType *typePtr);
636 /* 212 */
637 EXTERN Tcl_RegExp Tcl_RegExpCompile(Tcl_Interp *interp,
638 const char *pattern);
639 /* 213 */
640 EXTERN int Tcl_RegExpExec(Tcl_Interp *interp, Tcl_RegExp regexp,
641 const char *text, const char *start);
642 /* 214 */
643 EXTERN int Tcl_RegExpMatch(Tcl_Interp *interp, const char *text,
644 const char *pattern);
645 /* 215 */
646 EXTERN void Tcl_RegExpRange(Tcl_RegExp regexp, int index,
647 CONST84 char **startPtr,
648 CONST84 char **endPtr);
649 /* 216 */
650 EXTERN void Tcl_Release(ClientData clientData);
651 /* 217 */
652 EXTERN void Tcl_ResetResult(Tcl_Interp *interp);
653 /* 218 */
654 EXTERN int Tcl_ScanElement(const char *src, int *flagPtr);
655 /* 219 */
656 EXTERN int Tcl_ScanCountedElement(const char *src, int length,
657 int *flagPtr);
658 /* 220 */
659 EXTERN int Tcl_SeekOld(Tcl_Channel chan, int offset, int mode);
660 /* 221 */
661 EXTERN int Tcl_ServiceAll(void);
662 /* 222 */
663 EXTERN int Tcl_ServiceEvent(int flags);
664 /* 223 */
665 EXTERN void Tcl_SetAssocData(Tcl_Interp *interp,
666 const char *name, Tcl_InterpDeleteProc *proc,
667 ClientData clientData);
668 /* 224 */
669 EXTERN void Tcl_SetChannelBufferSize(Tcl_Channel chan, int sz);
670 /* 225 */
671 EXTERN int Tcl_SetChannelOption(Tcl_Interp *interp,
672 Tcl_Channel chan, const char *optionName,
673 const char *newValue);
674 /* 226 */
675 EXTERN int Tcl_SetCommandInfo(Tcl_Interp *interp,
676 const char *cmdName,
677 const Tcl_CmdInfo *infoPtr);
678 /* 227 */
679 EXTERN void Tcl_SetErrno(int err);
680 /* 228 */
681 EXTERN void Tcl_SetErrorCode(Tcl_Interp *interp, ...);
682 /* 229 */
683 EXTERN void Tcl_SetMaxBlockTime(const Tcl_Time *timePtr);
684 /* 230 */
685 EXTERN void Tcl_SetPanicProc(Tcl_PanicProc *panicProc);
686 /* 231 */
687 EXTERN int Tcl_SetRecursionLimit(Tcl_Interp *interp, int depth);
688 /* 232 */
689 EXTERN void Tcl_SetResult(Tcl_Interp *interp, char *result,
690 Tcl_FreeProc *freeProc);
691 /* 233 */
692 EXTERN int Tcl_SetServiceMode(int mode);
693 /* 234 */
694 EXTERN void Tcl_SetObjErrorCode(Tcl_Interp *interp,
695 Tcl_Obj *errorObjPtr);
696 /* 235 */
697 EXTERN void Tcl_SetObjResult(Tcl_Interp *interp,
698 Tcl_Obj *resultObjPtr);
699 /* 236 */
700 EXTERN void Tcl_SetStdChannel(Tcl_Channel channel, int type);
701 /* 237 */
702 EXTERN CONST84_RETURN char * Tcl_SetVar(Tcl_Interp *interp,
703 const char *varName, const char *newValue,
704 int flags);
705 /* 238 */
706 EXTERN CONST84_RETURN char * Tcl_SetVar2(Tcl_Interp *interp,
707 const char *part1, const char *part2,
708 const char *newValue, int flags);
709 /* 239 */
710 EXTERN CONST84_RETURN char * Tcl_SignalId(int sig);
711 /* 240 */
712 EXTERN CONST84_RETURN char * Tcl_SignalMsg(int sig);
713 /* 241 */
714 EXTERN void Tcl_SourceRCFile(Tcl_Interp *interp);
715 /* 242 */
716 EXTERN int Tcl_SplitList(Tcl_Interp *interp,
717 const char *listStr, int *argcPtr,
718 CONST84 char ***argvPtr);
719 /* 243 */
720 EXTERN void Tcl_SplitPath(const char *path, int *argcPtr,
721 CONST84 char ***argvPtr);
722 /* 244 */
723 EXTERN void Tcl_StaticPackage(Tcl_Interp *interp,
724 const char *pkgName,
725 Tcl_PackageInitProc *initProc,
726 Tcl_PackageInitProc *safeInitProc);
727 /* 245 */
728 EXTERN int Tcl_StringMatch(const char *str, const char *pattern);
729 /* 246 */
730 EXTERN int Tcl_TellOld(Tcl_Channel chan);
731 /* 247 */
732 EXTERN int Tcl_TraceVar(Tcl_Interp *interp, const char *varName,
733 int flags, Tcl_VarTraceProc *proc,
734 ClientData clientData);
735 /* 248 */
736 EXTERN int Tcl_TraceVar2(Tcl_Interp *interp, const char *part1,
737 const char *part2, int flags,
738 Tcl_VarTraceProc *proc,
739 ClientData clientData);
740 /* 249 */
741 EXTERN char * Tcl_TranslateFileName(Tcl_Interp *interp,
742 const char *name, Tcl_DString *bufferPtr);
743 /* 250 */
744 EXTERN int Tcl_Ungets(Tcl_Channel chan, const char *str,
745 int len, int atHead);
746 /* 251 */
747 EXTERN void Tcl_UnlinkVar(Tcl_Interp *interp,
748 const char *varName);
749 /* 252 */
750 EXTERN int Tcl_UnregisterChannel(Tcl_Interp *interp,
751 Tcl_Channel chan);
752 /* 253 */
753 EXTERN int Tcl_UnsetVar(Tcl_Interp *interp, const char *varName,
754 int flags);
755 /* 254 */
756 EXTERN int Tcl_UnsetVar2(Tcl_Interp *interp, const char *part1,
757 const char *part2, int flags);
758 /* 255 */
759 EXTERN void Tcl_UntraceVar(Tcl_Interp *interp,
760 const char *varName, int flags,
761 Tcl_VarTraceProc *proc,
762 ClientData clientData);
763 /* 256 */
764 EXTERN void Tcl_UntraceVar2(Tcl_Interp *interp,
765 const char *part1, const char *part2,
766 int flags, Tcl_VarTraceProc *proc,
767 ClientData clientData);
768 /* 257 */
769 EXTERN void Tcl_UpdateLinkedVar(Tcl_Interp *interp,
770 const char *varName);
771 /* 258 */
772 EXTERN int Tcl_UpVar(Tcl_Interp *interp, const char *frameName,
773 const char *varName, const char *localName,
774 int flags);
775 /* 259 */
776 EXTERN int Tcl_UpVar2(Tcl_Interp *interp, const char *frameName,
777 const char *part1, const char *part2,
778 const char *localName, int flags);
779 /* 260 */
780 EXTERN int Tcl_VarEval(Tcl_Interp *interp, ...);
781 /* 261 */
782 EXTERN ClientData Tcl_VarTraceInfo(Tcl_Interp *interp,
783 const char *varName, int flags,
784 Tcl_VarTraceProc *procPtr,
785 ClientData prevClientData);
786 /* 262 */
787 EXTERN ClientData Tcl_VarTraceInfo2(Tcl_Interp *interp,
788 const char *part1, const char *part2,
789 int flags, Tcl_VarTraceProc *procPtr,
790 ClientData prevClientData);
791 /* 263 */
792 EXTERN int Tcl_Write(Tcl_Channel chan, const char *s, int slen);
793 /* 264 */
794 EXTERN void Tcl_WrongNumArgs(Tcl_Interp *interp, int objc,
795 Tcl_Obj *const objv[], const char *message);
796 /* 265 */
797 EXTERN int Tcl_DumpActiveMemory(const char *fileName);
798 /* 266 */
799 EXTERN void Tcl_ValidateAllMemory(const char *file, int line);
800 /* 267 */
801 EXTERN void Tcl_AppendResultVA(Tcl_Interp *interp,
802 va_list argList);
803 /* 268 */
804 EXTERN void Tcl_AppendStringsToObjVA(Tcl_Obj *objPtr,
805 va_list argList);
806 /* 269 */
807 EXTERN char * Tcl_HashStats(Tcl_HashTable *tablePtr);
808 /* 270 */
809 EXTERN CONST84_RETURN char * Tcl_ParseVar(Tcl_Interp *interp,
810 const char *start, CONST84 char **termPtr);
811 /* 271 */
812 EXTERN CONST84_RETURN char * Tcl_PkgPresent(Tcl_Interp *interp,
813 const char *name, const char *version,
814 int exact);
815 /* 272 */
816 EXTERN CONST84_RETURN char * Tcl_PkgPresentEx(Tcl_Interp *interp,
817 const char *name, const char *version,
818 int exact, void *clientDataPtr);
819 /* 273 */
820 EXTERN int Tcl_PkgProvide(Tcl_Interp *interp, const char *name,
821 const char *version);
822 /* 274 */
823 EXTERN CONST84_RETURN char * Tcl_PkgRequire(Tcl_Interp *interp,
824 const char *name, const char *version,
825 int exact);
826 /* 275 */
827 EXTERN void Tcl_SetErrorCodeVA(Tcl_Interp *interp,
828 va_list argList);
829 /* 276 */
830 EXTERN int Tcl_VarEvalVA(Tcl_Interp *interp, va_list argList);
831 /* 277 */
832 EXTERN Tcl_Pid Tcl_WaitPid(Tcl_Pid pid, int *statPtr, int options);
833 /* 278 */
834 EXTERN void Tcl_PanicVA(const char *format, va_list argList);
835 /* 279 */
836 EXTERN void Tcl_GetVersion(int *major, int *minor,
837 int *patchLevel, int *type);
838 /* 280 */
839 EXTERN void Tcl_InitMemory(Tcl_Interp *interp);
840 /* 281 */
841 EXTERN Tcl_Channel Tcl_StackChannel(Tcl_Interp *interp,
842 const Tcl_ChannelType *typePtr,
843 ClientData instanceData, int mask,
844 Tcl_Channel prevChan);
845 /* 282 */
846 EXTERN int Tcl_UnstackChannel(Tcl_Interp *interp,
847 Tcl_Channel chan);
848 /* 283 */
849 EXTERN Tcl_Channel Tcl_GetStackedChannel(Tcl_Channel chan);
850 /* 284 */
851 EXTERN void Tcl_SetMainLoop(Tcl_MainLoopProc *proc);
852 /* Slot 285 is reserved */
853 /* 286 */
854 EXTERN void Tcl_AppendObjToObj(Tcl_Obj *objPtr,
855 Tcl_Obj *appendObjPtr);
856 /* 287 */
857 EXTERN Tcl_Encoding Tcl_CreateEncoding(const Tcl_EncodingType *typePtr);
858 /* 288 */
859 EXTERN void Tcl_CreateThreadExitHandler(Tcl_ExitProc *proc,
860 ClientData clientData);
861 /* 289 */
862 EXTERN void Tcl_DeleteThreadExitHandler(Tcl_ExitProc *proc,
863 ClientData clientData);
864 /* 290 */
865 EXTERN void Tcl_DiscardResult(Tcl_SavedResult *statePtr);
866 /* 291 */
867 EXTERN int Tcl_EvalEx(Tcl_Interp *interp, const char *script,
868 int numBytes, int flags);
869 /* 292 */
870 EXTERN int Tcl_EvalObjv(Tcl_Interp *interp, int objc,
871 Tcl_Obj *const objv[], int flags);
872 /* 293 */
873 EXTERN int Tcl_EvalObjEx(Tcl_Interp *interp, Tcl_Obj *objPtr,
874 int flags);
875 /* 294 */
876 EXTERN void Tcl_ExitThread(int status);
877 /* 295 */
878 EXTERN int Tcl_ExternalToUtf(Tcl_Interp *interp,
879 Tcl_Encoding encoding, const char *src,
880 int srcLen, int flags,
881 Tcl_EncodingState *statePtr, char *dst,
882 int dstLen, int *srcReadPtr,
883 int *dstWrotePtr, int *dstCharsPtr);
884 /* 296 */
885 EXTERN char * Tcl_ExternalToUtfDString(Tcl_Encoding encoding,
886 const char *src, int srcLen,
887 Tcl_DString *dsPtr);
888 /* 297 */
889 EXTERN void Tcl_FinalizeThread(void);
890 /* 298 */
891 EXTERN void Tcl_FinalizeNotifier(ClientData clientData);
892 /* 299 */
893 EXTERN void Tcl_FreeEncoding(Tcl_Encoding encoding);
894 /* 300 */
895 EXTERN Tcl_ThreadId Tcl_GetCurrentThread(void);
896 /* 301 */
897 EXTERN Tcl_Encoding Tcl_GetEncoding(Tcl_Interp *interp, const char *name);
898 /* 302 */
899 EXTERN CONST84_RETURN char * Tcl_GetEncodingName(Tcl_Encoding encoding);
900 /* 303 */
901 EXTERN void Tcl_GetEncodingNames(Tcl_Interp *interp);
902 /* 304 */
903 EXTERN int Tcl_GetIndexFromObjStruct(Tcl_Interp *interp,
904 Tcl_Obj *objPtr, const void *tablePtr,
905 int offset, const char *msg, int flags,
906 int *indexPtr);
907 /* 305 */
908 EXTERN void * Tcl_GetThreadData(Tcl_ThreadDataKey *keyPtr,
909 int size);
910 /* 306 */
911 EXTERN Tcl_Obj * Tcl_GetVar2Ex(Tcl_Interp *interp, const char *part1,
912 const char *part2, int flags);
913 /* 307 */
914 EXTERN ClientData Tcl_InitNotifier(void);
915 /* 308 */
916 EXTERN void Tcl_MutexLock(Tcl_Mutex *mutexPtr);
917 /* 309 */
918 EXTERN void Tcl_MutexUnlock(Tcl_Mutex *mutexPtr);
919 /* 310 */
920 EXTERN void Tcl_ConditionNotify(Tcl_Condition *condPtr);
921 /* 311 */
922 EXTERN void Tcl_ConditionWait(Tcl_Condition *condPtr,
923 Tcl_Mutex *mutexPtr, const Tcl_Time *timePtr);
924 /* 312 */
925 EXTERN int Tcl_NumUtfChars(const char *src, int length);
926 /* 313 */
927 EXTERN int Tcl_ReadChars(Tcl_Channel channel, Tcl_Obj *objPtr,
928 int charsToRead, int appendFlag);
929 /* 314 */
930 EXTERN void Tcl_RestoreResult(Tcl_Interp *interp,
931 Tcl_SavedResult *statePtr);
932 /* 315 */
933 EXTERN void Tcl_SaveResult(Tcl_Interp *interp,
934 Tcl_SavedResult *statePtr);
935 /* 316 */
936 EXTERN int Tcl_SetSystemEncoding(Tcl_Interp *interp,
937 const char *name);
938 /* 317 */
939 EXTERN Tcl_Obj * Tcl_SetVar2Ex(Tcl_Interp *interp, const char *part1,
940 const char *part2, Tcl_Obj *newValuePtr,
941 int flags);
942 /* 318 */
943 EXTERN void Tcl_ThreadAlert(Tcl_ThreadId threadId);
944 /* 319 */
945 EXTERN void Tcl_ThreadQueueEvent(Tcl_ThreadId threadId,
946 Tcl_Event *evPtr, Tcl_QueuePosition position);
947 /* 320 */
948 EXTERN Tcl_UniChar Tcl_UniCharAtIndex(const char *src, int index);
949 /* 321 */
950 EXTERN Tcl_UniChar Tcl_UniCharToLower(int ch);
951 /* 322 */
952 EXTERN Tcl_UniChar Tcl_UniCharToTitle(int ch);
953 /* 323 */
954 EXTERN Tcl_UniChar Tcl_UniCharToUpper(int ch);
955 /* 324 */
956 EXTERN int Tcl_UniCharToUtf(int ch, char *buf);
957 /* 325 */
958 EXTERN CONST84_RETURN char * Tcl_UtfAtIndex(const char *src, int index);
959 /* 326 */
960 EXTERN int Tcl_UtfCharComplete(const char *src, int length);
961 /* 327 */
962 EXTERN int Tcl_UtfBackslash(const char *src, int *readPtr,
963 char *dst);
964 /* 328 */
965 EXTERN CONST84_RETURN char * Tcl_UtfFindFirst(const char *src, int ch);
966 /* 329 */
967 EXTERN CONST84_RETURN char * Tcl_UtfFindLast(const char *src, int ch);
968 /* 330 */
969 EXTERN CONST84_RETURN char * Tcl_UtfNext(const char *src);
970 /* 331 */
971 EXTERN CONST84_RETURN char * Tcl_UtfPrev(const char *src, const char *start);
972 /* 332 */
973 EXTERN int Tcl_UtfToExternal(Tcl_Interp *interp,
974 Tcl_Encoding encoding, const char *src,
975 int srcLen, int flags,
976 Tcl_EncodingState *statePtr, char *dst,
977 int dstLen, int *srcReadPtr,
978 int *dstWrotePtr, int *dstCharsPtr);
979 /* 333 */
980 EXTERN char * Tcl_UtfToExternalDString(Tcl_Encoding encoding,
981 const char *src, int srcLen,
982 Tcl_DString *dsPtr);
983 /* 334 */
984 EXTERN int Tcl_UtfToLower(char *src);
985 /* 335 */
986 EXTERN int Tcl_UtfToTitle(char *src);
987 /* 336 */
988 EXTERN int Tcl_UtfToUniChar(const char *src, Tcl_UniChar *chPtr);
989 /* 337 */
990 EXTERN int Tcl_UtfToUpper(char *src);
991 /* 338 */
992 EXTERN int Tcl_WriteChars(Tcl_Channel chan, const char *src,
993 int srcLen);
994 /* 339 */
995 EXTERN int Tcl_WriteObj(Tcl_Channel chan, Tcl_Obj *objPtr);
996 /* 340 */
997 EXTERN char * Tcl_GetString(Tcl_Obj *objPtr);
998 /* 341 */
999 EXTERN CONST84_RETURN char * Tcl_GetDefaultEncodingDir(void);
1000 /* 342 */
1001 EXTERN void Tcl_SetDefaultEncodingDir(const char *path);
1002 /* 343 */
1003 EXTERN void Tcl_AlertNotifier(ClientData clientData);
1004 /* 344 */
1005 EXTERN void Tcl_ServiceModeHook(int mode);
1006 /* 345 */
1007 EXTERN int Tcl_UniCharIsAlnum(int ch);
1008 /* 346 */
1009 EXTERN int Tcl_UniCharIsAlpha(int ch);
1010 /* 347 */
1011 EXTERN int Tcl_UniCharIsDigit(int ch);
1012 /* 348 */
1013 EXTERN int Tcl_UniCharIsLower(int ch);
1014 /* 349 */
1015 EXTERN int Tcl_UniCharIsSpace(int ch);
1016 /* 350 */
1017 EXTERN int Tcl_UniCharIsUpper(int ch);
1018 /* 351 */
1019 EXTERN int Tcl_UniCharIsWordChar(int ch);
1020 /* 352 */
1021 EXTERN int Tcl_UniCharLen(const Tcl_UniChar *uniStr);
1022 /* 353 */
1023 EXTERN int Tcl_UniCharNcmp(const Tcl_UniChar *ucs,
1024 const Tcl_UniChar *uct,
1025 unsigned long numChars);
1026 /* 354 */
1027 EXTERN char * Tcl_UniCharToUtfDString(const Tcl_UniChar *uniStr,
1028 int uniLength, Tcl_DString *dsPtr);
1029 /* 355 */
1030 EXTERN Tcl_UniChar * Tcl_UtfToUniCharDString(const char *src, int length,
1031 Tcl_DString *dsPtr);
1032 /* 356 */
1033 EXTERN Tcl_RegExp Tcl_GetRegExpFromObj(Tcl_Interp *interp,
1034 Tcl_Obj *patObj, int flags);
1035 /* 357 */
1036 EXTERN Tcl_Obj * Tcl_EvalTokens(Tcl_Interp *interp,
1037 Tcl_Token *tokenPtr, int count);
1038 /* 358 */
1039 EXTERN void Tcl_FreeParse(Tcl_Parse *parsePtr);
1040 /* 359 */
1041 EXTERN void Tcl_LogCommandInfo(Tcl_Interp *interp,
1042 const char *script, const char *command,
1043 int length);
1044 /* 360 */
1045 EXTERN int Tcl_ParseBraces(Tcl_Interp *interp,
1046 const char *start, int numBytes,
1047 Tcl_Parse *parsePtr, int append,
1048 CONST84 char **termPtr);
1049 /* 361 */
1050 EXTERN int Tcl_ParseCommand(Tcl_Interp *interp,
1051 const char *start, int numBytes, int nested,
1052 Tcl_Parse *parsePtr);
1053 /* 362 */
1054 EXTERN int Tcl_ParseExpr(Tcl_Interp *interp, const char *start,
1055 int numBytes, Tcl_Parse *parsePtr);
1056 /* 363 */
1057 EXTERN int Tcl_ParseQuotedString(Tcl_Interp *interp,
1058 const char *start, int numBytes,
1059 Tcl_Parse *parsePtr, int append,
1060 CONST84 char **termPtr);
1061 /* 364 */
1062 EXTERN int Tcl_ParseVarName(Tcl_Interp *interp,
1063 const char *start, int numBytes,
1064 Tcl_Parse *parsePtr, int append);
1065 /* 365 */
1066 EXTERN char * Tcl_GetCwd(Tcl_Interp *interp, Tcl_DString *cwdPtr);
1067 /* 366 */
1068 EXTERN int Tcl_Chdir(const char *dirName);
1069 /* 367 */
1070 EXTERN int Tcl_Access(const char *path, int mode);
1071 /* 368 */
1072 EXTERN int Tcl_Stat(const char *path, struct stat *bufPtr);
1073 /* 369 */
1074 EXTERN int Tcl_UtfNcmp(const char *s1, const char *s2,
1075 unsigned long n);
1076 /* 370 */
1077 EXTERN int Tcl_UtfNcasecmp(const char *s1, const char *s2,
1078 unsigned long n);
1079 /* 371 */
1080 EXTERN int Tcl_StringCaseMatch(const char *str,
1081 const char *pattern, int nocase);
1082 /* 372 */
1083 EXTERN int Tcl_UniCharIsControl(int ch);
1084 /* 373 */
1085 EXTERN int Tcl_UniCharIsGraph(int ch);
1086 /* 374 */
1087 EXTERN int Tcl_UniCharIsPrint(int ch);
1088 /* 375 */
1089 EXTERN int Tcl_UniCharIsPunct(int ch);
1090 /* 376 */
1091 EXTERN int Tcl_RegExpExecObj(Tcl_Interp *interp,
1092 Tcl_RegExp regexp, Tcl_Obj *textObj,
1093 int offset, int nmatches, int flags);
1094 /* 377 */
1095 EXTERN void Tcl_RegExpGetInfo(Tcl_RegExp regexp,
1096 Tcl_RegExpInfo *infoPtr);
1097 /* 378 */
1098 EXTERN Tcl_Obj * Tcl_NewUnicodeObj(const Tcl_UniChar *unicode,
1099 int numChars);
1100 /* 379 */
1101 EXTERN void Tcl_SetUnicodeObj(Tcl_Obj *objPtr,
1102 const Tcl_UniChar *unicode, int numChars);
1103 /* 380 */
1104 EXTERN int Tcl_GetCharLength(Tcl_Obj *objPtr);
1105 /* 381 */
1106 EXTERN Tcl_UniChar Tcl_GetUniChar(Tcl_Obj *objPtr, int index);
1107 /* 382 */
1108 EXTERN Tcl_UniChar * Tcl_GetUnicode(Tcl_Obj *objPtr);
1109 /* 383 */
1110 EXTERN Tcl_Obj * Tcl_GetRange(Tcl_Obj *objPtr, int first, int last);
1111 /* 384 */
1112 EXTERN void Tcl_AppendUnicodeToObj(Tcl_Obj *objPtr,
1113 const Tcl_UniChar *unicode, int length);
1114 /* 385 */
1115 EXTERN int Tcl_RegExpMatchObj(Tcl_Interp *interp,
1116 Tcl_Obj *textObj, Tcl_Obj *patternObj);
1117 /* 386 */
1118 EXTERN void Tcl_SetNotifier(Tcl_NotifierProcs *notifierProcPtr);
1119 /* 387 */
1120 EXTERN Tcl_Mutex * Tcl_GetAllocMutex(void);
1121 /* 388 */
1122 EXTERN int Tcl_GetChannelNames(Tcl_Interp *interp);
1123 /* 389 */
1124 EXTERN int Tcl_GetChannelNamesEx(Tcl_Interp *interp,
1125 const char *pattern);
1126 /* 390 */
1127 EXTERN int Tcl_ProcObjCmd(ClientData clientData,
1128 Tcl_Interp *interp, int objc,
1129 Tcl_Obj *const objv[]);
1130 /* 391 */
1131 EXTERN void Tcl_ConditionFinalize(Tcl_Condition *condPtr);
1132 /* 392 */
1133 EXTERN void Tcl_MutexFinalize(Tcl_Mutex *mutex);
1134 /* 393 */
1135 EXTERN int Tcl_CreateThread(Tcl_ThreadId *idPtr,
1136 Tcl_ThreadCreateProc *proc,
1137 ClientData clientData, int stackSize,
1138 int flags);
1139 /* 394 */
1140 EXTERN int Tcl_ReadRaw(Tcl_Channel chan, char *dst,
1141 int bytesToRead);
1142 /* 395 */
1143 EXTERN int Tcl_WriteRaw(Tcl_Channel chan, const char *src,
1144 int srcLen);
1145 /* 396 */
1146 EXTERN Tcl_Channel Tcl_GetTopChannel(Tcl_Channel chan);
1147 /* 397 */
1148 EXTERN int Tcl_ChannelBuffered(Tcl_Channel chan);
1149 /* 398 */
1150 EXTERN CONST84_RETURN char * Tcl_ChannelName(
1151 const Tcl_ChannelType *chanTypePtr);
1152 /* 399 */
1153 EXTERN Tcl_ChannelTypeVersion Tcl_ChannelVersion(
1154 const Tcl_ChannelType *chanTypePtr);
1155 /* 400 */
1156 EXTERN Tcl_DriverBlockModeProc * Tcl_ChannelBlockModeProc(
1157 const Tcl_ChannelType *chanTypePtr);
1158 /* 401 */
1159 EXTERN Tcl_DriverCloseProc * Tcl_ChannelCloseProc(
1160 const Tcl_ChannelType *chanTypePtr);
1161 /* 402 */
1162 EXTERN Tcl_DriverClose2Proc * Tcl_ChannelClose2Proc(
1163 const Tcl_ChannelType *chanTypePtr);
1164 /* 403 */
1165 EXTERN Tcl_DriverInputProc * Tcl_ChannelInputProc(
1166 const Tcl_ChannelType *chanTypePtr);
1167 /* 404 */
1168 EXTERN Tcl_DriverOutputProc * Tcl_ChannelOutputProc(
1169 const Tcl_ChannelType *chanTypePtr);
1170 /* 405 */
1171 EXTERN Tcl_DriverSeekProc * Tcl_ChannelSeekProc(
1172 const Tcl_ChannelType *chanTypePtr);
1173 /* 406 */
1174 EXTERN Tcl_DriverSetOptionProc * Tcl_ChannelSetOptionProc(
1175 const Tcl_ChannelType *chanTypePtr);
1176 /* 407 */
1177 EXTERN Tcl_DriverGetOptionProc * Tcl_ChannelGetOptionProc(
1178 const Tcl_ChannelType *chanTypePtr);
1179 /* 408 */
1180 EXTERN Tcl_DriverWatchProc * Tcl_ChannelWatchProc(
1181 const Tcl_ChannelType *chanTypePtr);
1182 /* 409 */
1183 EXTERN Tcl_DriverGetHandleProc * Tcl_ChannelGetHandleProc(
1184 const Tcl_ChannelType *chanTypePtr);
1185 /* 410 */
1186 EXTERN Tcl_DriverFlushProc * Tcl_ChannelFlushProc(
1187 const Tcl_ChannelType *chanTypePtr);
1188 /* 411 */
1189 EXTERN Tcl_DriverHandlerProc * Tcl_ChannelHandlerProc(
1190 const Tcl_ChannelType *chanTypePtr);
1191 /* 412 */
1192 EXTERN int Tcl_JoinThread(Tcl_ThreadId threadId, int *result);
1193 /* 413 */
1194 EXTERN int Tcl_IsChannelShared(Tcl_Channel channel);
1195 /* 414 */
1196 EXTERN int Tcl_IsChannelRegistered(Tcl_Interp *interp,
1197 Tcl_Channel channel);
1198 /* 415 */
1199 EXTERN void Tcl_CutChannel(Tcl_Channel channel);
1200 /* 416 */
1201 EXTERN void Tcl_SpliceChannel(Tcl_Channel channel);
1202 /* 417 */
1203 EXTERN void Tcl_ClearChannelHandlers(Tcl_Channel channel);
1204 /* 418 */
1205 EXTERN int Tcl_IsChannelExisting(const char *channelName);
1206 /* 419 */
1207 EXTERN int Tcl_UniCharNcasecmp(const Tcl_UniChar *ucs,
1208 const Tcl_UniChar *uct,
1209 unsigned long numChars);
1210 /* 420 */
1211 EXTERN int Tcl_UniCharCaseMatch(const Tcl_UniChar *uniStr,
1212 const Tcl_UniChar *uniPattern, int nocase);
1213 /* 421 */
1214 EXTERN Tcl_HashEntry * Tcl_FindHashEntry(Tcl_HashTable *tablePtr,
1215 const void *key);
1216 /* 422 */
1217 EXTERN Tcl_HashEntry * Tcl_CreateHashEntry(Tcl_HashTable *tablePtr,
1218 const void *key, int *newPtr);
1219 /* 423 */
1220 EXTERN void Tcl_InitCustomHashTable(Tcl_HashTable *tablePtr,
1221 int keyType, const Tcl_HashKeyType *typePtr);
1222 /* 424 */
1223 EXTERN void Tcl_InitObjHashTable(Tcl_HashTable *tablePtr);
1224 /* 425 */
1225 EXTERN ClientData Tcl_CommandTraceInfo(Tcl_Interp *interp,
1226 const char *varName, int flags,
1227 Tcl_CommandTraceProc *procPtr,
1228 ClientData prevClientData);
1229 /* 426 */
1230 EXTERN int Tcl_TraceCommand(Tcl_Interp *interp,
1231 const char *varName, int flags,
1232 Tcl_CommandTraceProc *proc,
1233 ClientData clientData);
1234 /* 427 */
1235 EXTERN void Tcl_UntraceCommand(Tcl_Interp *interp,
1236 const char *varName, int flags,
1237 Tcl_CommandTraceProc *proc,
1238 ClientData clientData);
1239 /* 428 */
1240 EXTERN char * Tcl_AttemptAlloc(unsigned int size);
1241 /* 429 */
1242 EXTERN char * Tcl_AttemptDbCkalloc(unsigned int size,
1243 const char *file, int line);
1244 /* 430 */
1245 EXTERN char * Tcl_AttemptRealloc(char *ptr, unsigned int size);
1246 /* 431 */
1247 EXTERN char * Tcl_AttemptDbCkrealloc(char *ptr, unsigned int size,
1248 const char *file, int line);
1249 /* 432 */
1250 EXTERN int Tcl_AttemptSetObjLength(Tcl_Obj *objPtr, int length);
1251 /* 433 */
1252 EXTERN Tcl_ThreadId Tcl_GetChannelThread(Tcl_Channel channel);
1253 /* 434 */
1254 EXTERN Tcl_UniChar * Tcl_GetUnicodeFromObj(Tcl_Obj *objPtr,
1255 int *lengthPtr);
1256 /* 435 */
1257 EXTERN int Tcl_GetMathFuncInfo(Tcl_Interp *interp,
1258 const char *name, int *numArgsPtr,
1259 Tcl_ValueType **argTypesPtr,
1260 Tcl_MathProc **procPtr,
1261 ClientData *clientDataPtr);
1262 /* 436 */
1263 EXTERN Tcl_Obj * Tcl_ListMathFuncs(Tcl_Interp *interp,
1264 const char *pattern);
1265 /* 437 */
1266 EXTERN Tcl_Obj * Tcl_SubstObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
1267 int flags);
1268 /* 438 */
1269 EXTERN int Tcl_DetachChannel(Tcl_Interp *interp,
1270 Tcl_Channel channel);
1271 /* 439 */
1272 EXTERN int Tcl_IsStandardChannel(Tcl_Channel channel);
1273 /* 440 */
1274 EXTERN int Tcl_FSCopyFile(Tcl_Obj *srcPathPtr,
1275 Tcl_Obj *destPathPtr);
1276 /* 441 */
1277 EXTERN int Tcl_FSCopyDirectory(Tcl_Obj *srcPathPtr,
1278 Tcl_Obj *destPathPtr, Tcl_Obj **errorPtr);
1279 /* 442 */
1280 EXTERN int Tcl_FSCreateDirectory(Tcl_Obj *pathPtr);
1281 /* 443 */
1282 EXTERN int Tcl_FSDeleteFile(Tcl_Obj *pathPtr);
1283 /* 444 */
1284 EXTERN int Tcl_FSLoadFile(Tcl_Interp *interp, Tcl_Obj *pathPtr,
1285 const char *sym1, const char *sym2,
1286 Tcl_PackageInitProc **proc1Ptr,
1287 Tcl_PackageInitProc **proc2Ptr,
1288 Tcl_LoadHandle *handlePtr,
1289 Tcl_FSUnloadFileProc **unloadProcPtr);
1290 /* 445 */
1291 EXTERN int Tcl_FSMatchInDirectory(Tcl_Interp *interp,
1292 Tcl_Obj *result, Tcl_Obj *pathPtr,
1293 const char *pattern, Tcl_GlobTypeData *types);
1294 /* 446 */
1295 EXTERN Tcl_Obj * Tcl_FSLink(Tcl_Obj *pathPtr, Tcl_Obj *toPtr,
1296 int linkAction);
1297 /* 447 */
1298 EXTERN int Tcl_FSRemoveDirectory(Tcl_Obj *pathPtr,
1299 int recursive, Tcl_Obj **errorPtr);
1300 /* 448 */
1301 EXTERN int Tcl_FSRenameFile(Tcl_Obj *srcPathPtr,
1302 Tcl_Obj *destPathPtr);
1303 /* 449 */
1304 EXTERN int Tcl_FSLstat(Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1305 /* 450 */
1306 EXTERN int Tcl_FSUtime(Tcl_Obj *pathPtr, struct utimbuf *tval);
1307 /* 451 */
1308 EXTERN int Tcl_FSFileAttrsGet(Tcl_Interp *interp, int index,
1309 Tcl_Obj *pathPtr, Tcl_Obj **objPtrRef);
1310 /* 452 */
1311 EXTERN int Tcl_FSFileAttrsSet(Tcl_Interp *interp, int index,
1312 Tcl_Obj *pathPtr, Tcl_Obj *objPtr);
1313 /* 453 */
1314 EXTERN const char *CONST86 * Tcl_FSFileAttrStrings(Tcl_Obj *pathPtr,
1315 Tcl_Obj **objPtrRef);
1316 /* 454 */
1317 EXTERN int Tcl_FSStat(Tcl_Obj *pathPtr, Tcl_StatBuf *buf);
1318 /* 455 */
1319 EXTERN int Tcl_FSAccess(Tcl_Obj *pathPtr, int mode);
1320 /* 456 */
1321 EXTERN Tcl_Channel Tcl_FSOpenFileChannel(Tcl_Interp *interp,
1322 Tcl_Obj *pathPtr, const char *modeString,
1323 int permissions);
1324 /* 457 */
1325 EXTERN Tcl_Obj * Tcl_FSGetCwd(Tcl_Interp *interp);
1326 /* 458 */
1327 EXTERN int Tcl_FSChdir(Tcl_Obj *pathPtr);
1328 /* 459 */
1329 EXTERN int Tcl_FSConvertToPathType(Tcl_Interp *interp,
1330 Tcl_Obj *pathPtr);
1331 /* 460 */
1332 EXTERN Tcl_Obj * Tcl_FSJoinPath(Tcl_Obj *listObj, int elements);
1333 /* 461 */
1334 EXTERN Tcl_Obj * Tcl_FSSplitPath(Tcl_Obj *pathPtr, int *lenPtr);
1335 /* 462 */
1336 EXTERN int Tcl_FSEqualPaths(Tcl_Obj *firstPtr,
1337 Tcl_Obj *secondPtr);
1338 /* 463 */
1339 EXTERN Tcl_Obj * Tcl_FSGetNormalizedPath(Tcl_Interp *interp,
1340 Tcl_Obj *pathPtr);
1341 /* 464 */
1342 EXTERN Tcl_Obj * Tcl_FSJoinToPath(Tcl_Obj *pathPtr, int objc,
1343 Tcl_Obj *const objv[]);
1344 /* 465 */
1345 EXTERN ClientData Tcl_FSGetInternalRep(Tcl_Obj *pathPtr,
1346 const Tcl_Filesystem *fsPtr);
1347 /* 466 */
1348 EXTERN Tcl_Obj * Tcl_FSGetTranslatedPath(Tcl_Interp *interp,
1349 Tcl_Obj *pathPtr);
1350 /* 467 */
1351 EXTERN int Tcl_FSEvalFile(Tcl_Interp *interp, Tcl_Obj *fileName);
1352 /* 468 */
1353 EXTERN Tcl_Obj * Tcl_FSNewNativePath(
1354 const Tcl_Filesystem *fromFilesystem,
1355 ClientData clientData);
1356 /* 469 */
1357 EXTERN const void * Tcl_FSGetNativePath(Tcl_Obj *pathPtr);
1358 /* 470 */
1359 EXTERN Tcl_Obj * Tcl_FSFileSystemInfo(Tcl_Obj *pathPtr);
1360 /* 471 */
1361 EXTERN Tcl_Obj * Tcl_FSPathSeparator(Tcl_Obj *pathPtr);
1362 /* 472 */
1363 EXTERN Tcl_Obj * Tcl_FSListVolumes(void);
1364 /* 473 */
1365 EXTERN int Tcl_FSRegister(ClientData clientData,
1366 const Tcl_Filesystem *fsPtr);
1367 /* 474 */
1368 EXTERN int Tcl_FSUnregister(const Tcl_Filesystem *fsPtr);
1369 /* 475 */
1370 EXTERN ClientData Tcl_FSData(const Tcl_Filesystem *fsPtr);
1371 /* 476 */
1372 EXTERN const char * Tcl_FSGetTranslatedStringPath(Tcl_Interp *interp,
1373 Tcl_Obj *pathPtr);
1374 /* 477 */
1375 EXTERN CONST86 Tcl_Filesystem * Tcl_FSGetFileSystemForPath(Tcl_Obj *pathPtr);
1376 /* 478 */
1377 EXTERN Tcl_PathType Tcl_FSGetPathType(Tcl_Obj *pathPtr);
1378 /* 479 */
1379 EXTERN int Tcl_OutputBuffered(Tcl_Channel chan);
1380 /* 480 */
1381 EXTERN void Tcl_FSMountsChanged(const Tcl_Filesystem *fsPtr);
1382 /* 481 */
1383 EXTERN int Tcl_EvalTokensStandard(Tcl_Interp *interp,
1384 Tcl_Token *tokenPtr, int count);
1385 /* 482 */
1386 EXTERN void Tcl_GetTime(Tcl_Time *timeBuf);
1387 /* 483 */
1388 EXTERN Tcl_Trace Tcl_CreateObjTrace(Tcl_Interp *interp, int level,
1389 int flags, Tcl_CmdObjTraceProc *objProc,
1390 ClientData clientData,
1391 Tcl_CmdObjTraceDeleteProc *delProc);
1392 /* 484 */
1393 EXTERN int Tcl_GetCommandInfoFromToken(Tcl_Command token,
1394 Tcl_CmdInfo *infoPtr);
1395 /* 485 */
1396 EXTERN int Tcl_SetCommandInfoFromToken(Tcl_Command token,
1397 const Tcl_CmdInfo *infoPtr);
1398 /* 486 */
1399 EXTERN Tcl_Obj * Tcl_DbNewWideIntObj(Tcl_WideInt wideValue,
1400 const char *file, int line);
1401 /* 487 */
1402 EXTERN int Tcl_GetWideIntFromObj(Tcl_Interp *interp,
1403 Tcl_Obj *objPtr, Tcl_WideInt *widePtr);
1404 /* 488 */
1405 EXTERN Tcl_Obj * Tcl_NewWideIntObj(Tcl_WideInt wideValue);
1406 /* 489 */
1407 EXTERN void Tcl_SetWideIntObj(Tcl_Obj *objPtr,
1408 Tcl_WideInt wideValue);
1409 /* 490 */
1410 EXTERN Tcl_StatBuf * Tcl_AllocStatBuf(void);
1411 /* 491 */
1412 EXTERN Tcl_WideInt Tcl_Seek(Tcl_Channel chan, Tcl_WideInt offset,
1413 int mode);
1414 /* 492 */
1415 EXTERN Tcl_WideInt Tcl_Tell(Tcl_Channel chan);
1416 /* 493 */
1417 EXTERN Tcl_DriverWideSeekProc * Tcl_ChannelWideSeekProc(
1418 const Tcl_ChannelType *chanTypePtr);
1419 /* 494 */
1420 EXTERN int Tcl_DictObjPut(Tcl_Interp *interp, Tcl_Obj *dictPtr,
1421 Tcl_Obj *keyPtr, Tcl_Obj *valuePtr);
1422 /* 495 */
1423 EXTERN int Tcl_DictObjGet(Tcl_Interp *interp, Tcl_Obj *dictPtr,
1424 Tcl_Obj *keyPtr, Tcl_Obj **valuePtrPtr);
1425 /* 496 */
1426 EXTERN int Tcl_DictObjRemove(Tcl_Interp *interp,
1427 Tcl_Obj *dictPtr, Tcl_Obj *keyPtr);
1428 /* 497 */
1429 EXTERN int Tcl_DictObjSize(Tcl_Interp *interp, Tcl_Obj *dictPtr,
1430 int *sizePtr);
1431 /* 498 */
1432 EXTERN int Tcl_DictObjFirst(Tcl_Interp *interp,
1433 Tcl_Obj *dictPtr, Tcl_DictSearch *searchPtr,
1434 Tcl_Obj **keyPtrPtr, Tcl_Obj **valuePtrPtr,
1435 int *donePtr);
1436 /* 499 */
1437 EXTERN void Tcl_DictObjNext(Tcl_DictSearch *searchPtr,
1438 Tcl_Obj **keyPtrPtr, Tcl_Obj **valuePtrPtr,
1439 int *donePtr);
1440 /* 500 */
1441 EXTERN void Tcl_DictObjDone(Tcl_DictSearch *searchPtr);
1442 /* 501 */
1443 EXTERN int Tcl_DictObjPutKeyList(Tcl_Interp *interp,
1444 Tcl_Obj *dictPtr, int keyc,
1445 Tcl_Obj *const *keyv, Tcl_Obj *valuePtr);
1446 /* 502 */
1447 EXTERN int Tcl_DictObjRemoveKeyList(Tcl_Interp *interp,
1448 Tcl_Obj *dictPtr, int keyc,
1449 Tcl_Obj *const *keyv);
1450 /* 503 */
1451 EXTERN Tcl_Obj * Tcl_NewDictObj(void);
1452 /* 504 */
1453 EXTERN Tcl_Obj * Tcl_DbNewDictObj(const char *file, int line);
1454 /* 505 */
1455 EXTERN void Tcl_RegisterConfig(Tcl_Interp *interp,
1456 const char *pkgName,
1457 const Tcl_Config *configuration,
1458 const char *valEncoding);
1459 /* 506 */
1460 EXTERN Tcl_Namespace * Tcl_CreateNamespace(Tcl_Interp *interp,
1461 const char *name, ClientData clientData,
1462 Tcl_NamespaceDeleteProc *deleteProc);
1463 /* 507 */
1464 EXTERN void Tcl_DeleteNamespace(Tcl_Namespace *nsPtr);
1465 /* 508 */
1466 EXTERN int Tcl_AppendExportList(Tcl_Interp *interp,
1467 Tcl_Namespace *nsPtr, Tcl_Obj *objPtr);
1468 /* 509 */
1469 EXTERN int Tcl_Export(Tcl_Interp *interp, Tcl_Namespace *nsPtr,
1470 const char *pattern, int resetListFirst);
1471 /* 510 */
1472 EXTERN int Tcl_Import(Tcl_Interp *interp, Tcl_Namespace *nsPtr,
1473 const char *pattern, int allowOverwrite);
1474 /* 511 */
1475 EXTERN int Tcl_ForgetImport(Tcl_Interp *interp,
1476 Tcl_Namespace *nsPtr, const char *pattern);
1477 /* 512 */
1478 EXTERN Tcl_Namespace * Tcl_GetCurrentNamespace(Tcl_Interp *interp);
1479 /* 513 */
1480 EXTERN Tcl_Namespace * Tcl_GetGlobalNamespace(Tcl_Interp *interp);
1481 /* 514 */
1482 EXTERN Tcl_Namespace * Tcl_FindNamespace(Tcl_Interp *interp,
1483 const char *name,
1484 Tcl_Namespace *contextNsPtr, int flags);
1485 /* 515 */
1486 EXTERN Tcl_Command Tcl_FindCommand(Tcl_Interp *interp, const char *name,
1487 Tcl_Namespace *contextNsPtr, int flags);
1488 /* 516 */
1489 EXTERN Tcl_Command Tcl_GetCommandFromObj(Tcl_Interp *interp,
1490 Tcl_Obj *objPtr);
1491 /* 517 */
1492 EXTERN void Tcl_GetCommandFullName(Tcl_Interp *interp,
1493 Tcl_Command command, Tcl_Obj *objPtr);
1494 /* 518 */
1495 EXTERN int Tcl_FSEvalFileEx(Tcl_Interp *interp,
1496 Tcl_Obj *fileName, const char *encodingName);
1497 /* 519 */
1498 EXTERN Tcl_ExitProc * Tcl_SetExitProc(Tcl_ExitProc *proc);
1499 /* 520 */
1500 EXTERN void Tcl_LimitAddHandler(Tcl_Interp *interp, int type,
1501 Tcl_LimitHandlerProc *handlerProc,
1502 ClientData clientData,
1503 Tcl_LimitHandlerDeleteProc *deleteProc);
1504 /* 521 */
1505 EXTERN void Tcl_LimitRemoveHandler(Tcl_Interp *interp, int type,
1506 Tcl_LimitHandlerProc *handlerProc,
1507 ClientData clientData);
1508 /* 522 */
1509 EXTERN int Tcl_LimitReady(Tcl_Interp *interp);
1510 /* 523 */
1511 EXTERN int Tcl_LimitCheck(Tcl_Interp *interp);
1512 /* 524 */
1513 EXTERN int Tcl_LimitExceeded(Tcl_Interp *interp);
1514 /* 525 */
1515 EXTERN void Tcl_LimitSetCommands(Tcl_Interp *interp,
1516 int commandLimit);
1517 /* 526 */
1518 EXTERN void Tcl_LimitSetTime(Tcl_Interp *interp,
1519 Tcl_Time *timeLimitPtr);
1520 /* 527 */
1521 EXTERN void Tcl_LimitSetGranularity(Tcl_Interp *interp, int type,
1522 int granularity);
1523 /* 528 */
1524 EXTERN int Tcl_LimitTypeEnabled(Tcl_Interp *interp, int type);
1525 /* 529 */
1526 EXTERN int Tcl_LimitTypeExceeded(Tcl_Interp *interp, int type);
1527 /* 530 */
1528 EXTERN void Tcl_LimitTypeSet(Tcl_Interp *interp, int type);
1529 /* 531 */
1530 EXTERN void Tcl_LimitTypeReset(Tcl_Interp *interp, int type);
1531 /* 532 */
1532 EXTERN int Tcl_LimitGetCommands(Tcl_Interp *interp);
1533 /* 533 */
1534 EXTERN void Tcl_LimitGetTime(Tcl_Interp *interp,
1535 Tcl_Time *timeLimitPtr);
1536 /* 534 */
1537 EXTERN int Tcl_LimitGetGranularity(Tcl_Interp *interp, int type);
1538 /* 535 */
1539 EXTERN Tcl_InterpState Tcl_SaveInterpState(Tcl_Interp *interp, int status);
1540 /* 536 */
1541 EXTERN int Tcl_RestoreInterpState(Tcl_Interp *interp,
1542 Tcl_InterpState state);
1543 /* 537 */
1544 EXTERN void Tcl_DiscardInterpState(Tcl_InterpState state);
1545 /* 538 */
1546 EXTERN int Tcl_SetReturnOptions(Tcl_Interp *interp,
1547 Tcl_Obj *options);
1548 /* 539 */
1549 EXTERN Tcl_Obj * Tcl_GetReturnOptions(Tcl_Interp *interp, int result);
1550 /* 540 */
1551 EXTERN int Tcl_IsEnsemble(Tcl_Command token);
1552 /* 541 */
1553 EXTERN Tcl_Command Tcl_CreateEnsemble(Tcl_Interp *interp,
1554 const char *name,
1555 Tcl_Namespace *namespacePtr, int flags);
1556 /* 542 */
1557 EXTERN Tcl_Command Tcl_FindEnsemble(Tcl_Interp *interp,
1558 Tcl_Obj *cmdNameObj, int flags);
1559 /* 543 */
1560 EXTERN int Tcl_SetEnsembleSubcommandList(Tcl_Interp *interp,
1561 Tcl_Command token, Tcl_Obj *subcmdList);
1562 /* 544 */
1563 EXTERN int Tcl_SetEnsembleMappingDict(Tcl_Interp *interp,
1564 Tcl_Command token, Tcl_Obj *mapDict);
1565 /* 545 */
1566 EXTERN int Tcl_SetEnsembleUnknownHandler(Tcl_Interp *interp,
1567 Tcl_Command token, Tcl_Obj *unknownList);
1568 /* 546 */
1569 EXTERN int Tcl_SetEnsembleFlags(Tcl_Interp *interp,
1570 Tcl_Command token, int flags);
1571 /* 547 */
1572 EXTERN int Tcl_GetEnsembleSubcommandList(Tcl_Interp *interp,
1573 Tcl_Command token, Tcl_Obj **subcmdListPtr);
1574 /* 548 */
1575 EXTERN int Tcl_GetEnsembleMappingDict(Tcl_Interp *interp,
1576 Tcl_Command token, Tcl_Obj **mapDictPtr);
1577 /* 549 */
1578 EXTERN int Tcl_GetEnsembleUnknownHandler(Tcl_Interp *interp,
1579 Tcl_Command token, Tcl_Obj **unknownListPtr);
1580 /* 550 */
1581 EXTERN int Tcl_GetEnsembleFlags(Tcl_Interp *interp,
1582 Tcl_Command token, int *flagsPtr);
1583 /* 551 */
1584 EXTERN int Tcl_GetEnsembleNamespace(Tcl_Interp *interp,
1585 Tcl_Command token,
1586 Tcl_Namespace **namespacePtrPtr);
1587 /* 552 */
1588 EXTERN void Tcl_SetTimeProc(Tcl_GetTimeProc *getProc,
1589 Tcl_ScaleTimeProc *scaleProc,
1590 ClientData clientData);
1591 /* 553 */
1592 EXTERN void Tcl_QueryTimeProc(Tcl_GetTimeProc **getProc,
1593 Tcl_ScaleTimeProc **scaleProc,
1594 ClientData *clientData);
1595 /* 554 */
1596 EXTERN Tcl_DriverThreadActionProc * Tcl_ChannelThreadActionProc(
1597 const Tcl_ChannelType *chanTypePtr);
1598 /* 555 */
1599 EXTERN Tcl_Obj * Tcl_NewBignumObj(mp_int *value);
1600 /* 556 */
1601 EXTERN Tcl_Obj * Tcl_DbNewBignumObj(mp_int *value, const char *file,
1602 int line);
1603 /* 557 */
1604 EXTERN void Tcl_SetBignumObj(Tcl_Obj *obj, mp_int *value);
1605 /* 558 */
1606 EXTERN int Tcl_GetBignumFromObj(Tcl_Interp *interp,
1607 Tcl_Obj *obj, mp_int *value);
1608 /* 559 */
1609 EXTERN int Tcl_TakeBignumFromObj(Tcl_Interp *interp,
1610 Tcl_Obj *obj, mp_int *value);
1611 /* 560 */
1612 EXTERN int Tcl_TruncateChannel(Tcl_Channel chan,
1613 Tcl_WideInt length);
1614 /* 561 */
1615 EXTERN Tcl_DriverTruncateProc * Tcl_ChannelTruncateProc(
1616 const Tcl_ChannelType *chanTypePtr);
1617 /* 562 */
1618 EXTERN void Tcl_SetChannelErrorInterp(Tcl_Interp *interp,
1619 Tcl_Obj *msg);
1620 /* 563 */
1621 EXTERN void Tcl_GetChannelErrorInterp(Tcl_Interp *interp,
1622 Tcl_Obj **msg);
1623 /* 564 */
1624 EXTERN void Tcl_SetChannelError(Tcl_Channel chan, Tcl_Obj *msg);
1625 /* 565 */
1626 EXTERN void Tcl_GetChannelError(Tcl_Channel chan, Tcl_Obj **msg);
1627 /* 566 */
1628 EXTERN int Tcl_InitBignumFromDouble(Tcl_Interp *interp,
1629 double initval, mp_int *toInit);
1630 /* 567 */
1631 EXTERN Tcl_Obj * Tcl_GetNamespaceUnknownHandler(Tcl_Interp *interp,
1632 Tcl_Namespace *nsPtr);
1633 /* 568 */
1634 EXTERN int Tcl_SetNamespaceUnknownHandler(Tcl_Interp *interp,
1635 Tcl_NamespObjSetVar2
1636 Tcl_Namespace *nsPtr, Tcl_Obj *handlerPtr);
1637 /* 569 */
1638 EXTERN int Tcl_GetEncodingFromObj(Tcl_Interp *interp,
1639 Tcl_Obj *objPtr, Tcl_Encoding *encodingPtr);
1640 /* 570 */
1641 EXTERN Tcl_Obj * Tcl_GetEncodingSearchPath(void);
1642 /* 571 */
1643 EXTERN int Tcl_SetEncodingSearchPath(Tcl_Obj *searchPath);
1644 /* 572 */
1645 EXTERN const char * Tcl_GetEncodingNameFromEnvironment(
1646 Tcl_DString *bufPtr);
1647 /* 573 */
1648 EXTERN int Tcl_PkgRequireProc(Tcl_Interp *interp,
1649 const char define Tcl_ObjSEnvironment(
1650 Tcl_DString *bufPtr);
1651 /* 573 */
1652 EXTERN int Tcl_PkgRequireProc(Tcl_Interp *interp,
1653 const char *name, int objc,
1654 Tcl_Obj *const objv[], void *clientDataPtr);
1655 /* 574 */
1656 EXTERN void Tcl_AppendObjToErrorInfo(Tcl_Interp *interp,
1657 Tcl_Obj *objPtr);
1658 /* 575 */
1659 EXTERN void Tcl_AppendLimitedToObj(Tcl_Obj *objPtr,
1660 const char *bytes, int length, int limit,
1661 const char *ellipsis);
1662 /* 576 */
1663 EXTERN Tcl_Obj * Tcl_Format(Tcl_Interp *interp, const char *format,
1664 int objc, Tcl_Obj *const objv[]);
1665 /* 577 */
1666 EXTERN int Tcl_AppendFormatToObj(Tcl_Interp *interp,
1667 Tcl_Obj *objPtr, const char *format,
1668 int objc, Tcl_Obj *const objv[]);
1669 /* 578 */
1670 EXTERN Tcl_Obj * Tcl_ObjPrintf(const char *format, ...) TCL_FORMAT_PRINTF(1, 2);
1671 /* 579 */
1672 EXTERN void Tcl_AppendPrintfToObj(Tcl_Obj *objPtr,
1673 const char *format, ...) TCL_FORMAT_PRINTF(2, 3);
1674 /* 580 */
1675 EXTERN int Tcl_CancelEval(Tcl_Interp *interp,
1676 Tcl_Obj *resultObjPtr, ClientData clientData,
1677 int flags);
1678 /* 581 */
1679 EXTERN int Tcl_Canceled(Tcl_Interp *interp, int flags);
1680 /* 582 */
1681 EXTERN int Tcl_CreatePipe(Tcl_Interp *interp,
1682 Tcl_Channel *rchan, Tcl_Channel *wchan,
1683 int flags);
1684 /* 583 */
1685 EXTERN Tcl_Command Tcl_NRCreateCommand(Tcl_Interp *interp,
1686 const char *cmdName, Tcl_ObjCmdProc *proc,
1687 Tcl_ObjCmdProc *nreProc,
1688 ClientData clientData,
1689 Tcl_CmdDeleteProc *deleteProc);
1690 /* 584 */
1691 EXTERN int Tcl_NREvalObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
1692 int flags);
1693 /* 585 */
1694 EXTERN int Tcl_NREvalObjv(Tcl_Interp *interp, int objc,
1695 Tcl_Obj *const objv[], int flags);
1696 /* 586 */
1697 EXTERN int Tcl_NRCmdSwap(Tcl_Interp *interp, Tcl_Command cmd,
1698 int objc, Tcl_Obj *const objv[], int flags);
1699 /* 587 */
1700 EXTERN void Tcl_NRAddCallback(Tcl_Interp *interp,
1701 Tcl_NRPostProc *postProcPtr,
1702 ClientData data0, ClientData data1,
1703 ClientData data2, ClientData data3);
1704 /* 588 */
1705 EXTERN int Tcl_NRCallObjProc(Tcl_Interp *interp,
1706 Tcl_ObjCmdProc *objProc,
1707 ClientData clientData, int objc,
1708 Tcl_Obj *const objv[]);
1709 /* 589 */
1710 EXTERN unsigned Tcl_GetFSDeviceFromStat(const Tcl_StatBuf *statPtr);
1711 /* 590 */
1712 EXTERN unsigned Tcl_GetFSInodeFromStat(const Tcl_StatBuf *statPtr);
1713 /* 591 */
1714 EXTERN unsigned Tcl_GetModeFromStat(const Tcl_StatBuf *statPtr);
1715 /* 592 */
1716 EXTERN int Tcl_GetLinkCountFromStat(const Tcl_StatBuf *statPtr);
1717 /* 593 */
1718 EXTERN int Tcl_GetUserIdFromStat(const Tcl_StatBuf *statPtr);
1719 /* 594 */
1720 EXTERN int Tcl_GetGroupIdFromStat(const Tcl_StatBuf *statPtr);
1721 /* 595 */
1722 EXTERN int Tcl_GetDeviceTypeFromStat(const Tcl_StatBuf *statPtr);
1723 /* 596 */
1724 EXTERN Tcl_WideInt Tcl_GetAccessTimeFromStat(const Tcl_StatBuf *statPtr);
1725 /* 597 */
1726 EXTERN Tcl_WideInt Tcl_GetModificationTimeFromStat(
1727 const Tcl_StatBuf *statPtr);
1728 /* 598 */
1729 EXTERN Tcl_WideInt Tcl_GetChangeTimeFromStat(const Tcl_StatBuf *statPtr);
1730 /* 599 */
1731 EXTERN Tcl_WideUInt Tcl_GetSizeFromStat(const Tcl_StatBuf *statPtr);
1732 /* 600 */
1733 EXTERN Tcl_WideUInt Tcl_GetBlocksFromStat(const Tcl_StatBuf *statPtr);
1734 /* 601 */
1735 EXTERN unsigned Tcl_GetBlockSizeFromStat(const Tcl_StatBuf *statPtr);
1736 /* 602 */
1737 EXTERN int Tcl_SetEnsembleParameterList(Tcl_Interp *interp,
1738 Tcl_Command token, Tcl_Obj *paramList);
1739 /* 603 */
1740 EXTERN int Tcl_GetEnsembleParameterList(Tcl_Interp *interp,
1741 Tcl_Command token, Tcl_Obj **paramListPtr);
1742 /* 604 */
1743 EXTERN int Tcl_ParseArgsObjv(Tcl_Interp *interp,
1744 const Tcl_ArgvInfo *argTable, int *objcPtr,
1745 Tcl_Obj *const *objv, Tcl_Obj ***remObjv);
1746 /* 605 */
1747 EXTERN int Tcl_GetErrorLine(Tcl_Interp *interp);
1748 /* 606 */
1749 EXTERN void Tcl_SetErrorLine(Tcl_Interp *interp, int lineNum);
1750 /* 607 */
1751 EXTERN void Tcl_TransferResult(Tcl_Interp *sourceInterp,
1752 int result, Tcl_Interp *targetInterp);
1753 /* 608 */
1754 EXTERN int Tcl_InterpActive(Tcl_Interp *interp);
1755 /* 609 */
1756 EXTERN void Tcl_BackgroundException(Tcl_Interp *interp, int code);
1757 /* 610 */
1758 EXTERN int Tcl_ZlibDeflate(Tcl_Interp *interp, int format,
1759 Tcl_Obj *data, int level,
1760 Tcl_Obj *gzipHeaderDictObj);
1761 /* 611 */
1762 EXTERN int Tcl_ZlibInflate(Tcl_Interp *interp, int format,
1763 Tcl_Obj *data, int buffersize,
1764 Tcl_Obj *gzipHeaderDictObj);
1765 /* 612 */
1766 EXTERN unsigned int Tcl_ZlibCRC32(unsigned int crc,
1767 const unsigned char *buf, int len);
1768 /* 613 */
1769 EXTERN unsigned int Tcl_ZlibAdler32(unsigned int adler,
1770 const unsigned char *buf, int len);
1771 /* 614 */
1772 EXTERN int Tcl_ZlibStreamInit(Tcl_Interp *interp, int mode,
1773 int format, int level, Tcl_Obj *dictObj,
1774 Tcl_ZlibStream *zshandle);
1775 /* 615 */
1776 EXTERN Tcl_Obj * Tcl_ZlibStreamGetCommandName(Tcl_ZlibStream zshandle);
1777 /* 616 */
1778 EXTERN int Tcl_ZlibStreamEof(Tcl_ZlibStream zshandle);
1779 /* 617 */
1780 EXTERN int Tcl_ZlibStreamChecksum(Tcl_ZlibStream zshandle);
1781 /* 618 */
1782 EXTERN int Tcl_ZlibStreamPut(Tcl_ZlibStream zshandle,
1783 Tcl_Obj *data, int flush);
1784 /* 619 */
1785 EXTERN int Tcl_ZlibStreamGet(Tcl_ZlibStream zshandle,
1786 Tcl_Obj *data, int count);
1787 /*
--- a/compat/tcl-8.6/generic/tclPlatDecls.h
+++ b/compat/tcl-8.6/generic/tclPlatDecls.h
@@ -0,0 +1,120 @@
1
+/*
2
+ * tclPlatDecls.h --
3
+ *
4
+ * Declarations of platform specific Tcl APIs.
5
+ *
6
+ * Copyright (c) 1998-1999 by Scriptics Corporation.
7
+ * All rights reserved.
8
+ */
9
+
10
+#ifndef _TCLPLATDECLS
11
+#define _TCLPLATDECLS
12
+
13
+#undef TCL_STORAGE_CLASS
14
+#ifdef BUILD_tcl
15
+# define TCL_STORAGE_CLASS DLLEXPORT
16
+#else
17
+# ifdef USE_TCL_STUBS
18
+# define TCL_STORAGE_CLASS
19
+# else
20
+# define TCL_STORAGE_CLASS DLLIMPORT
21
+# endif
22
+#endif
23
+
24
+/*
25
+ * WARNING: This file is automatically generated by the tools/genStubs.tcl
26
+ * script. Any modifications to the function declarations below should be made
27
+ * in the generic/tcl.decls script.
28
+ */
29
+
30
+/*
31
+ * TCHAR is needed here for win32, so if it is not defined yet do it here.
32
+ * This way, we don't need to include <tchar.h> just for one define.
33
+ */
34
+#if (defined(_WIN32) || defined(__CYGWIN__)) && !defined(_TCHAR_DEFINED)
35
+# if defined(_UNICODE)
36
+ typedef wchar_t TCHAR;
37
+# else
38
+ typedef char TCHAR;
39
+# endif
40
+# define _TCHAR_DEFINED
41
+#endif
42
+
43
+/* !BEGIN!: Do not edit below this line. */
44
+
45
+/*
46
+ * Exported function declarations:
47
+ */
48
+
49
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
50
+/* 0 */
51
+EXTERN TCHAR * Tcl_WinUtfToTChar(const char *str, int len,
52
+ Tcl_DString *dsPtr);
53
+/* 1 */
54
+EXTERN char * Tcl_WinTCharToUtf(const TCHAR *str, int len,
55
+ Tcl_DString *dsPtr);
56
+#endif /* WIN */
57
+#ifdef MAC_OSX_TCL /* MACOSX */
58
+/* 0 */
59
+EXTERN int Tcl_MacOSXOpenBundleResources(Tcl_Interp *interp,
60
+ const char *bundleName, int hasResourceFile,
61
+ int maxPathLen, char *libraryPath);
62
+/* 1 */
63
+EXTERN int Tcl_MacOSXOpenVersionedBundleResources(
64
+ Tcl_Interp *interp, const char *bundleName,
65
+ const char *bundleVersion,
66
+ int hasResourceFile, int maxPathLen,
67
+ char *libraryPath);
68
+#endif /* MACOSX */
69
+
70
+typedef struct TclPlatStubs {
71
+ int magic;
72
+ void *hooks;
73
+
74
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
75
+ TCHAR * (*tcl_WinUtfToTChar) (const char *str, int len, Tcl_DString *dsPtr); /* 0 */
76
+ char * (*tcl_WinTCharToUtf) (const TCHAR *str, int len, Tcl_DString *dsPtr); /* 1 */
77
+#endif /* WIN */
78
+#ifdef MAC_OSX_TCL /* MACOSX */
79
+ int (*tcl_MacOSXOpenBundleResources) (Tcl_Interp *interp, const char *bundleName, int hasResourceFile, int maxPathLen, char *libraryPath); /* 0 */
80
+ int (*tcl_MacOSXOpenVersionedBundleResources) (Tcl_Interp *interp, const char *bundleName, const char *bundleVersion, int hasResourceFile, int maxPathLen, char *libraryPath); /* 1 */
81
+#endif /* MACOSX */
82
+} TclPlatStubs;
83
+
84
+#ifdef __cplusplus
85
+extern "C" {
86
+#endif
87
+extern const TclPlatStubs *tclPlatStubsPtr;
88
+#ifdef __cplusplus
89
+}
90
+#endif
91
+
92
+#if defined(USE_TCL_STUBS)
93
+
94
+/*
95
+ * Inline function declarations:
96
+ */
97
+
98
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
99
+#define Tcl_WinUtfToTChar \
100
+ (tclPlatStubsPtr->tcl_WinUtfToTChar) /* 0 */
101
+#define Tcl_WinTCharToUtf \
102
+ (tclPlatStubsPtr->tcl_WinTCharToUtf) /* 1 */
103
+#endif /* WIN */
104
+#ifdef MAC_OSX_TCL /* MACOSX */
105
+#define Tcl_MacOSXOpenBundleResources \
106
+ (tclPlatStubsPtr->tcl_MacOSXOpenBundleResources) /* 0 */
107
+#define Tcl_MacOSXOpenVersionedBundleResources \
108
+ (tclPlatStubsPtr->tcl_MacOSXOpenVersionedBundleResources) /* 1 */
109
+#endif /* MACOSX */
110
+
111
+#endif /* defined(USE_TCL_STUBS) */
112
+
113
+/* !END!: Do not edit above this line. */
114
+
115
+#undef TCL_STORAGE_CLASS
116
+#define TCL_STORAGE_CLASS DLLIMPORT
117
+
118
+#endif /* _TCLPLATDECLS */
119
+
120
+
--- a/compat/tcl-8.6/generic/tclPlatDecls.h
+++ b/compat/tcl-8.6/generic/tclPlatDecls.h
@@ -0,0 +1,120 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
--- a/compat/tcl-8.6/generic/tclPlatDecls.h
+++ b/compat/tcl-8.6/generic/tclPlatDecls.h
@@ -0,0 +1,120 @@
1 /*
2 * tclPlatDecls.h --
3 *
4 * Declarations of platform specific Tcl APIs.
5 *
6 * Copyright (c) 1998-1999 by Scriptics Corporation.
7 * All rights reserved.
8 */
9
10 #ifndef _TCLPLATDECLS
11 #define _TCLPLATDECLS
12
13 #undef TCL_STORAGE_CLASS
14 #ifdef BUILD_tcl
15 # define TCL_STORAGE_CLASS DLLEXPORT
16 #else
17 # ifdef USE_TCL_STUBS
18 # define TCL_STORAGE_CLASS
19 # else
20 # define TCL_STORAGE_CLASS DLLIMPORT
21 # endif
22 #endif
23
24 /*
25 * WARNING: This file is automatically generated by the tools/genStubs.tcl
26 * script. Any modifications to the function declarations below should be made
27 * in the generic/tcl.decls script.
28 */
29
30 /*
31 * TCHAR is needed here for win32, so if it is not defined yet do it here.
32 * This way, we don't need to include <tchar.h> just for one define.
33 */
34 #if (defined(_WIN32) || defined(__CYGWIN__)) && !defined(_TCHAR_DEFINED)
35 # if defined(_UNICODE)
36 typedef wchar_t TCHAR;
37 # else
38 typedef char TCHAR;
39 # endif
40 # define _TCHAR_DEFINED
41 #endif
42
43 /* !BEGIN!: Do not edit below this line. */
44
45 /*
46 * Exported function declarations:
47 */
48
49 #if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
50 /* 0 */
51 EXTERN TCHAR * Tcl_WinUtfToTChar(const char *str, int len,
52 Tcl_DString *dsPtr);
53 /* 1 */
54 EXTERN char * Tcl_WinTCharToUtf(const TCHAR *str, int len,
55 Tcl_DString *dsPtr);
56 #endif /* WIN */
57 #ifdef MAC_OSX_TCL /* MACOSX */
58 /* 0 */
59 EXTERN int Tcl_MacOSXOpenBundleResources(Tcl_Interp *interp,
60 const char *bundleName, int hasResourceFile,
61 int maxPathLen, char *libraryPath);
62 /* 1 */
63 EXTERN int Tcl_MacOSXOpenVersionedBundleResources(
64 Tcl_Interp *interp, const char *bundleName,
65 const char *bundleVersion,
66 int hasResourceFile, int maxPathLen,
67 char *libraryPath);
68 #endif /* MACOSX */
69
70 typedef struct TclPlatStubs {
71 int magic;
72 void *hooks;
73
74 #if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
75 TCHAR * (*tcl_WinUtfToTChar) (const char *str, int len, Tcl_DString *dsPtr); /* 0 */
76 char * (*tcl_WinTCharToUtf) (const TCHAR *str, int len, Tcl_DString *dsPtr); /* 1 */
77 #endif /* WIN */
78 #ifdef MAC_OSX_TCL /* MACOSX */
79 int (*tcl_MacOSXOpenBundleResources) (Tcl_Interp *interp, const char *bundleName, int hasResourceFile, int maxPathLen, char *libraryPath); /* 0 */
80 int (*tcl_MacOSXOpenVersionedBundleResources) (Tcl_Interp *interp, const char *bundleName, const char *bundleVersion, int hasResourceFile, int maxPathLen, char *libraryPath); /* 1 */
81 #endif /* MACOSX */
82 } TclPlatStubs;
83
84 #ifdef __cplusplus
85 extern "C" {
86 #endif
87 extern const TclPlatStubs *tclPlatStubsPtr;
88 #ifdef __cplusplus
89 }
90 #endif
91
92 #if defined(USE_TCL_STUBS)
93
94 /*
95 * Inline function declarations:
96 */
97
98 #if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
99 #define Tcl_WinUtfToTChar \
100 (tclPlatStubsPtr->tcl_WinUtfToTChar) /* 0 */
101 #define Tcl_WinTCharToUtf \
102 (tclPlatStubsPtr->tcl_WinTCharToUtf) /* 1 */
103 #endif /* WIN */
104 #ifdef MAC_OSX_TCL /* MACOSX */
105 #define Tcl_MacOSXOpenBundleResources \
106 (tclPlatStubsPtr->tcl_MacOSXOpenBundleResources) /* 0 */
107 #define Tcl_MacOSXOpenVersionedBundleResources \
108 (tclPlatStubsPtr->tcl_MacOSXOpenVersionedBundleResources) /* 1 */
109 #endif /* MACOSX */
110
111 #endif /* defined(USE_TCL_STUBS) */
112
113 /* !END!: Do not edit above this line. */
114
115 #undef TCL_STORAGE_CLASS
116 #define TCL_STORAGE_CLASS DLLIMPORT
117
118 #endif /* _TCLPLATDECLS */
119
120

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button