I am writing a function that inserts an item into the rear of the queue.
template <class T>
void Queue<T>::pushBack(const T& item)
{
QNode<T>* newNode;
newNode = new QNode<T>[item];
if (empty())
qFront = newNode;
else
qRear->next = newNode;
qRear = newNode;
qSize++;
}
It seems like line five is giving me my error.