Home > Guides > Programming > C/C++

Special Member Functions: Constructors, Destructors, and the Assignment Operator

Last updated Mar 1, 2004.

Objects are the fundamental unit of abstraction in object-oriented programming. In a broad sense, an object is a region of memory storage. Class objects have properties that are determined when the object is created. Conceptually, every class object has four special member functions: default constructor, copy constructor, assignment operator, and destructor. If these members are not explicitly declared by the programmer, the implementation implicitly declares them. This section surveys the semantics of the special member functions and their roles in class design and implementation.

Discussions

What is Required of a Move Constructor
Posted Jul 18, 2010 09:52 AM by alex14637
2 Replies
Bugzilla
Posted Nov 18, 2008 01:53 AM by cupu
2 Replies
i want c++ book through net
Posted Aug 23, 2007 11:13 PM by harivilu
3 Replies

Make a New Comment

You must log in in order to post a comment.

Related Resources

Danny KalevYves Smith: Suspicions that The Fed is manipulating Wall Street
By Danny KalevMay 24, 2010 No Comments

Yves Smith, the nom de plume of the creator of Naked Capitalism and one of the most savvy and respected members of the blogosphere. In professional life Yves is known as Susan Webber. Yves recently gave an interview to an Israeli financial newspaper in which she claims that a federal team unofficially called "the plunge protection team" is manipulating the stocks on Wall Street.

Danny KaleviPhone OS 4.0 SDK License Controversy
By Danny KalevApril 17, 2010 1 Comment

The much-discussed software development kit for the upcoming iPhone OS 4.0 says that native applications must be "originally written" in Objective C, C, or C++", forbidding developers from using any sort of "translation or compatibility layer." This legalese seems to rule out just about anything you can think of -- translating an application written in any other language to C++. However, this stern interpretation is probably exaggerated. Besides, when you consider the outcry and criticism with which Apple's license was greeted, you can't help but wondering where all these freedom of expression activists were when Sun -- and later Microsoft and Google -- imposed similar draconian restrictions on developers.

Danny KalevBjarne Stroustrups's Stevens Talk
By Danny KalevDecember 7, 2009 No Comments

On 2nd December Bjarne Stroustrup delivered a talk about the standardization process of C++0x at the Stevens institute. Here some of the key points from his talk.

See More Blogs

Informit Network