I'm having trouble making this global and I can't figure out what Im' doing wrong. It was actually just a test SSCCI and still comming up with errors.
Error: as.h:line 12: ifstream does not name a type.
error:as.cpp: ifs has not been declared....has not been declared... has not been declared...etc
Is it not possible to have classes as global variables? or is there just a small typo somewhere?
AS.H
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
#ifndef AS_H
#define AS_H
#include <fstream>
class as
{
public:
void openF();
void closeF();
private:
ifstream ifs;
};
#endif
usr/lib/gcc/i686-pc-cygwin/4.5.0/../../../libcygwin.a(libcmain.o):(.text+0xa9) undefinded reference to '_WinMain@16'
collect2: ld returned 1 exit status