diff options
author | das <das> | 2007-08-14 06:32:55 (GMT) |
---|---|---|
committer | das <das> | 2007-08-14 06:32:55 (GMT) |
commit | 1d3c3ca5bc5a27b8810c6653a5cdafd895a64c0b (patch) | |
tree | 85b24d056d0a9723d0d81dde23cd24241372e6b9 /unix/dltest | |
parent | a789ab33c1944041459d117c719d57c44582b717 (diff) | |
download | tcl-1d3c3ca5bc5a27b8810c6653a5cdafd895a64c0b.zip tcl-1d3c3ca5bc5a27b8810c6653a5cdafd895a64c0b.tar.gz tcl-1d3c3ca5bc5a27b8810c6653a5cdafd895a64c0b.tar.bz2 |
* unix/dltest/pkga.c: whitespace & comment cleanup, remove
* unix/dltest/pkgb.c: unused pkgf.c.
* unix/dltest/pkgc.c:
* unix/dltest/pkge.c:
* unix/dltest/pkgf.c (removed):
* unix/dltest/pkgua.c:
* macosx/Tcl.xcodeproj/project.pbxproj:
Diffstat (limited to 'unix/dltest')
-rw-r--r-- | unix/dltest/pkga.c | 3 | ||||
-rw-r--r-- | unix/dltest/pkgb.c | 9 | ||||
-rw-r--r-- | unix/dltest/pkgc.c | 10 | ||||
-rw-r--r-- | unix/dltest/pkge.c | 3 | ||||
-rw-r--r-- | unix/dltest/pkgf.c | 46 | ||||
-rw-r--r-- | unix/dltest/pkgua.c | 14 |
6 files changed, 21 insertions, 64 deletions
diff --git a/unix/dltest/pkga.c b/unix/dltest/pkga.c index b282614..d78e611 100644 --- a/unix/dltest/pkga.c +++ b/unix/dltest/pkga.c @@ -9,8 +9,9 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: pkga.c,v 1.10 2007/05/29 14:05:53 dgp Exp $ + * RCS: @(#) $Id: pkga.c,v 1.11 2007/08/14 06:32:55 das Exp $ */ + #include "tcl.h" /* diff --git a/unix/dltest/pkgb.c b/unix/dltest/pkgb.c index 1a60f05..35907ff 100644 --- a/unix/dltest/pkgb.c +++ b/unix/dltest/pkgb.c @@ -10,8 +10,9 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: pkgb.c,v 1.7 2007/05/29 14:05:53 dgp Exp $ + * RCS: @(#) $Id: pkgb.c,v 1.8 2007/08/14 06:32:55 das Exp $ */ + #include "tcl.h" /* @@ -51,11 +52,11 @@ Pkgb_SubObjCmd( if (objc != 3) { Tcl_WrongNumArgs(interp, 1, objv, "num num"); - return TCL_ERROR; + return TCL_ERROR; } if ((Tcl_GetIntFromObj(interp, objv[1], &first) != TCL_OK) || (Tcl_GetIntFromObj(interp, objv[2], &second) != TCL_OK)) { - return TCL_ERROR; + return TCL_ERROR; } Tcl_SetObjResult(interp, Tcl_NewIntObj(first - second)); return TCL_OK; @@ -133,7 +134,7 @@ Pkgb_Init( * Pkgb_SafeInit -- * * This is a package initialization procedure, which is called by Tcl - * when this package is to be added to an unsafe interpreter. + * when this package is to be added to a safe interpreter. * * Results: * None. diff --git a/unix/dltest/pkgc.c b/unix/dltest/pkgc.c index 6f16bf3..72434ae 100644 --- a/unix/dltest/pkgc.c +++ b/unix/dltest/pkgc.c @@ -10,8 +10,9 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: pkgc.c,v 1.7 2007/05/29 14:05:53 dgp Exp $ + * RCS: @(#) $Id: pkgc.c,v 1.8 2007/08/14 06:32:55 das Exp $ */ + #include "tcl.h" /* @@ -19,9 +20,9 @@ */ static int Pkgc_SubObjCmd(ClientData clientData, - Tcl_Interp *interp, int objc, Tcl_Obj * CONST objv[]); + Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]); static int Pkgc_UnsafeObjCmd(ClientData clientData, - Tcl_Interp *interp, int objc, Tcl_Obj * CONST objv[]); + Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]); /* *---------------------------------------------------------------------- @@ -95,8 +96,7 @@ Pkgc_UnsafeObjCmd( * Pkgc_Init -- * * This is a package initialization procedure, which is called by Tcl - * when this package is to be added to a normal (unsafe/trusted) - * interpreter. + * when this package is to be added to an interpreter. * * Results: * None. diff --git a/unix/dltest/pkge.c b/unix/dltest/pkge.c index 98a35a0..8f073ee 100644 --- a/unix/dltest/pkge.c +++ b/unix/dltest/pkge.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: pkge.c,v 1.8 2007/05/29 14:05:53 dgp Exp $ + * RCS: @(#) $Id: pkge.c,v 1.9 2007/08/14 06:32:55 das Exp $ */ #include "tcl.h" @@ -39,6 +39,7 @@ Pkge_Init( * made available. */ { static char script[] = "if 44 {open non_existent}"; + if (Tcl_InitStubs(interp, TCL_VERSION, 0) == NULL) { return TCL_ERROR; } diff --git a/unix/dltest/pkgf.c b/unix/dltest/pkgf.c deleted file mode 100644 index c32aaf0..0000000 --- a/unix/dltest/pkgf.c +++ /dev/null @@ -1,46 +0,0 @@ -/* - * pkgf.c -- - * - * This file contains a simple Tcl package "pkgf" that is intended for - * testing the Tcl dynamic loading facilities. Its Init procedure returns - * an error in order to test how this is handled. - * - * Copyright (c) 1995 Sun Microsystems, Inc. - * - * See the file "license.terms" for information on usage and redistribution of - * this file, and for a DISCLAIMER OF ALL WARRANTIES. - * - * RCS: @(#) $Id: pkgf.c,v 1.7 2007/05/29 14:05:53 dgp Exp $ - */ - -#include "tcl.h" - - -/* - *---------------------------------------------------------------------- - * - * Pkgf_Init -- - * - * This is a package initialization procedure, which is called by Tcl - * when this package is to be added to an interpreter. - * - * Results: - * Returns TCL_ERROR and leaves an error message in interp->result. - * - * Side effects: - * None. - * - *---------------------------------------------------------------------- - */ - -int -Pkgf_Init( - Tcl_Interp *interp) /* Interpreter in which the package is to be - * made available. */ -{ - static char script[] = "if 44 {open non_existent}"; - if (Tcl_InitStubs(interp, TCL_VERSION, 0) == NULL) { - return TCL_ERROR; - } - return Tcl_Eval(interp, script); -} diff --git a/unix/dltest/pkgua.c b/unix/dltest/pkgua.c index 4c2c713..de200a8 100644 --- a/unix/dltest/pkgua.c +++ b/unix/dltest/pkgua.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: pkgua.c,v 1.5 2007/05/29 14:05:53 dgp Exp $ + * RCS: @(#) $Id: pkgua.c,v 1.6 2007/08/14 06:32:55 das Exp $ */ #include "tcl.h" @@ -50,7 +50,7 @@ PkguaInitTokensHashTable(void) Tcl_InitHashTable(&interpTokenMap, TCL_ONE_WORD_KEYS); interpTokenMapInitialised = 1; } - + void PkguaFreeTokensHashTable(void) { @@ -63,7 +63,7 @@ PkguaFreeTokensHashTable(void) } interpTokenMapInitialised = 0; } - + static Tcl_Command * PkguaInterpToTokens( Tcl_Interp *interp) @@ -85,7 +85,7 @@ PkguaInterpToTokens( } return cmdTokens; } - + static void PkguaDeleteTokens( Tcl_Interp *interp) @@ -235,7 +235,7 @@ Pkgua_Init( * Pkgua_SafeInit -- * * This is a package initialization procedure, which is called by Tcl - * when this package is to be added to an unsafe interpreter. + * when this package is to be added to a safe interpreter. * * Results: * None. @@ -260,7 +260,7 @@ Pkgua_SafeInit( * Pkgua_Unload -- * * This is a package unloading initialization procedure, which is called - * by Tcl when this package is to be unloaded form an interpreter. + * by Tcl when this package is to be unloaded from an interpreter. * * Results: * None. @@ -313,7 +313,7 @@ Pkgua_Unload( * Pkgua_SafeUnload -- * * This is a package unloading initialization procedure, which is called - * by Tcl when this package is to be unloaded form an interpreter. + * by Tcl when this package is to be unloaded from an interpreter. * * Results: * None. |