summaryrefslogtreecommitdiffstats
path: root/generic/tkOldConfig.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2022-11-03 20:51:13 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2022-11-03 20:51:13 (GMT)
commit25f07e032603d465d333657ae2406f2017e3c848 (patch)
tree0f3eff56cfeca30f758ee359f2a5446dc1f6abe9 /generic/tkOldConfig.c
parent5989dcc44eebb29a6b8e6da75985ea31043d1ce5 (diff)
downloadtk-25f07e032603d465d333657ae2406f2017e3c848.zip
tk-25f07e032603d465d333657ae2406f2017e3c848.tar.gz
tk-25f07e032603d465d333657ae2406f2017e3c848.tar.bz2
If compiled with -DTK_NO_DEPRECATED, make TK_CONFIG_OBJS mandatory. So, we could get rid of this flag in Tk 9.x (TIP upcoming!)
Diffstat (limited to 'generic/tkOldConfig.c')
-rw-r--r--generic/tkOldConfig.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/generic/tkOldConfig.c b/generic/tkOldConfig.c
index 442c7a6..cc52e8c 100644
--- a/generic/tkOldConfig.c
+++ b/generic/tkOldConfig.c
@@ -127,7 +127,11 @@ Tk_ConfigureWidget(
if (flags & TK_CONFIG_OBJS) {
arg = Tcl_GetString((Tcl_Obj *) *argv);
} else {
+#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8)
+ Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory");
+#else
arg = *argv;
+#endif
}
specPtr = FindConfigSpec(interp, staticSpecs, arg, needFlags, hateFlags);
if (specPtr == NULL) {
@@ -147,7 +151,11 @@ Tk_ConfigureWidget(
if (flags & TK_CONFIG_OBJS) {
arg = Tcl_GetString((Tcl_Obj *) argv[1]);
} else {
+#if defined(TK_NO_DEPRECATED) || (TK_MAJOR_VERSION > 8)
+ Tcl_Panic("Flag TK_CONFIG_OBJS is mandatory");
+#else
arg = argv[1];
+#endif
}
if (DoConfig(interp, tkwin, specPtr, arg, 0, widgRec) != TCL_OK) {
Tcl_AppendObjToErrorInfo(interp, Tcl_ObjPrintf(