dtdocbook/instant: add Tcl_GetErrorLine check for older versions of Tcl
authorJon Trulson <jon@radscan.com>
Sun, 7 Oct 2018 19:28:04 +0000 (13:28 -0600)
committerJon Trulson <jon@radscan.com>
Sun, 7 Oct 2018 19:28:04 +0000 (13:28 -0600)
cde/programs/dtdocbook/instant/general.h

index 413e9aabbc98f1a348acc8342ccb39361aa1e475..d4c5afc4facaf9bd90c5851b9eeddb3e72dda4b2 100644 (file)
@@ -55,6 +55,11 @@ static char *gen_h_RCSid =
 /* get Tcl header so the variables make sense */
 #include <tcl.h>
 
+/* Compatibility with pre 8.6 versions */
+#if (TCL_MAJOR_VERSION < 8) || (TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION < 6)
+# define Tcl_GetErrorLine(x) ((x)->errorLine)
+#endif
+
 /* instant variable delimiter (can't use '$', collides with Tcl) */
 #define VDELIM         '@'