Hello Together
I have the following problem with the EPICS cadef.h file:
This .h file defines the following structure
struct channel_in_use{
ELLNODE node; /* list ptrs */
short type; /* database field type */
#define TYPENOTCONN (-1) /* the type when disconnected */
unsigned short count; /* array element count */
union{
unsigned sid; /* server id */
struct db_addr *paddr; /* database address */
} id;
void *puser; /* user available area */
enum channel_state state; /* connected/ disconnected etc */
caar ar; /* access rights */
/*
* The following fields may change or even vanish in the future
*/
caCh *pConnFunc;
caArh *pAccessRightsFunc;
ELLLIST eventq;
unsigned cid; /* client id */
unsigned retry; /* search retry number */
void *piiu; /* private ioc in use block */
#ifdef vxWorks
void *ppn; /* ptr to optional put notify blk */
#endif /* vxWorks */
/*
* channel name stored directly after this structure in a
* null terminated string.
*/
};
typedef struct channel_in_use *chid;
and does a typedef with the name chid for this structure.
Later this name is used in two structures, for example in :
struct event_handler_args{
void *usr; /* User argument supplied when event added */
---> chid chid; /* Channel id */
long type; /* the type of the value returned (long aligned)*/
long count; /* the element count of the item returned */
void *dbr; /* Pointer to the value returned */
int status; /* CA Status of the op from server - CA V4.1 */
};
This gives this warning with the SUN compiler:
"./epics.3.12.1/base/include/cadef.h", line 218: Warning (Anachronism): Redefining chid after use in event_handler_args.
"./epics.3.12.1/base/include/cadef.h", line 218: Note: Type "CC -migration" for more on anachronisms.
"./epics.3.12.1/base/include/cadef.h", line 257: Warning (Anachronism): Redefining chid after use in exception_handler_args.
and even worse it is a syntax error! with GNU g++ compiler
It compiles, when the name is changed. e.g. chid chidname
Can somebody help me ?!
-----------------------------------------------------------------
*** **** ** * * Olaf Hensler
* * * * * * DESY, -MVP- [email protected]
* * *** ** * Notkestrasse 85 Tel.: +49 40 8998 3372
* * * * * 22603 Hamburg FAX : +49 40 8998 4448
*** **** ** * Germany
-----------------------------------------------------------------
- Navigate by Date:
- Prev:
Re: InterViews and free_gdct for Solaris jbk
- Next:
Re: Epics C++ Problems John R. Winans
- Index:
1994
<1995>
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
- Navigate by Thread:
- Prev:
Re: InterViews and free_gdct for Solaris jbk
- Next:
Re: Epics C++ Problems John R. Winans
- Index:
1994
<1995>
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
|