You are here

Resolving Errors

19 January, 2016 - 11:41

Despite our best eforts at becoming perfect programmers, we will create errors. Solving these errors is known as debugging your program. The three types of errors in the order that they occur are:

  1. Compiler
  2. Linker
  3. Logic

There are two types of compiler errors; pre-processor (1st step) and conversion (2nd step). A review of Figure 1 above shows the four arrows returning to the source code so that the programmer can correct the mistake.

During the conversion (2nd step) the complier might give a warning message which in some cases may not be a problem to worry about. For example: Data type demotion may be exactly what you want your program to do, but most compilers give a warning message. Warnings don't stop the compiling process but as their name implies, they should be reviewed.

The next three fgures show IDE monitor interaction for the Bloodshed Dev-C++ 5 compiler/IDE.

media/image4.png
Figure 5.2 Compiler Error (the red line is where the complier stopped)  
media/image5.png
Figure 5.3 Linker Error (no red line with an error message describing linking problem)  
media/image6.png
Figure 5.4 Logic Error (from the output within the "Black Box" area)