© Ray Lischner 2020
R. LischnerExploring C++20https://doi.org/10.1007/978-1-4842-5961-0_6

6. Error Messages

Ray Lischner1 
(1)
Ellicott City, MD, USA
 

By now you’ve seen plenty of error messages from your C++ compiler. No doubt, some are helpful and others are cryptic—a few are both. This Exploration presents a number of common errors and gives you a chance to see what kinds of messages your compiler issues for these mistakes. The more familiar you are with these messages, the easier it will be for you to interpret them in the future.

Read through Listing 6-1 and keep an eye out for mistakes.
 1 #include <iosteam>
 2 // Look for errors
 3 int main()
 4 [
 5   std::cout < "This program prints a table of squares.\n";
 6          "Enter the starting value ...

Get Exploring C++20: The Programmer's Introduction to C++ 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.