SYNOPSIS
#include <tcl.h>
int Tcl_GetInt(interp, string, intPtr)
int Tcl_GetDouble(interp, string, doublePtr)
int Tcl_GetBoolean(interp, string, boolPtr)
ARGUMENTS
- Tcl_Interp *interp (in)
-
Interpreter to use for error reporting.
- char *string (in)
-
Textual value to be converted.
- int *intPtr (out)
-
Points to place to store integer value converted from string.
- double *doublePtr (out)
-
Points to place to store double-precision floating-point value converted from string.
- int *boolPtr (out)
-
Points to place to store boolean value (0 or 1) converted from string.
DESCRIPTION
These procedures convert from strings to integers or double-precision floating-point values or booleans (represented as 0- or 1-valued integers). Each of the procedures takes a string argument, converts it to an internal form of a particular type, and stores the converted value at the location indicated by the procedure's third argument. If all goes well, each of the procedures returns TCL_OK. If string doesn't have the proper syntax for the desired type then TCL_ERROR is returned, an error message is left in the interpreter's result, and nothing is stored at *intPtr or *doublePtr or *boolPtr.
PORTABILITY
Windows 8.1. Windows Server 2012 R2. Windows 10. Windows Server 2016. Windows Server 2019. Windows 11. Windows Server 2022.
AVAILABILITY
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition
PTC MKS Toolkit 10.4 Documentation Build 39.