The Grammar class gives warnings about conversion of signed integer to unsigned integer, due to the...

following enums:

   enum {
         UNKNOWN_SCOPE = -2
       , TOP_LEVEL_SCOPE = -1
    };

which are passed into functions like this:

   virtual unsigned int getElemId
    (
        const   unsigned int    uriId
        , const XMLCh* const    baseName
        , const XMLCh* const    qName
        , unsigned int          scope
    )   const = 0;


The enum is signed, but the parameter it's passed to is unsigned.

It would be nice to eliminate this warning message. One way would be to redefine the two enums as:

   enum {
         UNKNOWN_SCOPE = UINT_MAX-1
       , TOP_LEVEL_SCOPE =  UINT_MAX
    };

In this way they'd (presumably) keep their same values, but become unsigned to match the parameter.

Anybody have a comment?

-jdb


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to