Is there any advantage of using watch instead of break point to debug code? Which?
When you have to check the value of five variables at once, or the state of the instance that executes your logic, or properties properties properties of properties of properties of properties of properties, you will notice the value of watch
.
Is there any situation where the use of watch and only it is really necessary?
You’ll never be able to use watch
if not in debug mode. The closest thing to this, when you are not in debug mode, is to use some form of log to store a history of variable values as the code is executed. But this generates junk in storage over time.