You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
in our CMakeLists.txt and end up with an error about use if undeclared identifier 'anonymous' errors which causes the build to fail.
I guess my question is, is this a bug/issue that needs to be addressed in the cpp file or could Scapix improve the handling of the code generation here?
Example of the cpp code (some info renamed for privacy):
union {
Data data;
Command command;
RenamedThing::Error error;
OTA ota;
uint8_t subtype;
};
warning and error thrown:
/Users/bradmartin/projects/test/renamedthing-watchos/renamedthing-cpp-lib/generated/bridge/objc/cpplib/bridge/Packet.h:97:1: warning:
typedef requires a name [-Wmissing-declarations]
typedef struct {
^~~~~~~
/Users/bradmartin/projects/test/smartdrive-watchos/renamedthing-cpp-lib/generated/bridge/objc/cpplib/bridge/Packet.mm:243:54: error:
expected unqualified-id
struct scapix::link::objc::struct_<permobil::Packet::(anonymous union at /Users/bradmartin/projects/test...
^
/Users/bradmartin/projects/test/renamedthing-watchos/renamedthing-cpp-lib/generated/bridge/objc/cpplib/bridge/Packet.mm:243:55: error:
use of undeclared identifier 'anonymous'
struct scapix::link::objc::struct_<test::Packet::(anonymous union at /Users/bradmartin/projects/test...
^
1 warning and 2 errors generated.
@Boris-Rasin - I sent a message via the scapix website, would appreciate your reply if you have time. It's about some potential hourly consulting to fix some build issues with the project using Scapix. Thanks for your time.
Activity
Boris-Rasin commentedon Feb 21, 2024
Thank you for your report.
This was indeed a bug - in some cases, Scapix attempted to generate bindings for unions, which are not supported.
I have fixed this bug and released a new version.
Please use new version 1.0.44:
https://github.com/scapix-com/cmodule/releases
bradmartin commentedon Feb 21, 2024
Thanks, confirmed that does allow the build to succeed and generate the bridge files.
bradmartin commentedon Feb 21, 2024
@Boris-Rasin - I sent a message via the scapix website, would appreciate your reply if you have time. It's about some potential hourly consulting to fix some build issues with the project using Scapix. Thanks for your time.