| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
for immediate operand usage to permit leading space and sign
characters. [Bug 1165671]
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclCmdAH.c (Tcl_CatchObjCmd):
* generic/tclCmdMZ.c (TclMergeReturnOptions,TclProcessReturn):
* generic/tclCompCmds.c (TclCompileReturnCmd):
* generic/tclExecute.c (TclCompEvalObj):
* generic/tclInt.h (Interp):
* generic/tclProc.c (TclUpdateReturnInfo):
Place primary storage of the -level and -code information in private
fields of the Interp struct, rather than in a DictObj. This should
significantly improve performance of TclUpdateReturnInfo.
|
| |
|
|
|
|
|
| |
* tests/appendComp.test (8.1): at compile time, and allow runtime
to raise the error (or succeed if a redefined [append] allows).
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
such as [return -code error $msg] to be bytecompiled.
* generic/tclInt.h: Factored Tcl_ReturnObjCmd() into two pieces:
* generic/tclCmdMZ.c: TclMergeReturnOptions(), which can parse the
options to [return], check their validity, and create the
corresponding return options dictionary, and TclProcessReturn(),
which takes that return options dictionary and performs the
[return] operation.
* generic/tclCompCmds.c: Rewrote TclCompileReturnCmd() to
call TclMergeReturnOptions() at compile time so the return options
dictionary is computed at compile time (when it is fully known).
The dictionary is pushed on the stack along with the result, and
the code and level values are included in the bytecode as operands.
Also supports optimized compilation of un-[catch]ed [return]s from
procs with default options into the INST_DONE instruction.
* generic/tclExecute.c: Rewrote INST_RETURN instruction to retrieve
the code and level operands, pop the return options from the stack,
and call TclProcessReturn() to perform the [return] operation.
* generic/tclCompile.h: New utilities include TclEmitInt4 macro
* generic/tclCompile.c: and TclWordKnownAtCompileTime().
|
|
|
|
|
|
|
| |
to 'Tcl_Panic' (the function). The #define
of panic in tcl.h clearly states it is
deprecated in the comments.
[Patch 865264]
|
| |
|
|
|
|
| |
on 2003-04-07 introduced a buffer overflow. Corrected. [Bug 771613]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclCmdAH.c: extends the [catch] and [return]
* generic/tclCompCmds.c: commands to enable creation of a
* generic/tclExecute.c: proc that is a replacement for
* generic/tclInt.h: [return]. [Patch 531640]
* generic/tclProc.c:
* generic/tclResult.c:
* tests/cmdAH.test:
* tests/cmdMZ.test:
* tests/error.test:
* tests/proc-old.test:
* library/tcltest/tcltest.tcl: The -returnCodes option to [test]
failed to recognize the symbolic name "ok" for return code 0.
|
| |
|
| |
|
|
|
|
| |
arguments interpolated in error messages. [Bug 711371]
|
|
|
|
| |
compiles to INST_RETURN, it is safe to compile even outside a proc.
|
| |
|
|
|
|
|
|
|
| |
* generic/tclCompile.c (INST_RETURN): [Bug 633204] that uses a new
* generic/tclCompile.h (INST_RETURN): bytecode INST_RETURN to
* generic/tclExecute.c (INST_RETURN): properly bytecode the
[return] command to something that returns TCL_RETURN.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclCmdMZ.c (Tcl_SubstObj):
* generic/tclCompCmds.c (TclCompileSwitchCmd):
* generic/tclCompExpr.c (CompileSubExpr):
* generic/tclCompile.c (TclSetByteCodeFromAny,TclCompileScript,
TclCompileTokens,TclCompileCmdWord):
* generic/tclCompile.h (TclCompileScript):
* generic/tclExecute.c (TclCompEvalObj):
* generic/tclInt.h (Interp,TCL_BRACKET_TERM,TclSubstTokens):
* generic/tclParse.c (ParseTokens,Tcl_SubstObj,TclSubstTokens):
* tests/subst.test (2.4, 8.7, 8.8, 11.4, 11.5):
Substantial refactoring of Tcl_SubstObj to make use of the same
parsing and substitution procedures as normal script evaluation.
Tcl_SubstObj() moved to tclParse.c. New routine TclSubstTokens()
created in tclParse.c which implements all substantial functioning
of Tcl_EvalTokensStandard(). TclCompileScript() loses its
"nested" argument, the Tcl_Interp struct loses its termOffset
field and the TCL_BRACKET_TERM flag in the evalFlags field, all
of which were only used (indirectly) by Tcl_SubstObj(). Tests
subst-8.7,8.8,11.4,11.5 modified to accomodate the only behavior
change: reporting of parse errors now takes precedence over
[return] and [continue] exceptions. All other behavior should
|
| |
|
|
|
|
|
| |
case. There's room for improvement in the future, of course. [Patch #644819]
Also adds another macro to help with jump offset fixups.
|
|
|
|
|
|
|
|
|
|
|
| |
* tests/incr.test: Don't include the text
"(increment expression)" in the errorInfo
generated by the compiled version of the
incr command since it does not match the
message generated by the non-compiled version
of incr. It is also not possible to match
this error output under Jacl, which does
not support a compiler.
|
|
|
|
| |
compiler warnings on SGI. [Bug 664379]
|
|
|
|
| |
problem with recent commit. [Bug 633204]
|
|
|
|
|
|
|
| |
* tests/compile.test: Corrects failure of bytecompiled
[catch {return}] to have result TCL_RETURN (not TCL_OK) [Bug 633204].
This patch is a workaround for 8.4.X. A new opcode INST_RETURN is a
better long term solution for 8.5 and later.
|
|
|
|
|
|
|
| |
* generic/tclCompCmds.c (TclCompileRegexpCmd): add left and right
anchoring (^ and $) recognition and check starting or ending .* to
extend the number of REs that can be compiled to string match or
string equal.
|
|
|
|
|
| |
checking for bad re's that didn't terminate the re string.
Resultant compiles were correct, but much slower than necessary.
|
|
|
|
|
|
| |
* generic/tclCompCmds.c: fix for [Bug 599788] (error in element
name causing segfault), reported by Tom Wilkason. Fixed by copying
the tokens instead of the source string.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* doc/Concat.3: all remaining public interfaces of Tcl.
* doc/CrtCommand.3: Notably, the parser no longer writes on
* doc/CrtSlave.3: the string it is parsing, so it is no
* doc/CrtTrace.3: longer necessary for Tcl_Eval() to be
* doc/Eval.3: given a writable string. Also, the
* doc/ExprLong.3: refactoring of the Tcl_*Var* routines
* doc/LinkVar.3: by Miguel Sofer is included, so that the
* doc/ParseCmd.3: "part1" argument for them no longer needs
* doc/SetVar.3: to be writable either.
* doc/TraceVar.3:
* doc/UpVar.3: Compatibility support has been enhanced so
* generic/tcl.decls that a #define of USE_NON_CONST will remove
* generic/tcl.h all possible source incompatibilities with
* generic/tclBasic.c the 8.3 version of the header file(s).
* generic/tclCmdMZ.c The new #define of USE_COMPAT_CONST now does
* generic/tclCompCmds.c what USE_NON_CONST used to do -- disable
* generic/tclCompExpr.c only those new CONST's that introduce
* generic/tclCompile.c irreconcilable incompatibilities.
* generic/tclCompile.h
* generic/tclDecls.h Several bugs are also fixed by this patch.
* generic/tclEnv.c [Bugs 584051,580433] [Patches 585105,582429]
* generic/tclEvent.c
* generic/tclInt.decls
* generic/tclInt.h
* generic/tclIntDecls.h
* generic/tclInterp.c
* generic/tclLink.c
* generic/tclObj.c
* generic/tclParse.c
* generic/tclParseExpr.c
* generic/tclProc.c
* generic/tclTest.c
* generic/tclUtf.c
* generic/tclUtil.c
* generic/tclVar.c
* mac/tclMacTest.c
* tests/expr-old.test
* tests/parseExpr.test
* unix/tclUnixTest.c
* unix/tclXtTest.c
* win/tclWinTest.c
|
|
|
|
|
| |
TCL_OUT_LINE_COMPILE instead of TCL_ERROR: let the failure happen
at runtime so that it can be caught [Bug 577015].
|
| |
|
|
|
|
| |
[global], [upvar] and [variable].
|
|
|
|
| |
creation in code that no longer throws an error.
|
| |
|
| |
|
| |
|
|
|
|
| |
for bad RE to stop checking further.
|
|
|
|
|
| |
* generic/tclCompCmds.c (TclCompileRegexpCmd): enhanced to support
-nocase and -- options.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclInt.h:
* generic/tclBasic.c: added TclCompileRegexpCmd entry
* generic/tclCompCmds.c (TclCompileStringCmd): corrected to return
TCL_OUT_LINE_COMPILE instead of TCL_ERROR for parsing errors, so
it only throws the error for runtime compile, in case the user
modifies 'string'.
(TclCompileRegexpCmd): first try at a byte-compiled regexp
command. It handles static strings and ^$ bounded static strings.
(TclCompileAppendCmd): made TclPushVarName call always use
TCL_CREATE_VAR as numWords is always > 2 at that point.
|
|
|
|
|
|
|
|
|
|
|
| |
generic/tclIOUtil.c, generic/tclPipe.c, generic/tclResult.c,
generic/tclUtil.c, generic/tclVar.c and mac/tclMacResource.c according
to TIP 27. Tcl_TranslateFileName rewritten as wrapper around
VFS-aware version. Updated callers.
***POTENTIAL INCOMPATIBILITY***
Includes source incompatibilities: argv arguments of Tcl_Concat,
Tcl_JoinPath, Tcl_OpenCommandChannel, Tcl_Merge; argvPtr arguments of
Tcl_SplitList and Tcl_SplitPath.
|
|
|
|
|
|
|
| |
overlooked before. Updated callers.
***POTENTIAL INCOMPATIBILITY***
Includes a source incompatibility in the tablePtr arguments of
the Tcl_GetIndexFromObj* routines.
|
| |
|
|
|
|
| |
fix for [Bug 483611].
|
|
|
|
| |
483611].
|
| |
|
|
|
|
|
|
| |
ability of the [lindex] command to have multiple index arguments,
and adds the [lset] command. Both commands are byte-code compiled.
[Patch #471874] (work by Kenny, commited by Hobbs)
|
|
|
|
|
|
|
|
|
|
|
| |
Updated to Int1 instruction type and added special case to use
INST_STR_EQ instead when no glob chars are specified in a static
string.
* tests/{for.test,foreach.test,if.test,while.test}:
* generic/tclCompCmds.c (TclCompileForCmd, TclCompileForeachCmd,
TclCompileIfCmd, TclCompileWhileCmd): Corrected the overaggressive
compiling of loop bodies enclosed in ""s. [Bug #219166] (msofer)
|
|
|
|
|
|
|
|
| |
* generic/tclBasic.c: added TclCompileListCmd compile proc
* generic/tclCompCmds.c (TclCompileListCmd): function to compile
the 'list' command at parse time.
* generic/tclExecute.c (TclExecuteByteCode): definition of
INST_LIST bytecode.
|
|
|
|
| |
[Bug #453872]
|