F
flips
OK this is really simple but I can't think what is the best
and most elegant solution.
Say I am getting an int from an ifstream as follows:
int val;
inFile.get(reinterpret_cast<char*>(&val), sizeof(val));
How do I know if this succeeded? It only returns false if
the eof is at the end of the int.
and most elegant solution.
Say I am getting an int from an ifstream as follows:
int val;
inFile.get(reinterpret_cast<char*>(&val), sizeof(val));
How do I know if this succeeded? It only returns false if
the eof is at the end of the int.