diff options
Diffstat (limited to 'generic/tclPlatDecls.h')
| -rw-r--r-- | generic/tclPlatDecls.h | 103 |
1 files changed, 40 insertions, 63 deletions
diff --git a/generic/tclPlatDecls.h b/generic/tclPlatDecls.h index 8d1eee1..ef23c84 100644 --- a/generic/tclPlatDecls.h +++ b/generic/tclPlatDecls.h @@ -22,12 +22,6 @@ #endif /* - * WARNING: This file is automatically generated by the tools/genStubs.tcl - * script. Any modifications to the function declarations below should be made - * in the generic/tcl.decls script. - */ - -/* * TCHAR is needed here for win32, so if it is not defined yet do it here. * This way, we don't need to include <tchar.h> just for one define. */ @@ -40,14 +34,6 @@ # define _TCHAR_DEFINED #endif -#ifndef MODULE_SCOPE -# ifdef __cplusplus -# define MODULE_SCOPE extern "C" -# else -# define MODULE_SCOPE extern -# endif -#endif - /* !BEGIN!: Do not edit below this line. */ #ifdef __cplusplus @@ -58,102 +44,93 @@ extern "C" { * Exported function declarations: */ -#if defined(_WIN32) || defined(__CYGWIN__) /* WIN */ +#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */ +#ifndef Tcl_WinUtfToTChar_TCL_DECLARED +#define Tcl_WinUtfToTChar_TCL_DECLARED /* 0 */ -EXTERN TCHAR * Tcl_WinUtfToTChar(const char *str, int len, +EXTERN TCHAR * Tcl_WinUtfToTChar(CONST char *str, int len, Tcl_DString *dsPtr); +#endif +#ifndef Tcl_WinTCharToUtf_TCL_DECLARED +#define Tcl_WinTCharToUtf_TCL_DECLARED /* 1 */ -EXTERN char * Tcl_WinTCharToUtf(const TCHAR *str, int len, +EXTERN char * Tcl_WinTCharToUtf(CONST TCHAR *str, int len, Tcl_DString *dsPtr); -/* Slot 2 is reserved */ -/* 3 */ -EXTERN void Tcl_WinConvertError(unsigned errCode); +#endif #endif /* WIN */ #ifdef MAC_OSX_TCL /* MACOSX */ +#ifndef Tcl_MacOSXOpenBundleResources_TCL_DECLARED +#define Tcl_MacOSXOpenBundleResources_TCL_DECLARED /* 0 */ EXTERN int Tcl_MacOSXOpenBundleResources(Tcl_Interp *interp, - const char *bundleName, int hasResourceFile, - Tcl_Size maxPathLen, char *libraryPath); + CONST char *bundleName, int hasResourceFile, + int maxPathLen, char *libraryPath); +#endif +#ifndef Tcl_MacOSXOpenVersionedBundleResources_TCL_DECLARED +#define Tcl_MacOSXOpenVersionedBundleResources_TCL_DECLARED /* 1 */ EXTERN int Tcl_MacOSXOpenVersionedBundleResources( - Tcl_Interp *interp, const char *bundleName, - const char *bundleVersion, - int hasResourceFile, Tcl_Size maxPathLen, + Tcl_Interp *interp, CONST char *bundleName, + CONST char *bundleVersion, + int hasResourceFile, int maxPathLen, char *libraryPath); -/* 2 */ -EXTERN void Tcl_MacOSXNotifierAddRunLoopMode( - const void *runLoopMode); +#endif #endif /* MACOSX */ typedef struct TclPlatStubs { int magic; - void *hooks; + struct TclPlatStubHooks *hooks; -#if defined(_WIN32) || defined(__CYGWIN__) /* WIN */ - TCHAR * (*tcl_WinUtfToTChar) (const char *str, int len, Tcl_DString *dsPtr); /* 0 */ - char * (*tcl_WinTCharToUtf) (const TCHAR *str, int len, Tcl_DString *dsPtr); /* 1 */ - void (*reserved2)(void); - void (*tcl_WinConvertError) (unsigned errCode); /* 3 */ +#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */ + TCHAR * (*tcl_WinUtfToTChar) (CONST char *str, int len, Tcl_DString *dsPtr); /* 0 */ + char * (*tcl_WinTCharToUtf) (CONST TCHAR *str, int len, Tcl_DString *dsPtr); /* 1 */ #endif /* WIN */ #ifdef MAC_OSX_TCL /* MACOSX */ - int (*tcl_MacOSXOpenBundleResources) (Tcl_Interp *interp, const char *bundleName, int hasResourceFile, Tcl_Size maxPathLen, char *libraryPath); /* 0 */ - int (*tcl_MacOSXOpenVersionedBundleResources) (Tcl_Interp *interp, const char *bundleName, const char *bundleVersion, int hasResourceFile, Tcl_Size maxPathLen, char *libraryPath); /* 1 */ - void (*tcl_MacOSXNotifierAddRunLoopMode) (const void *runLoopMode); /* 2 */ + int (*tcl_MacOSXOpenBundleResources) (Tcl_Interp *interp, CONST char *bundleName, int hasResourceFile, int maxPathLen, char *libraryPath); /* 0 */ + int (*tcl_MacOSXOpenVersionedBundleResources) (Tcl_Interp *interp, CONST char *bundleName, CONST char *bundleVersion, int hasResourceFile, int maxPathLen, char *libraryPath); /* 1 */ #endif /* MACOSX */ } TclPlatStubs; -extern const TclPlatStubs *tclPlatStubsPtr; +extern TclPlatStubs *tclPlatStubsPtr; #ifdef __cplusplus } #endif -#if defined(USE_TCL_STUBS) +#if defined(USE_TCL_STUBS) && !defined(USE_TCL_STUB_PROCS) /* * Inline function declarations: */ -#if defined(_WIN32) || defined(__CYGWIN__) /* WIN */ +#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */ +#ifndef Tcl_WinUtfToTChar #define Tcl_WinUtfToTChar \ (tclPlatStubsPtr->tcl_WinUtfToTChar) /* 0 */ +#endif +#ifndef Tcl_WinTCharToUtf #define Tcl_WinTCharToUtf \ (tclPlatStubsPtr->tcl_WinTCharToUtf) /* 1 */ -/* Slot 2 is reserved */ -#define Tcl_WinConvertError \ - (tclPlatStubsPtr->tcl_WinConvertError) /* 3 */ +#endif #endif /* WIN */ #ifdef MAC_OSX_TCL /* MACOSX */ +#ifndef Tcl_MacOSXOpenBundleResources #define Tcl_MacOSXOpenBundleResources \ (tclPlatStubsPtr->tcl_MacOSXOpenBundleResources) /* 0 */ +#endif +#ifndef Tcl_MacOSXOpenVersionedBundleResources #define Tcl_MacOSXOpenVersionedBundleResources \ (tclPlatStubsPtr->tcl_MacOSXOpenVersionedBundleResources) /* 1 */ -#define Tcl_MacOSXNotifierAddRunLoopMode \ - (tclPlatStubsPtr->tcl_MacOSXNotifierAddRunLoopMode) /* 2 */ +#endif #endif /* MACOSX */ -#endif /* defined(USE_TCL_STUBS) */ +#endif /* defined(USE_TCL_STUBS) && !defined(USE_TCL_STUB_PROCS) */ /* !END!: Do not edit above this line. */ -#ifdef MAC_OSX_TCL /* MACOSX */ -#undef Tcl_MacOSXOpenBundleResources -#define Tcl_MacOSXOpenBundleResources(a,b,c,d,e) Tcl_MacOSXOpenVersionedBundleResources(a,b,NULL,c,d,e) -#endif - #undef TCL_STORAGE_CLASS #define TCL_STORAGE_CLASS DLLIMPORT -#if defined(USE_TCL_STUBS) && (defined(_WIN32) || defined(__CYGWIN__))\ - && (defined(TCL_NO_DEPRECATED) || TCL_MAJOR_VERSION > 8) -#undef Tcl_WinUtfToTChar -#undef Tcl_WinTCharToUtf -#ifdef _WIN32 -#define Tcl_WinUtfToTChar(string, len, dsPtr) (Tcl_DStringInit(dsPtr), \ - (TCHAR *)Tcl_UtfToChar16DString((string), (len), (dsPtr))) -#define Tcl_WinTCharToUtf(string, len, dsPtr) (Tcl_DStringInit(dsPtr), \ - (char *)Tcl_Char16ToUtfDString((const unsigned short *)(string), ((((len) + 2) >> 1) - 1), (dsPtr))) -#endif -#endif - #endif /* _TCLPLATDECLS */ + + |
