lib/C/iec_types_all.h
changeset 909 8b2a31dea131
parent 904 423ea3749212
child 932 061824c45a5b
equal deleted inserted replaced
908:9e8e1ba5ca46 909:8b2a31dea131
    84   IEC_##type *value;\
    84   IEC_##type *value;\
    85   IEC_BYTE flags;\
    85   IEC_BYTE flags;\
    86   IEC_##type fvalue;\
    86   IEC_##type fvalue;\
    87 } __IEC_##type##_p;
    87 } __IEC_##type##_p;
    88 
    88 
       
    89 
       
    90 
    89 #define __DECLARE_DERIVED_TYPE(type, base)\
    91 #define __DECLARE_DERIVED_TYPE(type, base)\
    90 typedef base type;\
    92 typedef base type;\
    91 typedef __IEC_##base##_t __IEC_##type##_t;\
    93 typedef __IEC_##base##_t __IEC_##type##_t;\
    92 typedef __IEC_##base##_p __IEC_##type##_p;
    94 typedef __IEC_##base##_p __IEC_##type##_p;
    93 
    95 
   118 #define __DECLARE_STRUCT_TYPE(type, elements)\
   120 #define __DECLARE_STRUCT_TYPE(type, elements)\
   119 typedef struct {\
   121 typedef struct {\
   120   elements\
   122   elements\
   121 } type;\
   123 } type;\
   122 __DECLARE_COMPLEX_STRUCT(type)
   124 __DECLARE_COMPLEX_STRUCT(type)
       
   125 
       
   126 #define __DECLARE_REFTO_TYPE(type, name)\
       
   127 typedef name * type;\
       
   128 __DECLARE_COMPLEX_STRUCT(type)
       
   129 
   123 
   130 
   124 /* Those typdefs clash with windows.h */
   131 /* Those typdefs clash with windows.h */
   125 /* i.e. this file cannot be included aside windows.h */
   132 /* i.e. this file cannot be included aside windows.h */
   126 __ANY(__DECLARE_IEC_TYPE)
   133 __ANY(__DECLARE_IEC_TYPE)
   127 
   134