About Us Documentation

Contact Site Map




Tcl_PkgRequire(3)    Tcl Library Procedures                   7.5



Tcl_PkgRequire, Tcl_PkgProvide - package version control


#include <tcl.h> char * Tcl_PkgRequire(interp, name, version, exact) int Tcl_PkgProvide(interp, name, version)


Tcl_Interp *interp (in) Interpreter where package is needed or available. char *name (in) Name of package. char *version (in) A version string con- sisting of one or more decimal numbers separated by dots. int exact (in) Non-zero means that only the particular version specified by version is acceptable. Zero means that newer versions than version are also acceptable as long as they have the same major version number as version. _________________________________________________________________


These procedures provide C-level interfaces to Tcl's package and version management facilities. Tcl_PkgRequire is equivalent to the package require command, and Tcl_PkgProvide is equivalent to the package provide command. See the documentation for the Tcl commands for details on what these procedures do. If Tcl_PkgRequire completes suc- cessfully it returns a pointer to the version string for the version of the package that is provided in the interpreter (which may be different than version); if an error occurs it returns NULL and leaves an error message in interp->result. Tcl_PkgProvide returns TCL_OK if it completes successfully; if an error occurs it returns TCL_ERROR and leaves an error Tcl 1 Tcl_PkgRequire(3) Tcl Library Procedures 7.5 message in interp->result.


package, provide, require, version Tcl 2 Prepared by Ready-to-Run Software, Inc.


Email addresses listed on this site may  NOT be used for unsolicited commercial email.

Ready-to-Run Software, Inc Privacy Statement

Portions (c)Copyright, 1996-2005 by Ready-to-Run Software, Inc
(All rights reserved.)
212 Cedar Cove
Lansing, NY 14882
Phone: 607 533 UNIX (8649)
Fax: 607 533 4002

To return to the Ready-to-Run Software WinPak Table of contents please presshere