1

1)

typedef union __rfun_gop_event_info
{
 unsigned int evt;
 struct
 {
  unsigned int reserved1:1;
  unsigned int reserved0:1;
  unsigned int f30:1;
  unsigned int f29:1;
 }frame;
}rfun_gop_event_info;

2)

typedef union __rfun_gop_event_info
{
 unsigned int evt;
 struct
 {
  unsigned int reserved1:1;
  unsigned int reserved0:1;
  unsigned int f30:1;
  unsigned int f29:1;
 }frame;
}rfun_gop_event_info;

Thank you.

Vladimir
  • 170,431
  • 36
  • 387
  • 313
svetlana
  • 11
  • 2

1 Answers1

3

Have a look at this article at Delphi Corner that explains variant records which is exactly what you need:

DelphiCorner: Variant Records: The equivalent to the C-union structure

Excerpt containing example:

type
 TPerson = record
   FirstName, LastName: string[40];
   BirthDate: TDate;
   case Citizen: Boolean of
     True: (BirthPlace: string[40]);
     False: (Country: string[20];
       EntryPort: string[20];
       EntryDate: TDate;
       ExitDate: TDate);
 end;
jpfollenius
  • 16,456
  • 10
  • 90
  • 156