TclOO Package

Artifact Content
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Artifact ff1939cd0e185d29156fa63044ae05f4b91e4368:

Wiki page [Doc: Tcl_OOInitStubs] by dkf 2016-09-17 13:57:11.
D 2016-09-17T13:57:11.841
L Doc:\sTcl_OOInitStubs
N text/x-markdown
P c23d92c9c44f1d148572c81b53e60225cd4ac25f
U dkf
W 1802
<H3><A NAME="M2">NAME</A></H3>
<b>Tcl\_OOInitStubs</b> &mdash; initialize library access to TclOO functionality
<H3><A NAME="M3">SYNOPSIS</A></H3>
<B>#include &lt;tclOO.h&gt;</B><BR>
const char \*<B>Tcl\_OOInitStubs</B>(<I>interp</I>)
<DL class="arguments">
<DT>Tcl\_Interp <B>\*interp</B> (in)<DD>
The Tcl interpreter that the TclOO API is integrated with and whose C
interface is going to be used.
When an extension library is going to use the C interface exposed by TclOO, it
should use <B>Tcl\_OOInitStubs</B> to initialize its access to that interface
from within its <I>\*</I><B>\_Init</B> (or <I>\*</I><B>\_SafeInit</B>) function, passing in
the <I>interp</I> that was passed into that routine as context. If the result
of calling <B>Tcl\_OOInitStubs</B> is NULL, the initialization failed and an
error message will have been left in the interpreter's result. Otherwise, the
initialization succeeded and the TclOO API may thereafter be used; the
version of the TclOO API is returned.
When using this function, either the C #define symbol <B>USE\_TCLOO\_STUBS</B>
should be defined and your library code linked against the Tcl stub library,
or that #define symbol should <I>not</I> be defined and your library code
linked against the Tcl main library directly.
If you are linking against the Tcl 8.5 forward compatibility package for
TclOO, <I>only</I> the stub-enabled configuration is supported and you should
also link against the TclOO independent stub library; that library is an
integrated part of the main Tcl stub library in Tcl 8.6.
<H3><A NAME="M7">KEYWORDS</A></H3>
Z 0e02332691d3fa0f3d5af4466f65d0a2