summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2019-09-14 12:36:36 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2019-09-14 12:36:36 (GMT)
commit5406b207723fa1acec5df7441387d1c9229a88ac (patch)
treebf39826587c7b96329fac7659f5d0c36f9e0d91b /generic
parente0d5d4dfe5371b9ff46431085fcb1f3cebd16143 (diff)
parente5f0aa50097a8428daf707fa8812a9b61916ddf3 (diff)
downloadtcl-5406b207723fa1acec5df7441387d1c9229a88ac.zip
tcl-5406b207723fa1acec5df7441387d1c9229a88ac.tar.gz
tcl-5406b207723fa1acec5df7441387d1c9229a88ac.tar.bz2
TIP #414 implementation: Add (back) Tcl_InitSubsystems as Public API
Diffstat (limited to 'generic')
-rw-r--r--generic/tcl.decls3
-rw-r--r--generic/tcl.h1
-rw-r--r--generic/tclBasic.c2
-rw-r--r--generic/tclCkalloc.c2
-rw-r--r--generic/tclEncoding.c2
-rw-r--r--generic/tclEvent.c6
-rw-r--r--generic/tclInt.h1
-rw-r--r--generic/tclPanic.c2
-rw-r--r--generic/tclThreadAlloc.c2
9 files changed, 12 insertions, 9 deletions
diff --git a/generic/tcl.decls b/generic/tcl.decls
index 19672a7..a3647d7 100644
--- a/generic/tcl.decls
+++ b/generic/tcl.decls
@@ -2468,6 +2468,9 @@ export {
export {
void Tcl_GetMemoryInfo(Tcl_DString *dsPtr)
}
+export {
+ void Tcl_InitSubsystems(void)
+}
# Local Variables:
# mode: tcl
diff --git a/generic/tcl.h b/generic/tcl.h
index 031b3f7..a5d5799 100644
--- a/generic/tcl.h
+++ b/generic/tcl.h
@@ -2399,6 +2399,7 @@ EXTERN void Tcl_MainEx(int argc, char **argv,
Tcl_AppInitProc *appInitProc, Tcl_Interp *interp);
EXTERN const char * Tcl_PkgInitStubsCheck(Tcl_Interp *interp,
const char *version, int exact);
+EXTERN void Tcl_InitSubsystems(void);
EXTERN void Tcl_GetMemoryInfo(Tcl_DString *dsPtr);
#ifndef _WIN32
EXTERN int TclZipfs_AppHook(int *argc, char ***argv);
diff --git a/generic/tclBasic.c b/generic/tclBasic.c
index db1e526..967ec73 100644
--- a/generic/tclBasic.c
+++ b/generic/tclBasic.c
@@ -645,7 +645,7 @@ Tcl_CreateInterp(void)
char mathFuncName[32];
CallFrame *framePtr;
- TclInitSubsystems();
+ Tcl_InitSubsystems();
/*
* Panic if someone updated the CallFrame structure without also updating
diff --git a/generic/tclCkalloc.c b/generic/tclCkalloc.c
index 57f65c8..d7604fa 100644
--- a/generic/tclCkalloc.c
+++ b/generic/tclCkalloc.c
@@ -145,7 +145,7 @@ static void ValidateMemory(struct mem_header *memHeaderP,
*
* Initialize the locks used by the allocator. This is only appropriate
* to call in a single threaded environment, such as during
- * TclInitSubsystems.
+ * Tcl_InitSubsystems.
*
*----------------------------------------------------------------------
*/
diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c
index 645df20..9896f85 100644
--- a/generic/tclEncoding.c
+++ b/generic/tclEncoding.c
@@ -1515,7 +1515,7 @@ Tcl_FindExecutable(
const char *argv0) /* The value of the application's argv[0]
* (native). */
{
- TclInitSubsystems();
+ Tcl_InitSubsystems();
TclpSetInitialEncodings();
TclpFindExecutable(argv0);
}
diff --git a/generic/tclEvent.c b/generic/tclEvent.c
index 734f114..41aeca4 100644
--- a/generic/tclEvent.c
+++ b/generic/tclEvent.c
@@ -1002,7 +1002,7 @@ Tcl_Exit(
/*
*-------------------------------------------------------------------------
*
- * TclInitSubsystems --
+ * Tcl_InitSubsystems --
*
* Initialize various subsytems in Tcl. This should be called the first
* time an interp is created, or before any of the subsystems are used.
@@ -1025,10 +1025,10 @@ Tcl_Exit(
*/
void
-TclInitSubsystems(void)
+Tcl_InitSubsystems(void)
{
if (inExit != 0) {
- Tcl_Panic("TclInitSubsystems called while exiting");
+ Tcl_Panic("Tcl_InitSubsystems called while exiting");
}
if (subsystemsInitialized == 0) {
diff --git a/generic/tclInt.h b/generic/tclInt.h
index 2ac833e..3db3f24 100644
--- a/generic/tclInt.h
+++ b/generic/tclInt.h
@@ -3074,7 +3074,6 @@ MODULE_SCOPE void TclInitLimitSupport(Tcl_Interp *interp);
MODULE_SCOPE void TclInitNamespaceSubsystem(void);
MODULE_SCOPE void TclInitNotifier(void);
MODULE_SCOPE void TclInitObjSubsystem(void);
-MODULE_SCOPE void TclInitSubsystems(void);
MODULE_SCOPE int TclInterpReady(Tcl_Interp *interp);
MODULE_SCOPE int TclIsSpaceProc(int byte);
MODULE_SCOPE int TclIsDigitProc(int byte);
diff --git a/generic/tclPanic.c b/generic/tclPanic.c
index e8c1e7f..4fce082 100644
--- a/generic/tclPanic.c
+++ b/generic/tclPanic.c
@@ -58,7 +58,7 @@ Tcl_SetPanicProc(
else
#endif
panicProc = proc;
- TclInitSubsystems();
+ Tcl_InitSubsystems();
}
/*
diff --git a/generic/tclThreadAlloc.c b/generic/tclThreadAlloc.c
index 60d7b0c..8dfe014 100644
--- a/generic/tclThreadAlloc.c
+++ b/generic/tclThreadAlloc.c
@@ -1062,7 +1062,7 @@ GetBlocks(
* TclInitThreadAlloc --
*
* Initializes the allocator cache-maintenance structures.
- * It is done early and protected during the TclInitSubsystems().
+ * It is done early and protected during the Tcl_InitSubsystems().
*
* Results:
* None.