When i throw this object,how several times will it be copied, C/C++ Programming

A: Depends. Might be "zero"

Objects which are thrown must have a publicly accessible copy-constructor. The compiler is permitted to generate code which copies the thrown object any number of times, by including zero. Though even if the compiler never in fact copies the thrown object, it has to make sure the exception class's copy constructor presents and is accessible.

 

Posted Date: 3/19/2013 8:53:10 AM | Location : United States







Related Discussions:- When i throw this object,how several times will it be copied, Assignment Help, Ask Question on When i throw this object,how several times will it be copied, Get Answer, Expert's Help, When i throw this object,how several times will it be copied Discussions

Write discussion on When i throw this object,how several times will it be copied
Your posts are moderated
Related Questions

c program for padovan string   Padovan series are positive integers obtained by the following process: The Padovan series is the sequence of integers P(n) defined by the

We have used logic symbols in the past, but not really though about the actual real devices. Semiconductor companies have taken the logic symbols are manufactured them into logic f

Aim: To implement a program to maintain information of employees in an educational institute using inheritance. Code:                       class staff {

Implementation of the Stack class in C++: How to implement stack class in c++. int Stack::push(int elem) {    if (top    {       list[top++] = elem;       r

A: no, can't. The names of, precedence of, associativity of, and arity of operators is fixed through the language. In C++, there is no operator** so you cannot create one for a

Memory management by c program: Write a program to memory management in c program unsigned max( unsigned, unsigned );   int BaseMemBlocks::allocBlock( size_t sz )

Program to design text styles: Write a C program to design different text style char *fname[] = { "DEFAULT font",                                   "TRIPLEX font",

Construct a console program to manage the booking of a Hotel room.

A: C++, unlike only about every other language with exceptions, is extremely accomodating while it comes to what you can throw. Actually, you can throw anything you akin to. That b