The error "Lack of a suitable function to call [...]" usually means "I cannot find a function that you can call with the following arguments." This can mean many things - either you mistakenly wrote the name of the function, or arguments of the wrong type, or you are trying to call a non-const member function in a const object, etc. Usually an error gives you some more detail about what went wrong, including the functions that he was trying to map, as well as the types of arguments that were actually found on the call site. Templates can make it harder to read, but with little time, you can usually learn to read them.
For this code, the second argument to the retrieve function is of type List_entry, which is the template parameter for List. In your main function, you instantiate the list, so List_entry is int in this case. However, you are trying to find a record that (I suppose) is not int. If you either modify the code to try to find an int, or to make a List List, this problem should go away.
Hope this helps!
source share