parse errors?
I''m getting a "parse error at end of input" for this simple program
#include <iostream.h>
#include <stdlib.h>
#include <string>
#include <fstream.h>
#include "Stack.h"
int main(int argc, char *argv[])
{
stack S(20);
return 0;
}
I''m more curious what the main cause of parse errors is, rather than whats wrong with my code...I''m just learning so this will help me for future
Thanks in advance
->What part of "Stack.h" gives the error?
______________________________Only dead fish go with the main-stream.
Parse errors are caused by errors in your code's syntax. Missing ; are a major culprit of this. Misspelled variable and function names can cause them too (among other things).
BTW, iostream.h is NOT a standard C++ header. You should use < iostream > instead and add
/*=========================================*/
/* Chem0sh */
/* Lead Software Engineer & Tech Support */
/* http://www.eFaces.biz */
/*=========================================*/
[edited by - Chem0sh on June 21, 2002 5:06:58 PM]
[edited by - Chem0sh on June 21, 2002 5:07:43 PM]
BTW, iostream.h is NOT a standard C++ header. You should use < iostream > instead and add
using namespace std;
after your includes. < iostream.h > != < iostream >. In fact, VC .NET will complain loudly if you use iostream.h, saying that it's depricated. /*=========================================*/
/* Chem0sh */
/* Lead Software Engineer & Tech Support */
/* http://www.eFaces.biz */
/*=========================================*/
[edited by - Chem0sh on June 21, 2002 5:06:58 PM]
[edited by - Chem0sh on June 21, 2002 5:07:43 PM]
/*=========================================// Chem0sh// Lead Software Engineer & Tech Support// http://www.eFaces.biz=========================================*/
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement