Hi Andrei, We need to check our UG ;-) I think your assumption is correct.
We even have a test (see test/cmpd_dset.c) that writes fields in one order and then reads them into a data structure that has a reversed order of the members (structures s1_t and s3_t for reference). Elena ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Elena Pourmal The HDF Group http://hdfgroup.org 1800 So. Oak St., Suite 203, Champaign IL 61820 217.531.6112 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ On Oct 24, 2013, at 1:25 PM, "Salnikov, Andrei A." <[email protected]> wrote: > Hi, > > quick qestion on the compound types. For some reason I had an > impression that compound types can match their fields by the > filed name and the order of the fields (and the number) does > not really matter. I re-read the User's Guide and there it > explicitely states (In Data Transfer section): > > The name and order of the fields must be the same in the source > and the destination but the source and destination may have > different alignments of the fields, and only some of the fields > might be transferred. > > It seems that my assumption is not correct. What should happen now > when source and destination types have the same fields but ordered > differently? Do we get any error or does it silently skip fileds? > > > Thanks, > Andy > > > _______________________________________________ > Hdf-forum is for HDF software users discussion. > [email protected] > http://mail.lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
_______________________________________________ Hdf-forum is for HDF software users discussion. [email protected] http://mail.lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
