There are some variations of this question but none exactly matches what I'm looking for.
Giving the following code:
string command="";
while (command.compare("quit")!=0)
{
    os << prompt;
    getline(is,command);
}
How may I detect if getline reached eof (end of file)
 
    