I am trying to get a better understanding of overloading operators because it is the topic of discussion in my class currently. I cannot seem to get it to work when I am putting it into practice. For the code I have displayed below, I am getting errors such as:
'std::ostream& StringVar::operator<<(std::ostream&, const StringVar&)' must have exactly one argument
I am also getting other errors saying that 'outs' was not declared in the scope. I do not know where to begin. If someone could provide a better explanation of overloading operators that would be wonderful. My book doesn't do a good job at explaining this topic.