Hey guys, I'm writing the simplest thing ever, just creating an ifstream to read in a text file and I have a weird error. Here is the code (note : the '<' missing for iostream and fstream are well written in my code but I couldn't write them here)
#include "genlib.h"
#include "simpio.h"
#include "random.h"
#include "vector.h"
#include "map.h"
#include <iostream>
#include <fstream>
int main() {
ifstream in;
in.open("Hamlet.txt");
if (in.fail()) Error("Could not open file");
return 0;
}
I get the following error after the ifstream in; line : "error : expected unqualified-id before '=' token"
Any idea what's going wrong ?
Thanks