Convert an object from one data type to another.
The typecast function performs a generic typecast operation on
x to convert it to new_type. If x represents an
array, the function will attempt to convert all elements of x
to new_type. Not all objects can be converted and a
type-mismatch error will result upon failure.
define to_complex (x)
{
return typecast (x, Complex_Type);
}
defines a function that converts its argument, x to a complex
number.
- slangrtl
-
__class_id,
__class_type,
__eqs,
__get_reference,
__is_initialized,
__pop_args,
__push_args,
_nargs,
_slang_guess_type,
_typeof,
array_info,
atof,
double,
dup,
int,
integer,
is_defined,
is_struct_type,
isdigit,
length,
set_float_format,
sscanf,
string,
tolower,
toupper,
typeof
|