Questions tagged [c++]

C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. Programming questions are off-topic and should be asked at http://stackoverflow.com/

[Above excerpt quoted from Wikipedia.]

New to C++?

Welcome! Whether you are new to programming or are coming to C++ from another programming language, it is highly recommended to have a good book from which to learn the language.

If you are looking for a good compiler, g++ is the most commonly used compiler on Linux and other platforms, while Microsoft Visual C++ is the most commonly used compiler on Windows. We also have a list of toolsets.

Join us in chat, where we discuss C++, programming in general, and even other stuff when boredom creeps in. Don't forget your sense of humor, but keep it civilized.

C++0x

The language standard has remained pretty much the same for a long time, but the new standard C++0x has now been defined. Rather than a "big bang" approach, it is being rolled out gradually as compilers are supporting the new language features. See the C++0x FAQ to see what is new in the language, and check your own compilers FAQs to see which of those features are currently supported.

Have a Question?

Programming questions are off-topic and should be asked at http://stackoverflow.com/. When you ask a question, be sure to include any relevant source code. Try to keep the code as minimalist as possible while still reproducing the problem; often the problem will be found during the process. Try to make sure that the source code compiles, if possible. However, if there are any compiler errors, be sure to indicate:

  • which compiler you are using
  • exactly what the errors are
  • on which lines they occur (mark the lines with comments)

Stack Overflow's C++ FAQ

Stack Overflow has recently started an effort to create a list of frequently asked C++ questions. You can reach them using the [c++-faq] tag on Stack Overflow.

External FAQs

On C++0x

Other External Resources

Third party code

General Posts

384 questions
6
votes
6 answers

notification upon program completion

I'm going to run prog.cpp on my university's Linux cluster (compiled with gcc). I project that the program will take 3-6 days to complete. I was thinking of running it as ./prog & to run it in the background. My questions are: Is it safe for me to…
covstat
  • 161
3
votes
1 answer

DEV C++ : No error while compiling any program but it is not running

All is working fine with DEV C++. Suddenly it stops working. The Program is compiling with no error messages. But when I hit the run button, nothing happens. This is happening with all programs. So there is no issue with the specific program. This…
2
votes
2 answers

Run same executable multiple times in parallel

I have an executable (e.g. test.exe) that is compiled c++/cli that can support multi threads. How can I run that same executable multiple times in parallel? The easiest way is to open several cmd windows and run test.exe from there, but that's…
fmvpsenior
2
votes
2 answers

running app in anjuta gives me **Error**: You must have `glib' installed

I get this error when I try to execute an application in anjuta in Fedora 16 and 18. Error: You must have `glib' installed. I did run 'yum install glib glib-devel' but the problem persists I created the default C++ foobar project.
Damian
  • 299
2
votes
1 answer

C++ 64bit page faults

I have a C++ server application running on Windows Server 2003 64 bit. Machine has 16 cores and 16 GB of ram. Once the app gets to about 2GB memory usage its Page Fault delta shoots up to ~200,000 and the app becomes very slow. The app is compiled…
unclepaul84
  • 121
  • 2
0
votes
1 answer

Lost fform design view in MS express 2010

Working on a windows forms project in MS C++ express 2010. It builds fully with no errors, runs correctly as a forms based application but in the solution explorer the icon for form1.h shows it as a header file - with the h icon, rather than with…
0
votes
1 answer

Cannot Run HelloWorld C++ App on Eclipse, Mac OS X? No RunAs Option; GCC Not Installed Despite XCode Installed

I've spent hours this evening trying to get the hello world C++ App to run and no luck. What I've Done: 1. Installed XCode and C++ for Eclipse as per http://www.banym.de/mac/install-eclipse-cc-juno-on-mac-os-x 2. Tested that XCode works and can open…
eb80
  • 263
0
votes
1 answer

transfer code from windows to linux

while transfer code from visual studio 2010 to linux we encounter the next message (compiler): "Tank.h:24: fatal error: can`t write PCH file: Disk quota exceeded" class Tank: public Vehicle { public: Tank(char* veID, char* model, int…
Elad Betite
0
votes
0 answers

OpenCV -- how to interpret contents of cv::imread object

I am new to OpenCV and have tried to copy the contents of a cv::imread object to an array. When I print the contents, however, I get a bunch of characters like this ^N ^X ^Y ^Q ^[ ^U How am I to interpret this as RGB values? I was expecting values…
0
votes
1 answer

TwinCAT 3 integration with C++

I am trying to use C++ module with TwinCAT 3 to explore its potential. However, I am stuck at the very beginning since I can´t create a new project. I get this when I try to create a new C++ item enter image description here I've followed the…
0
votes
0 answers

How do DLLs and dynamic linking work exactly?

How does dynamic linking happen in detail? And what does DLL have inside? I know that DLLs have machine instructions just like executables but what I don't understand is how does the executable locate the functions from the DLL by name. Is there…
0
votes
0 answers

c++ apls library couldn't find

I download and install the ALPS computational physics library for c++, set the PATH, but the compiler doesn't work. Have anyone used ALPS lib? Is there solution for this? Thanks
Jian
  • 101
  • 2
0
votes
2 answers

How to stop infinite loop program after compilation

I am using turbo c++ , in college we were learning loop structure and were implementing it. But when I wrote while loop it shows the result infinite times and the turbo program get hanged . Is there any way to stop this program and re-compile the…
Phill
  • 33
  • 1
  • 6
-2
votes
4 answers

Suggestion for C++ compiler

I am looking for a free C++ compiler compatible with Windows 8. Please add link of the web page from where it can be downloaded. DEV C++ is giving much trouble. Turbo C++ is available for DOS operating system. You may also suggest other free…
Supriyo
  • 105