Add mechanism for error handling.

Or rather, reporting.
Implement stack.