diff options
author | dgp <dgp@users.sourceforge.net> | 2006-11-15 20:08:41 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2006-11-15 20:08:41 (GMT) |
commit | f5e6dc061f04d3923e3e9098ee796d212209eff4 (patch) | |
tree | 752af501223a220be61c59c71f29857e4269dcd2 /generic/tclStringObj.c | |
parent | 957788b87ab7599dee6ac939d75fe8ae71ab91cf (diff) | |
download | tcl-f5e6dc061f04d3923e3e9098ee796d212209eff4.zip tcl-f5e6dc061f04d3923e3e9098ee796d212209eff4.tar.gz tcl-f5e6dc061f04d3923e3e9098ee796d212209eff4.tar.bz2 |
TIP#270 IMPLEMENTATION
* generic/tcl.decls: New public routines Tcl_ObjPrintf,
* generic/tclStringObj.c: Tcl_AppendObjToErrorInfo, Tcl_Format,
* generic/tclInt.h: Tcl_AppendLimitedToObj,
Tcl_AppendFormatToObj and Tcl_AppendPrintfToObj. Former internal
versions removed.
* generic/tclDecls.h: make genstubs
* generic/tclStubInit.c:
* generic/tclBasic.c: Updated callers.
* generic/tclCkalloc.c:
* generic/tclCmdAH.c:
* generic/tclCmdIL.c:
* generic/tclCmdMZ.c:
* generic/tclCompExpr.c:
* generic/tclCompile.c:
* generic/tclDictObj.c:
* generic/tclExecute.c:
* generic/tclIORChan.c:
* generic/tclIOUtil.c:
* generic/tclMain.c:
* generic/tclNamesp.c:
* generic/tclObj.c:
* generic/tclPkg.c:
* generic/tclProc.c:
* generic/tclStrToD.c:
* generic/tclTimer.c:
* generic/tclUtil.c:
* unix/tclUnixFCmd.c:
Diffstat (limited to 'generic/tclStringObj.c')
-rw-r--r-- | generic/tclStringObj.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c index 2e722c4..ea76330 100644 --- a/generic/tclStringObj.c +++ b/generic/tclStringObj.c @@ -33,7 +33,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclStringObj.c,v 1.62 2006/11/05 04:16:07 dgp Exp $ */ + * RCS: @(#) $Id: tclStringObj.c,v 1.63 2006/11/15 20:08:45 dgp Exp $ */ #include "tclInt.h" #include "tommath.h" @@ -1021,7 +1021,7 @@ Tcl_SetUnicodeObj( /* *---------------------------------------------------------------------- * - * TclAppendLimitedToObj -- + * Tcl_AppendLimitedToObj -- * * This function appends a limited number of bytes from a sequence of * bytes to an object, marking any limitation with an ellipsis. @@ -1037,7 +1037,7 @@ Tcl_SetUnicodeObj( */ void -TclAppendLimitedToObj( +Tcl_AppendLimitedToObj( register Tcl_Obj *objPtr, /* Points to the object to append to. */ CONST char *bytes, /* Points to the bytes to append to the * object. */ @@ -1054,7 +1054,7 @@ TclAppendLimitedToObj( int toCopy = 0; if (Tcl_IsShared(objPtr)) { - Tcl_Panic("%s called with shared object", "TclAppendLimitedToObj"); + Tcl_Panic("%s called with shared object", "Tcl_AppendLimitedToObj"); } SetStringFromAny(NULL, objPtr); @@ -1126,7 +1126,7 @@ Tcl_AppendToObj( * If < 0, then append all bytes up to NUL * byte. */ { - TclAppendLimitedToObj(objPtr, bytes, length, INT_MAX, NULL); + Tcl_AppendLimitedToObj(objPtr, bytes, length, INT_MAX, NULL); } /* @@ -1676,7 +1676,7 @@ Tcl_AppendStringsToObj( /* *---------------------------------------------------------------------- * - * TclAppendFormatToObj -- + * Tcl_AppendFormatToObj -- * * This function appends a list of Tcl_Obj's to a Tcl_Obj according to * the formatting instructions embedded in the format string. The @@ -1694,7 +1694,7 @@ Tcl_AppendStringsToObj( */ int -TclAppendFormatToObj( +Tcl_AppendFormatToObj( Tcl_Interp *interp, Tcl_Obj *appendObj, CONST char *format, @@ -1715,7 +1715,7 @@ TclAppendFormatToObj( }; if (Tcl_IsShared(appendObj)) { - Tcl_Panic("%s called with shared object", "TclAppendFormatToObj"); + Tcl_Panic("%s called with shared object", "Tcl_AppendFormatToObj"); } Tcl_GetStringFromObj(appendObj, &originalLength); @@ -2291,7 +2291,7 @@ TclAppendFormatToObj( /* *--------------------------------------------------------------------------- * - * TclFormat-- + * Tcl_Format-- * * Results: * A refcount zero Tcl_Obj. @@ -2303,7 +2303,7 @@ TclAppendFormatToObj( */ Tcl_Obj * -TclFormat( +Tcl_Format( Tcl_Interp *interp, CONST char *format, int objc, @@ -2311,7 +2311,7 @@ TclFormat( { int result; Tcl_Obj *objPtr = Tcl_NewObj(); - result = TclAppendFormatToObj(interp, objPtr, format, objc, objv); + result = Tcl_AppendFormatToObj(interp, objPtr, format, objc, objv); if (result != TCL_OK) { Tcl_DecrRefCount(objPtr); return NULL; @@ -2454,9 +2454,9 @@ AppendPrintfToObjVA( } while (seekingConversion); } Tcl_ListObjGetElements(NULL, list, &objc, &objv); - code = TclAppendFormatToObj(NULL, objPtr, format, objc, objv); + code = Tcl_AppendFormatToObj(NULL, objPtr, format, objc, objv); if (code != TCL_OK) { - TclAppendPrintfToObj(objPtr, + Tcl_AppendPrintfToObj(objPtr, "Unable to format \"%s\" with supplied arguments: %s", format, Tcl_GetString(list)); } @@ -2466,7 +2466,7 @@ AppendPrintfToObjVA( /* *--------------------------------------------------------------------------- * - * TclAppendPrintfToObj -- + * Tcl_AppendPrintfToObj -- * * Results: * A standard Tcl result. @@ -2478,7 +2478,7 @@ AppendPrintfToObjVA( */ void -TclAppendPrintfToObj( +Tcl_AppendPrintfToObj( Tcl_Obj *objPtr, CONST char *format, ...) @@ -2493,7 +2493,7 @@ TclAppendPrintfToObj( /* *--------------------------------------------------------------------------- * - * TclObjPrintf -- + * Tcl_ObjPrintf -- * * Results: * A refcount zero Tcl_Obj. @@ -2505,7 +2505,7 @@ TclAppendPrintfToObj( */ Tcl_Obj * -TclObjPrintf( +Tcl_ObjPrintf( CONST char *format, ...) { |