diff options
author | antirez <antirez> | 2005-03-10 10:03:32 +0000 |
---|---|---|
committer | antirez <antirez> | 2005-03-10 10:03:32 +0000 |
commit | 2936b0cfbf7fab966cfd65278a9140bc3848ce97 (patch) | |
tree | f0991f1ef52c6196bb6482aa2c6fed5c050ffd52 /jim.c | |
parent | 5223e4841465ac399bfed2122e7d61dcd60c0102 (diff) | |
download | jimtcl-2936b0cfbf7fab966cfd65278a9140bc3848ce97.zip jimtcl-2936b0cfbf7fab966cfd65278a9140bc3848ce97.tar.gz jimtcl-2936b0cfbf7fab966cfd65278a9140bc3848ce97.tar.bz2 |
Some fix to bench.tcl to make it able to run in Tcl7.6.
README update.
Diffstat (limited to 'jim.c')
-rw-r--r-- | jim.c | 15 |
1 files changed, 14 insertions, 1 deletions
@@ -1,7 +1,7 @@ /* Jim - A small embeddable Tcl interpreter * Copyright 2005 Salvatore Sanfilippo <antirez@invece.org> * - * $Id: jim.c,v 1.85 2005/03/09 11:06:42 antirez Exp $ + * $Id: jim.c,v 1.86 2005/03/10 10:03:32 antirez Exp $ * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -9590,6 +9590,18 @@ static int Jim_FormatCoreCommand(Jim_Interp *interp, int argc, return JIM_OK; } +/* [error] */ +static int Jim_ErrorCoreCommand(Jim_Interp *interp, int argc, + Jim_Obj *const *argv) +{ + if (argc != 2) { + Jim_WrongNumArgs(interp, 1, argv, "message"); + return JIM_ERR; + } + Jim_SetResult(interp, argv[1]); + return JIM_ERR; +} + static struct { const char *name; Jim_CmdProc cmdProc; @@ -9642,6 +9654,7 @@ static struct { {"split", Jim_SplitCoreCommand}, {"join", Jim_JoinCoreCommand}, {"format", Jim_FormatCoreCommand}, + {"error", Jim_ErrorCoreCommand}, {NULL, NULL}, }; |