fstream is obsolete now