Reworked implementation of custom error definition (unit tests and documentation updated as well)