removed Carp: no use
new feature: on_error callback option