swig/Examples/test-suite/guile/guile_ext_test_external.cxx
Olly Betts 336de2f745 [guile] Stop using deprecated aliases
The replacements should all work with Guile 1.8.0, which is the
oldest version we still aim to support.

Fixes #1624
2022-08-04 10:39:02 +12:00

24 lines
438 B
C++

#include <guile_ext_test_wrap_hdr.h>
#include <imports_a.h>
SCM test_create()
{
#define FUNC_NAME "test-create"
SCM result;
A *newobj;
swig_type_info *type;
newobj = new A();
type = SWIG_TypeQuery("A *");
result = SWIG_NewPointerObj(newobj, type, 1);
return result;
#undef FUNC_NAME
}
SCM test_is_pointer(SCM val)
{
#define FUNC_NAME "test-is-pointer"
return scm_from_bool(SWIG_IsPointer(val));
#undef FUNC_NAME
}