OSDN Git Service

Please enter the commit message for your changes. Lines starting
[eos/hostdependX86LINUX64.git] / util / X86LINUX64 / man / man3 / Tcl_AppendResult.3
index f457c16..eb5a14f 100644 (file)
@@ -5,76 +5,81 @@
 '\" See the file "license.terms" for information on usage and redistribution
 '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
 '\" 
-'\" RCS: @(#) $Id: SetResult.3,v 1.7 2002/01/25 20:40:55 dgp Exp $
-'\" 
-'\" The definitions below are for supplemental macros used in Tcl/Tk
-'\" manual entries.
-'\"
-'\" .AP type name in/out ?indent?
-'\"    Start paragraph describing an argument to a library procedure.
-'\"    type is type of argument (int, etc.), in/out is either "in", "out",
-'\"    or "in/out" to describe whether procedure reads or modifies arg,
-'\"    and indent is equivalent to second arg of .IP (shouldn't ever be
-'\"    needed;  use .AS below instead)
-'\"
-'\" .AS ?type? ?name?
-'\"    Give maximum sizes of arguments for setting tab stops.  Type and
-'\"    name are examples of largest possible arguments that will be passed
-'\"    to .AP later.  If args are omitted, default tab stops are used.
-'\"
-'\" .BS
-'\"    Start box enclosure.  From here until next .BE, everything will be
-'\"    enclosed in one large box.
-'\"
-'\" .BE
-'\"    End of box enclosure.
-'\"
-'\" .CS
-'\"    Begin code excerpt.
-'\"
-'\" .CE
-'\"    End code excerpt.
-'\"
-'\" .VS ?version? ?br?
-'\"    Begin vertical sidebar, for use in marking newly-changed parts
-'\"    of man pages.  The first argument is ignored and used for recording
-'\"    the version when the .VS was added, so that the sidebars can be
-'\"    found and removed when they reach a certain age.  If another argument
-'\"    is present, then a line break is forced before starting the sidebar.
-'\"
-'\" .VE
-'\"    End of vertical sidebar.
-'\"
-'\" .DS
-'\"    Begin an indented unfilled display.
-'\"
-'\" .DE
-'\"    End of indented unfilled display.
-'\"
-'\" .SO
-'\"    Start of list of standard options for a Tk widget.  The
-'\"    options follow on successive lines, in four columns separated
-'\"    by tabs.
-'\"
-'\" .SE
-'\"    End of list of standard options for a Tk widget.
-'\"
-'\" .OP cmdName dbName dbClass
-'\"    Start of description of a specific option.  cmdName gives the
-'\"    option's name as specified in the class command, dbName gives
-'\"    the option's name in the option database, and dbClass gives
-'\"    the option's class in the option database.
-'\"
-'\" .UL arg1 arg2
-'\"    Print arg1 underlined, then print arg2 normally.
-'\"
-'\" RCS: @(#) $Id: man.macros,v 1.4 2000/08/25 06:18:32 ericm Exp $
-'\"
-'\"    # Set up traps and other miscellaneous stuff for Tcl/Tk man pages.
+.TH Tcl_SetResult 3 8.0 Tcl "Tcl Library Procedures"
+.\" The -*- nroff -*- definitions below are for supplemental macros used
+.\" in Tcl/Tk manual entries.
+.\"
+.\" .AP type name in/out ?indent?
+.\"    Start paragraph describing an argument to a library procedure.
+.\"    type is type of argument (int, etc.), in/out is either "in", "out",
+.\"    or "in/out" to describe whether procedure reads or modifies arg,
+.\"    and indent is equivalent to second arg of .IP (shouldn't ever be
+.\"    needed;  use .AS below instead)
+.\"
+.\" .AS ?type? ?name?
+.\"    Give maximum sizes of arguments for setting tab stops.  Type and
+.\"    name are examples of largest possible arguments that will be passed
+.\"    to .AP later.  If args are omitted, default tab stops are used.
+.\"
+.\" .BS
+.\"    Start box enclosure.  From here until next .BE, everything will be
+.\"    enclosed in one large box.
+.\"
+.\" .BE
+.\"    End of box enclosure.
+.\"
+.\" .CS
+.\"    Begin code excerpt.
+.\"
+.\" .CE
+.\"    End code excerpt.
+.\"
+.\" .VS ?version? ?br?
+.\"    Begin vertical sidebar, for use in marking newly-changed parts
+.\"    of man pages.  The first argument is ignored and used for recording
+.\"    the version when the .VS was added, so that the sidebars can be
+.\"    found and removed when they reach a certain age.  If another argument
+.\"    is present, then a line break is forced before starting the sidebar.
+.\"
+.\" .VE
+.\"    End of vertical sidebar.
+.\"
+.\" .DS
+.\"    Begin an indented unfilled display.
+.\"
+.\" .DE
+.\"    End of indented unfilled display.
+.\"
+.\" .SO ?manpage?
+.\"    Start of list of standard options for a Tk widget. The manpage
+.\"    argument defines where to look up the standard options; if
+.\"    omitted, defaults to "options". The options follow on successive
+.\"    lines, in three columns separated by tabs.
+.\"
+.\" .SE
+.\"    End of list of standard options for a Tk widget.
+.\"
+.\" .OP cmdName dbName dbClass
+.\"    Start of description of a specific option.  cmdName gives the
+.\"    option's name as specified in the class command, dbName gives
+.\"    the option's name in the option database, and dbClass gives
+.\"    the option's class in the option database.
+.\"
+.\" .UL arg1 arg2
+.\"    Print arg1 underlined, then print arg2 normally.
+.\"
+.\" .QW arg1 ?arg2?
+.\"    Print arg1 in quotes, then arg2 normally (for trailing punctuation).
+.\"
+.\" .PQ arg1 ?arg2?
+.\"    Print an open parenthesis, arg1 in quotes, then arg2 normally
+.\"    (for trailing punctuation) and then a closing parenthesis.
+.\"
+.\"    # Set up traps and other miscellaneous stuff for Tcl/Tk man pages.
 .if t .wh -1.3i ^B
 .nr ^l \n(.l
 .ad b
-'\"    # Start an argument description
+.\"    # Start an argument description
 .de AP
 .ie !"\\$4"" .TP \\$4
 .el \{\
@@ -83,7 +88,7 @@
 .\}
 .ta \\n()Au \\n()Bu
 .ie !"\\$3"" \{\
-\&\\$1 \\fI\\$2\\fP    (\\$3)
+\&\\$1 \\fI\\$2\\fP (\\$3)
 .\".b
 .\}
 .el \{\
 .\}
 .\}
 ..
-'\"    # define tabbing values for .AP
+.\"    # define tabbing values for .AP
 .de AS
 .nr )A 10n
 .if !"\\$1"" .nr )A \\w'\\$1'u+3n
 .nr )C \\n()Bu+\\w'(in/out)'u+2n
 ..
 .AS Tcl_Interp Tcl_CreateInterp in/out
-'\"    # BS - start boxed text
-'\"    # ^y = starting y location
-'\"    # ^b = 1
+.\"    # BS - start boxed text
+.\"    # ^y = starting y location
+.\"    # ^b = 1
 .de BS
 .br
 .mk ^y
 .if n \l'\\n(.lu\(ul'
 .if n .fi
 ..
-'\"    # BE - end boxed text (draw box now)
+.\"    # BE - end boxed text (draw box now)
 .de BE
 .nf
 .ti 0
 .br
 .nr ^b 0
 ..
-'\"    # VS - start vertical sidebar
-'\"    # ^Y = starting y location
-'\"    # ^v = 1 (for troff;  for nroff this doesn't matter)
+.\"    # VS - start vertical sidebar
+.\"    # ^Y = starting y location
+.\"    # ^v = 1 (for troff;  for nroff this doesn't matter)
 .de VS
 .if !"\\$2"" .br
 .mk ^Y
 .ie n 'mc \s12\(br\s0
 .el .nr ^v 1u
 ..
-'\"    # VE - end of vertical sidebar
+.\"    # VE - end of vertical sidebar
 .de VE
 .ie n 'mc
 .el \{\
 .\}
 .nr ^v 0
 ..
-'\"    # Special macro to handle page bottom:  finish off current
-'\"    # box/sidebar if in box/sidebar mode, then invoked standard
-'\"    # page bottom macro.
+.\"    # Special macro to handle page bottom:  finish off current
+.\"    # box/sidebar if in box/sidebar mode, then invoked standard
+.\"    # page bottom macro.
 .de ^B
 .ev 2
 'ti 0
 .mk ^Y
 .\}
 ..
-'\"    # DS - begin display
+.\"    # DS - begin display
 .de DS
 .RS
 .nf
 .sp
 ..
-'\"    # DE - end display
+.\"    # DE - end display
 .de DE
 .fi
 .RE
 .sp
 ..
-'\"    # SO - start of list of standard options
+.\"    # SO - start of list of standard options
 .de SO
+'ie '\\$1'' .ds So \\fBoptions\\fR
+'el .ds So \\fB\\$1\\fR
 .SH "STANDARD OPTIONS"
 .LP
 .nf
 .ta 5.5c 11c
 .ft B
 ..
-'\"    # SE - end of list of standard options
+.\"    # SE - end of list of standard options
 .de SE
 .fi
 .ft R
 .LP
-See the \\fBoptions\\fR manual entry for details on the standard options.
+See the \\*(So manual entry for details on the standard options.
 ..
-'\"    # OP - start of full description for a single option
+.\"    # OP - start of full description for a single option
 .de OP
 .LP
 .nf
@@ -229,24 +236,46 @@ Database Class:   \\fB\\$3\\fR
 .fi
 .IP
 ..
-'\"    # CS - begin code excerpt
+.\"    # CS - begin code excerpt
 .de CS
 .RS
 .nf
 .ta .25i .5i .75i 1i
 ..
-'\"    # CE - end code excerpt
+.\"    # CE - end code excerpt
 .de CE
 .fi
 .RE
 ..
+.\"    # UL - underline word
 .de UL
 \\$1\l'|0\(ul'\\$2
 ..
-.TH Tcl_SetResult 3 8.0 Tcl "Tcl Library Procedures"
+.\"    # QW - apply quotation marks to word
+.de QW
+.ie '\\*(lq'"' ``\\$1''\\$2
+.\"" fix emacs highlighting
+.el \\*(lq\\$1\\*(rq\\$2
+..
+.\"    # PQ - apply parens and quotation marks to word
+.de PQ
+.ie '\\*(lq'"' (``\\$1''\\$2)\\$3
+.\"" fix emacs highlighting
+.el (\\*(lq\\$1\\*(rq\\$2)\\$3
+..
+.\"    # QR - quoted range
+.de QR
+.ie '\\*(lq'"' ``\\$1''\\-``\\$2''\\$3
+.\"" fix emacs highlighting
+.el \\*(lq\\$1\\*(rq\\-\\*(lq\\$2\\*(rq\\$3
+..
+.\"    # MT - "empty" string
+.de MT
+.QW ""
+..
 .BS
 .SH NAME
-Tcl_SetObjResult, Tcl_GetObjResult, Tcl_SetResult, Tcl_GetStringResult, Tcl_AppendResult, Tcl_AppendResultVA, Tcl_AppendElement, Tcl_ResetResult, Tcl_FreeResult \- manipulate Tcl result
+Tcl_SetObjResult, Tcl_GetObjResult, Tcl_SetResult, Tcl_GetStringResult, Tcl_AppendResult, Tcl_AppendResultVA, Tcl_AppendElement, Tcl_ResetResult, Tcl_TransferResult, Tcl_FreeResult \- manipulate Tcl result
 .SH SYNOPSIS
 .nf
 \fB#include <tcl.h>\fR
@@ -256,205 +285,237 @@ Tcl_SetObjResult, Tcl_GetObjResult, Tcl_SetResult, Tcl_GetStringResult, Tcl_Appe
 Tcl_Obj *
 \fBTcl_GetObjResult\fR(\fIinterp\fR)
 .sp
-\fBTcl_SetResult\fR(\fIinterp, string, freeProc\fR)
+\fBTcl_SetResult\fR(\fIinterp, result, freeProc\fR)
 .sp
-CONST char *
+const char *
 \fBTcl_GetStringResult\fR(\fIinterp\fR)
 .sp
-\fBTcl_AppendResult\fR(\fIinterp, string, string, ... , \fB(char *) NULL\fR)
+\fBTcl_AppendResult\fR(\fIinterp, result, result, ... , \fB(char *) NULL\fR)
 .sp
 \fBTcl_AppendResultVA\fR(\fIinterp, argList\fR)
 .sp
-\fBTcl_AppendElement\fR(\fIinterp, string\fR)
-.sp
 \fBTcl_ResetResult\fR(\fIinterp\fR)
 .sp
+.VS 8.6
+\fBTcl_TransferResult\fR(\fIsourceInterp, result, targetInterp\fR)
+.VE 8.6
+.sp
+\fBTcl_AppendElement\fR(\fIinterp, element\fR)
+.sp
 \fBTcl_FreeResult\fR(\fIinterp\fR)
 .SH ARGUMENTS
-.AS Tcl_FreeProc freeProc
+.AS Tcl_FreeProc sourceInterp out
 .AP Tcl_Interp *interp out
 Interpreter whose result is to be modified or read.
 .AP Tcl_Obj *objPtr in
-Object value to become result for \fIinterp\fR.
-.AP char *string in
+Tcl value to become result for \fIinterp\fR.
+.AP char *result in
 String value to become result for \fIinterp\fR or to be
 appended to the existing result.
+.AP "const char" *element in
+String value to append as a list element
+to the existing result of \fIinterp\fR.
 .AP Tcl_FreeProc *freeProc in
 Address of procedure to call to release storage at
-\fIstring\fR, or \fBTCL_STATIC\fR, \fBTCL_DYNAMIC\fR, or
+\fIresult\fR, or \fBTCL_STATIC\fR, \fBTCL_DYNAMIC\fR, or
 \fBTCL_VOLATILE\fR.
 .AP va_list argList in
-An argument list which must have been initialised using
-\fBTCL_VARARGS_START\fR, and cleared using \fBva_end\fR.
+An argument list which must have been initialized using
+\fBva_start\fR, and cleared using \fBva_end\fR.
+.AP Tcl_Interp *sourceInterp in
+.VS 8.6
+Interpreter that the result and error information should be copied from.
+.VE 8.6
+.AP Tcl_Interp *targetInterp in
+.VS 8.6
+Interpreter that the result and error information should be copied to.
+.VE 8.6
+.AP int result in
+.VS 8.6
+If \fBTCL_OK\fR, only copy the result. If \fBTCL_ERROR\fR, copy the error
+information as well.
+.VE 8.6
 .BE
-
 .SH DESCRIPTION
 .PP
 The procedures described here are utilities for manipulating the
 result value in a Tcl interpreter.
-The interpreter result may be either a Tcl object or a string.
+The interpreter result may be either a Tcl value or a string.
 For example, \fBTcl_SetObjResult\fR and \fBTcl_SetResult\fR
-set the interpreter result to, respectively, an object and a string.
+set the interpreter result to, respectively, a value and a string.
 Similarly, \fBTcl_GetObjResult\fR and \fBTcl_GetStringResult\fR
-return the interpreter result as an object and as a string.
-The procedures always keep the string and object forms
+return the interpreter result as a value and as a string.
+The procedures always keep the string and value forms
 of the interpreter result consistent.
 For example, if \fBTcl_SetObjResult\fR is called to set
-the result to an object,
+the result to a value,
 then \fBTcl_GetStringResult\fR is called,
-it will return the object's string value.
+it will return the value's string representation.
 .PP
 \fBTcl_SetObjResult\fR
 arranges for \fIobjPtr\fR to be the result for \fIinterp\fR,
 replacing any existing result.
-The result is left pointing to the object
+The result is left pointing to the value
 referenced by \fIobjPtr\fR.
 \fIobjPtr\fR's reference count is incremented
 since there is now a new reference to it from \fIinterp\fR.
-The reference count for any old result object
-is decremented and the old result object is freed if no
+The reference count for any old result value
+is decremented and the old result value is freed if no
 references to it remain.
 .PP
-\fBTcl_GetObjResult\fR returns the result for \fIinterp\fR as an object.
-The object's reference count is not incremented;
-if the caller needs to retain a long-term pointer to the object
+\fBTcl_GetObjResult\fR returns the result for \fIinterp\fR as a value.
+The value's reference count is not incremented;
+if the caller needs to retain a long-term pointer to the value
 they should use \fBTcl_IncrRefCount\fR to increment its reference count
-in order to keep it from being freed too early or accidently changed.
+in order to keep it from being freed too early or accidentally changed.
 .PP
 \fBTcl_SetResult\fR
-arranges for \fIstring\fR to be the result for the current Tcl
+arranges for \fIresult\fR to be the result for the current Tcl
 command in \fIinterp\fR, replacing any existing result.
 The \fIfreeProc\fR argument specifies how to manage the storage
-for the \fIstring\fR argument;
+for the \fIresult\fR argument;
 it is discussed in the section
 \fBTHE TCL_FREEPROC ARGUMENT TO TCL_SETRESULT\fR below.
-If \fIstring\fR is \fBNULL\fR, then \fIfreeProc\fR is ignored
+If \fIresult\fR is \fBNULL\fR, then \fIfreeProc\fR is ignored
 and \fBTcl_SetResult\fR
 re-initializes \fIinterp\fR's result to point to an empty string.
 .PP
-\fBTcl_GetStringResult\fR returns the result for \fIinterp\fR as an string.
-If the result was set to an object by a \fBTcl_SetObjResult\fR call,
-the object form will be converted to a string and returned.
-If the object's string representation contains null bytes,
+\fBTcl_GetStringResult\fR returns the result for \fIinterp\fR as a string.
+If the result was set to a value by a \fBTcl_SetObjResult\fR call,
+the value form will be converted to a string and returned.
+If the value's string representation contains null bytes,
 this conversion will lose information.
 For this reason, programmers are encouraged to
-write their code to use the new object API procedures
+write their code to use the new value API procedures
 and to call \fBTcl_GetObjResult\fR instead.
 .PP
 \fBTcl_ResetResult\fR clears the result for \fIinterp\fR
 and leaves the result in its normal empty initialized state.
-If the result is an object,
+If the result is a value,
 its reference count is decremented and the result is left
-pointing to an unshared object representing an empty string.
+pointing to an unshared value representing an empty string.
 If the result is a dynamically allocated string, its memory is free*d
 and the result is left as a empty string.
 \fBTcl_ResetResult\fR also clears the error state managed by
 \fBTcl_AddErrorInfo\fR, \fBTcl_AddObjErrorInfo\fR,
 and \fBTcl_SetErrorCode\fR.
-
-.SH "OLD STRING PROCEDURES"
-.PP
-Use of the following procedures is deprecated
-since they manipulate the Tcl result as a string.
-Procedures such as \fBTcl_SetObjResult\fR
-that manipulate the result as an object
-can be significantly more efficient.
 .PP
 \fBTcl_AppendResult\fR makes it easy to build up Tcl results in pieces.
-It takes each of its \fIstring\fR arguments and appends them in order
+It takes each of its \fIresult\fR arguments and appends them in order
 to the current result associated with \fIinterp\fR.
 If the result is in its initialized empty state (e.g. a command procedure
 was just invoked or \fBTcl_ResetResult\fR was just called),
 then \fBTcl_AppendResult\fR sets the result to the concatenation of
-its \fIstring\fR arguments.
+its \fIresult\fR arguments.
 \fBTcl_AppendResult\fR may be called repeatedly as additional pieces
 of the result are produced.
 \fBTcl_AppendResult\fR takes care of all the
 storage management issues associated with managing \fIinterp\fR's
 result, such as allocating a larger result area if necessary.
-It also converts the current interpreter result from an object
-to a string, if necessary, before appending the argument strings.
-Any number of \fIstring\fR arguments may be passed in a single
+It also manages conversion to and from the \fIresult\fR field of the
+\fIinterp\fR so as to handle backward-compatibility with old-style
+extensions.
+Any number of \fIresult\fR arguments may be passed in a single
 call; the last argument in the list must be a NULL pointer.
 .PP
 \fBTcl_AppendResultVA\fR is the same as \fBTcl_AppendResult\fR except that
 instead of taking a variable number of arguments it takes an argument list.
 .PP
+.VS 8.6
+\fBTcl_TransferResult\fR moves a result from one interpreter to another,
+optionally (dependent on the \fIresult\fR parameter) including the error
+information dictionary as well. The interpreters must be in the same thread.
+The source interpreter will have its result reset by this operation.
+.VE 8.6
+.SH "DEPRECATED INTERFACES"
+.SS "OLD STRING PROCEDURES"
+.PP
+Use of the following procedures (is deprecated
+since they manipulate the Tcl result as a string.
+Procedures such as \fBTcl_SetObjResult\fR
+that manipulate the result as a value
+can be significantly more efficient.
+.PP
 \fBTcl_AppendElement\fR is similar to \fBTcl_AppendResult\fR in
 that it allows results to be built up in pieces.
-However, \fBTcl_AppendElement\fR takes only a single \fIstring\fR
+However, \fBTcl_AppendElement\fR takes only a single \fIelement\fR
 argument and it appends that argument to the current result
 as a proper Tcl list element.
 \fBTcl_AppendElement\fR adds backslashes or braces if necessary
 to ensure that \fIinterp\fR's result can be parsed as a list and that
-\fIstring\fR will be extracted as a single element.
+\fIelement\fR will be extracted as a single element.
 Under normal conditions, \fBTcl_AppendElement\fR will add a space
 character to \fIinterp\fR's result just before adding the new
 list element, so that the list elements in the result are properly
 separated.
 However if the new list element is the first in a list or sub-list
 (i.e. \fIinterp\fR's current result is empty, or consists of the
-single character ``{'', or ends in the characters `` {'') then no
-space is added.
+single character
+.QW { ,
+or ends in the characters
+.QW " {" )
+then no space is added.
 .PP
 \fBTcl_FreeResult\fR performs part of the work
 of \fBTcl_ResetResult\fR.
 It frees up the memory associated with \fIinterp\fR's result.
-It also sets \fIinterp->freeProc\fR to zero, but doesn't
+It also sets \fIinterp->freeProc\fR to zero, but does not
 change \fIinterp->result\fR or clear error state.
 \fBTcl_FreeResult\fR is most commonly used when a procedure
 is about to replace one result value with another.
-
-.SH "DIRECT ACCESS TO INTERP->RESULT IS DEPRECATED"
+.SS "DIRECT ACCESS TO INTERP->RESULT"
 .PP
 It used to be legal for programs to
 directly read and write \fIinterp->result\fR
-to manipulate the interpreter result.
-Direct access to \fIinterp->result\fR is now strongly deprecated
-because it can make the result's string and object forms inconsistent.
-Programs should always read the result
-using the procedures \fBTcl_GetObjResult\fR or \fBTcl_GetStringResult\fR,
-and write the result using \fBTcl_SetObjResult\fR or \fBTcl_SetResult\fR.
-
+to manipulate the interpreter result.  The Tcl headers no longer
+permit this access by default, and C code still doing this must
+be updated to use supported routines \fBTcl_GetObjResult\fR,
+\fBTcl_GetStringResult\fR, \fBTcl_SetObjResult\fR, and \fBTcl_SetResult\fR.
+As a migration aid, access can be restored with the compiler directive
+.CS
+#define USE_INTERP_RESULT
+.CE
+but this is meant only to offer life support to otherwise dead code.
 .SH "THE TCL_FREEPROC ARGUMENT TO TCL_SETRESULT"
 .PP
 \fBTcl_SetResult\fR's \fIfreeProc\fR argument specifies how 
-the Tcl system is to manage the storage for the \fIstring\fR argument.
+the Tcl system is to manage the storage for the \fIresult\fR argument.
 If \fBTcl_SetResult\fR or \fBTcl_SetObjResult\fR are called
 at a time when \fIinterp\fR holds a string result,
 they do whatever is necessary to dispose of the old string result
 (see the \fBTcl_Interp\fR manual entry for details on this).
 .PP
-If \fIfreeProc\fR is \fBTCL_STATIC\fR it means that \fIstring\fR
+If \fIfreeProc\fR is \fBTCL_STATIC\fR it means that \fIresult\fR
 refers to an area of static storage that is guaranteed not to be
 modified until at least the next call to \fBTcl_Eval\fR.
 If \fIfreeProc\fR
-is \fBTCL_DYNAMIC\fR it means that \fIstring\fR was allocated with a call
+is \fBTCL_DYNAMIC\fR it means that \fIresult\fR was allocated with a call
 to \fBTcl_Alloc\fR and is now the property of the Tcl system.
 \fBTcl_SetResult\fR will arrange for the string's storage to be
 released by calling \fBTcl_Free\fR when it is no longer needed.
-If \fIfreeProc\fR is \fBTCL_VOLATILE\fR it means that \fIstring\fR
+If \fIfreeProc\fR is \fBTCL_VOLATILE\fR it means that \fIresult\fR
 points to an area of memory that is likely to be overwritten when
 \fBTcl_SetResult\fR returns (e.g. it points to something in a stack frame).
 In this case \fBTcl_SetResult\fR will make a copy of the string in
 dynamically allocated storage and arrange for the copy to be the
 result for the current Tcl command.
 .PP
-If \fIfreeProc\fR isn't one of the values \fBTCL_STATIC\fR,
+If \fIfreeProc\fR is not one of the values \fBTCL_STATIC\fR,
 \fBTCL_DYNAMIC\fR, and \fBTCL_VOLATILE\fR, then it is the address
 of a procedure that Tcl should call to free the string.
 This allows applications to use non-standard storage allocators.
 When Tcl no longer needs the storage for the string, it will
 call \fIfreeProc\fR. \fIFreeProc\fR should have arguments and
 result that match the type \fBTcl_FreeProc\fR:
+.PP
 .CS
-typedef void Tcl_FreeProc(char *\fIblockPtr\fR);
+typedef void \fBTcl_FreeProc\fR(
+        char *\fIblockPtr\fR);
 .CE
+.PP
 When \fIfreeProc\fR is called, its \fIblockPtr\fR will be set to
-the value of \fIstring\fR passed to \fBTcl_SetResult\fR.
-
+the value of \fIresult\fR passed to \fBTcl_SetResult\fR.
 .SH "SEE ALSO"
 Tcl_AddErrorInfo, Tcl_CreateObjCommand, Tcl_SetErrorCode, Tcl_Interp
-
 .SH KEYWORDS
-append, command, element, list, object, result, return value, interpreter
+append, command, element, list, value, result, return value, interpreter