I use Jochen Kalmbach's StackWalker class from CodeProject, to produce a stacktrace when an exception occurs in my DLL.
It relies on DbgHelp.dll
Is DbgHelp.dll built-in to Windows Vista, WS2008, Windows 7?
I know about The Debugging Tools for Windows from Microsoft, and I'm aware that DbgHelp.dll ships in that package. But I also f...
I know some languages allow this. Is it possible in C++?
...
If I use an array of linked list to implement a hash table, the "remove" function might require traversing through a "chain."
Is this also true for "deleting"?
...
Is it possible to return a class through it's own function, so you can chain functions like below:
class Foo;
Foo.setX(12).setY(90);
Can anyone confirm if this is possible, and how it would be achieved?
...
I'm in the process of porting a C++/WTL project from Visual Studio 2005 to VS 2008. One of the project configurations is a unit-testing build, which defines the preprocessor symbol UNIT_TEST.
In order to get my WTL classes into my test harness, I made a CFakeWindow class that stubs all the CWindow methods. Then in my stdafx.h file, I do...
Is it possible to specialize a templatized method for enums?
Something like (the invalid code below):
template <typename T>
void f(T value);
template <>
void f<enum T>(T value);
In the case it's not possible, then supposing I have specializations for a number of types, like int, unsigned int, long long, unsigned long long, etc, then...
Is there a way to pass foo_ around outside of main? I saw something about Boost in another question regarding functors. That looks like it may work. Here's the answer mentioning Boost in that question. If I can, I would like to avoid Boost.
#include <iostream>
int main()
{
class foo {
public:
void operator()() {
...
I'm looking for a tool (macro, extension) for Visual Studio 2008 that would reformat the source code (C/C++) when you save the file.
...
Possible Duplicates:
Autocompletion in Vim
Vim, Python, and Django autocompletion (pysmell?)
I don't know if that's the right word for it. When I use Ctrl+n in VIM to use autocomplete it doesn't do a very smart job of suggesting member functions or variables or what-have-you. Visual studio's intellisense makes suggestions that...
Hi, I am looking for a simple C++ library for making GUIs. I tried wxWidgets and GTK, but I think both are complex.
I want your opinion on what to use. Should I learn wxWidgets or you know a better one?
Thanks.
...
Hi! I am having a strange problem ( well, at least i find it strange =) ). I am writing my own GUI library, which is a wrapper around windows api (and yes, i am aware of WTL and frameworks like MFC =) ). At the current stage i have incapsulated common controls in such manner: for example, Edit class consists of a simple window and an sta...
I've written an ActiveX control using ATL. I used the wizard to add support for connection points which added public IConnectionPointContainerImpl<CActiveX> and CProxy_IActiveXEvents<CActiveX>, where the CProxy_... is the wizard generated code to fire events.
I've defined a dispinterface as follows:
[
uuid(43ECB3DF-F004-4FAD-...
The following issue popped up in my open source library, and I can't figure out what's going on.
Two of my users have (gcc) compiler errors that look like:
/home/someone/Source/src/._regex.cpp:1:1: warning: null character(s) ignored
/home/someone/Source/src/._regex.cpp:1: error: stray ‘\5’ in program
/home/someone/Source/src/._regex.cp...
Pimpl's are a source of boilerplate in a lot of C++ code. They seem like the kind of thing that a combination of macros, templates, and maybe a little external tool help could solve, but I'm not sure what the easiest way would be. I've seen templates that help do some of the lifting but not much -- you still end up needing to write forwa...
Hi
Is there a way to add new methods to a class, without modifying original class definition (i.e. compiled .lib containing class and corresponding .h file) like C#'s class extension methods?
...
The standard explicitly states that main has two valid (i.e., guaranteed to work) signatures; namely:
int main();
int main(int, char*[]);
My question is simple, would something like the following be legal?
int main(const unsigned int, const char* const* argv);
My tests say 'yes', but I'm unsure of the answer because am I not overlo...
Hello, I am not a very experienced C++ programmer, i get a warning when i do the following:
if (myString[i] != 'x')
{
}
what is the appropriate way to compare these?
thanks for your help!
...
Hi,
Since you 'should' learn C/C++ and as part of 'learn as much languages as possible', i decided to learn C++ in depth.
My OS is Windows and my question is should i re-install Linux as a dual boot to learn C++ on Linux?
Do i miss something if I develop in C++ only on the Windows platform?
(possible duplicate: http://stackoverflow.c...
I have made a program that has two threads, soon to be three, that is trying to get an image from a web cam from both threads at the same time. Is there a way to do this or is there a better way to do this? (using openCV 1.1)
...