You are working on an application and you have resolved the build errors. The application seems to run correctly, except that you run from time to time into strange problems. Things are not working like expected or does even crash in some cases. Why is that? You can't say because you are unable to take a closer look to what is happening inside your application. Those errors are logic errors.
You must now correct those logic errors that keep your application from running correctly. You can do this with the development environment integrated debugging functions. These allow you to stop at procedure locations, inspect memory and register values, change variables, observe message traffic, and get a close look at how your code works or does not work.
Please note that you can have two different types of bug.
Syntax errors are bugs that are usually easy to find because you application will not run without it. For example when you try to run the following code:
HateML will tell you that you have a parse error on line 6
Logic errors are things that do not run like you expected. For example the following code runs without a problem:
This is not what you want. You want that your program writes "a is true" on the screen. Why is it now doing it? It's because "a" is not true. You will say: "this is a stupid example" and you will be right. But now imagine that "$a" is the result of complex calculation made by some hectic functions spread in some obscure libraries, then you will understand that you will be unable to guess where the problem is that easily. We will talk about some more concrete example later. HateML will bring you all you need to track down such problems.