Union Type support ?



Using ORBit-0.5.1

four.idl
=====
interface Four {
        union UFixed switch(char) {
                case 'a': long x;
                case 'b': short y;
                default: float z;
        };
        UFixed doUFixed(in UFixed inparam, out UFixed outparam, inout UFixed inoutparam);
}

generated : four-common.c
===========
static const CORBA_any anon_sublabels_array15[] =
{
   {(CORBA_TypeCode) & TC_CORBA_char_struct, (gpointer) & anon_sublabel_values_a
rray16[0], CORBA_FALSE},
   {(CORBA_TypeCode) & TC_CORBA_char_struct, (gpointer) & anon_sublabel_values_a
rray16[1], CORBA_FALSE},
{(CORBA_TypeCode) & TC_CORBA_octet_struct, (int *) &zero_int, CORBA_FALSE}};
const struct CORBA_TypeCode_struct TC_Four_UFixed_struct =
 .....


Compile step :
  four-common.c
  four-common.c:89: `zero_int' undeclared here (not in a function)
  four-common.c:89: initializer element is not constant
  four-common.c:89: (near initialization for `anon_sublabels_array15[2]._value')
  gmake: *** [four-common.o] Error 1


At ORBit-0.5.1, Union Type Can't support ?

  ETRI, Jang Jong Hyun.


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