diff --git a/keccak.h b/keccak.h index acdc3f3b..5fd9b6b4 100644 --- a/keccak.h +++ b/keccak.h @@ -70,11 +70,11 @@ protected: //! \tparam DigestSize controls the digest size as a template parameter instead of a per-class constant //! \brief Keccak-X message digest, template for more fine-grained typedefs //! \since Crypto++ 5.7.0 -template +template class Keccak_Final : public Keccak { public: - CRYPTOPP_CONSTANT(DIGESTSIZE = digestSize) + CRYPTOPP_CONSTANT(DIGESTSIZE = T_DigestSize) CRYPTOPP_CONSTANT(BLOCKSIZE = 200 - 2 * DIGESTSIZE) //! \brief Construct a Keccak-X message digest @@ -83,7 +83,7 @@ public: unsigned int BlockSize() const { return BLOCKSIZE; } private: CRYPTOPP_COMPILE_ASSERT(BLOCKSIZE < 200); // ensure there was no underflow in the math - CRYPTOPP_COMPILE_ASSERT(BLOCKSIZE > DIGESTSIZE); // this is a general expectation by HMAC + CRYPTOPP_COMPILE_ASSERT(BLOCKSIZE > T_DigestSize); // this is a general expectation by HMAC }; //! \class Keccak_224 diff --git a/sha3.h b/sha3.h index 04c23260..23a18fad 100644 --- a/sha3.h +++ b/sha3.h @@ -55,11 +55,11 @@ protected: //! \tparam DigestSize controls the digest size as a template parameter instead of a per-class constant //! \brief SHA3-X message digest, template for more fine-grained typedefs //! \since Crypto++ 5.7.0 -template +template class SHA3_Final : public SHA3 { public: - CRYPTOPP_CONSTANT(DIGESTSIZE = digestSize) + CRYPTOPP_CONSTANT(DIGESTSIZE = T_DigestSize) CRYPTOPP_CONSTANT(BLOCKSIZE = 200 - 2 * DIGESTSIZE) //! \brief Construct a SHA3-X message digest @@ -68,7 +68,7 @@ public: unsigned int BlockSize() const { return BLOCKSIZE; } private: CRYPTOPP_COMPILE_ASSERT(BLOCKSIZE < 200); // ensure there was no underflow in the math - CRYPTOPP_COMPILE_ASSERT(BLOCKSIZE > DIGESTSIZE); // this is a general expectation by HMAC + CRYPTOPP_COMPILE_ASSERT(BLOCKSIZE > T_DigestSize); // this is a general expectation by HMAC }; //! \class SHA3_224 diff --git a/stdcpp.h b/stdcpp.h index 02e9cac3..919e7b53 100644 --- a/stdcpp.h +++ b/stdcpp.h @@ -46,8 +46,10 @@ namespace std { #include // uintptr_t and ptrdiff_t -#if (__cplusplus < 201103L) +#if (__cplusplus < 201103L) && (!defined(_MSC_VER) || (_MSC_VER >= 1400)) # include +#elif defined(_MSC_VER) && (_MSC_VER < 1400) +# include #endif #ifdef CRYPTOPP_INCLUDE_VECTOR_CC