...
void Foo_buggy_param(unsgined int arg);
unsgined int Foo_buggy_return();
...
and Foo.hpp :
static void buggy_param(unsgined int arg) noexcept;
static unsgined int buggy_return() noexcept;
Even the C compiler indicates the correction :
gcc -c -Wall -I../library/bindings/cpp/debug/include -g -o debug/obj/test-000.o test-000.c
In file included from test-000.c:3:
../library/bindings/cpp/debug/include/c_Foo.h:30:26: error: unknown type name ‘unsgined’; did you mean ‘unsigned’?
30 | void Foo_buggy_param(unsgined int arg);
| ^~~~~~~~
| unsigned
../library/bindings/cpp/debug/include/c_Foo.h:32:13: error: expected ‘;’ before ‘int’
32 | unsgined int Foo_buggy_return();
| ^~~~
| ;
Found this buggy conversion, while reading
cpp-include.rs
:Should be
Sample testing code :
Produces the following c_Foo.h :
and Foo.hpp :
Even the C compiler indicates the correction :