Ensemble error message rewriting
Closed / Accepted1056864fffffffffffffffffffffffffffffffffCreated 22 years agoUpdated 22 years ago
Descriptionplain2004-10-29 15:36:40
The attached patch improves the general quality of ensemble error messages.
dkfplain2004-10-29 22:36:41
File Added - 106966: rw.diff
dkf Closed ticket [1056864fff].
[History diff]2004-10-29 22:42:40
dgpplain2004-10-29 23:45:27
Logged In: YES user_id=80530 This patch uses the TCL_EVAL_INVOKE flag as a way to signal to TclEvalObjvInternal that an ensemble is in process. The TCL_EVAL_INVOKE flag is used in other ways too -- in interp aliases notably -- and has additional effects of forcing global evaluation, and suppressing errorInfo logging. This flag really needs factoring.
dgpplain2004-10-29 23:52:31
Logged In: YES user_id=80530 Since part of the functioning of this patch is manipulations immediately before calling the Tcl_ObjCmdProc, I expect there will be failures when other callers of a Tcl_ObjCmdProc are involved, like TclObjInvoke (for hidden commands) or InvokeImportedCmd (for [namespace import]ed commands). That is, this patch gives us yet another reason to factor all command procedure dispatch into a single location.
dkfplain2004-11-01 15:50:46
Logged In: YES user_id=79902 Yes and no. TCL_EVAL_INVOKE is actually what is wanted for both alias and ensemble processing.
dgpplain2004-11-04 00:35:20
Logged In: YES user_id=80530 The Itcl test suite appears to be very unhappy with this change.
dgpplain2004-11-04 00:47:18
Logged In: YES user_id=80530 Not certain, but I think because Itcl's ensemble dispatch mechanism does a direct call to a Tcl_ObjCmdProc instead of routing back through TclEvalObvInternal, then the iPtr->ensembleRewrite processing in TEOVI doesn't get done, and bogus Tcl_WrongNumArgs() output is the result. The need for that extra work in TEOVI appears to be an Achilles heel of this patch.
dgpplain2004-11-04 02:40:10
Logged In: YES user_id=80530 no, the trouble is that the fix for Tcl Bug 942757 got moved from tclProc.c into Tcl_WrongNumArgs() and Itcl relies on the prior (buggy?) behavior of Tcl_WrongNumArgs().
Log in (anonymous is fine) to add a comment.
Attachments:
- rw.diff [download] added by dkf on 2004-10-29 22:36:41. [details]