From charlesreid1

Revision as of 05:21, 1 June 2017 by Admin (talk | contribs) (Created page with "=basics= ==caught vs uncaught== The main difference in exceptions is caught versus uncaught exceptions. http://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentE...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

basics

caught vs uncaught

The main difference in exceptions is caught versus uncaught exceptions.

http://docs.oracle.com/javase/8/docs/api/java/lang/IllegalArgumentException.html

https://stackoverflow.com/questions/22952140/about-throwing-illegalargumentexception

When an unhandled exception occurs, the program terminates up the call stack -

Illustrating the stack

The Python debugger Pdb shows a better way of "inspecting"/instrumenting the stack easily, and is much more natural to do in an interpreted language. But many of the same concepts hold true in debugging a compiled language. Although things... get weird fast.

The optimal way to run and inspect a program is to run a process, stop it with a debugger insertion call, attach gdb or some other debugger, and continue the process under the control of the debugger, which allows you to explore the process in real time. Alternatively, you can "manage" the execution of the program from some other kind of automated hypervisor, not just a debugger, to make instrumentation of programs much more flexible.