I'm attempting to compile this code to test out certain blocks before I proceed to others, but there seems to be an issue at line 51 with stringstream. I don't know if I'm misusing it, but I get an error on that line when I try to compile:
error: no match for'operator>>' in 'std::basic_stringstream<char, ...
And so on.
I've tried removing the first instance of stringstream, but then I get the same error message for the next instance.
From the looks of it (correct me if I am erroneous), you are using the '>>' operator on a temporary object. The temporary object will not retain the value, so attempting to "extract" the information within the object stream and assign it to "loco[defcount].latitude" will do nothing. I've altered your code and posted it below. Does my answer satisfy you?
Quick question: Why are the numbers entered by the user being stored in a std::string object?
In response to your question, there's no particular reason I'm storing the numbers in such a way. In fact, now that you point it out, I think I'll change it.