no matching function for call to find(std::_List_iterator<Process>, std::_List_iterator<Process>, Process&)
C++ プログラムで" " というコンパイル エラーが発生しました。
mfqueue
クラスは次のようになります。
MFQueue::MFQueue() {
list<Process> queue;
vector<int> ran;
int time_quantum = 0;
int run_for = 0;
}
MFQueue::MFQueue(int quantum) {
list<Process> queue;
vector<int> ran;
int time_quantum = quantum;
int run_for = 0;
}
「プロセス」は私のクラスの 1 つです
bool MFQueue::contains(Process p) {
list<Process>::iterator itr = find(queue.begin(), queue.end(), p);
return (p == *itr);;
}
この問題を解決する方法を知っている人はいますか?前もって感謝します!