cronologic-de / xhptdc8_babel

Wrappers, Utilities and Examples for using the xHPTDC8 with various programming languages.
Mozilla Public License 2.0
0 stars 1 forks source link

Compilation error in xHPTDC8_interface.h, xhptdc8_grouping_configuration #11

Closed Bassem-Ramzy closed 3 years ago

Bassem-Ramzy commented 3 years ago

xHPTDC8_interface.h file generates the following compilation error on both MS Visual Studio 2019 Client, and MSBuild on github action:

error C5208: unnamed class used in typedef name cannot declare members other than non-static data members, member enumerations, or member classes The checked in solution is to do

typedef struct xhptdc8_grouping_configuration_ xhptdc8_grouping_configuration;
    struct xhptdc8_grouping_configuration_ {
        .
        .
        };

instead of:

    typedef struct {
        .
        .
        } xhptdc8_grouping_configuration;
Bassem-Ramzy commented 3 years ago

Log of the build & error is found here

sulimma commented 3 years ago

I currently don't have a compiler here, but I believe that the default assignment in this line is the problem: bool enabled = false;

I think you need to change it to crono_bool_t enabled;

and initialize it when the the other members are initialized. I file an issue with the developers.

Bassem-Ramzy commented 3 years ago

Applied