I am coding struct Node
and I think this is constructor initializer error. What did I write wrong?
class linkedlist
{
private:
struct Node
{
char m_num;
char m_logo;
char m_name;
char m_1;
int m_2;
Node* next;
};
Node()
: m_num(), m_logo(), m_name(), m_1(), m_2(), next(nullptr) // error: expected unqualified-id before ')' token|
{}
Node(const char& a, const char& b, const char& c, const char& d, const int& e)
: m_num(a), m_logo(b), m_name(c), m_1(d), m_2(e), next(nullptr) // error: expected unqualified-id before 'const'|
{} // error: expected ')' before 'const'|
Node* head = nullptr;
Node* tail = nullptr;