How do you iterate through every file/directory recursively in standard C++
How do you iterate through every file/directory recursively in standard C++ ...
How do you iterate through every file/directory recursively in standard C++ ...
I'm fairly new to the STL, so I was wondering whether there are any dynamically sortable containers? At the moment my current thinking is to use a vector in conjunction with the various sort algorithms, but I'm not sure whether there's a more appropriate selection given the (presumably) linear complexity of inserting entries into a sort...
Hi, I'm looking for a profiler in order to find the bottleneck of my c++ code. I'd like to find a free, non intrusive, good profiling tool. I'm a game developer and I use PIX for Xbox360, I found it very good (but not free) I know the Intel v-Tune, but it's not free. There exists any free profiling tool? ...
Specifically: When should we use it? What is happening at the compiler/linker level that requires us to use it? How in terms of compilation/linking does this solve the problems which require us to use it? ...
Let's say that on the C++ side my function takes a variable of type jstring named myString. I can convert it to an ANSI string as follows: const char* ansiString = env->GetStringUTFChars(myString, 0); is there a way of getting const wchar_t* unicodeString = ... ...
I'm trying to find a least-resistance path from C# to C++, and while I feel I handle C# pretty well after two solid years, I'm still not sure I've gotten the "groove" of C++, despite numerous attempts. Are there any particular books or websites that might be suitable for this transition? ...
I need to use XmlRpc in C++ on a Windows platform. Despite the fact that my friends assure me that XmlRpc is a "widely available standard technology", there are not many libraries available for it. In fact I only found one library to do this on Windows, (plus another one that claims "you'll have to do a lot of work to get this to compi...
A friend is having mysterious health problems that we're trying to track down. One thing that would help would be to improve his record keeping by giving him a handheld device with which he could keep track of various details of his day including diet and environmental factors. We will be getting him a device but haven't decided on Pal...
Can someone describe what a symbol table is in a C and C++ application? ...
Below is my current char* to hex string function. I wrote it as an exercise in bit manipulation. It takes ~7ms on a AMD Athlon MP 2800+ to hexify a 10 million byte array. Is there any trick or other way that I am missing? How can I make this faster? Compiled with -O3 in g++ static const char _hex2asciiU_value[256][2] = { {'0','0'...
In most C or C++ environments, there is a "debug" mode and a "release" mode compilation. Looking at the difference between the two, you find that the debug mode adds the debug symbols (often the -g option on lots of compilers) but it also disables most optimizations. In "release" mode, you usually have all sorts of optimizations turned o...
I am curious if anyone have used UnderC, Cint, and Ch (or any other C++ interpreter) and could share their experience. Thanks everyone for your valuable input. /Allan ...
I am working with an open-source UNIX tool that is implemented in C++, and I need to change some code to get it to do what I want. I would like to make the smallest possible change in hopes of getting my patch accepted upstream. Solutions that are implementable in standard C++ and do not create more external dependencies are preferred. ...
I have an iMac, and I want to be able to turn off the monitor when I go to sleep,. Alas, the iMac has no switch for this. I do not want to put the iMac into sleep mode, i want to write a "expose" like application or service, which when the mouse is put into the upper left hand corner of my screen, the display will sleep. Likewise, if ...
Is there any way to know if I'm compiling under Microsoft Visual Studio 2008 ? ...
What is the best source to learn C++ for a C programmer. ...
I'm trying to set the number format of a cell but the call to xlcFormatNumber fails leaving the cell number format as "General". I can successfully set the value of the cell using xlSet. XLOPER xRet; XLOPER xRef; //try to set the format of cell A1 xRef.xltype = xltypeSRef; xRef.val.sref.count = 1; xRef.val.sref.ref.rwFirst = 0; xRef.v...
I am looking for details of the VTable structure, order and contents, and the location of the vtable pointers within objects. Ideally, this will cover single inheritance, multiple inheritance, and virtual inheritance. References to external documentation would also be appreciated Documentation of GCC 4.0x class layout is here and the...
Say I have the following C++: char *p = new char[cb]; SOME_STRUCT *pSS = (SOME_STRUCT *)p; delete pSS; Is this safe according to the C++ standard? Do I need to cast back to a char* and then use delete[]? I know it'll work in most C++ compilers, because it's plain-ordinary-data, with no destructors. Is it guaranteed to be safe? ...
Under what circumstances might you want to use multiple indirection (that is, a chain of pointers as in **foo) in C++? ...