BONOBO_ARG_GET_STRING



Hello,

I am in the midst of porting bonobo-0.13 to Tru64 UNIX.  This is my
first attempt since version 0.9, which compiled with only minor
changes.

I'm stuck at bonobo-arg.c, line 198, which reads

    GTK_VALUE_STRING (*a) = g_strdup (BONOBO_ARG_GET_STRING (arg));

These macros resolve to

    ( ( * a ) . d . string_data )  = g_strdup ( ( do {     if ( ! ( ( arg ) -> _type -> kind == CORBA_tk_string ) )        g_log ( "Bonobo" ,      G_LOG_LEVEL_ERROR ,     "file %s: line %d: assertion failed: (%s)" ,    "bonobo-arg.c" ,        198 ,   "(arg)->_type->kind == CORBA_tk_string" ) ;     } while ( 0 ) , * ( ( CORBA_char * * ) ( arg -> _value ) ) ) );

I guess this must work on gcc, but it clearly is not ANSI C.  AFAIK
you cannot enclose a block in parens as above.

In most cases it's fairly easy to de-gcc-ify code; I could define
G_DISABLE_ASSERT, which I think would "fix" the problem, however I'm
not sure that's the best soluton.  I haven't run into this problem
with other packages.

Suggestions?

Thanks,
Aron

-- 
Aron Griffis            Compaq Computer Corporation, ZKO3-3/T30
Tru64 Hardware Support  110 Spit Brook Rd, Nashua, NH  03062
603-884-1276            http://bigfoot.com/~agriffis/




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