在 Botan v1.8.8 上运行 gcc v3.4.6 在成功构建 Botan 并运行其自检后,在构建我的应用程序时出现以下编译时错误:
../../src/Botan-1.8.8/build/include/botan/secmem.h: In member function `Botan::MemoryVector<T>& Botan::MemoryVector<T>::operator=(const Botan::MemoryRegion<T>&)':
../../src/Botan-1.8.8/build/include/botan/secmem.h:310: error: missing template arguments before '(' token
这个编译器错误告诉我什么?这是包含第 310 行的 secmem.h 的片段:
[...]
/**
* This class represents variable length buffers that do not
* make use of memory locking.
*/
template<typename T>
class MemoryVector : public MemoryRegion<T>
{
public:
/**
* Copy the contents of another buffer into this buffer.
* @param in the buffer to copy the contents from
* @return a reference to *this
*/
MemoryVector<T>& operator=(const MemoryRegion<T>& in)
{ if(this != &in) set(in); return (*this); } // This is line 310!
[...]