search for: tcl_getstringresult

Displaying 2 results from an estimated 2 matches for "tcl_getstringresult".

2018 Jul 01
2
[PATCH nbdkit] Add Tcl plugin, for writing plugins in Tcl.
...+ +static Tcl_Interp *interp; +static const char *script; + +static void +tcl_load (void) +{ + //Tcl_FindExecutable ("nbdkit"); + interp = Tcl_CreateInterp (); + if (Tcl_Init (interp) != TCL_OK) { + nbdkit_error ("cannot initialize Tcl interpreter: %s", + Tcl_GetStringResult (interp)); + exit (EXIT_FAILURE); + } +} + +static void +tcl_unload (void) +{ + if (interp) + Tcl_DeleteInterp (interp); + Tcl_Finalize (); +} + +/* Test if proc was defined by the Tcl code. */ +static int +proc_defined (const char *name) +{ + int r; + Tcl_Obj *cmd; + + cmd = Tcl_NewObj...
2008 May 04
1
Change in the Tcl/Tk loading in R 2.7.0 (under Unix/Mac OS X)?
Hello, Up to R 2.6.2, I used to start Tcl *without Tk* (I need only Tcl for some part of my work, like a socket server written in Tcl only, for instance) with this code under Mac OS X (particularly on this system, because I don't want to start X11 just to use Tcl code, which is required for Tk!): > Sys.unsetenv("DISPLAY") > library(tcltk) I got then the message