diff options
| author | Kevin B Kenny <kennykb@acm.org> | 2010-10-02 16:51:40 (GMT) |
|---|---|---|
| committer | Kevin B Kenny <kennykb@acm.org> | 2010-10-02 16:51:40 (GMT) |
| commit | 7d6af6d3f84a25a673ac3934eb4dd5a0ef518d7a (patch) | |
| tree | d946038bd3684c281b5dc824e92f51452830f12d /generic/tclAssembly.c | |
| parent | 2da266d103799f4bc5ad364ef24b6a8287d7c434 (diff) | |
| download | tcl-7d6af6d3f84a25a673ac3934eb4dd5a0ef518d7a.zip tcl-7d6af6d3f84a25a673ac3934eb4dd5a0ef518d7a.tar.gz tcl-7d6af6d3f84a25a673ac3934eb4dd5a0ef518d7a.tar.bz2 | |
nop and regexp
Diffstat (limited to 'generic/tclAssembly.c')
| -rw-r--r-- | generic/tclAssembly.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/generic/tclAssembly.c b/generic/tclAssembly.c index 4797cc8..71e7412 100644 --- a/generic/tclAssembly.c +++ b/generic/tclAssembly.c @@ -228,10 +228,12 @@ TalInstDesc TalInstructionTable[] = { {"mod", ASSEM_1BYTE, INST_MOD, 2, 1}, {"mult", ASSEM_1BYTE , INST_MULT , 2 , 1}, {"neq", ASSEM_1BYTE , INST_NEQ , 2 , 1}, + {"nop", ASSEM_1BYTE, INST_NOP, 0, 0}, {"not", ASSEM_1BYTE, INST_LNOT, 1, 1}, {"nsupvar", ASSEM_LVT4, INST_NSUPVAR, 2, 1}, {"over", ASSEM_OVER, INST_OVER, INT_MIN, -1-1}, {"pop", ASSEM_1BYTE , INST_POP , 1 , 0}, + {"regexp", ASSEM_REGEXP, INST_REGEXP, 2, 1}, {"reverse", ASSEM_REVERSE, INST_REVERSE, INT_MIN, -1-0}, {"rshift", ASSEM_1BYTE , INST_RSHIFT , 2 , 1}, {"store", ASSEM_LVT, (INST_STORE_SCALAR1<<8 @@ -1308,6 +1310,20 @@ AssembleOneLine(AssembleEnv* assemEnvPtr) BBEmitInstInt4(assemEnvPtr, tblind, opnd, opnd+1); break; + case ASSEM_REGEXP: + if (parsePtr->numWords != 2) { + Tcl_WrongNumArgs(interp, 1, &instNameObj, "boolean"); + goto cleanup; + } + if (GetBooleanOperand(assemEnvPtr, &tokenPtr, &opnd) != TCL_OK) { + goto cleanup; + } + { + int flags = TCL_REG_ADVANCED | (opnd ? TCL_REG_NOCASE : 0); + BBEmitInstInt1(assemEnvPtr, tblind, flags, 0); + } + break; + case ASSEM_REVERSE: if (parsePtr->numWords != 2) { Tcl_WrongNumArgs(interp, 1, &instNameObj, "count"); |
