X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fvm%2Fprimitive.hpp;h=c650521039b15acec2407f1e5ff1ff41e73cc289;hb=9737de9e5622be1c7c2cba765f71cc0e14017baf;hp=10501c8c991569187f1b0b6955f55507352f511b;hpb=219e4a46e3d127d3c0883ee2e8635b4fe3c94d60;p=cacao.git diff --git a/src/vm/primitive.hpp b/src/vm/primitive.hpp index 10501c8c9..c65052103 100644 --- a/src/vm/primitive.hpp +++ b/src/vm/primitive.hpp @@ -30,9 +30,9 @@ #include -#include "vm/class.h" +#include "vm/class.hpp" #include "vm/global.h" -#include "vm/linker.h" +#include "vm/linker.hpp" #include "vm/utf8.h" @@ -50,6 +50,7 @@ public: static classinfo* get_arrayclass_by_type(int type); static int get_type_by_wrapperclass(classinfo *c); + static int get_type_by_primitiveclass(classinfo *c); static java_handle_t* box(int type, imm_union value); @@ -63,6 +64,7 @@ public: static java_handle_t* box(double value); static imm_union unbox(java_handle_t *o); + static bool unbox_typed(java_handle_t *o, int type, imm_union* value); static uint8_t unbox_boolean(java_handle_t* o); static int8_t unbox_byte(java_handle_t* o); @@ -125,20 +127,6 @@ extern primitivetypeinfo primitivetype_table[PRIMITIVETYPE_COUNT]; void primitive_init(void); void primitive_postinit(void); -#ifndef __cplusplus -// Legacy C interface. -classinfo *Primitive_get_class_by_name(utf *name); -classinfo *Primitive_get_class_by_type(int type); - -classinfo *Primitive_get_arrayclass_by_name(utf *name); -classinfo *Primitive_get_arrayclass_by_type(int type); - -int Primitive_get_type_by_wrapperclass(classinfo *c); - -java_handle_t *Primitive_box(int type, imm_union value); -imm_union Primitive_unbox(java_handle_t *h); -#endif - #endif // _PRIMITIVE_HPP