求解释这个异常是如何造成的啊
求解释这个错误是怎么造成的啊。
\PriorityQueue.h|23|error: ISO C++ forbids declaration of 'enqueue' with no type|
\PriorityQueue.h|23|error: prototype for 'int PriorityQueue<T>::enqueue(T)' does not match any in class 'PriorityQueue<T>'|
\PriorityQueue.h|10|error: candidate is: void PriorityQueue<T>::enqueue(T)|
\PriorityQueue.h|29|error: ISO C++ forbids declaration of 'dequeue' with no type|
\PriorityQueue.h|29|error: prototype for 'int PriorityQueue<T>::dequeue()' does not match any in class 'PriorityQueue<T>'|
\PriorityQueue.h|11|error: candidate is: T PriorityQueue<T>::dequeue()|
------解决方案--------------------
如int enqueue;
这样的声明才是有效的。
------解决方案--------------------
程序写错了包
慢慢调试吧
\PriorityQueue.h|23|error: ISO C++ forbids declaration of 'enqueue' with no type|
\PriorityQueue.h|23|error: prototype for 'int PriorityQueue<T>::enqueue(T)' does not match any in class 'PriorityQueue<T>'|
\PriorityQueue.h|10|error: candidate is: void PriorityQueue<T>::enqueue(T)|
\PriorityQueue.h|29|error: ISO C++ forbids declaration of 'dequeue' with no type|
\PriorityQueue.h|29|error: prototype for 'int PriorityQueue<T>::dequeue()' does not match any in class 'PriorityQueue<T>'|
\PriorityQueue.h|11|error: candidate is: T PriorityQueue<T>::dequeue()|
------解决方案--------------------
如int enqueue;
这样的声明才是有效的。
------解决方案--------------------
程序写错了包
慢慢调试吧