summaryrefslogtreecommitdiffstats
path: root/generic/tclLoad.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-02 16:28:09 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-02 16:28:09 (GMT)
commitb7c4b811ec358b518d9a5ceaf204a84a5e5b59a8 (patch)
treee0bc5a6114da04b2bb9a713ea069b83d14620b23 /generic/tclLoad.c
parentcb6ae544245fea42d68f1f1c0c3ab5fd92babcaf (diff)
downloadtcl-b7c4b811ec358b518d9a5ceaf204a84a5e5b59a8.zip
tcl-b7c4b811ec358b518d9a5ceaf204a84a5e5b59a8.tar.gz
tcl-b7c4b811ec358b518d9a5ceaf204a84a5e5b59a8.tar.bz2
Fix -Wshadow warnings, when compiling with a C++ compiler
Diffstat (limited to 'generic/tclLoad.c')
-rw-r--r--generic/tclLoad.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/generic/tclLoad.c b/generic/tclLoad.c
index 1ca1950..c143d0a 100644
--- a/generic/tclLoad.c
+++ b/generic/tclLoad.c
@@ -137,7 +137,7 @@ Tcl_LoadObjCmd(
static const char *const options[] = {
"-global", "-lazy", "--", NULL
};
- enum options {
+ enum loadOptionsEnum {
LOAD_GLOBAL, LOAD_LAZY, LOAD_LAST
};
@@ -150,9 +150,9 @@ Tcl_LoadObjCmd(
return TCL_ERROR;
}
++objv; --objc;
- if (LOAD_GLOBAL == (enum options) index) {
+ if (LOAD_GLOBAL == (enum loadOptionsEnum) index) {
flags |= TCL_LOAD_GLOBAL;
- } else if (LOAD_LAZY == (enum options) index) {
+ } else if (LOAD_LAZY == (enum loadOptionsEnum) index) {
flags |= TCL_LOAD_LAZY;
} else {
break;
@@ -559,7 +559,7 @@ Tcl_UnloadObjCmd(
static const char *const options[] = {
"-nocomplain", "-keeplibrary", "--", NULL
};
- enum options {
+ enum unloadOptionsEnum {
UNLOAD_NOCOMPLAIN, UNLOAD_KEEPLIB, UNLOAD_LAST
};
@@ -584,7 +584,7 @@ Tcl_UnloadObjCmd(
break;
}
}
- switch (index) {
+ switch ((enum unloadOptionsEnum)index) {
case UNLOAD_NOCOMPLAIN: /* -nocomplain */
complain = 0;
break;