On 26 Dec 2011, at 19:42, Jeppe Græsdal Johansen wrote:

>>    union {
>>        struct xt_entry_match **match;
>>        struct xt_entry_target **target;
>>    };
>>    void *xt_entry;
>>    void *udata;
>> }
...
>  case integer of
>   0: (match: ^Pxt_entry_match; xt_entry, udata: pointer);
>   1: (target: ^Pxt_entry_target);
> end;

While that does happen to work here, it's not a good way to translate such 
records because it's easy to make mistakes in case not all parts of the union 
are of the same size.


Jonas_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to