Fork me on GitHub

source: svn/trunk/external/tcl/tcl.h@ 1203

Last change on this file since 1203 was 593, checked in by Pavel Demin, 12 years ago

initial commit

File size: 59.3 KB
Line 
1/*
2 * tcl.h --
3 *
4 * This header file describes the externally-visible facilities
5 * of the Tcl interpreter.
6 *
7 * Copyright (c) 1987-1994 The Regents of the University of California.
8 * Copyright (c) 1994-1997 Sun Microsystems, Inc.
9 * Copyright (c) 1993-1996 Lucent Technologies.
10 * Copyright (c) 1998-1999 Scriptics Corporation.
11 *
12 * See the file "license.terms" for information on usage and redistribution
13 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
14 *
15 * RCS: @(#) $Id: tcl.h,v 1.1 2008-06-04 13:58:02 demin Exp $
16 */
17
18#ifndef _TCL
19#define _TCL
20
21/*
22 * When version numbers change here, must also go into the following files
23 * and update the version numbers:
24 *
25 * README
26 * library/init.tcl (only if major.minor changes, not patchlevel)
27 * unix/configure.in
28 * win/makefile.bc (only if major.minor changes, not patchlevel)
29 * win/makefile.vc (only if major.minor changes, not patchlevel)
30 * win/README
31 * win/README.binary
32 * mac/README
33 *
34 * The release level should be 0 for alpha, 1 for beta, and 2 for
35 * final/patch. The release serial value is the number that follows the
36 * "a", "b", or "p" in the patch level; for example, if the patch level
37 * is 7.6b2, TCL_RELEASE_SERIAL is 2. It restarts at 1 whenever the
38 * release level is changed, except for the final release which is 0
39 * (the first patch will start at 1).
40 */
41
42#define TCL_MAJOR_VERSION 8
43#define TCL_MINOR_VERSION 0
44#define TCL_RELEASE_LEVEL 2
45#define TCL_RELEASE_SERIAL 5
46
47#define TCL_VERSION "8.0"
48#define TCL_PATCH_LEVEL "8.0.5"
49
50/*
51 * The following definitions set up the proper options for Windows
52 * compilers. We use this method because there is no autoconf equivalent.
53 */
54
55#ifndef __WIN32__
56# if defined(_WIN32) || defined(WIN32)
57# define __WIN32__
58# endif
59#endif
60
61#ifdef __WIN32__
62# ifndef STRICT
63# define STRICT
64# endif
65# ifndef USE_PROTOTYPE
66# define USE_PROTOTYPE 1
67# endif
68# ifndef HAS_STDARG
69# define HAS_STDARG 1
70# endif
71# ifndef USE_PROTOTYPE
72# define USE_PROTOTYPE 1
73# endif
74
75/*
76 * Under Windows we need to call Tcl_Alloc in all cases to avoid competing
77 * C run-time library issues.
78 */
79
80# ifndef USE_TCLALLOC
81# define USE_TCLALLOC 1
82# endif
83#endif /* __WIN32__ */
84
85/*
86 * The following definitions set up the proper options for Macintosh
87 * compilers. We use this method because there is no autoconf equivalent.
88 */
89
90#ifdef MAC_TCL
91# ifndef HAS_STDARG
92# define HAS_STDARG 1
93# endif
94# ifndef USE_TCLALLOC
95# define USE_TCLALLOC 1
96# endif
97# ifndef NO_STRERROR
98# define NO_STRERROR 1
99# endif
100#endif
101
102/*
103 * Utility macros: STRINGIFY takes an argument and wraps it in "" (double
104 * quotation marks), JOIN joins two arguments.
105 */
106
107#define VERBATIM(x) x
108#ifdef _MSC_VER
109# define STRINGIFY(x) STRINGIFY1(x)
110# define STRINGIFY1(x) #x
111# define JOIN(a,b) JOIN1(a,b)
112# define JOIN1(a,b) a##b
113#else
114# ifdef RESOURCE_INCLUDED
115# define STRINGIFY(x) STRINGIFY1(x)
116# define STRINGIFY1(x) #x
117# define JOIN(a,b) JOIN1(a,b)
118# define JOIN1(a,b) a##b
119# else
120# ifdef __STDC__
121# define STRINGIFY(x) #x
122# define JOIN(a,b) a##b
123# else
124# define STRINGIFY(x) "x"
125# define JOIN(a,b) VERBATIM(a)VERBATIM(b)
126# endif
127# endif
128#endif
129
130/*
131 * A special definition used to allow this header file to be included
132 * in resource files so that they can get obtain version information from
133 * this file. Resource compilers don't like all the C stuff, like typedefs
134 * and procedure declarations, that occur below.
135 */
136
137#ifndef RESOURCE_INCLUDED
138
139#ifndef BUFSIZ
140#include <stdio.h>
141#endif
142
143/*
144 * Definitions that allow Tcl functions with variable numbers of
145 * arguments to be used with either varargs.h or stdarg.h. TCL_VARARGS
146 * is used in procedure prototypes. TCL_VARARGS_DEF is used to declare
147 * the arguments in a function definiton: it takes the type and name of
148 * the first argument and supplies the appropriate argument declaration
149 * string for use in the function definition. TCL_VARARGS_START
150 * initializes the va_list data structure and returns the first argument.
151 */
152
153#if defined(__STDC__) || defined(HAS_STDARG)
154# define TCL_VARARGS(type, name) (type name, ...)
155# define TCL_VARARGS_DEF(type, name) (type name, ...)
156# define TCL_VARARGS_START(type, name, list) (va_start(list, name), name)
157#else
158# ifdef __cplusplus
159# define TCL_VARARGS(type, name) (type name, ...)
160# define TCL_VARARGS_DEF(type, name) (type va_alist, ...)
161# else
162# define TCL_VARARGS(type, name) ()
163# define TCL_VARARGS_DEF(type, name) (va_alist)
164# endif
165# define TCL_VARARGS_START(type, name, list) \
166 (va_start(list), va_arg(list, type))
167#endif
168
169/*
170 * Macros used to declare a function to be exported by a DLL.
171 * Used by Windows, maps to no-op declarations on non-Windows systems.
172 * The default build on windows is for a DLL, which causes the DLLIMPORT
173 * and DLLEXPORT macros to be nonempty. To build a static library, the
174 * macro STATIC_BUILD should be defined.
175 * The support follows the convention that a macro called BUILD_xxxx, where
176 * xxxx is the name of a library we are building, is set on the compile line
177 * for sources that are to be placed in the library. See BUILD_tcl in this
178 * file for an example of how the macro is to be used.
179 */
180
181#ifdef __WIN32__
182# ifdef STATIC_BUILD
183# define DLLIMPORT
184# define DLLEXPORT
185# else
186# if defined(_MSC_VER) || (defined(__GNUC__) && defined(__declspec))
187# define DLLIMPORT __declspec(dllimport)
188# define DLLEXPORT __declspec(dllexport)
189# else
190# define DLLIMPORT
191# define DLLEXPORT
192# endif
193# endif
194#else
195# define DLLIMPORT
196# define DLLEXPORT
197#endif
198
199#ifdef TCL_STORAGE_CLASS
200# undef TCL_STORAGE_CLASS
201#endif
202#ifdef BUILD_tcl
203# define TCL_STORAGE_CLASS DLLEXPORT
204#else
205# define TCL_STORAGE_CLASS DLLIMPORT
206#endif
207
208/*
209 * Definitions that allow this header file to be used either with or
210 * without ANSI C features like function prototypes.
211 */
212
213#undef _ANSI_ARGS_
214#undef CONST
215
216#if ((defined(__STDC__) || defined(SABER)) && !defined(NO_PROTOTYPE)) || defined(__cplusplus) || defined(USE_PROTOTYPE)
217# define _USING_PROTOTYPES_ 1
218# define _ANSI_ARGS_(x) x
219# define CONST const
220#else
221# define _ANSI_ARGS_(x) ()
222# define CONST
223#endif
224
225#ifdef __cplusplus
226# define EXTERN extern "C" TCL_STORAGE_CLASS
227#else
228# define EXTERN extern TCL_STORAGE_CLASS
229#endif
230
231/*
232 * Macro to use instead of "void" for arguments that must have
233 * type "void *" in ANSI C; maps them to type "char *" in
234 * non-ANSI systems.
235 */
236#ifndef __WIN32__
237#ifndef VOID
238# ifdef __STDC__
239# define VOID void
240# else
241# define VOID char
242# endif
243#endif
244#else /* __WIN32__ */
245/*
246 * The following code is copied from winnt.h
247 */
248#ifndef VOID
249#define VOID void
250typedef char CHAR;
251typedef short SHORT;
252typedef long LONG;
253#endif
254#endif /* __WIN32__ */
255
256/*
257 * Miscellaneous declarations.
258 */
259
260#ifndef NULL
261#define NULL 0
262#endif
263
264#ifndef _CLIENTDATA
265# if defined(__STDC__) || defined(__cplusplus)
266 typedef void *ClientData;
267# else
268 typedef int *ClientData;
269# endif /* __STDC__ */
270#define _CLIENTDATA
271#endif
272
273/*
274 * Data structures defined opaquely in this module. The definitions below
275 * just provide dummy types. A few fields are made visible in Tcl_Interp
276 * structures, namely those used for returning a string result from
277 * commands. Direct access to the result field is discouraged in Tcl 8.0.
278 * The interpreter result is either an object or a string, and the two
279 * values are kept consistent unless some C code sets interp->result
280 * directly. Programmers should use either the procedure Tcl_GetObjResult()
281 * or Tcl_GetStringResult() to read the interpreter's result. See the
282 * SetResult man page for details.
283 *
284 * Note: any change to the Tcl_Interp definition below must be mirrored
285 * in the "real" definition in tclInt.h.
286 *
287 * Note: Tcl_ObjCmdProc procedures do not directly set result and freeProc.
288 * Instead, they set a Tcl_Obj member in the "real" structure that can be
289 * accessed with Tcl_GetObjResult() and Tcl_SetObjResult().
290 */
291
292typedef struct Tcl_Interp {
293 char *result; /* If the last command returned a string
294 * result, this points to it. */
295 void (*freeProc) _ANSI_ARGS_((char *blockPtr));
296 /* Zero means the string result is
297 * statically allocated. TCL_DYNAMIC means
298 * it was allocated with ckalloc and should
299 * be freed with ckfree. Other values give
300 * the address of procedure to invoke to
301 * free the result. Tcl_Eval must free it
302 * before executing next command. */
303 int errorLine; /* When TCL_ERROR is returned, this gives
304 * the line number within the command where
305 * the error occurred (1 if first line). */
306} Tcl_Interp;
307
308typedef struct Tcl_AsyncHandler_ *Tcl_AsyncHandler;
309typedef struct Tcl_Channel_ *Tcl_Channel;
310typedef struct Tcl_Command_ *Tcl_Command;
311typedef struct Tcl_Event Tcl_Event;
312typedef struct Tcl_Pid_ *Tcl_Pid;
313typedef struct Tcl_RegExp_ *Tcl_RegExp;
314typedef struct Tcl_TimerToken_ *Tcl_TimerToken;
315typedef struct Tcl_Trace_ *Tcl_Trace;
316typedef struct Tcl_Var_ *Tcl_Var;
317
318/*
319 * When a TCL command returns, the interpreter contains a result from the
320 * command. Programmers are strongly encouraged to use one of the
321 * procedures Tcl_GetObjResult() or Tcl_GetStringResult() to read the
322 * interpreter's result. See the SetResult man page for details. Besides
323 * this result, the command procedure returns an integer code, which is
324 * one of the following:
325 *
326 * TCL_OK Command completed normally; the interpreter's
327 * result contains the command's result.
328 * TCL_ERROR The command couldn't be completed successfully;
329 * the interpreter's result describes what went wrong.
330 * TCL_RETURN The command requests that the current procedure
331 * return; the interpreter's result contains the
332 * procedure's return value.
333 * TCL_BREAK The command requests that the innermost loop
334 * be exited; the interpreter's result is meaningless.
335 * TCL_CONTINUE Go on to the next iteration of the current loop;
336 * the interpreter's result is meaningless.
337 */
338
339#define TCL_OK 0
340#define TCL_ERROR 1
341#define TCL_RETURN 2
342#define TCL_BREAK 3
343#define TCL_CONTINUE 4
344
345#define TCL_RESULT_SIZE 200
346
347/*
348 * Argument descriptors for math function callbacks in expressions:
349 */
350
351typedef enum {TCL_INT, TCL_DOUBLE, TCL_EITHER} Tcl_ValueType;
352typedef struct Tcl_Value {
353 Tcl_ValueType type; /* Indicates intValue or doubleValue is
354 * valid, or both. */
355 long intValue; /* Integer value. */
356 double doubleValue; /* Double-precision floating value. */
357} Tcl_Value;
358
359/*
360 * Forward declaration of Tcl_Obj to prevent an error when the forward
361 * reference to Tcl_Obj is encountered in the procedure types declared
362 * below.
363 */
364
365struct Tcl_Obj;
366
367/*
368 * Procedure types defined by Tcl:
369 */
370
371typedef int (Tcl_AppInitProc) _ANSI_ARGS_((Tcl_Interp *interp));
372typedef int (Tcl_AsyncProc) _ANSI_ARGS_((ClientData clientData,
373 Tcl_Interp *interp, int code));
374typedef void (Tcl_ChannelProc) _ANSI_ARGS_((ClientData clientData, int mask));
375typedef void (Tcl_CloseProc) _ANSI_ARGS_((ClientData data));
376typedef void (Tcl_CmdDeleteProc) _ANSI_ARGS_((ClientData clientData));
377typedef int (Tcl_CmdProc) _ANSI_ARGS_((ClientData clientData,
378 Tcl_Interp *interp, int argc, char *argv[]));
379typedef void (Tcl_CmdTraceProc) _ANSI_ARGS_((ClientData clientData,
380 Tcl_Interp *interp, int level, char *command, Tcl_CmdProc *proc,
381 ClientData cmdClientData, int argc, char *argv[]));
382typedef void (Tcl_DupInternalRepProc) _ANSI_ARGS_((struct Tcl_Obj *srcPtr,
383 struct Tcl_Obj *dupPtr));
384typedef int (Tcl_EventProc) _ANSI_ARGS_((Tcl_Event *evPtr, int flags));
385typedef void (Tcl_EventCheckProc) _ANSI_ARGS_((ClientData clientData,
386 int flags));
387typedef int (Tcl_EventDeleteProc) _ANSI_ARGS_((Tcl_Event *evPtr,
388 ClientData clientData));
389typedef void (Tcl_EventSetupProc) _ANSI_ARGS_((ClientData clientData,
390 int flags));
391typedef void (Tcl_ExitProc) _ANSI_ARGS_((ClientData clientData));
392typedef void (Tcl_FileProc) _ANSI_ARGS_((ClientData clientData, int mask));
393typedef void (Tcl_FileFreeProc) _ANSI_ARGS_((ClientData clientData));
394typedef void (Tcl_FreeInternalRepProc) _ANSI_ARGS_((struct Tcl_Obj *objPtr));
395typedef void (Tcl_FreeProc) _ANSI_ARGS_((char *blockPtr));
396typedef void (Tcl_IdleProc) _ANSI_ARGS_((ClientData clientData));
397typedef void (Tcl_InterpDeleteProc) _ANSI_ARGS_((ClientData clientData,
398 Tcl_Interp *interp));
399typedef int (Tcl_MathProc) _ANSI_ARGS_((ClientData clientData,
400 Tcl_Interp *interp, Tcl_Value *args, Tcl_Value *resultPtr));
401typedef void (Tcl_NamespaceDeleteProc) _ANSI_ARGS_((ClientData clientData));
402typedef int (Tcl_ObjCmdProc) _ANSI_ARGS_((ClientData clientData,
403 Tcl_Interp *interp, int objc, struct Tcl_Obj * CONST objv[]));
404typedef int (Tcl_PackageInitProc) _ANSI_ARGS_((Tcl_Interp *interp));
405typedef void (Tcl_TcpAcceptProc) _ANSI_ARGS_((ClientData callbackData,
406 Tcl_Channel chan, char *address, int port));
407typedef void (Tcl_TimerProc) _ANSI_ARGS_((ClientData clientData));
408typedef int (Tcl_SetFromAnyProc) _ANSI_ARGS_((Tcl_Interp *interp,
409 struct Tcl_Obj *objPtr));
410typedef void (Tcl_UpdateStringProc) _ANSI_ARGS_((struct Tcl_Obj *objPtr));
411typedef char *(Tcl_VarTraceProc) _ANSI_ARGS_((ClientData clientData,
412 Tcl_Interp *interp, char *part1, char *part2, int flags));
413
414/*
415 * The following structure represents a type of object, which is a
416 * particular internal representation for an object plus a set of
417 * procedures that provide standard operations on objects of that type.
418 */
419
420typedef struct Tcl_ObjType {
421 char *name; /* Name of the type, e.g. "int". */
422 Tcl_FreeInternalRepProc *freeIntRepProc;
423 /* Called to free any storage for the type's
424 * internal rep. NULL if the internal rep
425 * does not need freeing. */
426 Tcl_DupInternalRepProc *dupIntRepProc;
427 /* Called to create a new object as a copy
428 * of an existing object. */
429 Tcl_UpdateStringProc *updateStringProc;
430 /* Called to update the string rep from the
431 * type's internal representation. */
432 Tcl_SetFromAnyProc *setFromAnyProc;
433 /* Called to convert the object's internal
434 * rep to this type. Frees the internal rep
435 * of the old type. Returns TCL_ERROR on
436 * failure. */
437} Tcl_ObjType;
438
439/*
440 * One of the following structures exists for each object in the Tcl
441 * system. An object stores a value as either a string, some internal
442 * representation, or both.
443 */
444
445typedef struct Tcl_Obj {
446 int refCount; /* When 0 the object will be freed. */
447 char *bytes; /* This points to the first byte of the
448 * object's string representation. The array
449 * must be followed by a null byte (i.e., at
450 * offset length) but may also contain
451 * embedded null characters. The array's
452 * storage is allocated by ckalloc. NULL
453 * means the string rep is invalid and must
454 * be regenerated from the internal rep.
455 * Clients should use Tcl_GetStringFromObj
456 * to get a pointer to the byte array as a
457 * readonly value. */
458 int length; /* The number of bytes at *bytes, not
459 * including the terminating null. */
460 Tcl_ObjType *typePtr; /* Denotes the object's type. Always
461 * corresponds to the type of the object's
462 * internal rep. NULL indicates the object
463 * has no internal rep (has no type). */
464 union { /* The internal representation: */
465 long longValue; /* - an long integer value */
466 double doubleValue; /* - a double-precision floating value */
467 VOID *otherValuePtr; /* - another, type-specific value */
468 struct { /* - internal rep as two pointers */
469 VOID *ptr1;
470 VOID *ptr2;
471 } twoPtrValue;
472 } internalRep;
473} Tcl_Obj;
474
475/*
476 * Macros to increment and decrement a Tcl_Obj's reference count, and to
477 * test whether an object is shared (i.e. has reference count > 1).
478 * Note: clients should use Tcl_DecrRefCount() when they are finished using
479 * an object, and should never call TclFreeObj() directly. TclFreeObj() is
480 * only defined and made public in tcl.h to support Tcl_DecrRefCount's macro
481 * definition. Note also that Tcl_DecrRefCount() refers to the parameter
482 * "obj" twice. This means that you should avoid calling it with an
483 * expression that is expensive to compute or has side effects.
484 */
485
486EXTERN void Tcl_IncrRefCount _ANSI_ARGS_((Tcl_Obj *objPtr));
487EXTERN void Tcl_DecrRefCount _ANSI_ARGS_((Tcl_Obj *objPtr));
488EXTERN int Tcl_IsShared _ANSI_ARGS_((Tcl_Obj *objPtr));
489
490#ifdef TCL_MEM_DEBUG
491# define Tcl_IncrRefCount(objPtr) \
492 Tcl_DbIncrRefCount(objPtr, __FILE__, __LINE__)
493# define Tcl_DecrRefCount(objPtr) \
494 Tcl_DbDecrRefCount(objPtr, __FILE__, __LINE__)
495# define Tcl_IsShared(objPtr) \
496 Tcl_DbIsShared(objPtr, __FILE__, __LINE__)
497#else
498# define Tcl_IncrRefCount(objPtr) \
499 ++(objPtr)->refCount
500# define Tcl_DecrRefCount(objPtr) \
501 if (--(objPtr)->refCount <= 0) TclFreeObj(objPtr)
502# define Tcl_IsShared(objPtr) \
503 ((objPtr)->refCount > 1)
504#endif
505
506/*
507 * Macros and definitions that help to debug the use of Tcl objects.
508 * When TCL_MEM_DEBUG is defined, the Tcl_New* declarations are
509 * overridden to call debugging versions of the object creation procedures.
510 */
511
512EXTERN Tcl_Obj * Tcl_NewBooleanObj _ANSI_ARGS_((int boolValue));
513EXTERN Tcl_Obj * Tcl_NewDoubleObj _ANSI_ARGS_((double doubleValue));
514EXTERN Tcl_Obj * Tcl_NewIntObj _ANSI_ARGS_((int intValue));
515EXTERN Tcl_Obj * Tcl_NewListObj _ANSI_ARGS_((int objc,
516 Tcl_Obj *CONST objv[]));
517EXTERN Tcl_Obj * Tcl_NewLongObj _ANSI_ARGS_((long longValue));
518EXTERN Tcl_Obj * Tcl_NewObj _ANSI_ARGS_((void));
519EXTERN Tcl_Obj * Tcl_NewStringObj _ANSI_ARGS_((char *bytes,
520 int length));
521
522#ifdef TCL_MEM_DEBUG
523# define Tcl_NewBooleanObj(val) \
524 Tcl_DbNewBooleanObj(val, __FILE__, __LINE__)
525# define Tcl_NewDoubleObj(val) \
526 Tcl_DbNewDoubleObj(val, __FILE__, __LINE__)
527# define Tcl_NewIntObj(val) \
528 Tcl_DbNewLongObj(val, __FILE__, __LINE__)
529# define Tcl_NewListObj(objc, objv) \
530 Tcl_DbNewListObj(objc, objv, __FILE__, __LINE__)
531# define Tcl_NewLongObj(val) \
532 Tcl_DbNewLongObj(val, __FILE__, __LINE__)
533# define Tcl_NewObj() \
534 Tcl_DbNewObj(__FILE__, __LINE__)
535# define Tcl_NewStringObj(bytes, len) \
536 Tcl_DbNewStringObj(bytes, len, __FILE__, __LINE__)
537#endif /* TCL_MEM_DEBUG */
538
539/*
540 * The following definitions support Tcl's namespace facility.
541 * Note: the first five fields must match exactly the fields in a
542 * Namespace structure (see tcl.h).
543 */
544
545typedef struct Tcl_Namespace {
546 char *name; /* The namespace's name within its parent
547 * namespace. This contains no ::'s. The
548 * name of the global namespace is ""
549 * although "::" is an synonym. */
550 char *fullName; /* The namespace's fully qualified name.
551 * This starts with ::. */
552 ClientData clientData; /* Arbitrary value associated with this
553 * namespace. */
554 Tcl_NamespaceDeleteProc* deleteProc;
555 /* Procedure invoked when deleting the
556 * namespace to, e.g., free clientData. */
557 struct Tcl_Namespace* parentPtr;
558 /* Points to the namespace that contains
559 * this one. NULL if this is the global
560 * namespace. */
561} Tcl_Namespace;
562
563/*
564 * The following structure represents a call frame, or activation record.
565 * A call frame defines a naming context for a procedure call: its local
566 * scope (for local variables) and its namespace scope (used for non-local
567 * variables; often the global :: namespace). A call frame can also define
568 * the naming context for a namespace eval or namespace inscope command:
569 * the namespace in which the command's code should execute. The
570 * Tcl_CallFrame structures exist only while procedures or namespace
571 * eval/inscope's are being executed, and provide a Tcl call stack.
572 *
573 * A call frame is initialized and pushed using Tcl_PushCallFrame and
574 * popped using Tcl_PopCallFrame. Storage for a Tcl_CallFrame must be
575 * provided by the Tcl_PushCallFrame caller, and callers typically allocate
576 * them on the C call stack for efficiency. For this reason, Tcl_CallFrame
577 * is defined as a structure and not as an opaque token. However, most
578 * Tcl_CallFrame fields are hidden since applications should not access
579 * them directly; others are declared as "dummyX".
580 *
581 * WARNING!! The structure definition must be kept consistent with the
582 * CallFrame structure in tclInt.h. If you change one, change the other.
583 */
584
585typedef struct Tcl_CallFrame {
586 Tcl_Namespace *nsPtr;
587 int dummy1;
588 int dummy2;
589 char *dummy3;
590 char *dummy4;
591 char *dummy5;
592 int dummy6;
593 char *dummy7;
594 char *dummy8;
595 int dummy9;
596 char* dummy10;
597} Tcl_CallFrame;
598
599/*
600 * Information about commands that is returned by Tcl_GetCommandInfo and
601 * passed to Tcl_SetCommandInfo. objProc is an objc/objv object-based
602 * command procedure while proc is a traditional Tcl argc/argv
603 * string-based procedure. Tcl_CreateObjCommand and Tcl_CreateCommand
604 * ensure that both objProc and proc are non-NULL and can be called to
605 * execute the command. However, it may be faster to call one instead of
606 * the other. The member isNativeObjectProc is set to 1 if an
607 * object-based procedure was registered by Tcl_CreateObjCommand, and to
608 * 0 if a string-based procedure was registered by Tcl_CreateCommand.
609 * The other procedure is typically set to a compatibility wrapper that
610 * does string-to-object or object-to-string argument conversions then
611 * calls the other procedure.
612 */
613
614typedef struct Tcl_CmdInfo {
615 int isNativeObjectProc; /* 1 if objProc was registered by a call to
616 * Tcl_CreateObjCommand; 0 otherwise.
617 * Tcl_SetCmdInfo does not modify this
618 * field. */
619 Tcl_ObjCmdProc *objProc; /* Command's object-based procedure. */
620 ClientData objClientData; /* ClientData for object proc. */
621 Tcl_CmdProc *proc; /* Command's string-based procedure. */
622 ClientData clientData; /* ClientData for string proc. */
623 Tcl_CmdDeleteProc *deleteProc;
624 /* Procedure to call when command is
625 * deleted. */
626 ClientData deleteData; /* Value to pass to deleteProc (usually
627 * the same as clientData). */
628 Tcl_Namespace *namespacePtr; /* Points to the namespace that contains
629 * this command. Note that Tcl_SetCmdInfo
630 * will not change a command's namespace;
631 * use Tcl_RenameCommand to do that. */
632
633} Tcl_CmdInfo;
634
635/*
636 * The structure defined below is used to hold dynamic strings. The only
637 * field that clients should use is the string field, and they should
638 * never modify it.
639 */
640
641#define TCL_DSTRING_STATIC_SIZE 200
642typedef struct Tcl_DString {
643 char *string; /* Points to beginning of string: either
644 * staticSpace below or a malloced array. */
645 int length; /* Number of non-NULL characters in the
646 * string. */
647 int spaceAvl; /* Total number of bytes available for the
648 * string and its terminating NULL char. */
649 char staticSpace[TCL_DSTRING_STATIC_SIZE];
650 /* Space to use in common case where string
651 * is small. */
652} Tcl_DString;
653
654#define Tcl_DStringLength(dsPtr) ((dsPtr)->length)
655#define Tcl_DStringValue(dsPtr) ((dsPtr)->string)
656#define Tcl_DStringTrunc Tcl_DStringSetLength
657
658/*
659 * Definitions for the maximum number of digits of precision that may
660 * be specified in the "tcl_precision" variable, and the number of
661 * characters of buffer space required by Tcl_PrintDouble.
662 */
663
664#define TCL_MAX_PREC 17
665#define TCL_DOUBLE_SPACE (TCL_MAX_PREC+10)
666
667/*
668 * Flag that may be passed to Tcl_ConvertElement to force it not to
669 * output braces (careful! if you change this flag be sure to change
670 * the definitions at the front of tclUtil.c).
671 */
672
673#define TCL_DONT_USE_BRACES 1
674
675/*
676 * Flag that may be passed to Tcl_GetIndexFromObj to force it to disallow
677 * abbreviated strings.
678 */
679
680#define TCL_EXACT 1
681
682/*
683 * Flag values passed to Tcl_RecordAndEval.
684 * WARNING: these bit choices must not conflict with the bit choices
685 * for evalFlag bits in tclInt.h!!
686 */
687
688#define TCL_NO_EVAL 0x10000
689#define TCL_EVAL_GLOBAL 0x20000
690
691/*
692 * Special freeProc values that may be passed to Tcl_SetResult (see
693 * the man page for details):
694 */
695
696#define TCL_VOLATILE ((Tcl_FreeProc *) 1)
697#define TCL_STATIC ((Tcl_FreeProc *) 0)
698#define TCL_DYNAMIC ((Tcl_FreeProc *) 3)
699
700/*
701 * Flag values passed to variable-related procedures.
702 */
703
704#define TCL_GLOBAL_ONLY 1
705#define TCL_NAMESPACE_ONLY 2
706#define TCL_APPEND_VALUE 4
707#define TCL_LIST_ELEMENT 8
708#define TCL_TRACE_READS 0x10
709#define TCL_TRACE_WRITES 0x20
710#define TCL_TRACE_UNSETS 0x40
711#define TCL_TRACE_DESTROYED 0x80
712#define TCL_INTERP_DESTROYED 0x100
713#define TCL_LEAVE_ERR_MSG 0x200
714#define TCL_PARSE_PART1 0x400
715
716/*
717 * Types for linked variables:
718 */
719
720#define TCL_LINK_INT 1
721#define TCL_LINK_DOUBLE 2
722#define TCL_LINK_BOOLEAN 3
723#define TCL_LINK_STRING 4
724#define TCL_LINK_READ_ONLY 0x80
725
726/*
727 * The following declarations either map ckalloc and ckfree to
728 * malloc and free, or they map them to procedures with all sorts
729 * of debugging hooks defined in tclCkalloc.c.
730 */
731
732EXTERN char * Tcl_Alloc _ANSI_ARGS_((unsigned int size));
733EXTERN void Tcl_Free _ANSI_ARGS_((char *ptr));
734EXTERN char * Tcl_Realloc _ANSI_ARGS_((char *ptr,
735 unsigned int size));
736
737#ifdef TCL_MEM_DEBUG
738
739# define Tcl_Alloc(x) Tcl_DbCkalloc(x, __FILE__, __LINE__)
740# define Tcl_Free(x) Tcl_DbCkfree(x, __FILE__, __LINE__)
741# define Tcl_Realloc(x,y) Tcl_DbCkrealloc((x), (y),__FILE__, __LINE__)
742# define ckalloc(x) Tcl_DbCkalloc(x, __FILE__, __LINE__)
743# define ckfree(x) Tcl_DbCkfree(x, __FILE__, __LINE__)
744# define ckrealloc(x,y) Tcl_DbCkrealloc((x), (y),__FILE__, __LINE__)
745
746EXTERN int Tcl_DumpActiveMemory _ANSI_ARGS_((char *fileName));
747EXTERN void Tcl_ValidateAllMemory _ANSI_ARGS_((char *file,
748 int line));
749
750#else
751
752/*
753 * If USE_TCLALLOC is true, then we need to call Tcl_Alloc instead of
754 * the native malloc/free. The only time USE_TCLALLOC should not be
755 * true is when compiling the Tcl/Tk libraries on Unix systems. In this
756 * case we can safely call the native malloc/free directly as a performance
757 * optimization.
758 */
759
760# if USE_TCLALLOC
761# define ckalloc(x) Tcl_Alloc(x)
762# define ckfree(x) Tcl_Free(x)
763# define ckrealloc(x,y) Tcl_Realloc(x,y)
764# else
765# define ckalloc(x) malloc(x)
766# define ckfree(x) free(x)
767# define ckrealloc(x,y) realloc(x,y)
768# endif
769# define Tcl_DumpActiveMemory(x)
770# define Tcl_ValidateAllMemory(x,y)
771
772#endif /* TCL_MEM_DEBUG */
773
774/*
775 * Forward declaration of Tcl_HashTable. Needed by some C++ compilers
776 * to prevent errors when the forward reference to Tcl_HashTable is
777 * encountered in the Tcl_HashEntry structure.
778 */
779
780#ifdef __cplusplus
781struct Tcl_HashTable;
782#endif
783
784/*
785 * Structure definition for an entry in a hash table. No-one outside
786 * Tcl should access any of these fields directly; use the macros
787 * defined below.
788 */
789
790typedef struct Tcl_HashEntry {
791 struct Tcl_HashEntry *nextPtr; /* Pointer to next entry in this
792 * hash bucket, or NULL for end of
793 * chain. */
794 struct Tcl_HashTable *tablePtr; /* Pointer to table containing entry. */
795 struct Tcl_HashEntry **bucketPtr; /* Pointer to bucket that points to
796 * first entry in this entry's chain:
797 * used for deleting the entry. */
798 ClientData clientData; /* Application stores something here
799 * with Tcl_SetHashValue. */
800 union { /* Key has one of these forms: */
801 char *oneWordValue; /* One-word value for key. */
802 int words[1]; /* Multiple integer words for key.
803 * The actual size will be as large
804 * as necessary for this table's
805 * keys. */
806 char string[4]; /* String for key. The actual size
807 * will be as large as needed to hold
808 * the key. */
809 } key; /* MUST BE LAST FIELD IN RECORD!! */
810} Tcl_HashEntry;
811
812/*
813 * Structure definition for a hash table. Must be in tcl.h so clients
814 * can allocate space for these structures, but clients should never
815 * access any fields in this structure.
816 */
817
818#define TCL_SMALL_HASH_TABLE 4
819typedef struct Tcl_HashTable {
820 Tcl_HashEntry **buckets; /* Pointer to bucket array. Each
821 * element points to first entry in
822 * bucket's hash chain, or NULL. */
823 Tcl_HashEntry *staticBuckets[TCL_SMALL_HASH_TABLE];
824 /* Bucket array used for small tables
825 * (to avoid mallocs and frees). */
826 int numBuckets; /* Total number of buckets allocated
827 * at **bucketPtr. */
828 int numEntries; /* Total number of entries present
829 * in table. */
830 int rebuildSize; /* Enlarge table when numEntries gets
831 * to be this large. */
832 int downShift; /* Shift count used in hashing
833 * function. Designed to use high-
834 * order bits of randomized keys. */
835 int mask; /* Mask value used in hashing
836 * function. */
837 int keyType; /* Type of keys used in this table.
838 * It's either TCL_STRING_KEYS,
839 * TCL_ONE_WORD_KEYS, or an integer
840 * giving the number of ints that
841 * is the size of the key.
842 */
843 Tcl_HashEntry *(*findProc) _ANSI_ARGS_((struct Tcl_HashTable *tablePtr,
844 CONST char *key));
845 Tcl_HashEntry *(*createProc) _ANSI_ARGS_((struct Tcl_HashTable *tablePtr,
846 CONST char *key, int *newPtr));
847} Tcl_HashTable;
848
849/*
850 * Structure definition for information used to keep track of searches
851 * through hash tables:
852 */
853
854typedef struct Tcl_HashSearch {
855 Tcl_HashTable *tablePtr; /* Table being searched. */
856 int nextIndex; /* Index of next bucket to be
857 * enumerated after present one. */
858 Tcl_HashEntry *nextEntryPtr; /* Next entry to be enumerated in the
859 * the current bucket. */
860} Tcl_HashSearch;
861
862/*
863 * Acceptable key types for hash tables:
864 */
865
866#define TCL_STRING_KEYS 0
867#define TCL_ONE_WORD_KEYS 1
868
869/*
870 * Macros for clients to use to access fields of hash entries:
871 */
872
873#define Tcl_GetHashValue(h) ((h)->clientData)
874#define Tcl_SetHashValue(h, value) ((h)->clientData = (ClientData) (value))
875#define Tcl_GetHashKey(tablePtr, h) \
876 ((char *) (((tablePtr)->keyType == TCL_ONE_WORD_KEYS) ? (h)->key.oneWordValue \
877 : (h)->key.string))
878
879/*
880 * Macros to use for clients to use to invoke find and create procedures
881 * for hash tables:
882 */
883
884#define Tcl_FindHashEntry(tablePtr, key) \
885 (*((tablePtr)->findProc))(tablePtr, key)
886#define Tcl_CreateHashEntry(tablePtr, key, newPtr) \
887 (*((tablePtr)->createProc))(tablePtr, key, newPtr)
888
889/*
890 * Flag values to pass to Tcl_DoOneEvent to disable searches
891 * for some kinds of events:
892 */
893
894#define TCL_DONT_WAIT (1<<1)
895#define TCL_WINDOW_EVENTS (1<<2)
896#define TCL_FILE_EVENTS (1<<3)
897#define TCL_TIMER_EVENTS (1<<4)
898#define TCL_IDLE_EVENTS (1<<5) /* WAS 0x10 ???? */
899#define TCL_ALL_EVENTS (~TCL_DONT_WAIT)
900
901/*
902 * The following structure defines a generic event for the Tcl event
903 * system. These are the things that are queued in calls to Tcl_QueueEvent
904 * and serviced later by Tcl_DoOneEvent. There can be many different
905 * kinds of events with different fields, corresponding to window events,
906 * timer events, etc. The structure for a particular event consists of
907 * a Tcl_Event header followed by additional information specific to that
908 * event.
909 */
910
911struct Tcl_Event {
912 Tcl_EventProc *proc; /* Procedure to call to service this event. */
913 struct Tcl_Event *nextPtr; /* Next in list of pending events, or NULL. */
914};
915
916/*
917 * Positions to pass to Tcl_QueueEvent:
918 */
919
920typedef enum {
921 TCL_QUEUE_TAIL, TCL_QUEUE_HEAD, TCL_QUEUE_MARK
922} Tcl_QueuePosition;
923
924/*
925 * Values to pass to Tcl_SetServiceMode to specify the behavior of notifier
926 * event routines.
927 */
928
929#define TCL_SERVICE_NONE 0
930#define TCL_SERVICE_ALL 1
931
932/*
933 * The following structure keeps is used to hold a time value, either as
934 * an absolute time (the number of seconds from the epoch) or as an
935 * elapsed time. On Unix systems the epoch is Midnight Jan 1, 1970 GMT.
936 * On Macintosh systems the epoch is Midnight Jan 1, 1904 GMT.
937 */
938
939typedef struct Tcl_Time {
940 long sec; /* Seconds. */
941 long usec; /* Microseconds. */
942} Tcl_Time;
943
944/*
945 * Bits to pass to Tcl_CreateFileHandler and Tcl_CreateChannelHandler
946 * to indicate what sorts of events are of interest:
947 */
948
949#define TCL_READABLE (1<<1)
950#define TCL_WRITABLE (1<<2)
951#define TCL_EXCEPTION (1<<3)
952
953/*
954 * Flag values to pass to Tcl_OpenCommandChannel to indicate the
955 * disposition of the stdio handles. TCL_STDIN, TCL_STDOUT, TCL_STDERR,
956 * are also used in Tcl_GetStdChannel.
957 */
958
959#define TCL_STDIN (1<<1)
960#define TCL_STDOUT (1<<2)
961#define TCL_STDERR (1<<3)
962#define TCL_ENFORCE_MODE (1<<4)
963
964/*
965 * Typedefs for the various operations in a channel type:
966 */
967
968typedef int (Tcl_DriverBlockModeProc) _ANSI_ARGS_((
969 ClientData instanceData, int mode));
970typedef int (Tcl_DriverCloseProc) _ANSI_ARGS_((ClientData instanceData,
971 Tcl_Interp *interp));
972typedef int (Tcl_DriverInputProc) _ANSI_ARGS_((ClientData instanceData,
973 char *buf, int toRead, int *errorCodePtr));
974typedef int (Tcl_DriverOutputProc) _ANSI_ARGS_((ClientData instanceData,
975 char *buf, int toWrite, int *errorCodePtr));
976typedef int (Tcl_DriverSeekProc) _ANSI_ARGS_((ClientData instanceData,
977 long offset, int mode, int *errorCodePtr));
978typedef int (Tcl_DriverSetOptionProc) _ANSI_ARGS_((
979 ClientData instanceData, Tcl_Interp *interp,
980 char *optionName, char *value));
981typedef int (Tcl_DriverGetOptionProc) _ANSI_ARGS_((
982 ClientData instanceData, Tcl_Interp *interp,
983 char *optionName, Tcl_DString *dsPtr));
984typedef void (Tcl_DriverWatchProc) _ANSI_ARGS_((
985 ClientData instanceData, int mask));
986typedef int (Tcl_DriverGetHandleProc) _ANSI_ARGS_((
987 ClientData instanceData, int direction,
988 ClientData *handlePtr));
989
990/*
991 * Enum for different end of line translation and recognition modes.
992 */
993
994typedef enum Tcl_EolTranslation {
995 TCL_TRANSLATE_AUTO, /* Eol == \r, \n and \r\n. */
996 TCL_TRANSLATE_CR, /* Eol == \r. */
997 TCL_TRANSLATE_LF, /* Eol == \n. */
998 TCL_TRANSLATE_CRLF /* Eol == \r\n. */
999} Tcl_EolTranslation;
1000
1001/*
1002 * struct Tcl_ChannelType:
1003 *
1004 * One such structure exists for each type (kind) of channel.
1005 * It collects together in one place all the functions that are
1006 * part of the specific channel type.
1007 */
1008
1009typedef struct Tcl_ChannelType {
1010 char *typeName; /* The name of the channel type in Tcl
1011 * commands. This storage is owned by
1012 * channel type. */
1013 Tcl_DriverBlockModeProc *blockModeProc;
1014 /* Set blocking mode for the
1015 * raw channel. May be NULL. */
1016 Tcl_DriverCloseProc *closeProc; /* Procedure to call to close
1017 * the channel. */
1018 Tcl_DriverInputProc *inputProc; /* Procedure to call for input
1019 * on channel. */
1020 Tcl_DriverOutputProc *outputProc; /* Procedure to call for output
1021 * on channel. */
1022 Tcl_DriverSeekProc *seekProc; /* Procedure to call to seek
1023 * on the channel. May be NULL. */
1024 Tcl_DriverSetOptionProc *setOptionProc;
1025 /* Set an option on a channel. */
1026 Tcl_DriverGetOptionProc *getOptionProc;
1027 /* Get an option from a channel. */
1028 Tcl_DriverWatchProc *watchProc; /* Set up the notifier to watch
1029 * for events on this channel. */
1030 Tcl_DriverGetHandleProc *getHandleProc;
1031 /* Get an OS handle from the channel
1032 * or NULL if not supported. */
1033 VOID *reserved; /* reserved for future expansion */
1034} Tcl_ChannelType;
1035
1036/*
1037 * The following flags determine whether the blockModeProc above should
1038 * set the channel into blocking or nonblocking mode. They are passed
1039 * as arguments to the blockModeProc procedure in the above structure.
1040 */
1041
1042#define TCL_MODE_BLOCKING 0 /* Put channel into blocking mode. */
1043#define TCL_MODE_NONBLOCKING 1 /* Put channel into nonblocking
1044 * mode. */
1045
1046/*
1047 * Enum for different types of file paths.
1048 */
1049
1050typedef enum Tcl_PathType {
1051 TCL_PATH_ABSOLUTE,
1052 TCL_PATH_RELATIVE,
1053 TCL_PATH_VOLUME_RELATIVE
1054} Tcl_PathType;
1055
1056/*
1057 * Exported Tcl procedures:
1058 */
1059
1060EXTERN void Tcl_AddErrorInfo _ANSI_ARGS_((Tcl_Interp *interp,
1061 char *message));
1062EXTERN void Tcl_AddObjErrorInfo _ANSI_ARGS_((Tcl_Interp *interp,
1063 char *message, int length));
1064EXTERN void Tcl_AllowExceptions _ANSI_ARGS_((Tcl_Interp *interp));
1065EXTERN int Tcl_AppendAllObjTypes _ANSI_ARGS_((
1066 Tcl_Interp *interp, Tcl_Obj *objPtr));
1067EXTERN void Tcl_AppendElement _ANSI_ARGS_((Tcl_Interp *interp,
1068 char *string));
1069EXTERN void Tcl_AppendResult _ANSI_ARGS_(
1070 TCL_VARARGS(Tcl_Interp *,interp));
1071EXTERN void Tcl_AppendToObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1072 char *bytes, int length));
1073EXTERN void Tcl_AppendStringsToObj _ANSI_ARGS_(
1074 TCL_VARARGS(Tcl_Obj *,interp));
1075EXTERN Tcl_AsyncHandler Tcl_AsyncCreate _ANSI_ARGS_((Tcl_AsyncProc *proc,
1076 ClientData clientData));
1077EXTERN void Tcl_AsyncDelete _ANSI_ARGS_((Tcl_AsyncHandler async));
1078EXTERN int Tcl_AsyncInvoke _ANSI_ARGS_((Tcl_Interp *interp,
1079 int code));
1080EXTERN void Tcl_AsyncMark _ANSI_ARGS_((Tcl_AsyncHandler async));
1081EXTERN int Tcl_AsyncReady _ANSI_ARGS_((void));
1082EXTERN char Tcl_Backslash _ANSI_ARGS_((CONST char *src,
1083 int *readPtr));
1084EXTERN int Tcl_BadChannelOption _ANSI_ARGS_((Tcl_Interp *interp,
1085 char *optionName, char *optionList));
1086EXTERN void Tcl_CallWhenDeleted _ANSI_ARGS_((Tcl_Interp *interp,
1087 Tcl_InterpDeleteProc *proc,
1088 ClientData clientData));
1089EXTERN void Tcl_CancelIdleCall _ANSI_ARGS_((Tcl_IdleProc *idleProc,
1090 ClientData clientData));
1091#define Tcl_Ckalloc Tcl_Alloc
1092#define Tcl_Ckfree Tcl_Free
1093#define Tcl_Ckrealloc Tcl_Realloc
1094EXTERN int Tcl_Close _ANSI_ARGS_((Tcl_Interp *interp,
1095 Tcl_Channel chan));
1096EXTERN int Tcl_CommandComplete _ANSI_ARGS_((char *cmd));
1097EXTERN char * Tcl_Concat _ANSI_ARGS_((int argc, char **argv));
1098EXTERN Tcl_Obj * Tcl_ConcatObj _ANSI_ARGS_((int objc,
1099 Tcl_Obj *CONST objv[]));
1100EXTERN int Tcl_ConvertCountedElement _ANSI_ARGS_((CONST char *src,
1101 int length, char *dst, int flags));
1102EXTERN int Tcl_ConvertElement _ANSI_ARGS_((CONST char *src,
1103 char *dst, int flags));
1104EXTERN int Tcl_ConvertToType _ANSI_ARGS_((Tcl_Interp *interp,
1105 Tcl_Obj *objPtr, Tcl_ObjType *typePtr));
1106EXTERN int Tcl_CreateAlias _ANSI_ARGS_((Tcl_Interp *slave,
1107 char *slaveCmd, Tcl_Interp *target,
1108 char *targetCmd, int argc, char **argv));
1109EXTERN int Tcl_CreateAliasObj _ANSI_ARGS_((Tcl_Interp *slave,
1110 char *slaveCmd, Tcl_Interp *target,
1111 char *targetCmd, int objc,
1112 Tcl_Obj *CONST objv[]));
1113EXTERN Tcl_Channel Tcl_CreateChannel _ANSI_ARGS_((
1114 Tcl_ChannelType *typePtr, char *chanName,
1115 ClientData instanceData, int mask));
1116EXTERN void Tcl_CreateChannelHandler _ANSI_ARGS_((
1117 Tcl_Channel chan, int mask,
1118 Tcl_ChannelProc *proc, ClientData clientData));
1119EXTERN void Tcl_CreateCloseHandler _ANSI_ARGS_((
1120 Tcl_Channel chan, Tcl_CloseProc *proc,
1121 ClientData clientData));
1122EXTERN Tcl_Command Tcl_CreateCommand _ANSI_ARGS_((Tcl_Interp *interp,
1123 char *cmdName, Tcl_CmdProc *proc,
1124 ClientData clientData,
1125 Tcl_CmdDeleteProc *deleteProc));
1126EXTERN void Tcl_CreateEventSource _ANSI_ARGS_((
1127 Tcl_EventSetupProc *setupProc,
1128 Tcl_EventCheckProc *checkProc,
1129 ClientData clientData));
1130EXTERN void Tcl_CreateFileHandler _ANSI_ARGS_((
1131 int fd, int mask, Tcl_FileProc *proc,
1132 ClientData clientData));
1133EXTERN Tcl_Interp * Tcl_CreateInterp _ANSI_ARGS_((void));
1134EXTERN void Tcl_CreateMathFunc _ANSI_ARGS_((Tcl_Interp *interp,
1135 char *name, int numArgs, Tcl_ValueType *argTypes,
1136 Tcl_MathProc *proc, ClientData clientData));
1137EXTERN Tcl_Command Tcl_CreateObjCommand _ANSI_ARGS_((
1138 Tcl_Interp *interp, char *cmdName,
1139 Tcl_ObjCmdProc *proc, ClientData clientData,
1140 Tcl_CmdDeleteProc *deleteProc));
1141EXTERN Tcl_Interp * Tcl_CreateSlave _ANSI_ARGS_((Tcl_Interp *interp,
1142 char *slaveName, int isSafe));
1143EXTERN Tcl_TimerToken Tcl_CreateTimerHandler _ANSI_ARGS_((int milliseconds,
1144 Tcl_TimerProc *proc, ClientData clientData));
1145EXTERN Tcl_Trace Tcl_CreateTrace _ANSI_ARGS_((Tcl_Interp *interp,
1146 int level, Tcl_CmdTraceProc *proc,
1147 ClientData clientData));
1148EXTERN char * Tcl_DbCkalloc _ANSI_ARGS_((unsigned int size,
1149 char *file, int line));
1150EXTERN int Tcl_DbCkfree _ANSI_ARGS_((char *ptr,
1151 char *file, int line));
1152EXTERN char * Tcl_DbCkrealloc _ANSI_ARGS_((char *ptr,
1153 unsigned int size, char *file, int line));
1154EXTERN void Tcl_DbDecrRefCount _ANSI_ARGS_((Tcl_Obj *objPtr,
1155 char *file, int line));
1156EXTERN void Tcl_DbIncrRefCount _ANSI_ARGS_((Tcl_Obj *objPtr,
1157 char *file, int line));
1158EXTERN int Tcl_DbIsShared _ANSI_ARGS_((Tcl_Obj *objPtr,
1159 char *file, int line));
1160EXTERN Tcl_Obj * Tcl_DbNewBooleanObj _ANSI_ARGS_((int boolValue,
1161 char *file, int line));
1162EXTERN Tcl_Obj * Tcl_DbNewDoubleObj _ANSI_ARGS_((double doubleValue,
1163 char *file, int line));
1164EXTERN Tcl_Obj * Tcl_DbNewListObj _ANSI_ARGS_((int objc,
1165 Tcl_Obj *CONST objv[], char *file, int line));
1166EXTERN Tcl_Obj * Tcl_DbNewLongObj _ANSI_ARGS_((long longValue,
1167 char *file, int line));
1168EXTERN Tcl_Obj * Tcl_DbNewObj _ANSI_ARGS_((char *file, int line));
1169EXTERN Tcl_Obj * Tcl_DbNewStringObj _ANSI_ARGS_((char *bytes,
1170 int length, char *file, int line));
1171EXTERN void Tcl_DeleteAssocData _ANSI_ARGS_((Tcl_Interp *interp,
1172 char *name));
1173EXTERN int Tcl_DeleteCommand _ANSI_ARGS_((Tcl_Interp *interp,
1174 char *cmdName));
1175EXTERN int Tcl_DeleteCommandFromToken _ANSI_ARGS_((
1176 Tcl_Interp *interp, Tcl_Command command));
1177EXTERN void Tcl_DeleteChannelHandler _ANSI_ARGS_((
1178 Tcl_Channel chan, Tcl_ChannelProc *proc,
1179 ClientData clientData));
1180EXTERN void Tcl_DeleteCloseHandler _ANSI_ARGS_((
1181 Tcl_Channel chan, Tcl_CloseProc *proc,
1182 ClientData clientData));
1183EXTERN void Tcl_DeleteEvents _ANSI_ARGS_((
1184 Tcl_EventDeleteProc *proc,
1185 ClientData clientData));
1186EXTERN void Tcl_DeleteEventSource _ANSI_ARGS_((
1187 Tcl_EventSetupProc *setupProc,
1188 Tcl_EventCheckProc *checkProc,
1189 ClientData clientData));
1190EXTERN void Tcl_DeleteExitHandler _ANSI_ARGS_((Tcl_ExitProc *proc,
1191 ClientData clientData));
1192EXTERN void Tcl_DeleteFileHandler _ANSI_ARGS_((int fd));
1193EXTERN void Tcl_DeleteHashEntry _ANSI_ARGS_((
1194 Tcl_HashEntry *entryPtr));
1195EXTERN void Tcl_DeleteHashTable _ANSI_ARGS_((
1196 Tcl_HashTable *tablePtr));
1197EXTERN void Tcl_DeleteInterp _ANSI_ARGS_((Tcl_Interp *interp));
1198EXTERN void Tcl_DeleteTimerHandler _ANSI_ARGS_((
1199 Tcl_TimerToken token));
1200EXTERN void Tcl_DeleteTrace _ANSI_ARGS_((Tcl_Interp *interp,
1201 Tcl_Trace trace));
1202EXTERN void Tcl_DetachPids _ANSI_ARGS_((int numPids, Tcl_Pid *pidPtr));
1203EXTERN void Tcl_DontCallWhenDeleted _ANSI_ARGS_((
1204 Tcl_Interp *interp, Tcl_InterpDeleteProc *proc,
1205 ClientData clientData));
1206EXTERN int Tcl_DoOneEvent _ANSI_ARGS_((int flags));
1207EXTERN void Tcl_DoWhenIdle _ANSI_ARGS_((Tcl_IdleProc *proc,
1208 ClientData clientData));
1209EXTERN char * Tcl_DStringAppend _ANSI_ARGS_((Tcl_DString *dsPtr,
1210 CONST char *string, int length));
1211EXTERN char * Tcl_DStringAppendElement _ANSI_ARGS_((
1212 Tcl_DString *dsPtr, CONST char *string));
1213EXTERN void Tcl_DStringEndSublist _ANSI_ARGS_((Tcl_DString *dsPtr));
1214EXTERN void Tcl_DStringFree _ANSI_ARGS_((Tcl_DString *dsPtr));
1215EXTERN void Tcl_DStringGetResult _ANSI_ARGS_((Tcl_Interp *interp,
1216 Tcl_DString *dsPtr));
1217EXTERN void Tcl_DStringInit _ANSI_ARGS_((Tcl_DString *dsPtr));
1218EXTERN void Tcl_DStringResult _ANSI_ARGS_((Tcl_Interp *interp,
1219 Tcl_DString *dsPtr));
1220EXTERN void Tcl_DStringSetLength _ANSI_ARGS_((Tcl_DString *dsPtr,
1221 int length));
1222EXTERN void Tcl_DStringStartSublist _ANSI_ARGS_((
1223 Tcl_DString *dsPtr));
1224EXTERN Tcl_Obj * Tcl_DuplicateObj _ANSI_ARGS_((Tcl_Obj *objPtr));
1225EXTERN int Tcl_Eof _ANSI_ARGS_((Tcl_Channel chan));
1226EXTERN char * Tcl_ErrnoId _ANSI_ARGS_((void));
1227EXTERN char * Tcl_ErrnoMsg _ANSI_ARGS_((int err));
1228EXTERN int Tcl_Eval _ANSI_ARGS_((Tcl_Interp *interp,
1229 char *string));
1230EXTERN int Tcl_EvalFile _ANSI_ARGS_((Tcl_Interp *interp,
1231 char *fileName));
1232EXTERN void Tcl_EventuallyFree _ANSI_ARGS_((ClientData clientData,
1233 Tcl_FreeProc *freeProc));
1234EXTERN int Tcl_EvalObj _ANSI_ARGS_((Tcl_Interp *interp,
1235 Tcl_Obj *objPtr));
1236EXTERN int Tcl_ExposeCommand _ANSI_ARGS_((Tcl_Interp *interp,
1237 char *hiddenCmdToken, char *cmdName));
1238EXTERN int Tcl_ExprBoolean _ANSI_ARGS_((Tcl_Interp *interp,
1239 char *string, int *ptr));
1240EXTERN int Tcl_ExprBooleanObj _ANSI_ARGS_((Tcl_Interp *interp,
1241 Tcl_Obj *objPtr, int *ptr));
1242EXTERN int Tcl_ExprDouble _ANSI_ARGS_((Tcl_Interp *interp,
1243 char *string, double *ptr));
1244EXTERN int Tcl_ExprDoubleObj _ANSI_ARGS_((Tcl_Interp *interp,
1245 Tcl_Obj *objPtr, double *ptr));
1246EXTERN int Tcl_ExprLong _ANSI_ARGS_((Tcl_Interp *interp,
1247 char *string, long *ptr));
1248EXTERN int Tcl_ExprLongObj _ANSI_ARGS_((Tcl_Interp *interp,
1249 Tcl_Obj *objPtr, long *ptr));
1250EXTERN int Tcl_ExprObj _ANSI_ARGS_((Tcl_Interp *interp,
1251 Tcl_Obj *objPtr, Tcl_Obj **resultPtrPtr));
1252EXTERN int Tcl_ExprString _ANSI_ARGS_((Tcl_Interp *interp,
1253 char *string));
1254EXTERN void Tcl_Finalize _ANSI_ARGS_((void));
1255EXTERN void Tcl_FindExecutable _ANSI_ARGS_((char *argv0));
1256EXTERN Tcl_HashEntry * Tcl_FirstHashEntry _ANSI_ARGS_((
1257 Tcl_HashTable *tablePtr,
1258 Tcl_HashSearch *searchPtr));
1259EXTERN int Tcl_Flush _ANSI_ARGS_((Tcl_Channel chan));
1260EXTERN void TclFreeObj _ANSI_ARGS_((Tcl_Obj *objPtr));
1261EXTERN void Tcl_FreeResult _ANSI_ARGS_((Tcl_Interp *interp));
1262EXTERN int Tcl_GetAlias _ANSI_ARGS_((Tcl_Interp *interp,
1263 char *slaveCmd, Tcl_Interp **targetInterpPtr,
1264 char **targetCmdPtr, int *argcPtr,
1265 char ***argvPtr));
1266EXTERN int Tcl_GetAliasObj _ANSI_ARGS_((Tcl_Interp *interp,
1267 char *slaveCmd, Tcl_Interp **targetInterpPtr,
1268 char **targetCmdPtr, int *objcPtr,
1269 Tcl_Obj ***objv));
1270EXTERN ClientData Tcl_GetAssocData _ANSI_ARGS_((Tcl_Interp *interp,
1271 char *name, Tcl_InterpDeleteProc **procPtr));
1272EXTERN int Tcl_GetBoolean _ANSI_ARGS_((Tcl_Interp *interp,
1273 char *string, int *boolPtr));
1274EXTERN int Tcl_GetBooleanFromObj _ANSI_ARGS_((
1275 Tcl_Interp *interp, Tcl_Obj *objPtr,
1276 int *boolPtr));
1277EXTERN int Tcl_GetChannelHandle _ANSI_ARGS_((Tcl_Channel chan,
1278 int direction, ClientData *handlePtr));
1279EXTERN ClientData Tcl_GetChannelInstanceData _ANSI_ARGS_((
1280 Tcl_Channel chan));
1281EXTERN int Tcl_GetChannelMode _ANSI_ARGS_((Tcl_Channel chan));
1282EXTERN char * Tcl_GetChannelName _ANSI_ARGS_((Tcl_Channel chan));
1283EXTERN int Tcl_GetChannelOption _ANSI_ARGS_((Tcl_Interp *interp,
1284 Tcl_Channel chan, char *optionName,
1285 Tcl_DString *dsPtr));
1286EXTERN Tcl_ChannelType * Tcl_GetChannelType _ANSI_ARGS_((Tcl_Channel chan));
1287EXTERN int Tcl_GetCommandInfo _ANSI_ARGS_((Tcl_Interp *interp,
1288 char *cmdName, Tcl_CmdInfo *infoPtr));
1289EXTERN char * Tcl_GetCommandName _ANSI_ARGS_((Tcl_Interp *interp,
1290 Tcl_Command command));
1291EXTERN int Tcl_GetDouble _ANSI_ARGS_((Tcl_Interp *interp,
1292 char *string, double *doublePtr));
1293EXTERN int Tcl_GetDoubleFromObj _ANSI_ARGS_((
1294 Tcl_Interp *interp, Tcl_Obj *objPtr,
1295 double *doublePtr));
1296EXTERN int Tcl_GetErrno _ANSI_ARGS_((void));
1297EXTERN char * Tcl_GetHostName _ANSI_ARGS_((void));
1298EXTERN int Tcl_GetIndexFromObj _ANSI_ARGS_((Tcl_Interp *interp,
1299 Tcl_Obj *objPtr, char **tablePtr, char *msg,
1300 int flags, int *indexPtr));
1301EXTERN int Tcl_GetInt _ANSI_ARGS_((Tcl_Interp *interp,
1302 char *string, int *intPtr));
1303EXTERN int Tcl_GetInterpPath _ANSI_ARGS_((Tcl_Interp *askInterp,
1304 Tcl_Interp *slaveInterp));
1305EXTERN int Tcl_GetIntFromObj _ANSI_ARGS_((Tcl_Interp *interp,
1306 Tcl_Obj *objPtr, int *intPtr));
1307EXTERN int Tcl_GetLongFromObj _ANSI_ARGS_((Tcl_Interp *interp,
1308 Tcl_Obj *objPtr, long *longPtr));
1309EXTERN Tcl_Interp * Tcl_GetMaster _ANSI_ARGS_((Tcl_Interp *interp));
1310EXTERN CONST char * Tcl_GetNameOfExecutable _ANSI_ARGS_((void));
1311EXTERN Tcl_Obj * Tcl_GetObjResult _ANSI_ARGS_((Tcl_Interp *interp));
1312EXTERN Tcl_ObjType * Tcl_GetObjType _ANSI_ARGS_((char *typeName));
1313EXTERN int Tcl_GetOpenFile _ANSI_ARGS_((Tcl_Interp *interp,
1314 char *string, int write, int checkUsage,
1315 ClientData *filePtr));
1316EXTERN Tcl_PathType Tcl_GetPathType _ANSI_ARGS_((char *path));
1317EXTERN int Tcl_Gets _ANSI_ARGS_((Tcl_Channel chan,
1318 Tcl_DString *dsPtr));
1319EXTERN int Tcl_GetsObj _ANSI_ARGS_((Tcl_Channel chan,
1320 Tcl_Obj *objPtr));
1321EXTERN int Tcl_GetServiceMode _ANSI_ARGS_((void));
1322EXTERN Tcl_Interp * Tcl_GetSlave _ANSI_ARGS_((Tcl_Interp *interp,
1323 char *slaveName));
1324EXTERN char * Tcl_GetStringFromObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1325 int *lengthPtr));
1326EXTERN char * Tcl_GetStringResult _ANSI_ARGS_((Tcl_Interp *interp));
1327EXTERN char * Tcl_GetVar _ANSI_ARGS_((Tcl_Interp *interp,
1328 char *varName, int flags));
1329EXTERN char * Tcl_GetVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1330 char *part1, char *part2, int flags));
1331EXTERN int Tcl_GlobalEval _ANSI_ARGS_((Tcl_Interp *interp,
1332 char *command));
1333EXTERN int Tcl_GlobalEvalObj _ANSI_ARGS_((Tcl_Interp *interp,
1334 Tcl_Obj *objPtr));
1335EXTERN char * Tcl_HashStats _ANSI_ARGS_((Tcl_HashTable *tablePtr));
1336EXTERN int Tcl_HideCommand _ANSI_ARGS_((Tcl_Interp *interp,
1337 char *cmdName, char *hiddenCmdToken));
1338EXTERN void Tcl_InitHashTable _ANSI_ARGS_((Tcl_HashTable *tablePtr,
1339 int keyType));
1340EXTERN void Tcl_InitMemory _ANSI_ARGS_((Tcl_Interp *interp));
1341EXTERN int Tcl_InputBlocked _ANSI_ARGS_((Tcl_Channel chan));
1342EXTERN int Tcl_InputBuffered _ANSI_ARGS_((Tcl_Channel chan));
1343EXTERN int Tcl_InterpDeleted _ANSI_ARGS_((Tcl_Interp *interp));
1344EXTERN int Tcl_IsSafe _ANSI_ARGS_((Tcl_Interp *interp));
1345EXTERN void Tcl_InvalidateStringRep _ANSI_ARGS_((
1346 Tcl_Obj *objPtr));
1347EXTERN char * Tcl_JoinPath _ANSI_ARGS_((int argc, char **argv,
1348 Tcl_DString *resultPtr));
1349EXTERN int Tcl_LinkVar _ANSI_ARGS_((Tcl_Interp *interp,
1350 char *varName, char *addr, int type));
1351EXTERN int Tcl_ListObjAppendList _ANSI_ARGS_((
1352 Tcl_Interp *interp, Tcl_Obj *listPtr,
1353 Tcl_Obj *elemListPtr));
1354EXTERN int Tcl_ListObjAppendElement _ANSI_ARGS_((
1355 Tcl_Interp *interp, Tcl_Obj *listPtr,
1356 Tcl_Obj *objPtr));
1357EXTERN int Tcl_ListObjGetElements _ANSI_ARGS_((
1358 Tcl_Interp *interp, Tcl_Obj *listPtr,
1359 int *objcPtr, Tcl_Obj ***objvPtr));
1360EXTERN int Tcl_ListObjIndex _ANSI_ARGS_((Tcl_Interp *interp,
1361 Tcl_Obj *listPtr, int index,
1362 Tcl_Obj **objPtrPtr));
1363EXTERN int Tcl_ListObjLength _ANSI_ARGS_((Tcl_Interp *interp,
1364 Tcl_Obj *listPtr, int *intPtr));
1365EXTERN int Tcl_ListObjReplace _ANSI_ARGS_((Tcl_Interp *interp,
1366 Tcl_Obj *listPtr, int first, int count,
1367 int objc, Tcl_Obj *CONST objv[]));
1368EXTERN void Tcl_Main _ANSI_ARGS_((int argc, char **argv,
1369 Tcl_AppInitProc *appInitProc));
1370EXTERN Tcl_Channel Tcl_MakeFileChannel _ANSI_ARGS_((ClientData handle,
1371 int mode));
1372EXTERN int Tcl_MakeSafe _ANSI_ARGS_((Tcl_Interp *interp));
1373EXTERN Tcl_Channel Tcl_MakeTcpClientChannel _ANSI_ARGS_((
1374 ClientData tcpSocket));
1375EXTERN char * Tcl_Merge _ANSI_ARGS_((int argc, char **argv));
1376EXTERN Tcl_HashEntry * Tcl_NextHashEntry _ANSI_ARGS_((
1377 Tcl_HashSearch *searchPtr));
1378EXTERN void Tcl_NotifyChannel _ANSI_ARGS_((Tcl_Channel channel,
1379 int mask));
1380EXTERN Tcl_Obj * Tcl_ObjGetVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1381 Tcl_Obj *part1Ptr, Tcl_Obj *part2Ptr,
1382 int flags));
1383EXTERN Tcl_Obj * Tcl_ObjSetVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1384 Tcl_Obj *part1Ptr, Tcl_Obj *part2Ptr,
1385 Tcl_Obj *newValuePtr, int flags));
1386EXTERN Tcl_Channel Tcl_OpenCommandChannel _ANSI_ARGS_((
1387 Tcl_Interp *interp, int argc, char **argv,
1388 int flags));
1389EXTERN Tcl_Channel Tcl_OpenFileChannel _ANSI_ARGS_((Tcl_Interp *interp,
1390 char *fileName, char *modeString,
1391 int permissions));
1392EXTERN Tcl_Channel Tcl_OpenTcpClient _ANSI_ARGS_((Tcl_Interp *interp,
1393 int port, char *address, char *myaddr,
1394 int myport, int async));
1395EXTERN Tcl_Channel Tcl_OpenTcpServer _ANSI_ARGS_((Tcl_Interp *interp,
1396 int port, char *host,
1397 Tcl_TcpAcceptProc *acceptProc,
1398 ClientData callbackData));
1399EXTERN char * Tcl_ParseVar _ANSI_ARGS_((Tcl_Interp *interp,
1400 char *string, char **termPtr));
1401EXTERN int Tcl_PkgProvide _ANSI_ARGS_((Tcl_Interp *interp,
1402 char *name, char *version));
1403EXTERN char * Tcl_PkgRequire _ANSI_ARGS_((Tcl_Interp *interp,
1404 char *name, char *version, int exact));
1405EXTERN char * Tcl_PosixError _ANSI_ARGS_((Tcl_Interp *interp));
1406EXTERN void Tcl_Preserve _ANSI_ARGS_((ClientData data));
1407EXTERN void Tcl_PrintDouble _ANSI_ARGS_((Tcl_Interp *interp,
1408 double value, char *dst));
1409EXTERN int Tcl_PutEnv _ANSI_ARGS_((CONST char *string));
1410EXTERN void Tcl_QueueEvent _ANSI_ARGS_((Tcl_Event *evPtr,
1411 Tcl_QueuePosition position));
1412EXTERN int Tcl_Read _ANSI_ARGS_((Tcl_Channel chan,
1413 char *bufPtr, int toRead));
1414EXTERN void Tcl_ReapDetachedProcs _ANSI_ARGS_((void));
1415EXTERN int Tcl_RecordAndEval _ANSI_ARGS_((Tcl_Interp *interp,
1416 char *cmd, int flags));
1417EXTERN int Tcl_RecordAndEvalObj _ANSI_ARGS_((Tcl_Interp *interp,
1418 Tcl_Obj *cmdPtr, int flags));
1419EXTERN Tcl_RegExp Tcl_RegExpCompile _ANSI_ARGS_((Tcl_Interp *interp,
1420 char *string));
1421EXTERN int Tcl_RegExpExec _ANSI_ARGS_((Tcl_Interp *interp,
1422 Tcl_RegExp regexp, char *string, char *start));
1423EXTERN int Tcl_RegExpMatch _ANSI_ARGS_((Tcl_Interp *interp,
1424 char *string, char *pattern));
1425EXTERN void Tcl_RegExpRange _ANSI_ARGS_((Tcl_RegExp regexp,
1426 int index, char **startPtr, char **endPtr));
1427EXTERN void Tcl_RegisterObjType _ANSI_ARGS_((
1428 Tcl_ObjType *typePtr));
1429EXTERN void Tcl_Release _ANSI_ARGS_((ClientData clientData));
1430EXTERN void Tcl_ResetResult _ANSI_ARGS_((Tcl_Interp *interp));
1431#define Tcl_Return Tcl_SetResult
1432EXTERN int Tcl_ScanCountedElement _ANSI_ARGS_((CONST char *string,
1433 int length, int *flagPtr));
1434EXTERN int Tcl_ScanElement _ANSI_ARGS_((CONST char *string,
1435 int *flagPtr));
1436EXTERN int Tcl_Seek _ANSI_ARGS_((Tcl_Channel chan,
1437 int offset, int mode));
1438EXTERN int Tcl_ServiceAll _ANSI_ARGS_((void));
1439EXTERN int Tcl_ServiceEvent _ANSI_ARGS_((int flags));
1440EXTERN void Tcl_SetAssocData _ANSI_ARGS_((Tcl_Interp *interp,
1441 char *name, Tcl_InterpDeleteProc *proc,
1442 ClientData clientData));
1443EXTERN void Tcl_SetBooleanObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1444 int boolValue));
1445EXTERN void Tcl_SetChannelBufferSize _ANSI_ARGS_((
1446 Tcl_Channel chan, int sz));
1447EXTERN int Tcl_SetChannelOption _ANSI_ARGS_((
1448 Tcl_Interp *interp, Tcl_Channel chan,
1449 char *optionName, char *newValue));
1450EXTERN int Tcl_SetCommandInfo _ANSI_ARGS_((Tcl_Interp *interp,
1451 char *cmdName, Tcl_CmdInfo *infoPtr));
1452EXTERN void Tcl_SetDoubleObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1453 double doubleValue));
1454EXTERN void Tcl_SetErrno _ANSI_ARGS_((int err));
1455EXTERN void Tcl_SetErrorCode _ANSI_ARGS_(
1456 TCL_VARARGS(Tcl_Interp *,arg1));
1457EXTERN void Tcl_SetIntObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1458 int intValue));
1459EXTERN void Tcl_SetListObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1460 int objc, Tcl_Obj *CONST objv[]));
1461EXTERN void Tcl_SetLongObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1462 long longValue));
1463EXTERN void Tcl_SetMaxBlockTime _ANSI_ARGS_((Tcl_Time *timePtr));
1464EXTERN void Tcl_SetObjErrorCode _ANSI_ARGS_((Tcl_Interp *interp,
1465 Tcl_Obj *errorObjPtr));
1466EXTERN void Tcl_SetObjLength _ANSI_ARGS_((Tcl_Obj *objPtr,
1467 int length));
1468EXTERN void Tcl_SetObjResult _ANSI_ARGS_((Tcl_Interp *interp,
1469 Tcl_Obj *resultObjPtr));
1470EXTERN void Tcl_SetPanicProc _ANSI_ARGS_((void (*proc)
1471 _ANSI_ARGS_(TCL_VARARGS(char *, format))));
1472EXTERN int Tcl_SetRecursionLimit _ANSI_ARGS_((Tcl_Interp *interp,
1473 int depth));
1474EXTERN void Tcl_SetResult _ANSI_ARGS_((Tcl_Interp *interp,
1475 char *string, Tcl_FreeProc *freeProc));
1476EXTERN int Tcl_SetServiceMode _ANSI_ARGS_((int mode));
1477EXTERN void Tcl_SetStdChannel _ANSI_ARGS_((Tcl_Channel channel,
1478 int type));
1479EXTERN void Tcl_SetStringObj _ANSI_ARGS_((Tcl_Obj *objPtr,
1480 char *bytes, int length));
1481EXTERN void Tcl_SetTimer _ANSI_ARGS_((Tcl_Time *timePtr));
1482EXTERN char * Tcl_SetVar _ANSI_ARGS_((Tcl_Interp *interp,
1483 char *varName, char *newValue, int flags));
1484EXTERN char * Tcl_SetVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1485 char *part1, char *part2, char *newValue,
1486 int flags));
1487EXTERN char * Tcl_SignalId _ANSI_ARGS_((int sig));
1488EXTERN char * Tcl_SignalMsg _ANSI_ARGS_((int sig));
1489EXTERN void Tcl_SourceRCFile _ANSI_ARGS_((Tcl_Interp *interp));
1490EXTERN int Tcl_SplitList _ANSI_ARGS_((Tcl_Interp *interp,
1491 char *list, int *argcPtr, char ***argvPtr));
1492EXTERN void Tcl_SplitPath _ANSI_ARGS_((char *path,
1493 int *argcPtr, char ***argvPtr));
1494EXTERN void Tcl_StaticPackage _ANSI_ARGS_((Tcl_Interp *interp,
1495 char *pkgName, Tcl_PackageInitProc *initProc,
1496 Tcl_PackageInitProc *safeInitProc));
1497EXTERN int Tcl_StringMatch _ANSI_ARGS_((char *string,
1498 char *pattern));
1499EXTERN int Tcl_Tell _ANSI_ARGS_((Tcl_Channel chan));
1500#define Tcl_TildeSubst Tcl_TranslateFileName
1501EXTERN int Tcl_TraceVar _ANSI_ARGS_((Tcl_Interp *interp,
1502 char *varName, int flags, Tcl_VarTraceProc *proc,
1503 ClientData clientData));
1504EXTERN int Tcl_TraceVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1505 char *part1, char *part2, int flags,
1506 Tcl_VarTraceProc *proc, ClientData clientData));
1507EXTERN char * Tcl_TranslateFileName _ANSI_ARGS_((Tcl_Interp *interp,
1508 char *name, Tcl_DString *bufferPtr));
1509EXTERN int Tcl_Ungets _ANSI_ARGS_((Tcl_Channel chan, char *str,
1510 int len, int atHead));
1511EXTERN void Tcl_UnlinkVar _ANSI_ARGS_((Tcl_Interp *interp,
1512 char *varName));
1513EXTERN int Tcl_UnsetVar _ANSI_ARGS_((Tcl_Interp *interp,
1514 char *varName, int flags));
1515EXTERN int Tcl_UnsetVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1516 char *part1, char *part2, int flags));
1517EXTERN void Tcl_UntraceVar _ANSI_ARGS_((Tcl_Interp *interp,
1518 char *varName, int flags, Tcl_VarTraceProc *proc,
1519 ClientData clientData));
1520EXTERN void Tcl_UntraceVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1521 char *part1, char *part2, int flags,
1522 Tcl_VarTraceProc *proc, ClientData clientData));
1523EXTERN void Tcl_UpdateLinkedVar _ANSI_ARGS_((Tcl_Interp *interp,
1524 char *varName));
1525EXTERN int Tcl_UpVar _ANSI_ARGS_((Tcl_Interp *interp,
1526 char *frameName, char *varName,
1527 char *localName, int flags));
1528EXTERN int Tcl_UpVar2 _ANSI_ARGS_((Tcl_Interp *interp,
1529 char *frameName, char *part1, char *part2,
1530 char *localName, int flags));
1531EXTERN int Tcl_VarEval _ANSI_ARGS_(
1532 TCL_VARARGS(Tcl_Interp *,interp));
1533EXTERN ClientData Tcl_VarTraceInfo _ANSI_ARGS_((Tcl_Interp *interp,
1534 char *varName, int flags,
1535 Tcl_VarTraceProc *procPtr,
1536 ClientData prevClientData));
1537EXTERN ClientData Tcl_VarTraceInfo2 _ANSI_ARGS_((Tcl_Interp *interp,
1538 char *part1, char *part2, int flags,
1539 Tcl_VarTraceProc *procPtr,
1540 ClientData prevClientData));
1541EXTERN Tcl_Pid Tcl_WaitPid _ANSI_ARGS_((Tcl_Pid pid, int *statPtr,
1542 int options));
1543EXTERN int Tcl_Write _ANSI_ARGS_((Tcl_Channel chan,
1544 char *s, int slen));
1545EXTERN void Tcl_WrongNumArgs _ANSI_ARGS_((Tcl_Interp *interp,
1546 int objc, Tcl_Obj *CONST objv[], char *message));
1547
1548#undef TCL_STORAGE_CLASS
1549#define TCL_STORAGE_CLASS
1550
1551/*
1552 * Convenience declaration of Tcl_AppInit for backwards compatibility.
1553 * This function is not *implemented* by the tcl library, so the storage
1554 * class is neither DLLEXPORT nor DLLIMPORT
1555 */
1556
1557EXTERN int Tcl_AppInit _ANSI_ARGS_((Tcl_Interp *interp));
1558
1559#endif /* RESOURCE_INCLUDED */
1560
1561#undef TCL_STORAGE_CLASS
1562#define TCL_STORAGE_CLASS DLLIMPORT
1563
1564#endif /* _TCL */
Note: See TracBrowser for help on using the repository browser.