Compile-Time Errors

Compile-time errors in your program can be caused by a typing error or improper use of the language. Good compilers tell what you did wrong and point you to the exact place where you made the mistake. Occasionally, they can even suggest what you need to do to fix the error.

Punctuation Errors

While modern compilers try to find the line on which your bug appears, the absence of a semicolon or closing brace can confuse the compiler and you may find it pointing to a line that is otherwise fine. Beware of punctuation errors; they can be tricky to resolve.

You can test your compiler's reaction to an error by intentionally putting ...

Get SAMS Teach Yourself C++ in 10 Minutes SECOND EDITION now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.