[MOAB-dev] iMesh and enum types

Tim Tautges tautges at mcs.anl.gov
Wed Mar 4 22:52:48 CST 2009


Because languages don't generally guarantee how many bytes an enum will 
have.  Now, you being a smart guy, you'll point out that int doesn't 
necessarily have a deterministic size either.  What these should really 
be is long (if we wanted ultimate determinism, we'd use int_32 or 
somesuch, but I think that would harm compatibility with fortran).

- tim

Jed Brown wrote:
> Why does iMesh.h use plain int for all the enum types?  That is, why
> does the interface not use the enums for types, topologies, and storage
> order?  This means that if the user declares their types using the
> enums, they need to cast to int when using the iMesh interface.
> 
> Jed

-- 
================================================================
"You will keep in perfect peace him whose mind is
   steadfast, because he trusts in you."               Isaiah 26:3

              Tim Tautges            Argonne National Laboratory
          (tautges at mcs.anl.gov)      (telecommuting from UW-Madison)
          phone: (608) 263-8485      1500 Engineering Dr.
            fax: (608) 263-4499      Madison, WI 53706



More information about the moab-dev mailing list