GCC 3.3 template compile error?
GCC 3.3 template compile error?
- Subject: GCC 3.3 template compile error?
- From: "Tim Conkling" <email@hidden>
- Date: Fri, 12 Oct 2007 19:27:13 -0700
I'm compiling a Universal Binary. GCC 4 has no complaints (and neither does Visual C++), but GCC 3.3 chokes on the following code with the disappointingly non-descriptive message, "error: parse error before `;' token".
(The getAttribute() function in the offending line is a templated member function of the LibXmlReader class. It's called from lots of non-template functions with no problems.)
What am I doing wrong here?
template <class T>
class LevelValueScaleTable
{
private:
T m_initialValue;
std::vector<T> m_scaleTable;
mutable T m_cachedValue;
mutable int m_cachedScale;
public:
LevelValueScaleTable() : m_initialValue(0), m_cachedScale(-1) {}
void Read(const LibXmlReader& reader, const xmlpp::Node* node)
{
m_scaleTable.clear();
m_initialValue =
reader.getAttribute<T>(node, "initial"); // <-- error occurs here
...
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden