I wanted to write a template function for signing files
Something like this:
template<typename T> sign() {
CryptoPP::RSASS<CryptoPP::PSS, T>::Signer signer(m_privateKey);

// Code to do the signing and such...
}
So that it could be used like this

sign<CryptoPP::SHA256>()
However, I end up with a nice compiler error(s):
error C2760: syntax error: unexpected token 'identifier', expected ';'
note: This diagnostic occurred in the compiler generated function 'std::string 
sign(void)'
error C7510: 'Signer': use of dependent type name must be prefixed with 
'typename'
note: This diagnostic occurred in the compiler generated function 'std::string 
sign(void)'

I don't know if I am doing it wrong, or if this is not supported. 
I would love some input.
Thank you in advance!

-- 
You received this message because you are subscribed to "Crypto++ Users". More 
information about Crypto++ and this group is available at 
http://www.cryptopp.com and 
http://groups.google.com/forum/#!forum/cryptopp-users.
--- 
You received this message because you are subscribed to the Google Groups 
"Crypto++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cryptopp-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/cryptopp-users/de10c47d-856b-4ce5-998f-190c0a64f886o%40googlegroups.com.

Reply via email to