How can one handle a constructor that fails?, C/C++ Programming

How can one handle a constructor that fails?

Posted Date: 3/15/2013 5:15:55 AM | Location : United States





Q: How can one handle a constructor that fails?

A: Though throwing an exception. Constructors don''t contain a return type, so it''s not achievable to use return codes. The finest way to signal constructor failure is thus to throw an exception 

 

Posted by | Posted Date: 3/15/2013 5:16:18 AM


Related Discussions:- How can one handle a constructor that fails?, Assignment Help, Ask Question on How can one handle a constructor that fails?, Get Answer, Expert's Help, How can one handle a constructor that fails? Discussions

Write discussion on How can one handle a constructor that fails?
Your posts are moderated
Related Questions
#questio c++ program for drawing thick line

how to write a program for all the types of beam reactions

A virtual function permits derived classes to replace the implementation given by the base class. The compiler makes sure the replacement is always known as whenever the object in

creating a system having five process from p0 to p4 and five resource types. create the need matrix use the safe algorithm to test if the system is in safe mode.


Armed with your function from above, we can do some interesting things. For instance, any pixel where the offsets are both zero is a pit (lower than all surrounding points) .

What is memory allocation? Memory Allocation : It is the method of allocating memory storage to program in such that the program can be run.

Define One's Complement Operator? The one's complement operator, occasionally called the "bitwise NOT" or "bitwise complement" operator produces the bitwise one's complement of

Write a Program that illustrate Command Line Parameters? main(int argc, char *argv[]) { int i; for(i = 0; i printf("arg %d: %s\n", i, argv[i]); return 0; }

how to make basics strong and best logic skills what are the best way to be a expert programmer ? what counts a lot knowledge or practice?