Skip to content

Commit 17481a9

Browse files
author
stanton
committed
* win/tclAppInit.c:
* unix/tclAppInit.c: * mac/tclMacAppInit.c: * generic/tclTest.c: Changed some EXTERN declarations to extern since they are not defining exported interfaces. This avoids generating useless declspec() attributes and makes the windows makefile simpler. * generic/tcl.h: Moved Tcl_AppInit declaration to end and cleared out TCL_STORAGE_CLASS so it is not declared with a declspec().
1 parent e0ef154 commit 17481a9

File tree

5 files changed

+33
-21
lines changed

5 files changed

+33
-21
lines changed

generic/tcl.h

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* See the file "license.terms" for information on usage and redistribution
1313
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
1414
*
15-
* RCS: @(#) $Id: tcl.h,v 1.32 1999/01/06 21:08:50 stanton Exp $
15+
* RCS: @(#) $Id: tcl.h,v 1.33 1999/02/03 02:58:25 stanton Exp $
1616
*/
1717

1818
#ifndef _TCL
@@ -1072,7 +1072,6 @@ EXTERN void Tcl_AppendToObj _ANSI_ARGS_((Tcl_Obj *objPtr,
10721072
char *bytes, int length));
10731073
EXTERN void Tcl_AppendStringsToObj _ANSI_ARGS_(
10741074
TCL_VARARGS(Tcl_Obj *,interp));
1075-
EXTERN int Tcl_AppInit _ANSI_ARGS_((Tcl_Interp *interp));
10761075
EXTERN Tcl_AsyncHandler Tcl_AsyncCreate _ANSI_ARGS_((Tcl_AsyncProc *proc,
10771076
ClientData clientData));
10781077
EXTERN void Tcl_AsyncDelete _ANSI_ARGS_((Tcl_AsyncHandler async));
@@ -1562,6 +1561,17 @@ EXTERN int Tcl_Write _ANSI_ARGS_((Tcl_Channel chan,
15621561
EXTERN void Tcl_WrongNumArgs _ANSI_ARGS_((Tcl_Interp *interp,
15631562
int objc, Tcl_Obj *CONST objv[], char *message));
15641563

1564+
#undef TCL_STORAGE_CLASS
1565+
#define TCL_STORAGE_CLASS
1566+
1567+
/*
1568+
* Convenience declaration of Tcl_AppInit for backwards compatibility.
1569+
* This function is not *implemented* by the tcl library, so the storage
1570+
* class is neither DLLEXPORT nor DLLIMPORT
1571+
*/
1572+
1573+
EXTERN int Tcl_AppInit _ANSI_ARGS_((Tcl_Interp *interp));
1574+
15651575
#endif /* RESOURCE_INCLUDED */
15661576

15671577
#undef TCL_STORAGE_CLASS

generic/tclTest.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* See the file "license.terms" for information on usage and redistribution
1313
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
1414
*
15-
* RCS: @(#) $Id: tclTest.c,v 1.7 1999/02/03 00:55:06 stanton Exp $
15+
* RCS: @(#) $Id: tclTest.c,v 1.8 1999/02/03 02:58:25 stanton Exp $
1616
*/
1717

1818
#define TCL_TEST
@@ -217,10 +217,12 @@ static int TestwordendObjCmd _ANSI_ARGS_((ClientData dummy,
217217
Tcl_Obj *CONST objv[]));
218218

219219
/*
220-
* External (platform specific) initialization routine:
220+
* External (platform specific) initialization routine, this declaration
221+
* explicitly does not use EXTERN since this code does not get compiled
222+
* into the library:
221223
*/
222224

223-
EXTERN int TclplatformtestInit _ANSI_ARGS_((
225+
extern int TclplatformtestInit _ANSI_ARGS_((
224226
Tcl_Interp *interp));
225227

226228
/*

mac/tclMacAppInit.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* See the file "license.terms" for information on usage and redistribution
1010
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
1111
*
12-
* RCS: @(#) $Id: tclMacAppInit.c,v 1.3 1998/11/10 06:49:25 jingham Exp $
12+
* RCS: @(#) $Id: tclMacAppInit.c,v 1.4 1999/02/03 02:58:25 stanton Exp $
1313
*/
1414

1515
#include "tcl.h"
@@ -26,10 +26,10 @@ short InstallConsole _ANSI_ARGS_((short fd));
2626
#endif
2727

2828
#ifdef TCL_TEST
29-
EXTERN int Procbodytest_Init _ANSI_ARGS_((Tcl_Interp *interp));
30-
EXTERN int Procbodytest_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
31-
EXTERN int TclObjTest_Init _ANSI_ARGS_((Tcl_Interp *interp));
32-
EXTERN int Tcltest_Init _ANSI_ARGS_((Tcl_Interp *interp));
29+
extern int Procbodytest_Init _ANSI_ARGS_((Tcl_Interp *interp));
30+
extern int Procbodytest_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
31+
extern int TclObjTest_Init _ANSI_ARGS_((Tcl_Interp *interp));
32+
extern int Tcltest_Init _ANSI_ARGS_((Tcl_Interp *interp));
3333
#endif /* TCL_TEST */
3434

3535
/*

unix/tclAppInit.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* See the file "license.terms" for information on usage and redistribution
1111
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
1212
*
13-
* RCS: @(#) $Id: tclAppInit.c,v 1.3 1998/10/05 22:32:12 escoffon Exp $
13+
* RCS: @(#) $Id: tclAppInit.c,v 1.4 1999/02/03 02:58:26 stanton Exp $
1414
*/
1515

1616
#ifdef TCL_XT_TEST
@@ -29,13 +29,13 @@ int *tclDummyMathPtr = (int *) matherr;
2929

3030

3131
#ifdef TCL_TEST
32-
EXTERN int Procbodytest_Init _ANSI_ARGS_((Tcl_Interp *interp));
33-
EXTERN int Procbodytest_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
34-
EXTERN int TclObjTest_Init _ANSI_ARGS_((Tcl_Interp *interp));
35-
EXTERN int Tcltest_Init _ANSI_ARGS_((Tcl_Interp *interp));
32+
extern int Procbodytest_Init _ANSI_ARGS_((Tcl_Interp *interp));
33+
extern int Procbodytest_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
34+
extern int TclObjTest_Init _ANSI_ARGS_((Tcl_Interp *interp));
35+
extern int Tcltest_Init _ANSI_ARGS_((Tcl_Interp *interp));
3636
#endif /* TCL_TEST */
3737
#ifdef TCL_XT_TEST
38-
EXTERN int Tclxttest_Init _ANSI_ARGS_((Tcl_Interp *interp));
38+
extern int Tclxttest_Init _ANSI_ARGS_((Tcl_Interp *interp));
3939
#endif
4040

4141
/*

win/tclAppInit.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,18 @@
1010
* See the file "license.terms" for information on usage and redistribution
1111
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
1212
*
13-
* RCS: @(#) $Id: tclAppInit.c,v 1.3 1998/10/05 22:32:12 escoffon Exp $
13+
* RCS: @(#) $Id: tclAppInit.c,v 1.4 1999/02/03 02:58:26 stanton Exp $
1414
*/
1515

1616
#include "tcl.h"
1717
#include <windows.h>
1818
#include <locale.h>
1919

2020
#ifdef TCL_TEST
21-
EXTERN int Procbodytest_Init _ANSI_ARGS_((Tcl_Interp *interp));
22-
EXTERN int Procbodytest_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
23-
EXTERN int Tcltest_Init _ANSI_ARGS_((Tcl_Interp *interp));
24-
EXTERN int TclObjTest_Init _ANSI_ARGS_((Tcl_Interp *interp));
21+
extern int Procbodytest_Init _ANSI_ARGS_((Tcl_Interp *interp));
22+
extern int Procbodytest_SafeInit _ANSI_ARGS_((Tcl_Interp *interp));
23+
extern int Tcltest_Init _ANSI_ARGS_((Tcl_Interp *interp));
24+
extern int TclObjTest_Init _ANSI_ARGS_((Tcl_Interp *interp));
2525
#endif /* TCL_TEST */
2626

2727
static void setargv _ANSI_ARGS_((int *argcPtr, char ***argvPtr));

0 commit comments

Comments
 (0)