First  |  Prev |  Next  |  Last
Pages: 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
Types in template functions.
Let consider the function template <typename T> void check_const( T i ) { ++i; } If then it will be called such a way check_const<const int>( 0 ); the compiler ( VC++ 2005 EE) issue the error "error C3892: 'i' : you cannot assign to a variable that is const" However if it will be c... 7 Dec 2009 08:29
mempcpy and uname
Hi all, I would like to know if there are Windows-equivalent functions for mempcpy() and uname(). I'm using VS .NET 2003. Thank you. ... 7 Dec 2009 08:29
An exception that throws while it is being thrown, no terminate?
When the copy-constructor of an object throws an exception while the object itself is being thrown, I'd expect std::terminate to be called. But it doesn't seem to happen! At least, not when I use Visual C++. I've tried both VC 2008 and VC 2010 Beta 1. Is that a known compiler bug? I can't find it at https://co... 7 Dec 2009 12:56
Changing file attributes, Windows Explorer way.
There are many sample codes to change attributes of multiple files using some Windows API. As you should know, Windows Explorer can do this too. As for Windows 7, it shows a nice progress bar dialogue when applying the change to multiple files, or reports errors if access is denied and so on. Instead of implementin... 2 Dec 2009 01:05
Type cast problem with VC++ 2005 Express Edition
The following code compiles (and runs) OK with VC++ 6. std::vector<bool> smallsieve; smallsieve.reserve(smsize+1); memset(smallsieve.begin(), true, smsize+1); However I get the following error for the memset line. 1>c:\users\aslan\documents\visual studio 2005\projects\projecteuler\projecteuler\pro... 7 Dec 2009 08:29
Owner drawn listbox problem
I am looking for a listbox with items like this http://img209.imageshack.us/img209/1418/fileitem.jpg I have created an owner drawn listbox to achieve similar results I am currently dividing LPDRAWITEMSTRUCT::rcItem into two rectangles inside the DrawItem. The first rectangle holds the black text and seco... 25 Nov 2009 13:50
will global variable for class type be initialized at declaration?
hi, if i have a local variable as A a; in a class. I declare it in header and define/intialize it in the cpp file, normally. If I declare it as a global variable in my project, will that be initialized at the point of declaraion? thanks ... 20 Nov 2009 15:44
VS: operator <<(...const std::string&) does not call ->rdbuf()
"Victor Bazarov" wrote: Paul wrote: As I understand from the C++ Standard, operator std::ostream& operator <<(std::ostream& os, const std::string& s); should call os.rdbuf()->sputn() I don't see the Standard saying that it "should". I see "inserts characters as if by calling ... 18 Nov 2009 06:45
Question about the getline method...
Hello, The intent of the following code is to read the first 2 characters from each line until EOF is reached. It does this correctly on the first line but stores an empty string for all subsequent lines. Of course I an accomplish this task in other ways but I was wondering why this approach didn't work. ... 15 Nov 2009 18:56
What is the share mode fopen() uses?
Hi, I know this is an old method but does some one know what is the share mode, if any, fopen() uses? I know there is a _sopen() or _tsopen() that allows one to specify the share option. Thanks. Leon ... 14 Nov 2009 11:09
First  |  Prev |  Next  |  Last
Pages: 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32