parrotcode: Scalar Abstract Superclass | |
Contents | PMCs |
classes/scalar.pmc - Scalar Abstract Superclass
These are the vtable functions for the scalar base PMC class
PMC *clone()
INTVAL get_integer()
FLOATVAL get_number()
BIGNUM *get_bignum()
STRING *get_string()
INTVAL get_bool()
The set methods merely make the appropriate part of the cache be what it should be, more complex behaviour is left as an exercise for the inheriting class.
void set_integer_native(INTVAL value)
void set_number_native(FLOATVAL value)
void set_bignum_native(BIGNUM *value)
void set_string_native(STRING *value)
void add_int(INTVAL value, PMC *dest)
value
to the scalar and returns the result in *dest
.void add_float(FLOATVAL value, PMC *dest)
value
to the scalar and returns the result in *dest
.void subtract(PMC *value, PMC *dest)
void subtract_int(INTVAL value, PMC *dest)
value
from the scalar and returns the result in *dest
.void subtract_float (FLOATVAL value, PMC *dest)
value
from the scalar and returns the result in *dest
.void multiply (PMC *value, PMC *dest)
*value
and returns the result in *dest
.void multiply_int(INTVAL value, PMC *dest)
value
and returns the result in *dest
.void multiply_float(FLOATVAL value, PMC *dest)
value
and returns the result in *dest
.void divide(PMC *value, PMC *dest)
*value
and returns the result in *dest
.void divide_int(INTVAL value, PMC *dest)
value
and returns the result in *dest
.void divide_float(FLOATVAL value, PMC *dest)
value
and returns the result in *dest
.void modulus(PMC *value, PMC *dest)
*dest
the value of the scalar mod
the integer value of *value
.void modulus_int(INTVAL value, PMC *dest)
*dest
the value of the scalar mod
value
.void modulus_float(FLOATVAL value, PMC *dest)
void neg(PMC *dest)
dest
to the negated value of SELF
.void bitwise_or(PMC *value, PMC *dest)
*dest
the bitwise OR
of the scalar and *value
.void bitwise_or_int(INTVAL value, PMC *dest)
*dest
the bitwise OR
of the scalar and value
.void bitwise_and(PMC *value, PMC *dest)
*dest
the bitwise AND
of the scalar and *value
.void bitwise_and_int(INTVAL value, PMC *dest)
*dest
the bitwise AND
of the scalar and value
.void bitwise_xor(PMC *value, PMC *dest)
*dest
the bitwise XOR
of the scalar and *value
.void bitwise_xor_int(INTVAL value, PMC *dest)
*dest
the bitwise XOR
of the scalar and value
.void bitwise_not(PMC *dest)
*dest
the bitwise negation of the scalar and value
.void bitwise_shr(PMC *value, PMC *dest)
*dest
the shift right of the scalar by *value
.void bitwise_shr_int(INTVAL value, PMC *dest)
*dest
the shift right of the scalar by value
.void bitwise_shl(PMC *value, PMC *dest)
*dest
the shift left of the scalar by *value
.void bitwise_shl_int(INTVAL value, PMC *dest)
*dest
the shift left of the scalar by value
.void concatenate(PMC *value, PMC *dest)
*dest
the result of concatenating the scalar and *value
.void concatenate_str(STRING *value, PMC *dest)
*dest
the result of concatenating the scalar and *value
.INTVAL is_equal(PMC *value)
*value
.INTVAL cmp_num(PMC *value)
*value
.INTVAL cmp_string(PMC *value)
*value
.void logical_or(PMC *value, PMC *dest)
*dest
the result of the logical OR
of the scalar and *value
. void logical_and(PMC *value, PMC *dest)
*dest
the result of the logical AND
of the scalar and *value
.void logical_xor(PMC *value, PMC *dest)
*dest
the result of the logical XOR
of the scalar and *value
.void logical_not(PMC *dest)
*dest
the result of the logical negation of the scalar and *value
.void repeat(PMC *value, PMC *dest)
*dest
the result of repeating the scalar *value
times.void repeat_int(INTVAL value, PMC *dest)
*dest
the result of repeating the scalar value
times.void increment()
void decrement()
INTVAL defined()
STRING *substr_str(INTVAL offset, INTVAL length)
length
of the scalar starting at offset
.
|