Jump to content

Error


chitrangda

Recommended Posts

OK then. A couple other possibilities:

 

Did you name your file "myprogram.c" rather than "myprogram.cc" (or "myprogram.cpp" or "myprogram.c++")? Some compilers know that .c files are to be compiled as if they are written in C rather than C++.

 

Do you have an unterminated extern "C" { (i.e., missing close brace) lurking around somewhere, including in the headers files you #included before the #include <iostream> directive?

Link to comment
Share on other sites

OK then. A couple other possibilities:

 

Did you name your file "myprogram.c" rather than "myprogram.cc" (or "myprogram.cpp" or "myprogram.c++")? Some compilers know that .c files are to be compiled as if they are written in C rather than C++.

 

Do you have an unterminated extern "C" { (i.e., missing close brace) lurking around somewhere, including in the headers files you #included before the #include <iostream> directive?

no such error done by me.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.