![]() ![]() ![]() GDB allows you to do things like run the program up to a certain point then stop and print out the values of certain variables at that point, or step through the program one line at a time and print out the values of each variable after executing each line. GDB (GNU Debugger) is a debugger for C and C++. This is where Debuggers come to the rescue. This is too inefficient and a huge waste of time. And if you keep doing that repeatedly, you will have to recompile the code every single time you make a change. Now if you are stuck somewhere and you add a print statement you have to recompile the code. You are working on a large codebase and compiling the entire code takes like 3-4 mins. In our day-to-day programming scenarios, we often use the print statements (like console.log()) to debug. Can you guess it? Yes, finding where the error is in the first place.ĭebugging is the process of detecting and removing existing and potential errors (also called 'bugs') in a software code. ![]() But, even before fixing an error, we have a more daunting task. So as a developer we should know how to fix them. No matter how big or small the codebase is, errors and bugs are inevitable. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |