NAME ^

classes/pyfloat.pmc - Python Floating-Point Number

DESCRIPTION ^

These are the vtable functions for the PyFloat base class

Methods ^

PMC* "__new__"(PMC *class, PMC *source)

Create a new floating point number

void add(PMC *value, PMC *dest)

Adds *value to the number and returns the result in *dest.

INTVAL get_integer()

Returns an integer representation of the number (by casting).

PMC *get_class()

Return the class of this object.

STRING *get_repr()

Returns the number as a Parrot string.

STRING *get_string()

Returns the number as a Parrot string.

FLOATVAL get_number()

Returns the value of the number.

INTVAL hash()

Returns a unique hash for this value

void modulus_float(FLOATVAL value, PMC *dest)

void set_number_native(FLOATVAL value)

Sets the value of the number to value.

void set_string_native(STRING *value)

Sets the value of the number by converting *value to a number.


parrot