| |
thread by: Jeremy Cowles |
last post Jul 19 '05 by: Jeremy Cowles
I have the following:
int *array = new int;
and I destroy it with:
delete array;
|
thread by: sam |
last post Jul 19 '05 by: Paul Thompson
For Example, If I delete two times like the below code, the program will
behave differently. is this correct?
As C++ FAQ the delete checks where or not f1 has memory. How can the
following program can go wrong?
class foo{
//
};
int main{
foo *f1 = new foo()
|
thread by: |
last post Jul 19 '05 by: Mike Smith
Java has packages (libraries) for everything. EVERYTHING.
Instead, C++ is too poor in its classes.
Is there a concept to extend C++ with other standard libraries, about
multithreading, socket programming etc?
I do not speak about libraries programmed only in one platform (e.g. MFC)
but about standard C++ libraries.
|
thread by: Christian |
last post Jul 19 '05 by: Vinay Doma
Hi all,
I have an application with a GUI in Tcl/Tk (running on AIX /Linux) and
I need to make it running (porting) in Windows 2000.
I would like to have some suggestion about this.
What IDE should I use to recreate the GUI, is VisualC++ good enough?
Or may be the Tcl/Tk could be compatible for Microsoft VisualC++, just
some modification...
|
thread by: prettysmurfed |
last post Jul 19 '05 by: prettysmurfed
Hi all
I have a bit of a problem, the subject of this post is almost selfexplaing.
But here goes: Heres an example of the code I want to implement, its
all nice and simple, but the flaw is I can't seem to get the adress of the
member function stated properly in the DialogBox function. I thought it
was enough to write it as Dialog::DlgProc,...
|
thread by: Jacek Dziedzic |
last post Jul 19 '05 by: Alf P. Steinbach
.... making things like
#endif // of the "#ifdef DEBUG" part
valid? Or not?
- J.
|
thread by: Ales DOLECEK |
last post Jul 19 '05 by: Rob Williscroft
Hello,
few days ago I asked how to grant firend status to template. Thanks to
Rob Williscroft for his help. Now I have run into problems while using
class derived from the class created by the template. I'll try to give
part of code leaving out unnecesarry things.
---- base ----
template <typename T> class ptr_t;
|
| |
thread by: Dhruv |
last post Jul 19 '05 by: Dhruv
I was wondering if anyone could compile this code for me on VC.
The problem that I've run into is that VC++6 does not support templates
fully, and so, I cannot get this to compile, which relies heavily on
templates. So, if someone can compile the explicit specialication for me
with VC++7, and then I could try to use it in VC++6 (probably),...
|
thread by: Rajesh Garg |
last post Jul 19 '05 by: Victor Bazarov
Can we have private constructors and destructors? IF yes what is the
use of such constructors or destructors.....in the sense where can
these be implemented in a system.................
I have an idea that we can have private constructors and destructors
but am not able to find a situation where they can be used...
Regards
RVG...
|
thread by: Paul Woodward |
last post Jul 19 '05 by: Anthony Albert Nassar
I am new to programming in the C / C++ language and I am using a mixture of
online materials plus a small collection of C and C++ books.
What I basically want to know is how do I know if something I am learning is
from the C Language or the C++ Language and should I avoid mixing the two.
I am under the impression that C++ is the successor...
|
thread by: BCC |
last post Jul 19 '05 by: David White
Hi,
If I have something like this:
CMyClass* p1;
CMyClass* p2;
I know I can do:
p1 = new CMyClass();
p2 = p1;
|
thread by: Bonzo |
last post Jul 19 '05 by: Bonzo
Another smart pointer problem. I have a tree structure. The idea is for
parents to have SmartPtr's to the children, with children holding a weak
pointer (WeakPtr) back to the parent. That's great, but how do I
implement the link from child to parent?
Here's where the problem occurs:
SmartPtr<ContainerNode>
ContainerNode ::...
|
thread by: Peter _Grafenberger |
last post Jul 19 '05 by: Keith A. Lewis
hi,
i've some troubles compiling Bjarne Strostrup's Matrix class example
http://www.research.att.com/~bs/matrix.c
under ms visual c++ 6.0 (sp4). i get a lot off errors like
matrix_klasse_by_stroustup.cxx(37) : error C2143: Syntaxfehler :
Missing ';' before '<'
|
thread by: Davis King |
last post Jul 19 '05 by: Davis King
I'm trying to make a stream buffer which reads from a socket and it
works fine in visual stuiod, borland 5.5.x and g++ 3.2.x but
I get an infinite loop in g++ 3.0.4! I imagine it's somehow my fault
though :)
So I have implemented overflow, xsputn, underflow, uflow, pbackfail and
xsgetn. I haven't made any buffers as I just
want it to...
|
thread by: qazmlp |
last post Jul 19 '05 by: qazmlp
How do you check whether an std::string object contains only printable characters ?
|
| |
thread by: Xah Lee |
last post Jul 19 '05 by: Albert Lai
Dear functional programing comrades,
Among the community of automatons of the IT industry, there is a
popular quote about "theory vs practice" that goes something along the
lines of "in theory this, but in practice that", which is often quoted
by automatons to slight at computer science principles or
practice. (especially by perl or unix...
|
thread by: Peter Tawdross |
last post Jul 19 '05 by: Wellu Mäkinen
Hello
I need (at work) to create any type of movies, i have set of frames, but i
don't know how to use them to create a movie.
Peter Tawdross
|
thread by: qazmlp |
last post Jul 19 '05 by: John Harrison
How do you check whether an std::string object contains only printable characters ?
|
thread by: Chris E. Yoon |
last post Jul 19 '05 by: Michiel Salters
I just want to hear people's opinions on this subject.
My application has lots and lots of short-lived objects that use
dynamic allocation/deallocation. After implementing its functionality,
I found out that much processing is spent for new/delete calls.
So, to improve its performance, I made a little factory-like class that
pre-'new's...
|
thread by: Pani |
last post Jul 19 '05 by: Alexander Terekhov
Hi
I am new to C++ ,i really dont understand why there is a need for
VTable and can some experts give an example where exactly and how a compiler
uses it
Regards
Pani
|
thread by: Jeff Cheng |
last post Jul 19 '05 by: Alf P. Steinbach
Can anybody help to trace the runtime error for the following code
about sub-Linked list.
Thank you,
# include <stdio.h>
# include <stdlib.h>
typedef char *CategoryType;
|
thread by: Teddy |
last post Jul 19 '05 by: Lars Magne Engedal
I have installed GNU C/C++ on my Linux and tried to compile my first
helloworld program. I tried this with the command:
cc helloworld.cpp -c -o helloworld.o && ld helloworld.o -lstdc++ -o
helloworld
And got the Error:
ld: warning: cannot find entry symbol _start; defaulting to 08048380
|
thread by: Sheema |
last post Jul 19 '05 by: Sheema
Can you please help me with this problem:
I want my program, put a number of "int" data in a vector, after reading
them from another file.
Probably i should use "push_back" property...but i need to know the exact
syntax for this case...
Thanks
Sh.
|
| |
thread by: ishekar |
last post Jul 19 '05 by: ishekar
Hi,
class A
{
public:
virtual void x(){cout<<"inside A"<<endl;};
}
class B : public A
{
|
thread by: TF |
last post Jul 19 '05 by: Peter van Merkerk
I have a fixed array of vectors like:
vector<string> a_vStr;
Then I grow each vector item and use it later. Everything works fine
but I am curious about following potential problem.
When we grow a vector it may copy all of its elements to different
memory location to accomodate the new vector size. Is it possible that
at some point an...
|