I believe this is another case of gcc trying to protect you from yourself, just like not allowing non-const references to temporary data passed to a function. This case is absolutely benign. However, there was a bug from similar code where one initializer depended on another. C++ initializes the variables in the order they are *declared* in the class, not the order listed in the initializer list. By forcing you to list them correctly, you are more likely to catch such initializer dependency issues.

michael

At 11:51 PM 11/6/2003 -0600, you wrote:
This I know is not messing with the meaning of the program. Warning was
picky about the order. This could be classed as a compiler maker's
opinion of code. Honestly I do not know if makes a difference in
execution but I guess not.

Stephen

bash-2.05b$ cvs diff iterhash.h
Index: iterhash.h
===================================================================
RCS file: /cvsroot/cryptopp/c5/iterhash.h,v
retrieving revision 1.5
diff -U2 -r1.5 iterhash.h
--- iterhash.h  10 Jul 2003 04:34:23 -0000      1.5
+++ iterhash.h  7 Nov 2003 05:41:52 -0000
@@ -15,5 +15,5 @@
        typedef T HashWordType;

-       IteratedHashBase() : m_countHi(0), m_countLo(0) {}
+       IteratedHashBase() : m_countLo(0), m_countHi(0) {}
        void SetBlockSize(unsigned int blockSize)
{m_data.resize(blockSize / sizeof(HashWordType));}
        void SetStateSize(unsigned int stateSize)
{m_digest.resize(stateSize / sizeof(HashWordType));}

--
Stephen Torri
GPG Key: http://www.cs.wustl.edu/~storri/storri.asc
--
Stephen Torri
GPG Key: http://www.cs.wustl.edu/~storri/storri.asc



Reply via email to