///home/berryj/link/bin/genMethods "-g" "-t" "int" "-h" "List" "-I" "LINK/basic/List.h" "-d" "basic" 
#include <stk.h>
#include <LINK/stkWrapper/LINK_STk.h>

#include <LINK/basic/List.h>

#include <LINK/stkWrapper/Wrapper.h>
#include <LINK/stkWrapper/Register.h>
#include <LINK/stkWrapper/ListWrapper.h>


typedef int _int;
typedef List<int > _List_int_;
static List<int > s__List_int_;

#define _List_int_DATA(x) ((List<int >*) (EXTDATA(x)))
#define _List_int_IS_DATA(x) (TYPEP(x, tc_CXXwrapper) && \
		TYPEP(STk_slot_ref(x,val_scm), tc_CXXwrapper) && \
		(EXTID(STk_slot_ref(x,val_scm)) == Wrapper<List<int > >::type))
#define _List_int_ISNT_DATA(x) (!_List_int_IS_DATA(x))

#define _List_int_CXX_DATA(x) (*(List<int >*) (EXTDATA(VAL(x))))
#define _List_int_CXX_IS_DATA(x) (INSTANCEP(x) && \
		TYPEP(STk_slot_ref(x,val_scm), tc_CXXwrapper) && \
		(EXTID(STk_slot_ref(x,val_scm)) == Wrapper<List<int > >::type))
#define _List_int_CXX_ISNT_DATA(x) (!_List_int_CXX_IS_DATA(x))


PRIMITIVE STk_init__List_int_()
{
	Wrapper<_List_int_>::type = STk_new_CXXwrapper_id(
			Wrapper<_List_int_>::name, 
			"",
			(void (*)(SCM x, SCM port, int mode))
			ListWrapper<_int>::displayTypedList,
			(void (*)(SCM x))ListWrapper<_int>::markTypedList,
			(void (*)(SCM x))ListWrapper<_int>::freeTypedList);
	Tcl_InitHashTable(&Register<_List_int_>::objTable, TCL_ONE_WORD_KEYS);
	return UNDEFINED;
}

void genExtra_List_int_Methods(void);

PRIMITIVE STk_init_methods__List_int_()
{
	STk_add_new_cpp_primitive("List-int-make", tc_subr_0, 
	(PRIMITIVE (*)(...))  ListWrapper<_int>::makeLinkList);
	STk_add_new_cpp_primitive("List-int?", tc_subr_1, 
	(PRIMITIVE (*)(...))  ListWrapper<_int>::linkListP);
	STk_add_new_cpp_primitive("list->List-int", tc_subr_1, 
	(PRIMITIVE (*)(...))  ListWrapper<_int>::stkList2LinkList);
	STk_add_new_cpp_primitive("List-int->list", tc_subr_1, 
	(PRIMITIVE (*)(...))  ListWrapper<_int>::linkList2STkList);
	genExtra_List_int_Methods();
	return UNDEFINED;
}
