summaryrefslogtreecommitdiffstats
path: root/generic/tkBind.c
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2022-10-17 19:25:11 (GMT)
committerfvogel <fvogelnew1@free.fr>2022-10-17 19:25:11 (GMT)
commit2f576289dc210ca386257e2e4248ccd81dc420bc (patch)
tree7faddbf27ecde9bd19dde058a4a0e3d3735c2a68 /generic/tkBind.c
parent5950205d3ffddc5bd73d6c6f024dabab08719877 (diff)
parentf77cb9fd0c936cad6f224fc2da64cb7ae5cf8446 (diff)
downloadtk-2f576289dc210ca386257e2e4248ccd81dc420bc.zip
tk-2f576289dc210ca386257e2e4248ccd81dc420bc.tar.gz
tk-2f576289dc210ca386257e2e4248ccd81dc420bc.tar.bz2
Work around [d93c8175fd]: MSVC optimization bug.
Diffstat (limited to 'generic/tkBind.c')
-rw-r--r--generic/tkBind.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/generic/tkBind.c b/generic/tkBind.c
index e1caf14..ceaa468 100644
--- a/generic/tkBind.c
+++ b/generic/tkBind.c
@@ -4010,7 +4010,12 @@ HandleEventGenerate(
for (i = 2; i < (unsigned) objc; i += 2) {
Tcl_Obj *optionPtr, *valuePtr;
+#if defined(_MSC_VER)
+ /* Work around MSVC compiler optimization bug, see [d93c8175fd]. */
+ volatile int badOpt = 0;
+#else
int badOpt = 0;
+#endif
int index;
optionPtr = objv[i];