Re: type-punning warnings with optimizations turned on?



Alan M. Evans schrieb:
        struct MyMutex {
            GStaticMutex mutex;
        };

Unless you add a define like "typedef MyMutex MyMutex" you have to
add the "struct" keyword. Otherwise this is an incomplete type the
compiler grouch about:

        MyMutex * MyMutex_new() {
          struct MyMutex* MyMutex_new() {

        void MyMutex_free(MyMutex *mutex) {
          void MyMutex_free(struct MyMutex *mutex) {

Cheers, Andy



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]