Skip to content

Replace unresolved opaque types with Byte if they are used only in pointers #106

Closed
@kornilova203

Description

@kornilova203

Bindings for uv.h give following errors:

Error: type declaration for struct___fsid_t was not found.
Error: type declaration for struct___va_list_tag was not found.
Error: type declaration for struct__IO_FILE_plus was not found.
...

It happens when declaration of opaque type was not found.

Seems like it is not a problem but such cases should be handled carefully.

I checked couple of these types and they are used in one of following situations:

  • Only pointers to such type is used.
    In this case type may be replaced by Byte.
  • Type is used in a chain of unused typedefs.
    Whole chain may be removed in this case. Related to Only output types and methods from the original header #13.
  • Extern variable of such type exist.
    In uv.h these variables are private, so they should be filtered.
    We do not know size of type so we cannot change type of extern to array of Byte
    I think, it is okay to always remove these extern variables.

Metadata

Metadata

Assignees

Labels

bindgenBinding generator

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions