Milan Krejci said:
hello, sorry to bother you with this but i can't seem to figure out why i
can't do:
struct SD {
int from;
int to;
} sd;
std::map<sd,std::string> ListOfWorkingSchedule;
First, "sd" is the name of the variable, not the type:
--------------------------------------------------------------------
#include <map>
#include <string>
struct SD {
int from;
int to;
}sd;
std::map<SD, std::string> ListOfWorkingSchedule;
--------------------------------------------------------------------
After this change, you will still get a compiler error, albeit a different
one. Then once you get this new error, try to understand what it means. If
you can't figure it out, post the compiler error (I know what the problem
is -- I'm seeing if you know what the problem is).
Paul