Jump to ratings and reviews
Rate this book

C++ Gotchas: Avoiding Common Problems in Coding and Design

Rate this book
The professional programmer's guide to avoiding and correcting ninety-nine of the most common, destructive, and interesting C++ design and programming errors. Serves as an inside look at the more subtle C++ features and programming techniques. Softcover.

346 pages, Paperback

First published November 1, 2002

4 people are currently reading
43 people want to read

About the author

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
20 (37%)
4 stars
19 (35%)
3 stars
12 (22%)
2 stars
1 (1%)
1 star
1 (1%)
Displaying 1 - 6 of 6 reviews
Profile Image for Curtis Jensen.
503 reviews11 followers
September 6, 2016
Touches on some nice aspects of C++. Possibly a bit dated. I found the tone to often be belittling. It was full of phrases like programmers today often don't know... or inexperienced engineers ... I'm a little surprised some of it made it past the editors. But it would appeal to the egotistical software engineer.
Profile Image for Bart.
113 reviews
May 3, 2018

"This may well be the best C++ book I have ever read. I was surprised by the amount I learned."


--Matthew Wilson, Development Consultant, Synesis Software


"C++ Gotchas" is the professional programmer's guide to avoiding and correcting ninety-nine of the most common, destructive, and interesting C++ design and programming errors. It also serves as an inside look at the more subtle C++ features and programming techniques.


This book discusses basic errors present in almost all C++ code, as well as complex mistakes in syntax, preprocessing, conversions, initialization, memory and resource management, polymorphism, class design, and hierarchy design. Each error and its repercussions are explained in context, and the resolution of each problem is detailed and demonstrated.


Author Stephen Dewhurst supplies readers with idioms and design patterns that can be used to generate customized solutions for common problems. Readers will also learn more about commonly misunderstood features of C++ used in advanced programming and design. A companion Web site, located at http: //www.semantics.org, includes detailed code samples from the book.


Readers will discover: How to escape both common and complex traps associated with C++ How to produce more reusable, maintainable code Advanced C++ programming techniques Nuances of the C++ language


"C++ Gotchas" shows how to navigate through the greatest dangers in C++ programming, and gives programmers the practical know-how they need to gain expert status.

0321125185B10212002

Profile Image for Danien.
44 reviews
March 11, 2010
C++ is a powerful programming language that is also complicated. This book covers many of the foundational through advanced C++ concepts and features and the potential issues that commonly arise in their usage, even by advanced programmers. It provides advice on how to avoid these problems and solutions that lead to better overall code design.

This intermediate level book covers some advanced features of the language without a lot of hand-holding for beginners so you'll need to understand how C++ works.

The book is presented as a series of tips and makes a great reference. You should read through it at least once or twice but keep it on hand until you've mastered most of its techniques as you'll no doubt come across these issues from time to time.
Profile Image for Ettore Pasquini.
135 reviews121 followers
September 18, 2011
C++ is a language with a lot (too many) gotchas: that's why I find a book like this a treasure. It helped making me tolerate C++.
Displaying 1 - 6 of 6 reviews

Can't find what you're looking for?

Get help and learn more about the design.