#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include "kite_object.h"
#include "vm/kite_vm.h"
Functions | |
kite_object_t * | kite_boolean_object (kite_thread_t *thd, kite_object_t *obj) |
kite_object_t * | kite_string_object (kite_thread_t *thd, kite_object_t *obj) |
kite_object_t * | kite_int_object (kite_thread_t *thd, kite_object_t *obj) |
kite_object_t * | kite_float_object (kite_thread_t *thd, kite_object_t *obj) |
kite_object_t * | kite_list_object (kite_thread_t *thd, kite_object_t *obj) |
kite_object_t * | kite_object_name (kite_thread_t *thd, kite_object_t *obj) |
kite_object_t* kite_boolean_object | ( | kite_thread_t * | thd, | |
kite_object_t * | obj | |||
) |
Produce Boolean object from the given object.
thd | The current thread. | |
obj | The object to operate on. |
References kite_object_t::builtin_data, FALSE, kite_object_t::floatvalue, kite_object_t::intvalue, kite_new_boolean(), kite_new_list(), kite_reference_object(), kite_vm_call_method(), kite_vm_pop, kite_object_t::listvalue, kite_object_t::stringvalue, TRUE, and kite_object_t::type.
kite_object_t* kite_float_object | ( | kite_thread_t * | thd, | |
kite_object_t * | obj | |||
) |
Produce floating-point object from the given object.
thd | The current thread. | |
obj | The object to operate on. |
References kite_object_t::builtin_data, kite_object_t::intvalue, kite_new_float(), kite_new_list(), kite_reference_object(), kite_vm_call_method(), kite_vm_pop, kite_object_t::stringvalue, TRUE, and kite_object_t::type.
kite_object_t* kite_int_object | ( | kite_thread_t * | thd, | |
kite_object_t * | obj | |||
) |
Produce integer object from the given object.
thd | The current thread. | |
obj | The object to operate on. |
References kite_object_t::builtin_data, kite_object_t::floatvalue, kite_object_t::intvalue, kite_new_integer(), kite_new_list(), kite_reference_object(), kite_vm_call_method(), kite_vm_pop, kite_object_t::stringvalue, TRUE, and kite_object_t::type.
kite_object_t* kite_list_object | ( | kite_thread_t * | thd, | |
kite_object_t * | obj | |||
) |
Produce list object from the given object.
thd | The current thread. | |
obj | The object to operate on. |
References kite_object_t::builtin_data, kite_new_list(), kite_reference_object(), and kite_object_t::listvalue.
Referenced by kite_new_exception().
kite_object_t* kite_object_name | ( | kite_thread_t * | thd, | |
kite_object_t * | obj | |||
) |
Find the fully-qualified name of the object.
thd | The current thread. | |
obj | The object to operate on. |
References kite_object_t::inherit_from, kite_new_string(), kite_object_t::name, and kite_object_t::object_data.
Referenced by kite_string_object(), and kite_vm_execute_exception().
kite_object_t* kite_string_object | ( | kite_thread_t * | thd, | |
kite_object_t * | obj | |||
) |
Produce string object from the given object.
thd | The current thread. | |
obj | The object to operate on. |
References kite_object_t::builtin_data, kite_object_t::floatvalue, kite_object_t::intvalue, kite_new_list(), kite_new_string(), kite_object_name(), kite_reference_object(), kite_vm_call_method(), kite_vm_pop, TRUE, and kite_object_t::type.