I have never used STL sets before, but I have used some other STL stuff.
I am having trouble with upper_bound.
I have a class I defined, and I have a (STL set) set of pointers to different instantiations of the class. i compare using a comparison function, which takes 2 ptrs to the class type and then calls a function to compare based on an member variable of the class.
The problem is that I want to call upper_bound on my set, but I want to find the upper_bound based on that internal variable, not the key (because the key is a pointer to the class). How do I do this?