[XviD-devel] [RFC] Core options

Edouard Gomez ed.gomez at free.fr
Sun Mar 23 01:31:52 CET 2003


suxen_drol (suxen_drol at hotmail.com) wrote:
> also i was hoping the enumerations would prevent usage stupidy.
> such that something like...
>  	frame.vol = XVID_ME_FLAG
> ...would generate a compiler warning. is there a way to enable strict
> enumeration checking?

Here is what i did not like with enums in XviD.

The move  from defines to enums  is useless because flags  are set using
the int<->enum equivalence when doing things like:

  xvid.flags |= flag;

So the "checking" they were supposed  to provide is not performed by the
compiler.

I fear it's not possible to  enable strict enum checking, else you won't
be able to  combine flags (as "flag1  or flag2" is not part  of the enum
set)

-- 
Edouard Gomez-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://edu.bnhof.de/pipermail/xvid-devel/attachments/20030323/cc9250d2/attachment.bin


More information about the XviD-devel mailing list