summaryrefslogtreecommitdiffstats
path: root/doc/load.n
diff options
context:
space:
mode:
Diffstat (limited to 'doc/load.n')
-rw-r--r--doc/load.n11
1 files changed, 4 insertions, 7 deletions
diff --git a/doc/load.n b/doc/load.n
index b35f320..4982c96 100644
--- a/doc/load.n
+++ b/doc/load.n
@@ -4,7 +4,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: load.n,v 1.22 2007/12/13 15:22:32 dgp Exp $
+'\" RCS: @(#) $Id: load.n,v 1.23 2008/06/29 22:28:24 dkf Exp $
'\"
.so man.macros
.TH load n 7.5 Tcl "Tcl Built-In Commands"
@@ -19,7 +19,6 @@ load \- Load machine code and initialize new commands
.br
\fBload \fIfileName packageName interp\fR
.BE
-
.SH DESCRIPTION
.PP
This command loads binary code from a file into the
@@ -59,7 +58,8 @@ on Safe\-Tcl, see the \fBsafe\fR manual entry.
.PP
The initialization procedure must match the following prototype:
.CS
-typedef int Tcl_PackageInitProc(Tcl_Interp *\fIinterp\fR);
+typedef int \fBTcl_PackageInitProc\fR(
+ Tcl_Interp *\fIinterp\fR);
.CE
The \fIinterp\fR argument identifies the interpreter in which the
package is to be loaded. The initialization procedure must return
@@ -73,12 +73,10 @@ in an application. If a given \fIfileName\fR is loaded into multiple
interpreters, then the first \fBload\fR will load the code and
call the initialization procedure; subsequent \fBload\fRs will
call the initialization procedure without loading the code again.
-.VS 8.5
For Tcl versions lower than 8.5, it is not possible to unload or reload a
package. From version 8.5 however, the \fBunload\fR command allows the unloading
of libraries loaded with \fBload\fR, for libraries that are aware of the
Tcl's unloading mechanism.
-.VE 8.5
.PP
The \fBload\fR command also supports packages that are statically
linked with the application, if those packages have been registered
@@ -131,6 +129,7 @@ be loaded into the process's address space multiple times. The
behavior of this varies from system to system (some systems may
detect the redundant loads, others may not).
.SH EXAMPLE
+.PP
The following is a minimal extension:
.PP
.CS
@@ -169,9 +168,7 @@ switch $tcl_platform(platform) {
# Now execute the command defined by the extension
foo
.CE
-
.SH "SEE ALSO"
info sharedlibextension, Tcl_StaticPackage(3), safe(n)
-
.SH KEYWORDS
binary code, loading, safe interpreter, shared library