summaryrefslogtreecommitdiffstats
path: root/generic/tclCompile.h
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2006-12-08 20:48:08 (GMT)
committerdgp <dgp@users.sourceforge.net>2006-12-08 20:48:08 (GMT)
commit737023909817fcc30432c33881868b521a3661d9 (patch)
tree2ec0dbf630fbc773ffa1f75145aba1677f457a21 /generic/tclCompile.h
parentc31a5d22b7398ccaa6b9d0e17e4865563253b0f5 (diff)
downloadtcl-737023909817fcc30432c33881868b521a3661d9.zip
tcl-737023909817fcc30432c33881868b521a3661d9.tar.gz
tcl-737023909817fcc30432c33881868b521a3661d9.tar.bz2
* generic/tclBasic.c: Another step down the path of re-using
* generic/tclCompExpr.c: TclExecuteByteCode to implement the TIP 174 * generic/tclCompile.h: commands instead of using a mass of code * generic/tclMathOp.c: duplication. Now all operator commands that * tests/mathop.test: demand exactly one operation are implemented via TclSingleOpCmd and a call to TEBC.
Diffstat (limited to 'generic/tclCompile.h')
-rw-r--r--generic/tclCompile.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/generic/tclCompile.h b/generic/tclCompile.h
index 5dc9cd7..c864c3c 100644
--- a/generic/tclCompile.h
+++ b/generic/tclCompile.h
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclCompile.h,v 1.63 2006/12/08 18:08:35 dgp Exp $
+ * RCS: @(#) $Id: tclCompile.h,v 1.64 2006/12/08 20:48:09 dgp Exp $
*/
#ifndef _TCLCOMPILATION
@@ -746,6 +746,16 @@ typedef struct JumptableInfo {
} JumptableInfo;
MODULE_SCOPE AuxDataType tclJumptableInfoType;
+
+/*
+ * ClientData type used by the math operator commands.
+ */
+typedef struct {
+ const char *operator;
+ const char *expected;
+ int numArgs;
+} TclOpCmdClientData;
+
/*
*----------------------------------------------------------------
@@ -845,6 +855,9 @@ MODULE_SCOPE int TclRegisterLiteral(CompileEnv *envPtr,
MODULE_SCOPE void TclReleaseLiteral(Tcl_Interp *interp, Tcl_Obj *objPtr);
MODULE_SCOPE void TclSetCmdNameObj(Tcl_Interp *interp, Tcl_Obj *objPtr,
Command *cmdPtr);
+MODULE_SCOPE int TclSingleOpCmd(ClientData clientData,
+ Tcl_Interp *interp, int objc,
+ Tcl_Obj *CONST objv[]);
#ifdef TCL_COMPILE_DEBUG
MODULE_SCOPE void TclVerifyGlobalLiteralTable(Interp *iPtr);
MODULE_SCOPE void TclVerifyLocalLiteralTable(CompileEnv *envPtr);