Perf: Use `err.stack` without throwing if possible

Fixes #2.