Patrick wrote:
 > Hi all,
 > 
 > I found what was causing the problem (compiling with g++), it's simply that
 > the struct initialization is not g++ compatible :
 > 
 >  __attribute__((weak)) struct __xn_tscinfo __xn_tscinfo = {
 >          .type = -1
 >  };
 > 
 > should be :
 > 
 > __attribute__((weak)) struct __xn_tscinfo __xn_tscinfo = {
 >          type : -1
 >  };
 > 
 > I tested this with g++ and gcc versions 4.1.2 and it compiles correctly.

...but is fragile, if we are not trying to initialize the structure
first member, g++ says:
sorry, unimplemented: non-trivial designated initializers not supported

So, we are better off do it the C++ way.

-- 


                                            Gilles Chanteperdrix.

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to