Closed stephan57160 closed 2 years ago
Input in glue.rs.in:
glue.rs.in
foreign_class!( class Foo { /// do_nothing() does nothing at all. fn do_nothing(); } );
Output in c_Foo.h:
#ifdef __cplusplus static_assert(sizeof(uintptr_t) == sizeof(uint8_t) * 8, "our conversion usize <-> uintptr_t is wrong"); extern "C" { #endif typedef struct FooOpaque FooOpaque; //do_nothing() does nothing at all. void Foo_do_nothing(); #ifdef __cplusplus } #endif
But as there is no struct FooOpaque defined anywhere, is there a need for this ?
struct FooOpaque
typedef struct FooOpaque FooOpaque;
Yes, in case of class with methods without "self" argument there are no need for this typedef.
OK. I'll check for a fix. Sorry, I just saw that with my own enum test cases :-)
Input in
glue.rs.in
:Output in c_Foo.h:
But as there is no
struct FooOpaque
defined anywhere, is there a need for this ?